Skip to main content
Glama

Awareness — Memory, Knowledge & Agent Markets

awareness_record

Save memory — pass ONE content string, server handles the rest.

Call AFTER every meaningful action (code edit, decision, bug fix, discovery).
If you don't record it, it's lost forever in the next session.

PRIMARY USAGE (single-parameter, F-053):
  awareness_record(content="Today I decided to switch from Pinecone to pgvector because...")

Server defaults action="write" and triggers client-side salience-aware
extraction asynchronously. You do NOT need to pass action, scope, or metadata.

RECOMMENDED (one call, richer insights):
  awareness_record(
    content="WHAT: Refactored auth to JWT. WHY: Sessions didn't scale. OUTCOME: Tests pass.",
    insights={
      "knowledge_cards": [{"category": "decision", "title": "JWT for auth",
        "summary": "Switched from session cookies to JWT...", "status": "resolved",
        "tags": ["auth","jwt"], "confidence": 0.9}],
      "action_items": [{"title": "Add refresh token rotation", "priority": "high", "status": "pending"}]
    })

Content auto-detection:
  str             → single event (detailed natural language description)
  list[dict/str]  → batch of events
  str + scope="knowledge" → document/knowledge import

OTHER ACTIONS (explicit — server will NOT infer these):
  update_task — Multi-agent task protocol (all transitions are atomic):
    claim:    awareness_record(action="update_task", task_id=..., status="claimed",
                               expect_status="open", agent_role="builder_agent")
              → {status:"conflict", claimed:false, current_agent_role} if another agent holds it
    renew:    status="doing", expect_status="doing" (claims are leased for 60 minutes)
    hand off: status="open", expect_status="doing",
              handoff={goal, files, decisions, open_questions}
    finish:   status="done" | "blocked" | "failed", expect_status="doing"
    attest:   verified_by="reviewer_agent" (first verifier wins)
    Legacy statuses pending/in_progress/completed are accepted as open/doing/done.

PERCEPTION (auto-returned, review carefully):
  The response may include a "perception" field with signals you didn't ask about:
  - contradiction: your new record conflicts with a prior belief
  - resonance: a similar past experience was found
  - pattern: a recurring theme detected (3+ occurrences)
  - staleness: related knowledge hasn't been updated in 60+ days
  - related_decision: a prior decision in the same domain exists
  These are push signals — the system noticed something important.
  YOU MUST ACT on these signals:
  - contradiction → Tell user about the conflict, ask if intentional
  - resonance → Mention the related experience to the user
  - pattern → Suggest a systematic fix for the recurring issue
  - staleness → Warn user the related knowledge may be outdated
  - related_decision → Mention the prior decision, ask if still valid

Args:
    action: "write" (default) | "update_task".
    content: What happened. String, list of events, or document content.
    insights: Structured insights to create in ONE step. Include knowledge_cards, risks, action_items.
    scope: "timeline" (default) or "knowledge" for document import.
    session_id: From awareness_init (auto-resolved if omitted).
    task_id: Task identifier (for action="update_task").
    status: open | claimed | doing | done | blocked | failed (legacy: pending | in_progress | completed).
    expect_status: CAS guard — the update only lands if the task still holds this status; pass "open" when claiming.
    handoff: Structured hand-off (goal/files/decisions/open_questions) carried by the same atomic transition.
    verified_by: Attestation identity; the first verifier wins, later verifiers get a conflict.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "awareness_record"
  }
}

Input Schema

NameRequiredDescriptionDefault
actorNo
scopeNotimeline
actionNowrite
sourceNo
statusNo
api_keyNo
contentNo
handoffNo
task_idNo
user_idNo
insightsNo
metadataNo
memory_idNo
agent_roleNo
event_typeNo
max_eventsNo
session_idNo
verified_byNo
expect_statusNo
generate_summaryNo
metadata_defaultsNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changed
    • addedInput schema / properties / expect_status
      Added value: +{
      +  "default": "",
      +  "title": "Expect Status",
      +  "type": "string"
      +}
    • addedInput schema / properties / handoff
      Added value: +{
      +  "anyOf": [
      +    {
      +      "additionalProperties": true,
      +      "type": "object"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "title": "Handoff"
      +}
    • addedInput schema / properties / verified_by
      Added value: +{
      +  "default": "",
      +  "title": "Verified By",
      +  "type": "string"
      +}
  2. First observed

TDQS

A4.3/5.0
Behavior5/5

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

Annotations only declare a non-destructive mutation; the description adds async extraction, server defaults, content auto-detection, 60-minute leases, CAS conflict behavior, first-verifier-wins semantics, and perception return signals. This is substantial behavioral context beyond structured data.

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-loads the primary call and uses concrete examples, but repeats some guidance and includes long directive sections. It is structured and mostly earns its length for a complex tool, though some imperative text could be trimmed.

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?

Covers the common write path, knowledge import, task lifecycle, and perception returns, which is substantial for a 21-param mutation with no output schema. It still leaves several parameters and the ordinary success response unspecified.

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 0% across 21 params, and the description richly explains content, action, insights, scope, task_id, status, expect_status, handoff, agent_role, and verified_by. However, many operational params such as actor, source, api_key, user_id, metadata, memory_id, event_type, max_events, generate_summary, and metadata_defaults are left undefined.

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?

Opens with 'Save memory' and defines the primary single-parameter write path, plus explicitly labels action='update_task' as a separate mode. An agent can distinguish recording from read-oriented siblings even without opening the schema.

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?

Says to call after every meaningful action and warns that unrecorded work is lost, and it gives explicit conditions for update_task transitions. It does not name read siblings such as awareness_recall or awareness_timeline as alternatives, so a 4 rather than 5.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources