KusiScribe Core
Monitors Google Antigravity agent streams, redacts sensitive data from transcripts, and exposes searchable memory cards and topic indexes to MCP clients.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@KusiScribe Coreretrieve atomic memory cards about the database schema debate"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
KusiScribe Core
Local MCP Notary & Long-Context Fact Fabric for Autonomous Multi-Agent Workflows.
Overview
Modern LLM agents operating in multi-turn, long-context software engineering environments suffer from two structural points of failure:
The "Lost in the Middle" Attention Collapse: When critical decisions, system rules, and technical architectures are placed in the middle or historical parts of an expansive context window, model retrieval fidelity drops sharply.
Multi-Agent State Collision: When multiple agents (e.g., Anthropic Claude, Google Antigravity, OpenCowork) execute in the same workspace, concurrent uncoordinated writes degrade memory files, causing hallucinations and race conditions.
KusiScribe Core solves both problems via an asynchronous, dual-layer forensic architecture:
The Single-Writer Principle: An isolated notary engine captures raw agent dialogue streams, redacts secrets on the fly, and generates literal immutable transcripts. Memory distillation runs asynchronously through an atomic schema, ensuring knowledge bases are never corrupted by concurrent edits.
Deterministic MCP Access: Exposes a 12-tool Model Context Protocol (MCP) server that provides agents with sub-500-token canonical memory cards, transversal topic indexes, playbooks, experiments, and literal grep search without fuzzy hallucinations.
Related MCP server: MultiService IA
Empirical Benchmark: Attention Degradation vs. Structure
To evaluate the impact of information structure on agent recall across long contexts, an empirical benchmark of $N = 450$ GPU inferences ($3 \times 3 \times 50$ counterbalanced iterations) was conducted on local infrastructure (EXP-2026-09-04-LOST-IN-MIDDLE).
Retrieval Matrix
Structure Format | Top Position (Header) | Middle Position (Lost in Middle) | Bottom Position (Tail) |
Traditional Flat Text | 100% | 2% | 6% |
Atomic Fact Block (60 words) | 100% | 72% (30% entity binding) | 34% |
Structured Matrix ( | 100% | 100% | 98% |
Architectural Implication
Unstructured prose and unbounded chat history lose up to 98% recall fidelity when pushed into the middle of context. KusiScribe converts raw dialogue into typed atomic facts (- [TYPE | p:NN] Fact) constrained to strict token limits (~500 tokens), completely bypassing the positional attention drop.
Architecture
+-------------------------------------------------------------+
| ACTIVE AGENT STREAMS |
| Google Antigravity (Anty) / OpenCowork (Kairo / Claude) |
+------------------------------+------------------------------+
|
| (stdout / transcript.jsonl)
v
+------------------------------+
| watcher.py |
| - Secret Masking (Regex) |
| - Voice Topic Triggers |
| - Transcript Archiving |
+--------------+---------------+
|
+-------------+-------------+
| |
v v
+-----------------------+ +-----------------------+
| TRANSCRIPCIONES/ | | EXPEDIENTES/ |
| (Literal Work Logs) | | (_indice_temas.json)|
+-----------+-----------+ +-----------------------+
|
| Asynchronous Extraction (Triggered / Cron)
v
+-----------------------+
| kusiscribe_distill | <--- KusiAI Atomic Arbiter
| (Azure / OpenAI API) | (Store / Skip / Update / Merge)
+-----------+-----------+
|
v
+-----------------------+
| FICHAS/ | <--- Single-Writer Authority
| (Atomic Memory Cards)|
+-----------+-----------+
|
v
+-------------------------------------------------------+
| server_mcp.py |
| (Model Context Protocol JSON-RPC 2.0) |
+-------------------------------------------------------+
^ ^
| |
Claude Desktop / Cursor Antigravity / TerminalsFeatures
1. Single-Writer Principle
watcher.pyis the only process permitted to write literal session records toTRANSCRIPCIONES_LITERALES/.kusiscribe_distill.pyis the only process permitted to update knowledge base files inFICHAS/.The watcher never calls summarization APIs synchronously in the critical path, keeping latency at zero and eliminating file contention.
2. Zero-Leak Credential Masking
Before any line of conversation is flushed to disk, real-time regular expressions sanitize sensitive authorization data:
OpenAI / Anthropic / HuggingFace tokens (
sk-...,Bearer ...)GitHub Personal Access Tokens (
ghp-...,gho-...)Slack & third-party webhook tokens (
xoxb-...)Long cryptographic secrets and raw hashes
3. KusiAI 4-Way Conflict Arbitration
Memory distillation applies a 4-way decision matrix for incoming facts against existing records:
store: Novel, valuable architectural decision or rule.skip: Redundant information already captured.update: Supercedes an older fact with higher priority.merge: Synthesizes complementary data into a unified bullet.
The 12 Model Context Protocol (MCP) Tools
The included server_mcp.py implements the standard JSON-RPC 2.0 protocol over stdio, providing 12 specialized tools:
Tool Name | Scope | Description |
| Memory Cards | Reads the compact (~500 tokens) atomic memory card for a domain. |
| Topic Map | Searches the cross-chat master index and returns chat UUIDs, lines, and dates. |
| Forensic Grep | Fast literal search across all historical work logs and transcripts. |
| Deep Archive | Reads comprehensive historical dossier files from |
| Audit | Lists all tracked sessions and conversation UUIDs. |
| Transcript | Returns the full literal session transcript for a specific UUID. |
| Lab | Retrieves technical reports and benchmarks from |
| Lab | Lists all empirical benchmarks and research documents. |
| Ops | Fetches step-by-step engineering SOPs from |
| Ops | Lists all operational procedure manuals. |
| Tooling | Reads source code of utility scripts stored in |
| Tooling | Lists available utility scripts and sanity checkers. |
Quick Start
1. Clone & Install
git clone https://github.com/kusiai070/kusiscribe-core.git
cd kusiscribe-core
pip install -r requirements.txt2. Configuration
Copy the template configuration:
cp config.example.json config.jsonEdit config.json to define your monitored agent directories and model endpoint:
{
"fuentes": {
"antigravity": {
"activa": true,
"directorio_brain": "~/.gemini/antigravity/brain"
},
"opencowork": {
"activa": true,
"directorio_brain": "~/AppData/Roaming/open-cowork/brain"
}
},
"azure_foundry": {
"endpoint": "https://<your-resource>.services.ai.azure.com/openai/v1/chat/completions",
"model": "gpt-5.4-mini",
"api_key": ""
}
}Note: Environment variables AZURE_AI_KEY or OPENAI_API_KEY are automatically discovered if left empty in the configuration.
3. Run the Notary Watcher
On Windows:
arrancar_kusiscribe.batOn Linux / macOS:
python3 watcher.py4. CLI Inspection
Query historical facts directly from your terminal:
# Search across all logs
python buscar.py "deployment"
# Read atomic memory card for a domain
python buscar.py -f deploy
# Locate which sessions discussed a topic
python buscar.py -t vpsMCP Client Setup
Claude Desktop
Add the following to your claude_desktop_config.json:
{
"mcpServers": {
"kusiscribe": {
"command": "python",
"args": [
"C:\\path\\to\\kusiscribe-core\\server_mcp.py"
]
}
}
}Cursor / Windsurf / Antigravity
Configure the server executable:
Command:
pythonArguments:
["/absolute/path/to/kusiscribe-core/server_mcp.py"]Transport:
stdio
Repository Structure
kusiscribe-core/
├── EXPERIMENTOS/
│ ├── experimento_lost_in_the_middle.md # 450 GPU inference benchmark
│ └── README.md
├── PLAYBOOKS/
│ ├── playbook_despliegue_produccion.md # Sample SOP
│ └── README.md
├── SCRIPTS/
│ ├── saneamiento_fichas.py # Health check & audit utility
│ └── README.md
├── examples/
│ ├── demo_transcript.jsonl # Synthetic test transcript
│ └── README.md
├── arrancar_kusiscribe.bat # Windows quickstart launcher
├── buscar.py # Forensic terminal CLI
├── config.example.json # Configuration template
├── kusiscribe_distill.py # KusiAI atomic memory distillation engine
├── requirements.txt # Python dependencies
├── server_mcp.py # 12-tool JSON-RPC 2.0 MCP server
├── watcher.py # Single-writer forensic notary daemon
├── .gitignore # Secret and data isolation rules
├── LICENSE # MIT License
└── README.md # Master documentationSecurity & Privacy Policy
KusiScribe Core is engineered for enterprise-grade privacy:
All transcripts, index files, and memory cards are stored locally in plain markdown and JSON.
The repository's default
.gitignoreprevents logs, state files, credentials, and transcript folders from ever being tracked in Git.No telemetry, no external callbacks, and no cloud dependencies beyond your own self-hosted or configured LLM endpoint.
License
MIT License. Developed by KusiAI. Free for personal, commercial, and research use.
This server cannot be deployed
Maintenance
Related MCP Connectors
- memnodeOAuthdev.memnode
Persistent, inspectable memory for AI agents with lineage, correction, and a hosted MCP endpoint.
- KogniteOAuthdev.kognite
Hosted agent memory: store, search, and recall facts across sessions from any MCP client.
- MemocoreOAuthai.memocore
Shared memory for all your AI agents, your whole team and every MCP client — save, search, recall.
- EngramOAuthapp.getengram
Persistent, verbatim, searchable memory for AI assistants — one memory across every MCP client.
Related MCP Servers
- AlicenseNot gradedqualityCmaintenanceA local MCP memory server giving LLMs a persistent, auditable memory fabric with temporal awareness, relationship tracking, and contradiction detection.MIT
- AlicenseNot gradedqualityBmaintenanceA local MCP server that provides a sovereign memory substrate for LLMs, enabling capture, recall, explanation, and anticipation of conversation turns with bi-temporal events and a strict read-only query surface.Apache 2.0

CarpeOS MCP Serverofficial
AlicenseNot gradedqualityAmaintenanceEnables AI agents to capture, search, and manage structured memory from agent sessions with append-only events and provenance tracking, providing eight local MCP stdio tools.Apache 2.0- AlicenseNot gradedqualityBmaintenanceEnables AI agents to store, search, assemble, and manage local-first memories through seven MCP tools, including conversation turns, feedback, status, and dashboard access without cloud dependencies.AGPL 3.0