Skip to main content
Glama

mcp_engram_safe_edit_and_verify

Safe composite for editing code in crates/, docs/, or processes/: combines context, trace, verification, and lineage checks. Returns trace_id, arc_concept, crs_delta, and reflection.

Instructions

SAFE composite for code edits: context_for_edit + quick_trace + optional __arc update + verify_manifold + lineage check + tensor edit_pattern bond. Prefer this over ad-hoc context_for_edit when changing crates/, docs/, or processes/. Returns trace_id, arc_concept, crs_delta, reflection_suggested. FEW-SHOT EXAMPLES: (1) Pre+post edit with arc delta: {"path":"/home/user/Engram/crates/engram-server/src/mcp.rs","decision":"Add safe_edit composite tool","why":"Agent tool fidelity goal — one-shot verified edit path","arc_delta":"delta: registered mcp_engram_safe_edit_and_verify handler","goal_context":"goal:agent_tool_fidelity_v1"} (2) Intent-only trace before external editor edit: {"path":"/home/user/Engram/docs/AGENT_MEMORY_CONTRACT.md","decision":"Refresh 8-tool examples","why":"Mirror hardened few-shots in docs","run_verify":true}

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
whyYesJustification for the edit
pathYesAbsolute file path to edit (required)
decisionYesEdit intent — one clear sentence
arc_deltaNoOptional delta narrative appended to first spatial __arc
prev_traceNoOptional prev_in_trace chain head
run_verifyNoRun sampled verify_manifold_integrity (default true)
goal_contextNoOptional goal:* this edit serves
Behavior2/5

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

No annotations exist, so description bears full burden. It mentions edits and returns, but fails to explicitly state that the tool modifies files on disk or disclose any side effects, authorization needs, or safety guarantees beyond the vague 'SAFE' label.

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

Conciseness4/5

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

Front-loaded with key purpose and suboperation list. Examples are useful but lengthy; could be more concise. Overall structure is logical: purpose, usage, returns, examples.

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

Completeness3/5

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

Covers purpose, usage, returns, and examples. Missing explicit statement about side effects (file modification) and prerequisites (file must exist). For a composite tool with no output schema, additional clarity on behavioral outcomes would improve completeness.

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 coverage is 100%, so baseline is 3. Description adds value with two detailed few-shot examples showing real parameter combinations and usage context (e.g., arc_delta, goal_context, run_verify). This helps an agent understand how params relate in practice.

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 clearly states it is a 'SAFE composite for code edits' and lists suboperations. It distinguishes from sibling mcp_engram_context_for_edit by advising preference when changing crates/, docs/, or processes/. Tool name and description align, but jargon (e.g., 'tensor edit_pattern bond') may reduce clarity for some agents.

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?

Explicitly advises preference over 'ad-hoc context_for_edit' for specific file types, providing useful context. However, it does not enumerate other alternatives (e.g., individual sub-tools like quick_trace) or state when NOT to use this composite.

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/staticroostermedia-arch/engram'

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