Skip to main content
Glama

memory_extract

Extract capsule-sized memory candidates from free text using deterministic heuristics and entity anchors. Returns each candidate with its kind and literal cue for review before you ingest it.

Instructions

Mine a free-text blob (param content; text accepted as an alias) for capsule-sized memory candidates — deterministic heuristics, verbatim substrings only (never synthesized). Segmentation: per line, then per sentence within a line (; also splits — semicolon-joined rules are independent claims); fenced AND indented code is skipped (tracebacks are not claims), and chat/log dress ([10:05] name: ) is peeled like list markers. Cue tables are closed keyword lists in ENGLISH + PORTUGUESE (decisão/decidimos, sempre/nunca/não, é/são/deve/devem, todo/pendente, epic/marco, ideia/e se, doc/runbook, procedure/procedimento/how to, constraint/restrição + must not/não pode(m)/não deve(m), capability/capacidade + use when/use quando, failure/falha/symptom/sintoma + fails with/falha quando/breaks when, …) — other languages need the caller to judge kind themselves. Work-plane and procedure LABELS must open the segment (once dress is stripped); decision/fact shape cues also fire mid-segment. ENTITY GATE (q108): the declarative fact cues (is/are/was/deve/devem/é/são/foi/…) fire ONLY when the segment ALSO carries an ENTITY ANCHOR — the first concrete token: an acronym or mixed-case internal capital (API, SSOT, SQLite, nMEMORY), a token bearing a digit (v2, 4320, 400), a path/symbol shape (/etc/x, a::b), an internal dot (PLAN.md, menot.you), or a backtick code span (nsh) — tokens carrying call punctuation ( ) { } ; are fenced out as code debris. It is a deliberate noise fence, BROADER than just "acronym or number": "A API é lenta" mines a fact (entity API), "o sistema é resiliente" mines NOTHING (no anchor). The standing-rule adverbs never/always/nunca/sempre/jamais are the ONE fact shape exempt — they need no anchor. Precedence when the same adverb opens a COMMAND: an imperative opener wins ("Sempre valide o token" mines procedure, cue imperative-opener); the adverb exemption applies only to declarative shapes ("o deploy sempre roda às 18h" mines fact). Each candidate carries a closed kind (fact/procedure/decision/task/epic/brainstorm/doc/constraint/capability/failure_pattern — task/epic/brainstorm/doc are the work/docs plane; constraint/capability/failure_pattern the governance plane: prohibitions, applicability, failure shapes) and the literal cue that fired. ADVISORY only: NOTHING is stored — the caller reviews and captures chosen candidates via memory_ingest (optionally classifying them via memory_classify with the candidate kind carried forward). 0 candidates is an honest answer.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
textNoAlias for content (the pre-w2-fix spelling). Send content OR text, never both.
contentNoThe free-text blob to mine for capsule-sized candidates (alias: text — send exactly one, never both).
Behavior5/5

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

With no annotations provided, the description fully covers behavior: it explains deterministic heuristics, verbatim substrings, segmentation rules, noise filters (entity gate, code skipping), kind assignment, and explicitly states nothing is stored. The 'ADVISORY only' note is critical for safe agent use.

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

Conciseness3/5

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

The description is very long (multiple paragraphs) and contains extensive algorithmic details. While necessary for a complex tool, it could be more concise. The front-loading of purpose and key behavior is good, but overall verbosity reduces clarity.

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

Completeness5/5

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

Given no output schema, the description adequately explains what the tool returns (candidates with kind and cue) and that 0 candidates is an honest answer. It also covers edge cases (other languages, imperative vs declarative precedence). The tool is well-contextualized.

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

Parameters5/5

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

Schema coverage is 100% (both content and text described). The description adds meaning by explaining that content is the primary blob and text is an alias, and it provides context on how the blob is processed (line-based segmentation, etc.), which goes beyond schema definitions.

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 clearly states the tool mines a free-text blob for memory candidates, using a specific verb ('Mine') and resource ('free-text blob'). It distinguishes itself from sibling tools by emphasizing it does not store anything, leaving capture to memory_ingest.

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 on when to use this tool (to extract candidates) and directs the caller to memory_ingest for storage. It also notes language limitations (English/Portuguese cues only), but does not explicitly list when not to use or alternative tools beyond ingest.

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/menot-you/n-memory'

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