npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@turwin/mcp-server

v0.1.0

Published

Turwin verification MCP server - exposes verified AI code generation via Model Context Protocol

Readme

@turwin/mcp-server

Verified AI code generation via Model Context Protocol - Connect Claude Desktop and other AI assistants to Turwin's mathematical verification engine.

npm version License: MIT

What is This?

Turwin MCP Server exposes Turwin's verification capabilities as tools for AI assistants through the Model Context Protocol. Get mathematically verified code generation with ε-robustness guarantees, martingale convergence proofs, and cryptographic certificates.

Key Features

  • 🔬 Mathematical Verification - ε-robustness, martingale convergence, falsification loop
  • 🎯 Real-Time Certification - Connects to Firebase Cloud Functions for production verification
  • 🛡️ Cryptographic Proof - SHA-256 proof hashes with blockchain timestamps
  • 🔄 Automatic Fallback - Mock kernel for testing without credentials
  • 📦 Zero Config - Works out of the box, optionally connects to real API

Quick Start

Installation

npm install -g @turwin/mcp-server

Claude Desktop Setup

Add to ~/Library/Application Support/Claude/claude_desktop_config.json:

{
  "mcpServers": {
    "turwin": {
      "command": "npx",
      "args": ["-y", "@turwin/mcp-server"]
    }
  }
}

Restart Claude Desktop. You'll now have 3 Turwin verification tools available!

Available Tools

1. turwin_execute_protocol

Execute and verify an AI protocol with mathematical guarantees.

Input:

{
  "protocol": "Build a secure authentication system with OAuth2",
  "goal": "Ensure security and reliability"
}

Output: Execution ID, verification status, certificate, artifacts

2. turwin_verify_code

Verify code against specified constraints.

Input:

{
  "code": "function authenticate(user) { ... }",
  "constraints": [
    "No SQL injection vulnerabilities",
    "Proper error handling",
    "Type-safe inputs"
  ]
}

Output: Per-constraint verification results with proofs

3. turwin_get_certificate

Retrieve a previously generated certificate.

Input:

{
  "executionId": "cert_abc123..."
}

Output: Full certificate with proof artifacts

Production Setup (Real API)

Configuration

Create .env file or set environment variables:

FIREBASE_FUNCTIONS_URL=https://us-central1-your-project.cloudfunctions.net
FIREBASE_API_KEY=your_firebase_api_key

Update Claude Desktop config:

{
  "mcpServers": {
    "turwin": {
      "command": "node",
      "args": ["/path/to/node_modules/@turwin/mcp-server/dist/index.js"],
      "env": {
        "FIREBASE_FUNCTIONS_URL": "https://us-central1-your-project.cloudfunctions.net",
        "FIREBASE_API_KEY": "your_api_key_here"
      }
    }
  }
}

See FIREBASE_INTEGRATION.md for complete setup guide.

How It Works

Architecture

AI Assistant (Claude Desktop)
    ↓ Model Context Protocol
Turwin MCP Server
    ↓ HTTP + Firebase Auth
Firebase Cloud Functions
    ├── /certify → TurwinVerificationEngine
    ├── /getCertificationStatus
    └── /vaosApi/verify

Verification Process

  1. Protocol Submission → MCP tool called from AI assistant
  2. Certification Request → HTTP POST to /certify with protocol content
  3. Mathematical Verification → Turwin engine runs ε-robustness, martingale convergence, falsification loop
  4. Certificate Generation → Cryptographic proof hash (SHA-256)
  5. Result Return → Certificate with verification status, confidence scores, warnings, recommendations

Development

Local Testing

git clone https://github.com/your-org/turwin-mcp-server.git
cd turwin-mcp-server
npm install
npm run build
npm start

Mock Mode (No Firebase)

Without .env credentials, the server runs in mock mode:

  • ✅ All tools functional
  • ✅ Valid certificate structures
  • ⚠️ Mock verification (not real proofs)

Perfect for testing and development!

Configuration Options

Certification Levels

| Level | ε-threshold | Confidence | Use Case | |-------|-------------|------------|----------| | basic | 0.1 | 0.8 | Prototyping, low-risk | | standard | 0.01 | 0.95 | Production systems | | critical | 0.001 | 0.999 | Financial, healthcare | | ultra-critical | 0.0001 | 0.9999 | Safety-critical systems |

Documentation

License

MIT © Turwin