Skip to content

Latest commit

Β 

History

21 Commits

Folders and files

NameName
Last commit message
Last commit date
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

πŸ›‘οΈ ProofCore Python SDK

PyPI Version Python Versions License: MIT TON Blockchain Strict Zero-Storage

Decentralized Cryptographic Evidence Layer for Autonomous AI Agents, Developers, and DevOps.
Anchor text, model inferences, and software supply chains to The Open Network (TON) Blockchain via Merkle trees.


⚑ The Problem & The Solution

In the era of autonomous AI agents, digital trust is broken:

  • Denial of Generation: AI outputs can be secretly altered or deleted.
  • Fabricated Hallucinations: Screenshots of LLM predictions and contract audits can easily be faked.
  • Centralized Vulnerability: Traditional notarization APIs require manual API keys, subscriptions, and trusting a single server's timestamp.

ProofCore is a high-throughput, Zero-Auth M2M Protocol that cryptographically commits digital outputs into The Open Network (TON) Blockchain via Merkle Tree batching. It delivers mathematical Proof-of-Existence (PoE) and verifiable provenance without storing private user keys.

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”     POST /api/v0.1/seal     β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚ Autonomous AI  β”‚ ──────────────────────────> β”‚   ProofCore    β”‚
β”‚ Agent / LLM    β”‚ <────────────────────────── β”‚   API Gateway  β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜    Instant Citation Badge   β””β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                                                       β”‚
                                            SHA-256 Merkle Batching
                                                       β”‚
                                                       β–Ό
                                            β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
                                            β”‚   TON Blockchain   β”‚
                                            β”‚ (Immutable Anchor) β”‚
                                            β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

⚑ Core Axiom

β€œDon't trust ProofCore. Verify the mathematical proof yourself.”

ProofCore separates cryptographic trust from vendor dependency:

  • Instant Attestation (<10ms): Server signs SHA-256 payload digests with an Ed25519 notary key.
  • Decentralized Anchor (~30s): Aggregates thousands of hashes into a single RFC 6962 Merkle root anchored in a public TON block.
  • Strict Zero-Storage: Raw inputs and prompts are processed in RAM and discarded. Hashes are anchored; your data never touches our disk.
  • 100% Offline Verifiability: Verify proofs locally without internet, API keys, or ProofCore servers.

πŸš€ Installation

pip install --upgrade proofcore

Optional agent ecosystem dependencies:

pip install proofcore[langchain]  # LangChain tools
pip install proofcore[crewai]     # CrewAI tools
pip install proofcore[gradio]     # Gradio UI components

πŸ› οΈ Quickstart

1. Atomic AI Inference Sealing (Eliminates JSON Escaping Bugs)

Best for LLM pipelines and autonomous agents. Prevents prompt/output tampering:

import proofcore

proof = proofcore.seal_inference(
    prompt="Audit this Solidity contract for reentrancy vulnerabilities...",
    output="Audit complete. Severity: 0 High, 0 Critical. Safe for mainnet deployment.",
    model_id="claude-3-5-sonnet-20241022",
    title="Vault.sol Security Audit"
)

print(f"Deal ID: {proof['deal_id']}")
print(f"Explorer URL: {proof['verification_url']}")
print(f"Verification Badge: {proof['badge_markdown']}")

2. General Text / Raw JSON Sealing (WYSIWYWH)

Accepts plain text, markdown, source code, or arbitrary stringified JSON envelopes (e.g. precomputed hashes of terabyte datasets):

import proofcore

# Plain text or code
proof = proofcore.seal(
    content="Bilateral Agreement Terms: Party A agrees to pay Party B $5,000 on delivery.",
    title="Freelance P2P Milestone"
)

# Or stringified JSON envelope containing offline hashes
proof_json = proofcore.seal(
    content='{"dataset": "imagenet-subset.tar.gz", "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855"}',
    title="ML Training Dataset Checksum"
)

3. Multi-File Artifacts & SBOM Batching

Seal multiple files or codebases into a single cryptographic batch:

import proofcore

files = [
    {"filename": "main.py", "content": "print('hello world')"},
    {"filename": "requirements.txt", "content": "fastapi==0.115.0\npydantic==2.9.2"},
    {"filename": "sbom.json", "content": '{"spdxVersion": "SPDX-2.3", "packages": []}'}
]

