show_memory_path
Retrieve the absolute path of the active knowledge-graph file to enable structured reasoning and persistent memory access for AI assistants in complex problem-solving tasks.
Instructions
Return absolute path of the active knowledge-graph file.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| random_string | No | Dummy parameter for no-parameter tools |
Input Schema (JSON Schema)
{
"$schema": "http://json-schema.org/draft-07/schema#",
"additionalProperties": false,
"properties": {
"random_string": {
"description": "Dummy parameter for no-parameter tools",
"type": "string"
}
},
"type": "object"
}
Implementation Reference
- src/utils/tools.ts:17-21 (handler)The tool handler function that returns the JSON-stringified path to the memory file, using the MEMORY_PATH environment variable or a default path in the user's home directory.execute: async (_args, { log }) => { const memoryPath = process.env.MEMORY_PATH || path.join(os.homedir(), '.mcp-think-tank/memory.jsonl'); // Removed debug log return JSON.stringify(memoryPath); }
- src/utils/tools.ts:14-16 (schema)Zod schema defining the optional dummy input parameter for the tool.parameters: z.object({ random_string: z.string().describe("Dummy parameter for no-parameter tools").optional() }),
- src/utils/tools.ts:11-22 (registration)Registration of the show_memory_path tool in the registerUtilityTools function.server.addTool({ name: 'show_memory_path', description: 'Return absolute path of the active knowledge-graph file.', parameters: z.object({ random_string: z.string().describe("Dummy parameter for no-parameter tools").optional() }), execute: async (_args, { log }) => { const memoryPath = process.env.MEMORY_PATH || path.join(os.homedir(), '.mcp-think-tank/memory.jsonl'); // Removed debug log return JSON.stringify(memoryPath); } });
- src/core/tools.ts:28-28 (registration)Invocation of registerUtilityTools during overall tool registration, which includes show_memory_path.registerUtilityTools(server);