Skip to main content
Glama

engrim_add

Save durable project memories to local SQLite storage for cross-session persistence. Record architectural decisions, facts, user constraints, and milestones for later retrieval.

Instructions

Write operation: Save a durable memory record to local SQLite storage so it persists across sessions and agent restarts. Call this whenever a non-trivial architectural choice, durable fact, user constraint, or state milestone is established. Appends a new record to the project memory database.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
tagsNoOptional list of categorical string tags (e.g. ['auth', 'api']).
typeYesCategory of memory: 'decision' (architectural choices), 'fact' (project truths), 'feedback' (user preferences), 'state' (progress milestones), 'reference' (external links), or 'user' (durable user constraints).
detailNoOptional detailed explanation, context, trade-offs, or rationale.
globalNoIf true, stores in the global user-layer (~/.engrim/memory.db) accessible across all projects.
projectNoProject identifier tag; 'auto' infers from current working directory repository root.auto
summaryYesConcise one-line headline summarizing the record.
origin_agentNoOrigin agent identifier for provenance tracking.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
idYes
typeYes
projectYes
summaryYes
origin_agentYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changedv1.4.11
    • changedInput schema / properties / origin_agent / description
      Previous value: -"Origin agent identifier for provenance tracking ('antigravity', 'claude-code', 'cursor', 'cli', 'user')."New value: +"Origin agent identifier for provenance tracking."
    • changedInput schema / properties / origin_agent / enum
      Previous value: -[
      -  "antigravity",
      -  "claude-code",
      -  "cursor",
      -  "opencode",
      -  "cli",
      -  "user"
      -]New value: +[
      +  "antigravity",
      +  "claude-code",
      +  "cursor",
      +  "codex",
      +  "opencode",
      +  "copilot",
      +  "cli",
      +  "user"
      +]
  2. Changed2 schema fields changedv1.4.6
    • changedInput schema / properties / origin_agent / enum
      Previous value: -[
      -  "antigravity",
      -  "claude-code",
      -  "cursor",
      -  "cli",
      -  "user"
      -]New value: +[
      +  "antigravity",
      +  "claude-code",
      +  "cursor",
      +  "opencode",
      +  "cli",
      +  "user"
      +]
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "description": "Confirmation identifying the stored record.",
      +  "properties": {
      +    "id": {
      +      "type": "integer"
      +    },
      +    "origin_agent": {
      +      "type": "string"
      +    },
      +    "project": {
      +      "type": "string"
      +    },
      +    "summary": {
      +      "type": "string"
      +    },
      +    "type": {
      +      "type": "string"
      +    }
      +  },
      +  "required": [
      +    "id",
      +    "type",
      +    "project",
      +    "summary",
      +    "origin_agent"
      +  ],
      +  "type": "object"
      +}
  3. Changed7 schema fields changedv1.4.2
    • changedInput schema / properties / detail / description
      Previous value: -"Optional longer body / the why."New value: +"Optional detailed explanation, context, trade-offs, or rationale."
    • changedInput schema / properties / global / description
      Previous value: -"Write to the global user-layer that loads in every project."New value: +"If true, stores in the global user-layer (~/.engrim/memory.db) accessible across all projects."
    • changedInput schema / properties / origin_agent / description
      Previous value: -"Origin agent identifier for provenance tracking."New value: +"Origin agent identifier for provenance tracking ('antigravity', 'claude-code', 'cursor', 'cli', 'user')."
    • addedInput schema / properties / project / description
      Added value: +"Project identifier tag; 'auto' infers from current working directory repository root."
    • changedInput schema / properties / summary / description
      Previous value: -"One-line headline for the record."New value: +"Concise one-line headline summarizing the record."
    • addedInput schema / properties / tags / description
      Added value: +"Optional list of categorical string tags (e.g. ['auth', 'api'])."
    • addedInput schema / properties / type / description
      Added value: +"Category of memory: 'decision' (architectural choices), 'fact' (project truths), 'feedback' (user preferences), 'state' (progress milestones), 'reference' (external links), or 'user' (durable user constraints)."
  4. First observedv0.1.0

TDQS

A3.8/5.0
Behavior3/5

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

With no annotations, the description carries the full behavioral burden. It discloses persistence across sessions/restarts, append-only behavior, and local SQLite storage. However, the final sentence 'Appends a new record to the project memory database' ignores the `global` parameter which can redirect storage to a user-layer database, making the statement slightly incomplete or misleading.

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 three sentences, each carrying distinct value: what it does, when to call it, and append behavior. No filler or redundancy, and the key operation is front-loaded.

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?

For a simple write tool with a full schema and output schema present, the description covers the essential aspects: operation type, persistence, and invocation conditions. The only notable omission is not acknowledging the `global` storage option, but that is documented in the schema, so the description is still sufficiently complete.

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

Parameters3/5

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

Schema coverage is 100% – every parameter (type, summary, tags, detail, global, project, origin_agent) is described in the schema. The description adds no additional parameter semantics, which is appropriate given the high coverage; baseline 3 applies.

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

Purpose4/5

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

Description states a specific verb and resource: 'Save a durable memory record to local SQLite storage' and opens with 'Write operation', which contrasts with read-like siblings. However, it does not explicitly name sibling tools or explain how this differs from engrim_context or engrim_recall beyond the write semantics.

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?

Provides explicit trigger conditions: 'Call this whenever a non-trivial architectural choice, durable fact, user constraint, or state milestone is established.' It does not mention when not to use it or name alternative tools like engrim_recall for retrieval, so it falls short of a full 5 but is clear on the primary use case.

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

Deploy Server

Other Tools