Skip to main content
Glama

setup_ai_memory

Configure persistent AI memory for projects by setting up a 3-layer system that automatically saves lessons and recalls solutions before tasks.

Instructions

One-shot setup of the cachly 3-layer AI Memory system for a project.

Layer 1 — Storage: your cachly instance (Valkey, persistent across sessions) Layer 2 — Tools: learn_from_attempts + recall_best_solution + smart_recall (the memory API) Layer 3 — Autopilot: generates a copilot-instructions.md / .github/copilot-instructions.md that instructs any MCP-compatible AI to recall known solutions BEFORE each task and save lessons AFTER — fully automatic, zero manual effort.

Returns the copilot-instructions.md content + provider-specific .mcp.json snippet. Optionally writes copilot-instructions.md directly to the project directory.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
instance_idYesUUID of the cachly instance to use as the AI brain
project_dirNoAbsolute path to the project root. If provided, writes copilot-instructions.md to .github/copilot-instructions.md in that directory.
embed_providerNoEmbedding provider to use for smart_recall / semantic search. Default: openai. Use ollama for fully local/free setup.
project_descriptionNoShort description of the project (used in the generated instructions)
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the full burden. It discloses key behavioral traits: it's a 'One-shot setup' (implying idempotent configuration), it writes files optionally, and it returns content and snippets. However, it lacks details on permissions, side effects (e.g., file overwriting), error handling, or performance, which are important for a setup tool with potential file system interactions.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is appropriately sized and front-loaded: the first sentence states the core purpose, followed by a structured breakdown of layers and outputs. Every sentence earns its place by explaining the system components and optional behaviors without redundancy or fluff.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's complexity (setup of a multi-layer system with 4 parameters) and lack of output schema, the description is mostly complete: it explains what the tool does, the layers involved, and the outputs. However, it could be more complete by detailing error cases or the format of returned content, which would help an agent handle results better.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so the schema already documents all parameters well. The description adds minimal value beyond the schema by implying that 'project_dir' is used for writing files and 'embed_provider' affects 'smart_recall,' but it doesn't provide additional syntax or format details. With high schema coverage, the baseline is 3, but the slight contextual boost justifies a 4.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description explicitly states the tool's purpose as 'One-shot setup of the cachly 3-layer AI Memory system for a project,' which is a specific verb ('setup') + resource ('AI Memory system') + scope ('for a project'). It clearly distinguishes this from sibling tools like 'create_instance' (which likely creates instances) or 'learn_from_attempts' (which is part of the memory API), as this tool configures the entire system rather than performing individual operations.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides clear context for when to use this tool: for setting up the AI Memory system in a project, including generating copilot instructions. However, it does not explicitly state when not to use it or name alternatives among the many sibling tools (e.g., vs. using 'create_instance' or 'index_project' separately), which prevents a score of 5.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/cachly-dev/cachly-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server