Skip to main content

Bartholomew AI • BTP v2.2 Standards Track

Cryptographic Trust Protocol & Autonomous Pre-Flight Execution Gate for AI Agents

OpenSSF Best Practices DOI Protocol Status CI Security Gate License MCP Server


[EXECUTIVE_SUMMARY] What is Bartholomew & BTP?

Bartholomew is the open cryptographic trust and verification gateway for autonomous AI agents.
Built on the Bartholomew Trust Protocol (BTP v2.2 Standards Track), it replaces probabilistic prompt filters with deterministic, hermetic pre-flight sandboxing and signed RFC 8785 Ed25519 attestations. Downstream execution environments (LangGraph, AutoGen, CrewAI, MCP, Kubernetes clusters) verify agent tool calls 100% offline in sub-50 microseconds with zero cloud dependencies.


⚡ 3-Second Live Terminal Showcase

Test the in-process AST scanner, hermetic path sandbox, LDMU loop governor, and Ed25519 notary on your machine:

# Clone and run the live 5-scenario attack simulation
git clone https://github.com/ivegotahunnitonit/bartholomew.git
cd bartholomew
python cli.py demo

60-Second Multi-Language Quickstarts

1. Python (pip install btp-guard)

from btp_guard import Guard

# Set spend limit and max retries
guard = Guard(spend_cap=100.0, max_retries=5)

# Protect any agent tool or function with a decorator
@guard.protect
def execute_database_query(sql_query: str):
    # If the agent attempts a DROP TABLE or exceeds budget,
    # it is blocked in <5 microseconds before executing.
    return db.execute(sql_query)

# Or check actions directly:
result = guard.check("rm -rf /var/data")
print(result["allowed"]) # False
print(result["reason"])  # "Policy Violation: Trajectory contained forbidden pattern 'rm -rf'"

2. TypeScript / Node.js (npm install @bartholomew/btp-guard)

import { BTPGuard } from '@bartholomew/btp-guard';

const guard = new BTPGuard();
const receipt = guard.evaluateAction({
  agentId: 'claude-desktop',
  actionType: 'DATABASE_MUTATION',
  payload: { query: 'DROP TABLE accounts;' }
});
console.log(receipt.verdict); // "DENY" (Blocked in 11 µs)

3. Go (go get github.com/ivegotahunnitonit/bartholomew/pkg/btp)

package main
import "fmt"
import "github.com/ivegotahunnitonit/bartholomew/pkg/btp"

func main() {
    guard := btp.NewGuard()
    verdict := guard.Evaluate("AGENT_01", "DB_READ", map[string]interface{}{"id": 101})
    fmt.Println("Verdict:", verdict) // ALLOW (0.00s latency)
}

4. Command-Line CLI

# Validate declarative YAML security policies
python -m src.cli policy validate --file policies/default_security_policy.yaml

# Test an action payload directly in your terminal
python -m src.cli policy eval -f policies/default_security_policy.yaml -p '{"query": "SELECT 1"}'

[FRAMEWORK_ADAPTERS] 1-Line Drop-in Middleware

Framework Integration File 1-Line Guard Description
LangGraph / LangChain framework_adapters/langgraph/ @guard.wrap_tool Protects database & tool calls with offline Ed25519 receipts
Microsoft AutoGen framework_adapters/autogen/ guard.intercept_message() Blocks confused-deputy tool exploits in multi-agent chat
CrewAI framework_adapters/crewai/ guard.wrap_task() Enforces pre-flight capability containment (NO_NET_EGRESS)
Anthropic MCP mcp_server/ mcp-server-bartholomew Native Model Context Protocol security server for Claude Desktop

[OFFLINE_VERIFIERS] Zero-Dependency Cross-Language Reference Verifiers


[INTERACTIVE_DEMO] Live AST Auto-Fix Test Scenarios

Click any test case below to inspect the deterministic compiler mutation and verification diff:

[TEST_CASE_01] Async Event Loop Deprecation Crash (Python 3.12+)
# Target: worker.py (Root cause: asyncio.get_event_loop() deprecated in Python 3.12+)
def execute_async_task(task_payload):
-   loop = asyncio.get_event_loop()
-   return loop.run_until_complete(worker_coroutine(task_payload))
+   loop = asyncio.new_event_loop()
+   asyncio.set_event_loop(loop)
+   try:
+       return loop.run_until_complete(worker_coroutine(task_payload))
+   finally:
+       loop.close()

# Verification Receipt: 48/48 unit tests passed | Latency: 0.14s | Zero regressions
[TEST_CASE_02] Python 3.14 AST Constant() Node Migration (Google Python Fire)
# Target: fire/core.py (Root cause: ast.Str, ast.Num removed in Python 3.14)
class LiteralExtractor(ast.NodeVisitor):
    def visit_Constant(self, node):
-       if isinstance(node, (ast.Str, ast.Num)):
-           self.literals.append(node.n if hasattr(node, 'n') else node.s)
+       if isinstance(node, ast.Constant):
+           self.literals.append(node.value)

