Skip to main content
Glama
ai-dememory

ai-dememory

ai DeMemory

ai DeMemory gives people and AI tools a small, local memory that remains easy to inspect and edit. Markdown is the memory source of truth. Search SQLite is disposable; optional provider budgets and job receipts are separate durable state.

The current development branch is rebuilding the product as V3. The source version is 3.0.0a2 (alpha). See releases for published artifacts and the target index. V3 deliberately does not migrate or emulate 2.x. Existing historical/test vaults remain separate and must not be deleted when replacing the installed package.

Start in under five minutes

Use Python 3.11 or newer from a source checkout:

python -m pip install .
ai-dememory setup
ai-dememory remember "Markdown is the canonical memory." --title "Storage rule"

setup explains where the vault will live and offers optional Codex integration and a Windows consolidation task. Declining both keeps the core passive: no daemon, child process, model call or network. Explicit extras register client/OS configuration but do not start a model or scan conversations. The selected vault is saved in the user's local configuration, so normal commands work from any directory. After setup it prints the selected location, index state and one next command instead of a raw configuration dump.

remember is the V3 MVP. It atomically writes one Markdown file, reads that file back, and only then prints Saved and verified with its identifier and path. It does not build SQLite, start a process or require the source checkout. Use --json for a stable machine-readable result with saved: true and verified: true.

Recall is a separate, lazy step. The disposable SQLite index is created or updated only when it is actually needed. Human output reports how many memories matched; --json returns query, count and results:

ai-dememory recall "canonical memory"
ai-dememory status

status is a read-only summary of the selected vault: canonical memories, pending proposals, generated index state and enabled modules. Its zero-call and zero-process fields describe the core only, not running optional modules. It does not build the index or start anything. Use ai-dememory status --json for scripts.

Use --vault <path> only when deliberately overriding the saved default.

Connect Codex across local projects with one optional user-level installation:

ai-dememory setup --with-codex --yes

Restart Codex and trust the generated UserPromptSubmit and SessionStart commands in /hooks. Each task receives its own project scope; Git worktrees share their project. The hook recalls relevant memory without reading transcripts or calling another model. The host assistant can learn useful facts through the same scoped MCP. Normal Codex tool-approval settings still apply. See integration setup and rollback. Use this branch's built package or source, not historical V2 scripts, when testing V3.

On Windows, add --with-schedule to that setup command for weekly consolidation without leaving the dashboard open. Existing cadence/scope are preserved; change them in the dashboard. This is one hourly check, not a resident service. See setup, hooks and scheduled work for costs, limits and removal.

Manual remember and recall default to shared global memory. Add --scope auto to use the current project, or --scope project:NAME for an explicit scope. status shows the runtime, selected configuration and current project scope.

Related MCP server: personal-project-knowledge-mcp

Learning without approving every fact

remember saves your explicit input. Enabled integrations can also call memory.learn with scope and provenance: explicit statements and verified outcomes become active, while inferences remain provisional and out of recall. Trusted clients supply that evidence; this is not automatic truth verification. Keys allow explicit corrections and forgetting the latest correction restores its predecessor. This is not general semantic contradiction detection.

Optional model-generated summaries still use proposals. review shows them; accepting saves verified Markdown and rejecting creates no memory:

ai-dememory review
ai-dememory review show <proposal-id>
ai-dememory review accept <proposal-id>
ai-dememory review reject <proposal-id>

Optional modules

Everything beyond the local core is opt-in. A disabled module contributes zero runtime imports, tools and processes. Dependencies of an already installed third-party package remain installed until that package is uninstalled.

ai-dememory module list
ai-dememory module enable mcp
ai-dememory serve mcp

module list shows enabled/disabled state and capabilities. Enabling a module prints its foreground serve command; disabling it starts no cleanup process.

The bundled MCP module runs in the foreground over stdio and exposes seven tools: search, get, context, propose, learn, forget and status. It opens no network port and starts no subprocess. Disable it with ai-dememory module disable mcp.

The workbench also provides live provider model discovery, optional official Codex browser/device login, and manual local-conversation previews. Its Modules page toggles these extensions. API billing and subscription usage are distinct. Provider plugins and replacement dashboards reuse the existing trusted Python module contract.

Create a community module without copying this repository:

ai-dememory module create my-module

The scaffold command prints its location followed by the three commands to install, enable and run it. The generated package is deliberately small: one manifest, one foreground function and one test.

See modules for the trust and resource contract.

For project-local Codex or Claude Code MCP settings and optional prompt recall, follow local harness integrations. These adapters are alpha: consult the acceptance status before assuming native client support. Hermes has a separate opt-in native memory provider using the same scoped vault. Its installed contract smoke is verified; a full Hermes client/model episode is still pending.

Local dashboard

ai-dememory module enable workbench
ai-dememory serve workbench

Open http://127.0.0.1:8765. Manage memory, providers, per-operation or hook/skill routes, fallback order, budgets and a consolidation schedule in the browser. No model is selected and no schedule is enabled by default. Choose OpenAI, Anthropic / Claude or a local/custom endpoint. API keys can be entered for the current workbench session or loaded from environment-variable references; neither is saved as plaintext in the vault. An optional codex-subscription module provides isolated managed login; its authenticated generation acceptance is still pending. It is not generic OAuth for other providers. Scheduled jobs run while the foreground service runs; an optional Windows task can check consolidation without it. One consolidation runs at a time, and the foreground UI waits during its own provider calls. Optional source schedules require separate explicit opt-in; enabling the dashboard alone does not import conversations. Remote access remains a later slice.

See the workbench guide and the V3 plan.

Product boundaries

  • Python is the only core runtime; Node is not required.

  • Markdown is canonical; indexes/memory.sqlite is disposable.

  • The default install has no scheduler, hooks, dashboard, graph, vectors, embeddings, model calls or background process.

  • Modules are local trusted Python code, not sandboxes. Their declared resource budgets are visible metadata, not an operating-system enforcement boundary.

  • The public source repository and every private vault are separate locations.

  • High-confidence secret material is rejected at canonical and proposal writes; credentials still belong in a credential manager.

Documentation

Unlinked 2.x design documents and ADRs are historical source material only and will be removed before the first V3 package release. They do not define current behavior or priorities.

Available Tools

74 tools
memory.acceptance_packetManual Acceptance PacketB
Read-only

Render the manual acceptance review packet without writing reports or recording evidence.

Inputs: limit, offset, pr_url, reviewer. Returns: items, limit, total, offset, +15 more

memory.acceptance_packet_archive_retention_planManual Acceptance Packet Archive Retention PlanC
Read-only

Plan generated manual acceptance packet archive pruning without deleting files or recording evidence.

Inputs: keep, limit, offset, archive_dir. Returns: keep, limit, offset, has_more, +12 more

memory.acceptance_packet_archive_statusManual Acceptance Packet Archive StatusA
Read-only

List generated manual acceptance packet archives without writing files or recording evidence.

Inputs: limit, offset, archive_dir. Returns: limit, offset, archives, has_more, +8 more

memory.acceptance_planManual Acceptance PlanA
Read-only

Return remaining and blocked manual acceptance next actions without recording evidence.

Inputs: pr_url, reviewer. Returns: plan

memory.acceptance_statusManual Acceptance StatusB
Read-only

Return reviewed manual release acceptance evidence status.

Inputs: no named parameters. Returns: items

memory.acceptance_templateManual Acceptance Evidence TemplateC
Read-only

Return a reviewed-evidence template and record command without recording acceptance evidence.

Inputs: item (required), pr_url, status, reviewer. Returns: item, pr_url, status, command, +7 more

memory.acceptance_verifyVerify Manual AcceptanceA
Read-only

Return manual acceptance completion state without recording evidence.

Inputs: no named parameters. Returns: verification

memory.capture_importCapture Import CandidateA

Capture explicit text or a repository-local file into inbox/imports/ for review.

Inputs: kind (required), path, text, limit, +1 more. Returns: result

memory.capture_missCapture Recall MissC

Write a reviewed recall miss candidate to inbox/recall-feedback/.

Inputs: query (required), reason (required), expected_id, expected_path. Returns: path

memory.conflict_dismissDismiss Memory ConflictC

Record that a conflict candidate was reviewed and intentionally dismissed.

Inputs: id (required), reason (required), reviewer (required), recommendation_id. Returns: id, path, status, decision, +7 more

memory.conflict_keepResolve Conflict Keep MemoryA

Record a reviewed keep decision for a conflict without editing canonical memory.

Inputs: id (required), keep (required), reviewer (required), recommendation_id. Returns: id, keep, path, status, +8 more

memory.conflict_merge_proposalWrite Conflict Merge ProposalB

Write a conflict merge proposal under inbox/conflict-resolution/ and audit the decision.

Inputs: id (required), reviewer (required), recommendation_id. Returns: id, path, status, decision, +8 more

memory.consolidateConsolidation Dry RunA
Read-only

Generate a consolidation dry-run report. Does not mutate memories.

Inputs: dry_run. Returns: report

memory.contextAssemble Memory ContextC
Read-only

Return token-budgeted memory context for an explicit query or generated working context.

Inputs: auto, limit, query, budget_tokens, +3 more. Returns: text, items, query, query_source, +4 more

memory.doctorMemory DoctorA
Read-only

Return local ai-dememory readiness checks without mutating files.

Inputs: no named parameters. Returns: checks, profile, summary

memory.false_positive_ignoreIgnore False PositiveC

Record a reviewed secret-scan false-positive suppression in .ai-dememory-ignore.toml.

Inputs: id (required), reason (required), reviewer (required), recommendation_id, +1 more. Returns: id, path, ignored, reviewer, +9 more

memory.false_positive_unignoreUnignore False PositiveC

Record a reviewed false-positive unsuppression in .ai-dememory-ignore.toml.

Inputs: id (required), reviewer (required), recommendation_id. Returns: id, path, ignored, reviewer, +9 more

memory.getGet MemoryB
Read-only

Read a memory document by id or repository-relative path.

Inputs: id, path, include_sensitive. Returns: path, content, frontmatter

memory.git_lessonsCapture Git Lesson CandidatesA

Inspect local git history and preview review-first lesson candidates; dry_run=false writes into inbox/git-lessons/.

Inputs: days, repo, limit, repos, +1 more. Returns: result

memory.graphMemory GraphC
Read-only

Return a lightweight graph of memory, tag, project, type, scope, and reference relationships.

Inputs: include_sensitive. Returns: edges, nodes

memory.hook_capture_reviewReview Hook CaptureA

Record a reviewed outcome on a hook capture under inbox/session-events/ without promoting memory.

Inputs: path (required), reason (required), status (required), reviewed_by (required). Returns: path, reason, reviewed_at, reviewed_by, +2 more

memory.hook_configHook ConfigB
Read-only

Return local hook config fragments for Codex or Claude Code.

Inputs: root, client, command. Returns: config

memory.hook_eventsHook EventsB
Read-only

Return supported local provider hook events.

Inputs: provider. Returns: providers

memory.hook_statusHook StatusB
Read-only

Return managed hook instruction install status without writing files.

Inputs: client, capture_event, capture_provider, capture_created_to, +4 more. Returns: hooks, captures, writes_files, all_installed, +4 more

memory.import_chatsImport Chat CandidatesC

Import configured provider chat/session files into inbox/imports/ for review.

Inputs: provider (required), limit, dry_run. Returns: result

memory.lifecycle_scoresLifecycle ScoresA
Read-only

Return generated lifecycle scores from retrieval and outcome feedback.

Inputs: no named parameters. Returns: scores

memory.maintenance_runRun Memory MaintenanceC

Run an opt-in daily or weekly maintenance profile.

Inputs: dry_run, profile, report_dir. Returns: result

memory.maintenance_statusMemory Maintenance StatusA
Read-only

Show configured providers, schedule settings, generated artifacts, generated packet archives, recent reports, and lock state.

Inputs: no named parameters. Returns: schedule, artifacts, providers, review_due, +8 more

memory.mark_seenMark Memory SeenC

Log that a memory search result was used.

Inputs: query (required), score, used_by, selected_memory_id. Returns: query, score, used_by, created_at, +2 more

memory.outcomeRecord Memory OutcomeA

Record good/bad usefulness feedback for a memory or last seen memory.

Inputs: outcome (required), id, last, note. Returns: outcome, strength, memory_id, created_at, +6 more

memory.provenance_statusDurable Provenance StatusB
Read-only

Audit durable memories for reviewed provenance metadata.

Inputs: no named parameters. Returns: issues, issue_count, generated_at, durable_count

memory.providers_detectDetect Memory ProvidersA
Read-only

Detect known local LLM provider folders for optional chat import.

Inputs: no named parameters. Returns: providers

memory.providers_planProvider Setup PlanA
Read-only

Return reviewable provider configure/import commands without mutating config or reading provider files.

Inputs: command. Returns: providers, next_actions, mutates_system, reads_provider_files, +1 more

memory.providers_statusProvider Import StatusA
Read-only

Return configured provider import readiness without reading or importing chat files.

Inputs: no named parameters. Returns: providers, enabled_count, mutates_system, configured_count, +3 more

memory.publish_planPublish PlanB
Read-only

Plan manual TestPyPI or PyPI publishing without uploading packages.

Inputs: pr_url, command, repository. Returns: root, workflow, repository, guard_issues, +29 more

memory.recall_fixture_statusRecall Fixture StatusB
Read-only

Report recall fixture provenance and reviewed-promotion freshness.

Inputs: max_age_days. Returns: stale, status, next_action, max_age_days, +8 more

memory.recall_miss_candidateCheck Recall Miss CandidateB
Read-only

Check whether a query and expected memory are a recall miss candidate without writing files.

Inputs: query (required), limit, min_rank, expected_id, +2 more. Returns: query, reason, min_rank, expected_id, +8 more

memory.recall_miss_reviewReview Recall MissA

Reject or dismiss a reviewed recall miss without writing recall fixtures or canonical memory.

Inputs: miss (required), reason (required), status (required), reviewer (required). Returns: path, reason, status, reviewed_at, +3 more

memory.recall_review_packetRecall Review PacketA
Read-only

Render the weekly recall review packet without writing reports, fixture files, or miss outcomes.

Inputs: limit, pr_url, reviewer, max_age_days, +3 more. Returns: limit, stale, pr_url, status, +22 more

memory.recall_review_packet_archive_retention_planRecall Review Packet Archive Retention PlanC
Read-only

Plan generated recall review packet archive pruning without deleting files, writing fixtures, or closing misses.

Inputs: keep, limit, offset, archive_dir. Returns: keep, limit, offset, has_more, +13 more

memory.recall_review_packet_archive_statusRecall Review Packet Archive StatusB
Read-only

List generated recall review packet archives without writing files, fixtures, or miss outcomes.

Inputs: limit, offset, archive_dir. Returns: limit, offset, archives, has_more, +9 more

memory.recall_review_planRecall Review PlanC
Read-only

Report pending recall miss review work without writing fixture files.

Inputs: limit, max_age_days, invalid_offset, pending_offset, +1 more. Returns: limit, stale, pr_url, status, +19 more

memory.reindexRebuild Memory IndexC

Run secret scan, validation, and rebuild the SQLite index.

Inputs: no named parameters. Returns: path, count

memory.release_evidenceRelease EvidenceB
Read-only

Return local v2 release evidence without writing report files.

Inputs: pr_url, reviewer. Returns: reason, evidence, available

memory.release_evidence_reportRelease Evidence ReportB
Read-only

Render the v2 release evidence Markdown report without writing report files.

Inputs: pr_url, reviewer. Returns: reason, markdown, available, report_path, +5 more

memory.review_configure_modeConfigure Review ModeA

Persist the active review mode in .ai-dememory.toml without editing canonical memory.

Inputs: mode (required), reviewer. Returns: path, active, reviewer, requested_mode, +7 more

memory.review_conflictsReview Memory ConflictsA
Read-only

Return duplicate, preference, project decision, and restricted memory conflict candidates.

Inputs: no named parameters. Returns: policy, enabled, conflicts

memory.review_false_positivesReview False PositivesA
Read-only

Return secret-scan findings with deterministic review ids and suppression metadata.

Inputs: due_only. Returns: policy, enabled, due_only, findings, +1 more

memory.review_modesReview ModesA
Read-only

Return built-in review modes and the active configured mode.

Inputs: no named parameters. Returns: modes, active, policy

memory.review_planReview PlanB
Read-only

Return mode-specific LLM, human, and validation steps for a review kind.

Inputs: kind. Returns: kind, mode, policy, summary, +4 more

memory.review_recommendationStore Review RecommendationC

Store an advisory LLM/client review recommendation under inbox/review-recommendations/ without applying it.

Inputs: kind (required), rationale (required), target_id (required), recommendation (required), +3 more. Returns: id, kind, mode, path, +11 more

memory.review_recommendation_archive_restore_previewPreview Review Recommendation Archive RestoreB
Read-only

Preview restoring one archived advisory recommendation artifact to the active inbox without moving files.

Inputs: id (required), recursive, archive_root. Returns: dry_run, skipped, restored, malformed, +12 more

memory.review_recommendation_archive_statusArchived Review Recommendation StatusA
Read-only

List archived accepted/rejected advisory recommendation artifacts without moving files.

Inputs: kind, limit, offset, recursive, +3 more. Returns: offset, enabled, filters, invalid, +20 more

memory.review_recommendation_outcomeRecord Review Recommendation OutcomeA

Record accepted/rejected status on an advisory review recommendation artifact without applying it.

Inputs: id (required), reason (required), status (required), reviewer (required). Returns: id, path, writes_files, outcome_reason, +8 more

memory.review_recommendation_outcome_reportReview Recommendation Outcome ReportB
Read-only

Render the reviewed recommendation outcome sign-off report without writing files.

Inputs: kind, limit, offset, invalid_offset, +1 more. Returns: offset, enabled, filters, invalid, +20 more

memory.review_recommendationsList Review RecommendationsA
Read-only

List advisory review recommendation artifacts without applying review outcomes.

Inputs: kind, outcome_status, policy_violations_only. Returns: enabled, filters, invalid, total_count, +15 more

memory.review_stale_false_positivesReview Stale False PositivesA
Read-only

Return ignored false-positive suppressions whose current scanner finding no longer exists.

Inputs: no named parameters. Returns: items, policy, enabled, stale_count

memory.roadmap_statusRoadmap StatusA
Read-only

Return read-only implementation status for the v2 operational roadmap phases.

Inputs: no named parameters. Returns: root, phases, phase_count, next_actions, +3 more

memory.schedule_environmentMemory Schedule EnvironmentB
Read-only

Check local scheduler, Docker, and crontab command availability without running commands.

Inputs: mode, platform. Returns: mode, ready, checks, platform, +3 more

memory.schedule_planPlan Memory ScheduleC
Read-only

Return platform scheduler commands and reviewed cron export entries without installing them.

Inputs: mode, image, action, platform. Returns: mode, root, image, action, +9 more

memory.schedule_statusMemory Schedule StatusA
Read-only

Return configured schedule settings and platform status commands without querying or mutating the OS scheduler.

Inputs: platform. Returns: mode, image, valid, platform, +6 more

memory.searchSearch MemoryC
Read-only

Search ranked local memory results from the SQLite index.

Inputs: query (required), limit, include_sensitive. Returns: results

memory.secret_scanSecret ScanB
Read-only

Scan selected paths or the repository for suspected secrets.

Inputs: paths. Returns: findings

memory.setup_healthLocal Setup HealthA
Read-only

Return combined validation, context config, manual acceptance, recall, vector, provider, scheduler, maintenance, and review health without running commands or writing files.

Inputs: mode, platform. Returns: mode, root, ready, platform, +21 more

memory.setup_planLocal Setup PlanC
Read-only

Return review-first vault, MCP, provider, hook, and scheduler setup commands without mutating files.

Inputs: mode, image, client, command. Returns: root, commands, next_actions, writes_files, +6 more

memory.sleep_apply_reviewedWrite Sleep Review PacketsC

Write selected sleep consolidation candidates to inbox/sleep-consolidation/.

Inputs: all, ids. Returns: written

memory.sleep_planSleep Consolidation PlanA
Read-only

Return safe sleep consolidation candidates without mutating memory.

Inputs: no named parameters. Returns: candidates, generated_at

memory.validate_statusValidate Memory StatusA
Read-only

Return structured Markdown memory validation and conflict scan status without mutating files.

Inputs: no named parameters. Returns: ok, errors, messages, exit_code, +2 more

memory.vector_statusVector Readiness StatusA
Read-only

Report whether recall fixtures justify a future vector search experiment.

Inputs: min_failed_cases, recall_threshold. Returns: recall, decision, rationale, generated_at, +3 more

memory.working_currentCurrent Working MemoryA
Read-only

Read the generated working/current.json snapshot if present.

Inputs: no named parameters. Returns: exists, current

memory.working_handoffWrite Working HandoffB

Write a generated working/handoffs/ Markdown handoff after secret scanning.

Inputs: notes (required), title (required). Returns: path

memory.working_snapshotWrite Working SnapshotA

Write generated working/current.json and working/recent-session.md after secret scanning.

Inputs: notes (required), title (required), task. Returns: path

memory.working_statusWorking Memory StatusB
Read-only

Summarize current working state, recent-session file, and recent handoffs.

Inputs: limit. Returns: current, handoffs, current_path, handoff_count, +3 more

memory.write_proposalWrite Memory ProposalC

Write a reviewed proposal candidate to inbox/llm-captures/.

Inputs: title (required), content (required), tags, project, +2 more. Returns: path

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    B3.2/5.0

    Scored across 74 tools

    Disambiguation4/5

    Most tools have distinct purposes with detailed descriptions, but the large number (74) creates some potential for confusion between closely related tools like acceptance_plan, acceptance_status, and acceptance_template. Overall, an agent can differentiate with careful attention.

    Naming Consistency5/5

    All tools follow a consistent pattern: 'memory.' prefix plus snake_case with verb_noun structure (e.g., capture_import, conflict_dismiss). Even longer names like acceptance_packet_archive_retention_plan adhere to this pattern, making naming highly predictable.

    Tool Count2/5

    With 74 tools, the count is very high, exceeding the typical well-scoped range. While the server covers a complex domain (memory management), many tools are read-only planning variants, suggesting potential over-fragmentation that could overwhelm agents.

    Completeness4/5

    The tool set covers a wide range of operations: capture, acceptance, conflicts, review, recall, maintenance, search, secrets, scheduling, and more. However, there is a notable lack of tools for actual deletion or mutation of core memories (most tools are planning/status), which may limit direct action capabilities.

    Maintenance

    ActivityMaintained
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      A
      quality
      B
      maintenance
      A local-first shared memory layer for MCP-aware agents like Claude, Codex, and Hermes, enabling persistent memory across chats and clients via Markdown files and SQLite FTS.
      6
      2
      MIT
    • A
      license
      Not graded
      quality
      B
      maintenance
      A local markdown memory and cross-agent context engine for AI coding assistants. It provides an MCP server with tools to search, add, retrieve, and distill persistent memory across tools like Claude Code, Cursor, and Zed.
      5
      MIT