AI Developer Tools

Millwright

Millwright is an open-source, self-hosted LLM router that routes AI requests to the lowest-cost model providers based on policy, preserving prompt caches and controlling spend.

Millwright logo

Millwright

Visit website

What is Millwright?

Millwright is an open-source LLM router that directs AI requests to the cheapest appropriate model provider based on policy, preserving prompt cache affinity and controlling spend. It runs between your AI applications and model providers, accepting OpenAI Chat Completions and Anthropic Messages, and routing to OpenAI-compatible APIs, Anthropic, or Amazon Bedrock.

Millwright vs Similar AI Tools

Pricing ModelFreeCustom PricingPaidFree
Free Credits
Key Features
  • Policy-controlled routing with task and risk headers
  • Cache-aware concurrency maintaining independent affinity lanes for cheap, mid, and frontier roles
  • Spend tracking and cost analysis via ledger, CLI commands, and management APIs
  • Composable workflows with conditional branching and retry-safe execution
  • PCI-compliant payment stack with tokenized card vaulting
  • Cooperative bot-mitigation via Web Bot Auth, Skyfire KYA, and signed agent identity
  • Buy GPU hours by the week
  • Instant liquidity for buying and selling
  • Sealed-bid auction for future weeks
  • Wraps shell commands to produce compact, token-efficient output
  • Preserves critical information (errors, line numbers, exit codes)
  • Deduplication and delta summaries for re-run efficiency
Pros
  • Cost control by using cheapest appropriate models
  • Preserves prompt caches across requests
  • Reliable transaction clearing with PCI compliance
  • Works with bot mitigation systems (Cloudflare, Human, Fingerprint)
  • Flexible weekly rental periods
  • Instant liquidity allows selling back unused hours
  • Significantly reduces token usage for common shell commands
  • Preserves exit codes and critical diagnostic information
Cons
  • Requires self-hosting and setup
  • Limited to supported protocols (OpenAI, Anthropic, Bedrock)
  • Limited to transactional workflows only
  • Requires developer integration effort
  • Auction-based pricing can be unpredictable
  • Limited to specific weeks and cluster during initial auction
  • Only supports a limited set of commands out of the box
  • Requires installation and configuration
Best For
  • Teams managing LLM costs
  • Developers needing policy-based routing
  • Developers automating checkout and payment processes
  • Teams building agentic commerce applications
  • AI researchers
  • Machine learning engineers
  • Developers using AI coding assistants to reduce token consumption
  • Teams running frequent git commands or test suites in LLM contexts

How to use Millwright?

  1. 1git clone https://github.com/Northwood-Systems/millwright.git
  2. 2cd millwright
  3. 3cargo install --path . --locked
  4. 4millwright init
  5. 5millwright serve
  6. 6Alternatively, for a local demo:
  7. 7make compose-up
  8. 8curl http://localhost:8080/v1/chat/completions -H 'Authorization: Bearer sk-millwright-local-demo' -H 'Content-Type: application/json' -d '{"model":"millwright-fast","messages":[{"role":"user","content":"Hello"}]}'

Millwright Key Features

  • Policy-controlled routing with task and risk headers
  • Cache-aware concurrency maintaining independent affinity lanes for cheap, mid, and frontier roles
  • Spend tracking and cost analysis via ledger, CLI commands, and management APIs
  • Provider and protocol support for OpenAI Chat Completions, Anthropic Messages, and Amazon Bedrock
  • Self-hosting as a single Rust binary with Docker support; provider credentials stay on your infrastructure

Millwright Use Cases

  • Reduce LLM costs by routing requests to the cheapest model that meets policy requirements
  • Maintain prompt cache reuse across a session by preserving provider/model affinity
  • Switch between providers without changing application code
  • Inspect and audit routing decisions with response headers and ledger entries

Millwright Pricing & Free Credits

Millwright currently operates on a Free model.

This tool is completely free to use

Self-Hosted

Free

Open-source under Apache-2.0 license; no usage limits.

Millwright Pros & Cons

Pros

  • Cost control by using cheapest appropriate models
  • Preserves prompt caches across requests
  • Provider-agnostic; easy to switch without code changes
  • Fully self-hosted; data and credentials remain on your infrastructure
  • Inspectable routing decisions with detailed logging

Cons

  • Requires self-hosting and setup
  • Limited to supported protocols (OpenAI, Anthropic, Bedrock)
  • Not an agent orchestrator; no prompt inspection or rewriting

What is Millwright best for?

  • Teams managing LLM costs
  • Developers needing policy-based routing
  • Enterprises requiring self-hosted privacy

Millwright FAQ

Top free alternatives to Millwright

Manifest logo

Manifest converts any URL into a structured JSON map of what AI agents can interact with on a page—buttons, forms, inputs, and required fields.

Free
B

Personal GitHub Pages site by Basert, currently displaying default welcome content and instructions for using GitHub Pages with Jekyll.

Free
Termaxa logo

A cooperative gate for shell commands that AI agents run, providing previews, backups, policy enforcement, and audit for tools like Claude Code and Cursor.

Free
Agentcard logo

Agentcard provides agent-friendly card issuing and payment infrastructure for AI agents, enabling 5-minute setup and autonomous purchases.

Free
Oodle AI logo

Oodle AI provides agent observability with fast trace search, S3-based storage, and out-of-the-box insights to detect silent failures in AI agents.

Free
Jacquard logo

Jacquard is a small programming language designed for running, reviewing, and trusting programs written by machine-learning models and reviewed by people.

Free
Perfai Security logo

Autonomous security testing platform that finds and fixes access control vulnerabilities in live AI-built apps.

Free
Octolens logo

AI-powered social listening tool that monitors Reddit, X, LinkedIn, and 10+ other platforms, filters mentions with AI, and delivers them to your stack via API, Slack, or webhooks.

Free

Best alternatives AI Tools to Millwright

CartAI logo

CartAI provides an API and MCP server to deploy AI agents that autonomously navigate web properties and complete transactions like checkout, subscriptions, and invoice payments.

Computable logo

A marketplace for buying and selling GPU hours by the week, offering instant liquidity and flexible compute for AI workloads.

szr logo

szr is a Go-native CLI proxy that reduces noisy terminal output before it reaches an LLM context, saving tokens and preserving command exit codes.

CodeAlmanac logo

CodeAlmanac is a living wiki for your codebase, maintained by AI coding agents, capturing decisions, flows, invariants, and gotchas in plain markdown.

Stele logo

Stele provides shared memory for AI coding agents, recording decisions, tasks, and lessons to maintain context across tools and sessions.

Netmon logo

Self-hosted network monitor that runs hourly speed tests, LAN device scans, logs to SQLite, and delivers sarcastic AI-generated reports to Telegram.

SlapMetrics logo

A macOS menu bar app that connects to Stripe, GA4, and Google Search Console to celebrate real-time metrics with emoji rain, sounds, and full-screen reactions.