base76-research-lab avatar

Cognos Session Memory

base76-research-lab/cognos-session-memory

This server maintains verified session context across Claude conversations using an epistemic trust scoring formula (C = p·(1−Ue−Ua)) that weighs prediction confidence against uncertainty before injecting context. It exposes two MCP tools: save_session to persist summaries with trust scores and load_session to retrieve verified context above a threshold. Under the hood it runs a FastAPI gateway with a /v1/plan endpoint that extracts structured fields from recent SQLite traces, computes trust scores, and either injects a system prompt or flags low-confidence context for review. Reach for this when you need audit trails of what context was injected into prompts or want to gate retrieval on confidence scores rather than dumping all prior session data indiscriminately.

GitHub stars
1
tools
2
transport
STDIO
env var
1
last updated
Mar 3, 2026

Tools

2 tools

Public tool metadata for what this MCP can expose to an agent.

save_sessionTrust-score and persist a session summary

Trust-score and persist a session summary

No parameter schema in public metadata yet.

load_sessionRetrieve last verified context (default threshold: 0.45)

Retrieve last verified context (default threshold: 0.45)

No parameter schema in public metadata yet.

Sponsors

Configuration

COGNOS_TRACE_DB

Path to SQLite trace database (default: data/traces.sqlite3)

Readme

CognOS Session Memory

mcp-name: io.github.base76-research-lab/cognos-session-memory

Verified context injection via epistemic trust scoring for LLMs.

Solves session fragmentation by maintaining verified, high-confidence session context between conversations.

Problem

Large language models suffer from session fragmentation: each new conversation starts without verified context of previous work. This forces repeated explanations, loses decision history, and breaks long-running workflows.

Existing solutions (persistent memory systems, vector retrieval) either:

  • Lack trust scores before injection → hallucinations propagate
  • Don't audit which context was injected → compliance gaps
  • Treat all past information equally → noise overwhelms signal

Solution

A plan-mode gateway that:

  1. Extracts structured context from 3-5 recent traces
  2. Scores context quality via CognOS epistemic formula: C = p · (1 − Ue − Ua)
  3. Injects as system prompt only if C > threshold
  4. Flags for manual review if C < threshold
  5. Audits every context injection with trace IDs → EU AI Act compliance

Architecture


View the full README on GitHub

Details

Repository
github.com/base76-research-lab/cognos-session-memory
Categories
AI & LLM Tools, Monitoring & Observability
Package
cognos-session-memory-mcp
Transport
STDIO
Registry
MCP registry, active

More from base76-research-lab

Related AI & LLM Tools MCP servers

View all
1dingdawg-dev avatarDingdawg Finance Agentdingdawg-dev/dingdawg-finance-agentFinancial analysis AI. Forecasting, audit prep, SOX/GAAP compliance. Accuracy compounds with use.1stars
2dingdawg-dev avatarDingdawg Healthcare Agentdingdawg-dev/dingdawg-healthcare-agentHIPAA-aware healthcare AI. Clinical documentation, compliance checks, audit prep. Free local tier.1stars
3cognitivemyriad avatarVerified Repo Memorycognitivemyriad/mcp-verified-repo-memoryStale-proof repository memory with citations + just-in-time verification + TTL (repo-scoped).1stars
4dingdawg avatarDingdawg Legal Agentdingdawg/dingdawg-agent-1AI contract review, clause drafting, compliance checklists & legal research.0stars
5dingdawg avatarDingdawg Support Agentdingdawg/dingdawg-agent-1AI support agent — ticket classification, response drafting, escalation routing.0stars
6sharedmemoryai avatarMemorysharedmemoryai/mcp-serverPersistent memory for AI agents. Remember, recall, and explore a shared knowledge graph.0stars