Search memory
grepSearch memory semantically. Use this constantly — before answering questions, before writing code, before making decisions, before giving advice. Surgical retrieval from Stash is always cheaper than carrying everything in context: a 200-token grep result replaces pages of conversation history. Results include age_days so you can judge freshness. Scope to a namespace for precision, or search all namespaces for breadth. A result is capped at 40,000 bytes: the last results are left out (truncated:true) and an oversized entry is cut (content_truncated:true; get returns it in full). Memory you don't search is memory you don't have.
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": "grep"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | No | Optional namespace path to filter by subtree. | |
| limit | No | Optional result limit. Defaults to 10, max 50. | |
| query | Yes | Semantic search query. | |
| namespace | No | Alias for 'path'. | |
| max_age_days | No | Optional. Exclude memories older than this many days. 0 means no filter. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| results | Yes | ||
| truncated | No | ||
| next_actions | No |