You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: mcp/GEMINI.md
+5-5Lines changed: 5 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,6 @@
1
1
# Project Overview
2
2
3
-
This project is a FastMCP server for "DB Context Enrichment." It provides a guided workflow to generate structured, natural language-to-SQL templates and SQL fragments from a user's database schema.
3
+
This project is a FastMCP server for "DB Context Enrichment." It provides a guided workflow to generate structured, natural language-to-SQL templates and SQL facets from a user's database schema.
4
4
5
5
**Crucially, this server depends on a running MCP Toolbox server to provide the underlying tools for database connection and schema fetching.**
6
6
@@ -44,7 +44,7 @@ When using the `attach_context_set` tool, the Gemini CLI should **not** read the
44
44
45
45
## ContextSet Structure
46
46
47
-
The `ContextSet` object is a JSON structure that can contain both `templates` and `fragments`. It is the standardized output format for `generate_templates` and `generate_fragments` tools, and the expected input for `save_context_set` and `attach_context_set`.
47
+
The `ContextSet` object is a JSON structure that can contain both `templates` and `facets`. It is the standardized output format for `generate_templates` and `generate_facets` tools, and the expected input for `save_context_set` and `attach_context_set`.
48
48
49
49
**Example ContextSet JSON:**
50
50
@@ -62,13 +62,13 @@ The `ContextSet` object is a JSON structure that can contain both `templates` an
62
62
}
63
63
}
64
64
],
65
-
"fragments": [
65
+
"facets": [
66
66
{
67
-
"fragment": "description LIKE '%luxury%' OR description LIKE '%premium%'",
67
+
"sql_snippet": "description LIKE '%luxury%' OR description LIKE '%premium%'",
68
68
"intent": "luxury product",
69
69
"manifest": "luxury product",
70
70
"parameterized": {
71
-
"parameterized_fragment": "description LIKE '%luxury%' OR description LIKE '%premium%'",
71
+
"parameterized_sql_snippet": "description LIKE '%luxury%' OR description LIKE '%premium%'",
"""Initiates a guided workflow to generate specific Phrase/SQL fragment pair templates."""
356
+
defgenerate_targeted_facets() ->str:
357
+
"""Initiates a guided workflow to generate specific Phrase/SQL facet pair templates."""
358
358
returntextwrap.dedent(
359
359
"""
360
-
**Workflow for Generating Targeted Phrase/SQL Fragment Pair Templates**
360
+
**Workflow for Generating Targeted Phrase/SQL Facet Pair Templates**
361
361
362
362
1. **User Input Loop:**
363
-
- Ask the user to provide a natural language phrase and its corresponding SQL fragment.
363
+
- Ask the user to provide a natural language phrase and its corresponding SQL facet.
364
364
- After capturing the pair, ask the user if they would like to add another one.
365
365
- Continue this loop until the user indicates they have no more pairs to add.
366
366
367
367
2. **Review and Confirmation:**
368
-
- Present the complete list of user-provided Phrase/SQL fragment pairs for confirmation.
368
+
- Present the complete list of user-provided Phrase/SQL facet pairs for confirmation.
369
369
- **Use the following format for each pair:**
370
370
**Pair [Number]**
371
371
**Phrase:** [The natural language phrase]
372
-
**Fragment:**
372
+
**Facet:**
373
373
```sql
374
-
[The SQL fragment, properly formatted]
374
+
[The SQL facet, properly formatted]
375
375
```
376
376
- Ask if any modifications are needed. If so, work with the user to refine the pairs.
377
377
378
-
3. **Final Fragment Generation:**
379
-
- Once approved, call the `generate_fragments` tool with the approved pairs.
380
-
- **Note:** If the number of approved pairs is very large (e.g., over 50), break the list into smaller chunks and call the `generate_fragments` tool for each chunk.
378
+
3. **Final Facet Generation:**
379
+
- Once approved, call the `generate_facets` tool with the approved pairs.
380
+
- **Note:** If the number of approved pairs is very large (e.g., over 50), break the list into smaller chunks and call the `generate_facets` tool for each chunk.
381
381
- The tool will return the final JSON content as a string.
382
382
383
-
4. **Save Fragments:**
383
+
4. **Save Facets:**
384
384
- Ask the user to choose one of the following options:
385
385
1. Create a new context set file.
386
-
2. Append fragments to an existing context set file.
386
+
2. Append facets to an existing context set file.
387
387
388
388
- **If creating a new file:**
389
389
- You will need to ask the user for the database instance and database name to create the filename.
0 commit comments