get_targeted_context
Retrieve a minimal context pack for a query by using the knowledge graph as an index. Reads only the smallest relevant slices of Memory Bank files, avoiding full document dumps. Ideal for targeted questions.
Instructions
Returns a budgeted, minimal "context pack" for a query by using the knowledge graph as an index. Reads only the smallest relevant slices of Memory Bank files instead of dumping full documents. Prefer this over get_context_bundle or batch_read_files for most questions.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| query | Yes | Search query to find relevant context | |
| maxChars | No | Hard ceiling for entire payload in characters (default: 8000) | |
| maxFiles | No | Maximum number of files to excerpt (default: 4) | |
| graphLimit | No | Maximum number of KG entity hits (default: 6) | |
| graphDepth | No | Neighborhood expansion depth (1 or 2, default: 1) | |
| preferActiveContext | No | Prioritize core Memory Bank files in pointer ranking (default: true) |