@@ -13,7 +13,7 @@ MongoDB Github Copilot Participant
13
13
:class: singlecol
14
14
15
15
16
- |vsce-full| automatically includes a MongoDB Github Copilot Participant
16
+ |vsce-full| includes a MongoDB Github Copilot Participant
17
17
to assist in using Copilot with your MongoDB deployments. Through
18
18
Copilot's chat feature, users with |vsce| can interact their MongoDB
19
19
clusters and generate code with MongoDB domain-specific knowledge on top
@@ -22,15 +22,18 @@ of VSCode Copilot's LLM.
22
22
/query
23
23
------
24
24
25
- Users can use the ``/query`` command to generate queries from a natural
26
- language against a connected MongoDB cluster. The MongoDB Participant
27
- provides underlying schema information of the relevant collections and
28
- MongoDB domain specific knowledge to Copilot to generate a response.
25
+ Users can use the ``/query`` command in the Copilot chat to
26
+ generate queries from a natural language against a connected MongoDB
27
+ cluster. The MongoDB Participant provides underlying schema information
28
+ of the relevant collections to Copilot to generate a response. If you do
29
+ not specify a collection in your prompt to Copilot, the MongoDB
30
+ Participant prompts you to select a relevant collection.
31
+
29
32
When the LLM generates a query, users can open the query in a playground
30
33
file or run the query directly in their collection.
31
34
32
- /query Example
33
- ~~~~~~~~~~~~~~
35
+ Example
36
+ ~~~~~~~
34
37
35
38
Consider a ``fruits`` collection that contains documents with the
36
39
following structure:
@@ -44,10 +47,9 @@ following structure:
44
47
type: "citrus"
45
48
}
46
49
47
-
48
- In the Github Copilot Chat tab, you can ask the MongoDB Copilot
49
- participant to generate a query to find all documents in the ``fruits``
50
- collection that have the type ``citrus``.
50
+ Once you connet to the databse that contains the ``fruits`` collection,
51
+ you can ask the Copilot chat to generate a query that finds all documents
52
+ in the ``fruits`` collection that have the type ``citrus``.
51
53
52
54
.. code-block:: javascript
53
55
:copyable: false
@@ -60,11 +62,12 @@ the following query using knowledge of your database schema:
60
62
61
63
.. code-block:: javascript
62
64
63
- use('fruits');
64
- db.getCollection('fruits').find({ type: 'citrus' });
65
-
65
+ db.getCollection('fruits').find({ type: 'citrus' })
66
66
67
67
68
+ .. toctree::
69
+ :titlesonly:
68
70
71
+ /ai-data-usage
69
72
70
73
0 commit comments