proof = proofcore.seal_artifacts(
    files=files,
    title="Release v1.0.0 Artifacts"
)

πŸ” Independent Verification

ProofCore gives you two independent verification workflows:

A. 100% Offline Local Verification (The Killer Feature)

Mathematically verify that a string matches a proof manifest locally. Zero network calls, zero vendor dependency:

import proofcore

# Fetch the proof manifest once (or load from local proof.json)
proof_data = proofcore.get_proof("b4ed4c20-7f2a-4c8d-9a81-123456789abc")

# Verify offline!
result = proofcore.verify_local(
    content="Audit complete. Severity: 0 High, 0 Critical. Safe for mainnet deployment.",
    proof_data=proof_data
)

if result["valid"]:
    print(f"βœ… Cryptographically Proven! Merkle Root: {result['calculated_merkle_root']}")
    print(f"TON Transaction: {result['ton_tx_hash']}")
else:
    print(f"❌ Verification Failed: {result.get('error')}")

B. Remote M2M Verification (Gateway Check)

Verify content directly against the ProofCore notary oracle:

import proofcore

result = proofcore.verify(
    deal_id="b4ed4c20-7f2a-4c8d-9a81-123456789abc",
    content="Audit complete. Severity: 0 High, 0 Critical. Safe for mainnet deployment."
)

print(result["valid"])  # True / False
print(result["checks"]["signature_valid"])  # Ed25519 Notary Signature

πŸ€– Model Context Protocol (MCP) Integration

ProofCore hosts a public, zero-auth Model Context Protocol server.

Connect to Cursor / Windsurf

Add to .cursor/mcp.json or Windsurf settings:

{
  "mcpServers": {
    "proofcore": {
      "url": "https://mcp.proofcore.org"
    }
  }
}

Connect to Claude Desktop / Claude Code

claude mcp add proofcore https://mcp.proofcore.org

🧩 Agent Framework Tools

LangChain Integration

from proofcore.langchain import ProofCoreSealerTool, ProofCoreVerifierTool
from langchain.agents import initialize_agent, AgentType
from langchain_openai import ChatOpenAI

tools = [ProofCoreSealerTool(), ProofCoreVerifierTool()]
agent = initialize_agent(tools, ChatOpenAI(model="gpt-4o"), agent=AgentType.OPENAI_FUNCTIONS)

agent.run("Review this smart contract and cryptographically seal your findings.")

CrewAI Integration

from crewai import Agent, Task, Crew
from proofcore.crewai import ProofCoreCrewTool

auditor = Agent(
    role="Smart Contract Auditor",
    goal="Identify security vulnerabilities and anchor results to TON Blockchain",
    tools=[ProofCoreCrewTool()],
    verbose=True
)

πŸ”’ Strict Zero-Storage Architecture

ProofCore operates on a strict Zero-Knowledge, Zero-Storage principle for developer APIs:

  1. Payloads sent to /seal are hashed in RAM via SHA-256.
  2. Raw payloads are never written to disk.
  3. The database only records: sha256_hash, merkle_root, deal_id, timestamps, and the Ed25519 notary signature.
  4. GDPR & Enterprise Safe: We physically cannot leak your proprietary source code, secrets, or prompts because we never retain them.

βš–οΈ Evidentiary & Regulatory Alignment

ProofCore Evidence Packages are architected to satisfy digital evidence standards across global jurisdictions:

  • US FRE 902(13) & 902(14): Self-authenticating electronic records verified by a process or system producing an accurate result (hash values).
  • EU AI Act (Article 50): Machine-readable marking and provenance of AI-generated synthetic content.
  • EU eIDAS 2.0 (Reg 2024/1183): Electronic ledgers and timestamps legally recognized across member states.
  • SLSA Level 3 & SBOM: Cryptographic provenance for CI/CD build pipelines using GitHub Actions OIDC tokens.
  • UK Civil Evidence Act 1995: Section 8/9 continuous Chain of Custody validation.

🌐 Ecosystem Links


πŸ“„ License

MIT License Β© 2026 ProofCore Protocol Core Contributors.

About

πŸ›‘ Trust you can't delete. Cryptographic Proof-of-Existence (PoE) engine built on TON Blockchain. Seal Telegram chats, E-Mails, and files into immutable digital evidence compliant with FRE 902 & eIDAS.

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages