
Glassbox Framework
io.github.TheBarmaEffectPublished by GitHub account TheBarmaEffectv1.0.3Updated Oct 27, 2026
Runtime constitutional verification for AI answers — claim reasoning, ECS, red team, audits.
Overview
Local MCP server that runs a verification pipeline over a question and AI answer, returning claims, an ECS score, red-team probes and a Trust Card.
- What you can do
- Verify a question and answer pair through the full pipeline and get a Trust Card with a verdict
- Extract atomic claims from an answer, each with a reasoning chain
- Score epistemic confidence with a per-dimension breakdown and published formula
- Run seven adversarial red-team probes against the answer
- Compile natural-language deployer intents into constitution rules and evaluate the answer against them
- Assemble a Trust Card from prebuilt parts or export an audit report with a deterministic SHA-256 log id
- When to use it
- Useful when you want an assistant to check its own or another model's answers for unsupported claims, overconfidence or policy violations, and to produce a traceable verdict and audit reference. Suited to teams adding a verification step before shipping AI-generated content.
- Requirements
- Runs locally over stdio, installed from the npm package or via npx; a Python client package is also available. Requires an ANTHROPIC_API_KEY for the claim extractor, red team, constitution engines and ECS checks; only the trust-card assembly tool works without one. Optional settings include GLASSBOX_MODEL, GLASSBOX_MAX_TOKENS and GLASSBOX_ECS_MODE. Desktop only.
Installation
In SourceWeft
- Open Glassbox Framework in the dashboard and add it to a workspace.
- Enable the server for the chats that should use its tools.
Desktop only via STDIO. STDIO servers start a local process, so they need the SourceWeft desktop host.
Other MCP clients
Follow the launch instructions in the repository.
README
Glass Box Framework
Runtime constitutional verification for AI answers. Every claim carries a reasoning chain. Every score breaks down. Every verdict is traceable.
[CI] [PyPI version] [npm version] [Homebrew] [MCP Registry] [PyPI downloads] [License] [GitHub stars]
⭐️ Star this repo if you want runtime AI verification to become the default. Every star moves Glassbox up the search ranking on GitHub, the MCP Registry, and Smithery — which means more developers find this before they ship an AI feature without a Trust Card.
[Glassbox in 70 seconds — walkthrough of all 6 tools]
Zero-cost public GlassBox Lite
The repository also ships a separate deterministic Lite verifier and cross-platform gateway that require no paid model API:
- Web app / installable PWA
- Public remote MCP for ChatGPT, Claude, and compatible clients
- GitHub App
- Discord
- Telegram
- Notion: embed
https://glassbox-platform-gateway.onrender.com/app - Browser, VS Code, and JetBrains packages: latest GitHub release
Lite performs bounded structural checks and does not browse or establish factual truth. The original six-tool model-assisted MCP documented below remains a separate surface.
See PLATFORMS.md for the exact live, downloadable, pilot, and external-review status of every integration.
What it is
The Glass Box Framework hands an (question, answer) pair to a runtime verification pipeline and returns a structured Trust Card containing:
- Claims — every atomic assertion in the answer, paired with a reasoning chain explaining why it's asserted, what would support it, and what would falsify it.
- Epistemic Confidence Score (ECS) — a transparent, weighted aggregate over five dimensions with a published formula and an always-visible per-dimension breakdown.
- Glassbox Court — seven adversarial probes (fabrication, source manipulation, bias injection, context attack, overconfidence, underspecification, constitutional violation).
- Constitution — your natural-language deployer intents compiled into structured runtime rules and evaluated against the answer.
- Verdict —
trust/caution/reject, with the exact reasoning that derived it. - Audit reference — a deterministic SHA-256 log_id; identical inputs reproduce the same identifier across runs and languages.
It is intentionally not a wrapper around a single LLM call — the reasoning chain on every claim, the formula on the ECS, and the determinism of the audit hash together form the "Glass Box" principle: no opaque scores.
Quick start (Python)
The six tools
Full schemas, examples, and configuration: mcp/README.md. Python pip-specific docs: mcp/python/README.md.
Architecture (two-layer)
The Python client makes zero LLM calls itself; it forwards arguments to the MCP server over stdio and renders the returned JSON. Set ANTHROPIC_API_KEY once and both layers use it.
Use with Claude Desktop
~/Library/Application Support/Claude/claude_desktop_config.json on macOS.
Determinism
Audit log_ids are SHA-256 over canonicalised JSON of (inputs_hash, claims, ECS dimensions, red-team probe verdicts, constitution evaluations). Timestamps are recorded but never enter the hash, so identical inputs and identical engine outputs always produce the same log_id — across runs, machines, and even languages (the Python client → Node server → JSON canonicalisation produces byte-identical hashes).
Verifiable example, no API key needed:
Project layout
Contributing
Glassbox is open source under Apache 2.0 and actively wants forks and PRs. A few specific places we'd love help:
- More red-team probes —
mcp/src/engines/redteam.tshas// v2:placeholders foralignment_faking,reasoning_trace_deception,eval_awareness_gaming,agentic_misalignment, andsustained_jailbreak. Each is a tractable PR — same shape as the existing 7 probes, just a different angle. See.github/ISSUE_TEMPLATE/good_first_issue.md. - More language clients — currently Python (
glassbox-framework) and Node (@glassbox-framework/mcp). Go, Rust, Ruby, Swift, Kotlin would all be welcome as thin JSON-RPC clients that spawn the existing MCP server. - More integrations — Cursor / Cline / Continue / Roo Cline / Zed / Neovim — wherever MCP is read, Glassbox should be one paste away.
- Real-world Trust Card examples — submit (Q, A) pairs from your own AI workflows so the test suite covers more terrain.
Process:
- Pick a
good first issueor open one with your idea - Fork, branch, work — the PR template walks you through verification
- CI must pass (
.github/workflows/ci.yml) — TS strict mode, Python wheel build, cross-language determinism on the canonical audit hash - Open the PR; we aim for review within 48 hours
Code of conduct: Contributor Covenant 2.1. Be kind, stay on substance, no harassment, contact [email protected] for anything off-public-channel.
Star ⭐ this repo
The fastest way to help right now is to star the repo. Every star:
- Surfaces Glassbox higher in GitHub's MCP topic listings
- Pushes the project up on the MCP Registry and Smithery rankings
- Tells the next developer evaluating AI-safety tooling that this is the one with eyes on it
Author
Karthik Barma · MS Artificial Intelligence · Northeastern University.
Powered by Aura.
Issues + PRs: https://github.com/TheBarmaEffect/glassbox/issues
Source: README.md at commit 97a7fe7
Tools
0Version history
1- v1.0.3LatestSep 16, 2026
Score
50% of the applicable checks met
How complete this listing is, computed from the registry entry, the endpoint and public sources. Not a rating of the server and not a statement that it is safe or working today: reachability is a dated check, and no installs or reviews go into the score.
- Reached in the last 30 days25 pts
Keep the endpoint answering the MCP handshake; SourceWeft probes it every 30 days.
- Auth declared10 pts
Declare the credential headers in the registry entry, or keep the endpoint answering the probe so its auth can be classified.
- Tools listed15 pts
Answer tools/list without a credential, or ship a package that starts in a sandbox without one.
- DescriptionRequired15 pts
- Logo10 pts
- Documentation15 pts
- License10 pts