# Verification Receipt: 112/112 test suite passed | AST Delta: 2 lines | Formally verified
[TEST_CASE_03] Socket File Descriptor Teardown Leak
# Target: transport/socket_pool.py (Root cause: unclosed socket upon timeout exception)
def transmit_payload(sock, buffer):
-   sock.sendall(buffer)
-   return sock.recv(4096)
+   with sock:
+       sock.sendall(buffer)
+       return sock.recv(4096)

# Verification Receipt: Memory & socket leak checks verified | Exit code 0

[EMPIRICAL_TELEMETRY] 10,000,000-Cycle Multi-Core Stress Benchmark

Metric Empirical Result Architecture / Substrate
Total Attestation Cycles 9,999,996 Cycles (~10M) Executed across 12 parallel CPU cores
Pass Reliability 100.0000% Zero regressions ($0\text{ failures}$, $0.00000%$)
Throughput 22,921.37 ops/sec Verified RFC 8785 Ed25519 signatures
Kernel Intercept Latency 1.14 μs Compiled Go Trajectory Daemon (11.98M ops/sec)
Average Surgical Delta 3 Lines Minimal AST transformation (zero drift)

[ARCHITECTURE] The 4-Step Mechanical Verification Engine

 [1. INGEST & REPRODUCE]   --->   [2. SURGICAL AST PATCH]   --->   [3. 100% PRE-FLIGHT TEST]   --->   [4. SIGNED PR]
 Webhook intercepts crash        Calculates minimal 3-line       Executes test battery in        Attaches Ed25519 proof
 in hermetic sandbox             compiler syntax delta           isolated container              & opens green PR

[QUICK_ACTIONS] Interactive Workspace Hub

Interface Direct Production URL Description
Web Platform www.bartholomew.info Primary landing page & feature overview
Command Center app.bartholomew.info/dashboard Real-time agent monitoring & telemetry
Operations Hub app.bartholomew.info/operations Live trajectory logs & verifier console
Auto-Fix Simulator app.bartholomew.info/simulator Interactive multi-turn attack & repair harness
Investor Deck pitch.bartholomew.info/PITCH_DECK.html 10-Slide technical and market overview
Executive Proposal www.bartholomew.info/BARTHOLOMEW_EXECUTIVE_PROPOSAL.pdf Official grant and investment proposal (PDF)

[INTELLECTUAL_PROPERTY] Commercial Protection Notice

NOTICE OF PROPRIETARY OWNERSHIP & RESTRICTED COMMERCIAL USE:

All code, compiler AST transformations, Go trajectory intercept daemons, RFC 8785 cryptographic attestation algorithms, and autonomous reproduction pipelines contained within this repository are the exclusive proprietary intellectual property of Bartholomew AI & Contributors.

  • Zero Unauthorized Duplication: No entity, organization, or automated crawler is granted permission to clone, sub-license, scrape, train commercial AI models upon, or re-distribute this codebase without an explicit, signed commercial licensing agreement.
  • Cryptographic Verification: Every commit, release artifact, and execution receipt is cryptographically hashed and signed via RFC 8785 JSON Canonicalization and Ed25519 digital signatures registered to our root key authority.
  • Patent & Trade Secret Protections: The mechanical AST delta synthesis, hermetic reproduction synthesis, and sub-microsecond POSIX execution boundary algorithms are protected under international copyright, trademark, and trade secret laws.

For commercial enterprise licensing, contact: help@bartholomew.info (routing to itsub@bartholomew.info).


© 2026 Bartholomew AI & Contributors. All Rights Reserved.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

btp_guard-2.3.0.tar.gz (133.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

btp_guard-2.3.0-py3-none-any.whl (106.2 kB view details)

Uploaded Python 3

File details

Details for the file btp_guard-2.3.0.tar.gz.

File metadata

  • Download URL: btp_guard-2.3.0.tar.gz
  • Upload date:
  • Size: 133.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.14.6

File hashes

Hashes for btp_guard-2.3.0.tar.gz
Algorithm Hash digest
SHA256 4a84bbd71cb906b8674ee56f2820c7d842a57dadbc079cb66e7f68c87d73df1e
MD5 19f65ef66fe2b069e63fb4117998adfa
BLAKE2b-256 7e68cc4370cc65ed485a40316061418befaea7ae2aa66818fc88e3c64758320a

See more details on using hashes here.

File details

Details for the file btp_guard-2.3.0-py3-none-any.whl.

File metadata

  • Download URL: btp_guard-2.3.0-py3-none-any.whl
  • Upload date:
  • Size: 106.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.14.6

File hashes

Hashes for btp_guard-2.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 28edfa78b649723e2017183c6e7c10aa26996d04cd1e28a2a55843e56e620248
MD5 81a49b84b138a8b34e682c4b8c65a543
BLAKE2b-256 9718c5eb776b2be826635c733e86a2530b0c6e518d3ddcb15c3fc1369c9ebab3

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

2.3.0 This release

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page