retrieve_context
Search a knowledge base and retrieve formatted results with source citations for LLM context building. Supports filters to refine results.
Instructions
Search and return results formatted for LLM context building.
Args: query: Natural language query. k: Number of results (max 20). filters: Optional JSON string of filter conditions.
Returns: Formatted string with source citations.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"query": "<query>"
},
"name": "retrieve_context"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| k | No | ||
| query | Yes | ||
| filters | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |