Project Memory
project_memoryManage durable project knowledge across MCP sessions: create projects, record plans, experiments, decisions, and corrections, then search, rebuild, export, or reverse changes in a shared knowledge base.
Instructions
PROJECT MEMORY MANAGEMENT. With research enabled, one local broker lets multiple MCP sessions query the same knowledge base concurrently and orders writes safely. Use create to create a project; show to inspect known projects or durable records; record to store session intent, immutable plan revisions, experiments, decisions, versioned ontology terms, or corrections; rebuild to index approved local roots; export to write graph or lineage views; and forget for reversible deletion. show always returns a bounded summary; detail_level=full is accepted for compatibility but never dumps every durable record body. Use project_memory_search for relevant bodies or target_id for one assertion or entity. record returns only a compact receipt and never echoes submitted bodies. action=search remains a compatibility alias, but project_memory_search should be used for local knowledge retrieval. Ontology revisions use supersedes_term_id. Corrections preserve bitemporal data lineage and support assertion replacement plus entity merge or split. rebuild indexes approved local roots and code structure into a reproducible snapshot; export writes an interactive HTML viewer, Graphviz DOT, D3 JSON, or a Neo4j import bundle. HTML always includes PKM, Lineage, and Ontology tabs, an embedded-project selector, empty-canvas focus reset, and visible PNG or JSON download. forget previews impact before reversible project or assertion deletion. Search, search_parallel, scholar_search, and extract automatically capture sources and provenance; project_memory manages their durable structure.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| body | No | Plan body for record_type=plan. | |
| name | No | Project name for create, or entity name lookup for show. | |
| limit | No | Maximum local RAG results for action=search. | |
| query | No | Required for action=search. Searches stored local knowledge only and does not start live web discovery. | |
| roots | No | Approved local roots to index. Omit to rebuild derived state from stored sources. | |
| title | No | Plan title, experiment name, or decision title. | |
| action | Yes | create: project_id and name required. show: inspect a known project, assertion, entity, or durable record. search: compatibility alias for project_memory_search. record: project_id and record_type required. rebuild: project_id required; roots optional. export: project_id, include_project_ids, or all_projects=true required. forget: project_id and forget_mode required; apply also requires confirm_token. | |
| intent | No | Durable intent for record_type=session. | |
| reason | No | Required reason for any correction. | |
| status | No | Use success, failed, or inconclusive to finish an experiment. Omit or use running when starting it. | |
| aliases | No | Ontology term aliases, or aliases moved during entity_split. | |
| metrics | No | Terminal experiment metrics. | |
| summary | No | Experiment result or decision summary. | |
| version | No | Ontology revision number. Defaults to 1 or the superseded term version plus one. | |
| git_root | No | Optional Git root recorded with a rebuild snapshot. | |
| valid_to | No | Corrected assertion valid-time end. | |
| artifacts | No | Experiment artifact paths or identifiers. | |
| target_id | No | Assertion or entity id for show or correction. | |
| hypothesis | No | Hypothesis when starting an experiment. | |
| project_id | No | Stable project id. For search, this is the write-isolated primary scope. Omit to list projects or use all_projects. | |
| source_ids | No | Entity ids merged into target_id by entity_merge. | |
| valid_from | No | Corrected assertion valid-time start. | |
| export_view | No | Initial HTML tab or non-HTML export scope. graph is PKM; ontology shows types, shared schema, verified identity links, and typed instances; lineage shows aligned data and research lineage. | graph |
| forget_mode | No | Preview first. Apply requires its confirm_token. Restore reverses deletion. | |
| record_type | No | Required for record. session stores intent; plan creates an immutable revision; experiment starts or finishes a run; decision links a conclusion; ontology creates a versioned type or relation; correction replaces an assertion or merges/splits entities. | |
| replacement | No | New assertion value, or new entity name for entity_split. | |
| all_projects | No | Search or export every active named project. Excludes Inbox and cannot be combined with project ids. | |
| detail_level | No | For show with project_id and no target_id, both values return a bounded summary. full is retained only for compatibility and never returns every durable record body. | summary |
| evidence_ids | No | Evidence retained on a corrected assertion. | |
| change_reason | No | Reason for a new plan revision. | |
| confirm_token | No | Token returned by the matching forget preview. | |
| experiment_id | No | Experiment to finish or associate with a decision. | |
| export_format | No | Visualization file format. html writes one offline explorer with PKM, Lineage, Ontology, project selection, and current-view PNG or anonymized JSON download; d3 writes node-link JSON; dot writes Graphviz DOT; neo4j writes an import-ready CSV and Cypher bundle. | d3 |
| memory_handle | No | Existing project session handle for a session intent revision. | |
| ontology_kind | No | Ontology term kind for record_type=ontology. | |
| query_variants | No | Optional local retrieval variants for action=search. They run inside one broker request and are fused before one rerank. | |
| correction_kind | No | Correction operation. Defaults to assertion. | |
| plan_revision_id | No | Plan revision associated with an experiment or decision. | |
| supersedes_term_id | No | Prior ontology term replaced by this revision. | |
| include_project_ids | No | Additional read-only projects for one local search or integrated visualization export. | |
| based_on_experiment_id | No | Experiment that motivated a plan revision. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| meta | No | ||
| error | No | ||
| index | No | ||
| plans | No | ||
| query | No | ||
| entity | No | ||
| forget | No | ||
| memory | No | ||
| record | No | ||
| project | No | ||
| results | No | ||
| session | No | ||
| entities | No | ||
| projects | No | ||
| assertion | No | ||
| decisions | No | ||
| elapsed_ms | No | ||
| job_counts | No | ||
| plan_count | No | ||
| experiments | No | ||
| entity_count | No | ||
| memory_handle | No | ||
| session_count | No | ||
| visualization | No | ||
| decision_count | No | ||
| document_count | No | ||
| assertion_count | No | ||
| correction_count | No | ||
| experiment_count | No | ||
| search_event_count | No | ||
| source_entry_count | No | ||
| active_source_snapshot | No | ||
| entity_operation_count | No | ||
| citation_observation_count | No |