Skip to main content
Glama

Sentinela MCP

A lessons-learned oracle that refuses to record a "success" it can't attribute to anything but the agent's own opinion.

License: Apache 2.0 MCP Python 3.12+

A Model Context Protocol server that gives coding agents a durable, cross-session memory of what worked and what didn't — with one hard rule baked into the write path: an agent cannot write its own success story.

Built by Luclino Cruz for LuCross, a one-person, AI-agent-operated holding company. Released publicly because the "no self-graded verdicts" constraint is broadly useful, not because it's a finished, install-anywhere product — see Requirements below before you assume it drops into your project.


The problem this solves

An agent finishes a task and reports success. Nothing verifies that claim — the next session (or the next agent) has no memory that this exact mistake was already made and already corrected, so it happily repeats it. Worse: if the agent itself gets to decide what counts as "success" and write that down as a lesson, the lesson can be wrong from the moment it's created.

This project's own dogfooding caught exactly that failure: a production run recorded a "lesson-success" note claiming "final audit validated 80/80 articles clean and compliant." An external, five-minute audit of the actual files — run minutes later — found the opposite: fabricated data still present, several articles at 2-3x the stated length limit, review verdicts copy-pasted across unrelated files. The lesson was accepted as true before anyone outside the agent had checked it.

Related MCP server: cogmem

The 3 tools

Tool

What it does

consultar_sentinela(agente, tarefa, tags)

Returns past corrections ("never repeat") and past confirmations ("worth repeating") relevant to this agent/task, read from a plain-Markdown vault — no vector DB, no embeddings, just files any tool can read.

reportar_resultado(agente, tarefa, resultado, veredito, detalhe, fonte_veredito, ...)

Records a durable lesson (success or failure) — but only if fonte_veredito is one of chairman_aprovou / chairman_corrigiu / metrica_objetiva. Anything else is refused outright. The agent that did the work cannot be the source of the verdict about the work.

session_brief(braco, dias)

Aggregates recent lessons (default: last 7 days) for injection at session start, so an agent starts a task already knowing what's already gone wrong in this area.

Why refuse self-graded verdicts instead of just trusting the agent

Because trusting it is exactly what fails. The rejection in reportar_resultado isn't a formal proof system or a second model checking the first — it's a deliberately blunt gate: if you can't point to a human approval, a human correction, or an external objective metric, the "lesson" doesn't get written. No exceptions, no "but I'm pretty confident" carve-out.

Requirements

This repo has a hard runtime dependency it does not vendor: parsers.py imports VaultValidator from a sibling vault-guardian MCP project (the write-gate that actually validates and commits a lesson to the vault) via sys.path — see the top of parsers.py. That sibling project is not published yet. Cloning this repo alone gets you:

  • Full, working source for consultar_sentinela and session_brief's logic (parsers.py module load will still fail without the sibling — see below), and a complete reference for the "never accept a self-graded verdict" pattern.

  • Not a turnkey install — import parsers fails at module load time (from validator import VaultValidator) until you either (a) also have a vault-guardian directory as a sibling of this one implementing the same VaultValidator.from_schema_file(path) / .validate_write(...) interface, or (b) fork this and swap that import for your own write-gate (a plain "write this Markdown file with frontmatter" function is enough to satisfy the interface parsers.py expects).

This is published as-is, honestly labeled, rather than silently pretending it's a one-command install — which would be exactly the kind of unverified claim this project exists to prevent.

Quick start (once you have a compatible vault-guardian sibling)

git clone https://github.com/luclinocruz/lucross-sentinela-mcp.git
cd lucross-sentinela-mcp
python -m venv .venv
.venv/Scripts/activate   # or: source .venv/bin/activate on Linux/macOS
pip install -r requirements.txt

Register as a project-scoped MCP server (.mcp.json in your project root):

{
  "mcpServers": {
    "sentinela": {
      "command": "/absolute/path/to/lucross-sentinela-mcp/.venv/bin/python",
      "args": ["/absolute/path/to/lucross-sentinela-mcp/server.py"],
      "cwd": "/absolute/path/to/lucross-sentinela-mcp"
    }
  }
}

By default, legacy-memory fallback reads from ~/.claude/projects/C--Users-<you>/memory — override with the SENTINELA_MEMORY_DIR environment variable if your setup differs.

Design notes

  • Plain Markdown vault, not a database. Lessons are files with YAML frontmatter (type: lesson-error / lesson-success) — readable and editable by any tool, not locked into this server.

  • No neural network, no formal proof. The "rigor" here is a hard business rule (verdict source allow-list), not a model judging another model. Simple, auditable, impossible to argue around.

  • Stateless per call. Every tool call reads the vault fresh — no in-memory cache to go stale or get out of sync across sessions.

License

Apache License 2.0 — see LICENSE.

Author

Luclino Cruzgithub.com/luclinocruz

Built as part of the harness for LuCross, a solo-operated, AI-agent-driven company. See also lucross-sensory-grounding-mcp, the sibling project that applies the same "no self-graded verdicts" rule to visual/audio/video/text output.

A
license - permissive license
-
quality - not tested
C
maintenance

Maintenance

Maintainers
Response time
Release cycle
Releases (12mo)
Commit activity

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Servers

  • A
    license
    A
    quality
    A
    maintenance
    Self-improving, verifiable memory for AI coding agents. Learns how you work, stops repeating mistakes, models each project, recalls the right lesson at the right moment. Every memory is signed and tamper-evident. Local-first.
    Last updated
    8
    2
    Apache 2.0
  • A
    license
    A
    quality
    B
    maintenance
    Local-first project memory for AI coding agents. Records failed attempts, fragile files, and decisions per repo, and warns the agent via hooks before it repeats a recorded mistake.
    Last updated
    6
    42
    MIT

View all related MCP servers

Related MCP Connectors

  • Experience memory for coding agents: validated traps, fixes and dead-ends at decision time.

  • Persistent memory for AI agents — verbatim conversations, searchable by meaning.

  • Adaptive plan/build/review cycles for AI coding assistants, persisted across sessions.

View all MCP Connectors

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/luclinocruz/lucross-sentinela-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server