# Smarty Pants > Smarty Pants is a distributed inference network powered by independently owned Macs: OpenAI-compatible AI on Apple silicon, serving pinned, quantized builds of open models (each build named in /v1/models), priced per token, plus short sandboxed code jobs. Requests run on Macs owned by other people. Owners agree not to read requests and the app doesn't show them, but a serving Mac decrypts each request in memory to answer it, so that is a rule and a design, not a technical guarantee. Don't send sensitive data on the general network. Anyone can sign up with an email at https://smartypants.network/api. New accounts get $10 of free credit, usable for 90 days. Mac owners join separately, by invite. ## Models (live from /v1/models) - `smartypants/arete-27b` (Arete 27B (Smarty Pants)): chat; $0.2 per million input tokens, $1.2 per million output tokens; context 16,384 tokens; license Apache-2.0 (https://huggingface.co/NousResearch/Arete-27B/blob/108f0afbdcfaa1ceeda4a635004304dfff6d4da2/LICENSE); released; check is_ready before sending traffic - `smartypants/axion-1.0-35b` (Axion 1.0 35B (Smarty Pants)): chat; $0.09 per million input tokens, $0.8 per million output tokens; context 16,384 tokens; license Apache-2.0 (https://huggingface.co/Axion1-0/Axion-1.0-35B/blob/d4fdb2d6d284ecc24359bfa161a58b835a63c754/LICENSE); released; check is_ready before sending traffic - `smartypants/wan2.2-5b-video` (Wan 2.2 video (Smarty Pants)): video generation; price in /v1/models; license Apache-2.0 (https://huggingface.co/FastVideo/FastWan2.2-TI2V-5B-FullAttn-Diffusers/blob/3e187042a324f6f5fb68fd22110a78725253de8f/README.md); released; check is_ready before sending traffic - `smartypants/gpt-oss-20b` (gpt-oss-20b (Smarty Pants)): chat; $0.027 per million input tokens, $0.135 per million output tokens; context 16,384 tokens; license Apache-2.0 (https://huggingface.co/openai/gpt-oss-20b/blob/6cee5e81ee83917806bbde320786a8fb61efebee/LICENSE); released; check is_ready before sending traffic - `smartypants/muse-glimmer-30b` (Muse Glimmer 30B (Smarty Pants)): chat; $0.27 per million input tokens, $1.08 per million output tokens; context 16,384 tokens; license Apache-2.0 (https://huggingface.co/meta-models/Muse-Glimmer-30B/blob/cec94fcfd6512f2cfe708138c32533b346ea4f69/LICENSE); released; check is_ready before sending traffic - `smartypants/nanbeige4.3-33b` (Nanbeige4.3 33B (Smarty Pants)): chat; $0.3 per million input tokens, $2 per million output tokens; context 16,384 tokens; license Apache-2.0 (https://huggingface.co/Nurymanau/Nanbeige4.3-33B-MLX-4bit/blob/604f4abb0d4ef97550aa76327dfc3953229b9d74/LICENSE); released; check is_ready before sending traffic - `smartypants/qwen3-embedding-0.6b` (Qwen3 Embedding 0.6B (Smarty Pants)): embeddings; $0.01 per million input tokens; license Apache-2.0 (https://huggingface.co/Qwen/Qwen3-Embedding-0.6B/blob/97b0c614be4d77ee51c0cef4e5f07c00f9eb65b3/README.md); released; check is_ready before sending traffic - `smartypants/qwen3-reranker-0.6b` (Qwen3 Reranker 0.6B (Smarty Pants)): reranking; $0.009 per million input tokens; license Apache-2.0 (https://huggingface.co/Qwen/Qwen3-Reranker-0.6B/blob/e61197ed45024b0ed8a2d74b80b4d909f1255473/README.md); released; check is_ready before sending traffic - `smartypants/qwen3.5-4b` (Qwen3.5 4B (Smarty Pants)): chat; $0.1 per million input tokens, $0.25 per million output tokens; context 8,192 tokens; license Apache-2.0 (https://huggingface.co/Qwen/Qwen3.5-4B/blob/851bf6e806efd8d0a36b00ddf55e13ccb7b8cd0a/LICENSE); early testing, not for production traffic - `smartypants/qwen3.5-9b` (Qwen3.5 9B (Smarty Pants)): chat; $0.1 per million input tokens, $0.4 per million output tokens; context 16,384 tokens; license Apache-2.0 (https://huggingface.co/Qwen/Qwen3.5-9B/blob/c202236235762e1c871ad0ccb60c8ee5ba337b9a/LICENSE); released; check is_ready before sending traffic - `smartypants/qwen3.6-35b-a3b` (Qwen3.6 35B-A3B (Smarty Pants)): chat; $0.09 per million input tokens, $0.8 per million output tokens; context 98,304 tokens; license Apache-2.0 (https://huggingface.co/Qwen/Qwen3.6-35B-A3B/blob/995ad96eacd98c81ed38be0c5b274b04031597b0/LICENSE); released; check is_ready before sending traffic - `smartypants/qwen3.8-27b` (Qwen3.8 27B (Smarty Pants)): chat; $0.2 per million input tokens, $1.2 per million output tokens; context 16,384 tokens; license Apache-2.0 (https://huggingface.co/Qwen/Qwen3.8-27B/blob/1d4bf0f2ff6012fd82039f2fa52739d0dd7c60c0/LICENSE); released; check is_ready before sending traffic - `smartypants/whisper-large-v3-turbo` (Whisper large-v3 turbo (Smarty Pants)): speech to text; price in /v1/models; license MIT (https://huggingface.co/openai/whisper-large-v3-turbo/blob/41f01f3fe87f28c78e2fbf8b568835947dd65ed9/README.md); early testing, not for production traffic ## Endpoints - Base URL: https://smartypants.network/v1 - Auth: `Authorization: Bearer ` (create a key on your account page after sign-in; keep it in `SMARTYPANTS_API_KEY`) - Models: `GET https://smartypants.network/v1/models` lists every model with prices, context size and `is_ready` - Batches: work that can wait, at half the normal per-token price for model calls, results within 24 hours on Macs that are otherwise idle (live work always comes first). OpenAI's Batch API format: upload a JSONL file to `POST https://smartypants.network/v1/files` (purpose batch), then `POST https://smartypants.network/v1/batches` with input_file_id, endpoint and completion_window "24h"; or send `requests: [{custom_id, body}]` inline instead of a file. Endpoints: /v1/chat/completions, /v1/embeddings, /v1/rerank, and /v1/cpu/jobs (code jobs, normal CPU price, where your account has code jobs). Read `GET /v1/batches/{id}`, then the output_file_id with `GET /v1/files/{id}/content`. Up to 10,000 requests per batch and 10 unfinished batches per key - Budget: `GET https://smartypants.network/v1/key` shows this key's own spending limit, what it has spent and what is left (`remaining_usd`), plus the account balance. Check it before long or costly work - Chat: `POST https://smartypants.network/v1/chat/completions` (OpenAI format; streaming, tools and JSON output), for example with `"model": "smartypants/arete-27b"` - Same chat, other request styles: `POST https://smartypants.network/v1/messages` (Claude Messages format; the key may go in `x-api-key`) and `POST https://smartypants.network/v1/responses` (OpenAI Responses format, nothing stored: send the whole conversation each time). Both stream, both pass tools through, both are text only, and replies are capped at 2,048 tokens - Embeddings: `POST https://smartypants.network/v1/embeddings` (OpenAI format) - Reranking: `POST https://smartypants.network/v1/rerank` (Cohere and Jina format: query, documents, top_n; returns index and relevance_score, best first) - Speech to text: `POST https://smartypants.network/v1/audio/transcriptions` (OpenAI format, multipart audio upload) - Video: `POST https://smartypants.network/v1/videos/generations` (model, prompt, size 832x480 or 480x832, seconds 2, 3 or 5; returns an MP4 as b64_json; takes a few minutes). Better for agents: `POST https://smartypants.network/v1/videos` with the same body answers at once with a job id; poll `GET https://smartypants.network/v1/videos/{id}` (status queued with ahead and eta_seconds, in_progress, then completed with the same fields, or failed); a finished clip is held until collected, at most 30 minutes - MCP server: `https://smartypants.network/mcp` (Streamable HTTP, no sign-in): list_models, estimate_cost, find_model, request_model, get_started - Signed-in MCP server: `https://smartypants.network/mcp/account` (OAuth 2.1 with PKCE and app registration; the person signs in by email link and presses Allow). Adds run_prompt, embed (text to vectors for search), rerank (best documents first, once reranking is switched on), get_balance (balance plus this connection's own limit) and add_credit (returns a Stripe payment page for a person to pay); run_code (sandboxed code jobs) and the workspace tools (open_workspace, workspace_run, workspace_write_file, workspace_read_file, workspace_status, close_workspace: one sealed VM that keeps files across many commands) are open to our own account first and appear in the tool list once your account has them - Before sending traffic, check `is_ready` on /v1/models. When it is false, keep your current provider. ## How an agent should use Smarty Pants - Good fit: everyday text work (summaries, extraction, classification, drafting, tool calls, JSON output) and embeddings, where an exact open model is good enough and price matters. Measure quality on your own non-sensitive examples first. - Not a fit yet: work that needs a frontier-size model, more context than a model lists, or strict latency guarantees. Keep your current provider for those, and as a fallback. - Use rules: everyone agrees to the Smarty Pants use rules (https://smartypants.network/legal/acceptable-use) once, when they create an API key. A model whose license has extra rules lists them in `use_rules` on /v1/models; agree once (`POST https://smartypants.network/api/developer/use-rules/agree`, signed in). Until then that model answers 403 `USE_RULES_NOT_AGREED` with the rules and the link. - Do not send secrets, personal, customer, regulated or confidential data unless the person you work for has approved it. - Ask your person before spending. Spending comes from their balance; each connected MCP app is capped at $20 a month and its connection lasts 90 days. A person can give any key its own monthly limit; GET /v1/key (or get_balance over MCP) shows what is left. - Never handle card details. To add money, call add_credit (or send the person to their account page) and give them the payment link; they pay on Stripe. The balance updates about a minute later. - Errors: 402 means not enough balance; 429 or 503 means no Mac is free right now, so wait the `Retry-After` seconds, back off, or use your fallback provider. - Keep the API key in an environment variable, never in code or chat. ## Docs - [Agent kit and docs](https://smartypants.network/docs/agents): copy-ready Python, JavaScript, curl and MCP examples, and these rules - [Python starter kit](https://smartypants.network/kits/smartypants.py) and [JavaScript starter kit](https://smartypants.network/kits/smartypants.mjs): one file each, no packages needed - Command-line tool: `npm install -g smartypants-network` gives `smartypants` for models, balance, code runs, workspaces and fleets, with `--json` output (Node 18+, no dependencies; with npx use `npx smartypants-network`, since `npx smartypants` is an unrelated package). Or [download it](https://smartypants.network/kits/smartypants-cli.mjs) next to the JavaScript kit - Packages: `pip install smartypants-network` (Python kit, module `smartypants_network`) and `npm install smartypants-network` (JavaScript kit plus the command-line tool) - [Agent frameworks](https://smartypants.network/docs/agents#frameworks): LangChain, OpenAI Agents SDK, Vercel AI SDK, LlamaIndex, Claude Code (MCP and a [skill](https://smartypants.network/kits/skills/smartypants/SKILL.md)) and GitHub Actions setups; all of them in [llms-full.txt](https://smartypants.network/llms-full.txt) - [Eval kit](https://smartypants.network/docs/agents#eval-kit) ([Python](https://smartypants.network/kits/eval_kit.py), [JavaScript](https://smartypants.network/kits/eval-kit.mjs)): run a set of tests on one exact model build, score them locally or in a fresh sealed VM, and get a receipt of the exact versions so the run can be repeated - [Job results](https://smartypants.network/v1/results/jobs): what whole jobs (code in, setup, tests, files back) did in the last 30 days, as JSON with a sha256: pass rate, cost per successful job, median and slowest-5% times, jobs that lost a Mac and still finished, and each recent job's steps - [Full agent flow example](https://smartypants.network/kits/agent-e2e.mjs): sign in through MCP, check the balance, run a prompt, add money (Node, no packages) - [OpenAPI description](https://smartypants.network/openapi.json): the public API routes - [Agent brief](https://smartypants.network/agents?format=json): how an agent checks fit and savings, then sets up a reversible trial the person approves - [API guide](https://smartypants.network/api): quickstart for developers - [Request a model](https://smartypants.network/request-a-model): ask us to host a model we do not offer yet (`POST https://smartypants.network/v1/model-wishes` with a Hugging Face link and `"from":"agent"`, no sign-in). We check it at once (license, safe file types, no outside code, fits our Macs) and answer; follow it from requested to checked, in testing and live at `GET https://smartypants.network/v1/model-wishes/{id}` - [First Shown on Smarty Pants](https://smartypants.network/first-on-smarty-pants): open models we served before any other provider, per Hugging Face (`GET https://smartypants.network/v1/first-shown`) - [Live status](https://smartypants.network/api/public/status): Macs connected and models ready - [State machines](https://smartypants.network/api/public/state-machines): every stage a Mac, a model release or a payout can be in, what it means, and the allowed moves ## Optional - [Mac benchmarks](https://huggingface.co/datasets/smartypantsnet/mac-benchmarks): speed and quality on real Macs - [Hugging Face](https://huggingface.co/smartypantsnet): Smarty Pants on Hugging Face - [Legal](https://smartypants.network/legal): terms and privacy - Support: info@howcan.io ## Agent frameworks Smarty Pants speaks the OpenAI API, so these frameworks work by pointing their OpenAI client at https://smartypants.network/v1. ### LangChain (Python) Install: `pip install langchain-openai` ``` import os from langchain_openai import ChatOpenAI, OpenAIEmbeddings llm = ChatOpenAI(model="smartypants/arete-27b", base_url="https://smartypants.network/v1", api_key=os.environ["SMARTYPANTS_API_KEY"], max_retries=3) print(llm.invoke("Summarize: Macs can serve open models.").content) emb = OpenAIEmbeddings(model="smartypants/qwen3-embedding-0.6b", base_url="https://smartypants.network/v1", api_key=os.environ["SMARTYPANTS_API_KEY"], check_embedding_ctx_length=False) ``` ### OpenAI Agents SDK (Python) Install: `pip install openai-agents` ``` import os from openai import AsyncOpenAI from agents import Agent, Runner, OpenAIChatCompletionsModel, set_tracing_disabled set_tracing_disabled(True) # tracing would need an OpenAI key client = AsyncOpenAI(base_url="https://smartypants.network/v1", api_key=os.environ["SMARTYPANTS_API_KEY"]) agent = Agent(name="helper", instructions="Answer in one short paragraph.", model=OpenAIChatCompletionsModel(model="smartypants/arete-27b", openai_client=client)) print(Runner.run_sync(agent, "What is an exact model build?").final_output) ``` ### Vercel AI SDK (TypeScript) Install: `npm install ai @ai-sdk/openai-compatible` ``` import { generateText } from 'ai'; import { createOpenAICompatible } from '@ai-sdk/openai-compatible'; const smartypants = createOpenAICompatible({ name: 'smartypants', baseURL: 'https://smartypants.network/v1', apiKey: process.env.SMARTYPANTS_API_KEY, }); const { text } = await generateText({ model: smartypants('smartypants/arete-27b'), prompt: 'Name three uses for embeddings.' }); console.log(text); ``` ### LlamaIndex (Python) Install: `pip install llama-index-llms-openai-like` ``` import os from llama_index.llms.openai_like import OpenAILike llm = OpenAILike(model="smartypants/arete-27b", api_base="https://smartypants.network/v1", api_key=os.environ["SMARTYPANTS_API_KEY"], is_chat_model=True, is_function_calling_model=True, context_window=16384) print(llm.complete("One sentence on Apple silicon.")) ``` ### Claude Code (MCP server and skill) Install: `claude mcp add --transport http smartypants https://smartypants.network/mcp` ``` # Prices, model search and sign-up help, no account needed: claude mcp add --transport http smartypants https://smartypants.network/mcp # Signed in (run prompts, balance; you sign in by email link and press Allow): claude mcp add --transport http smartypants-account https://smartypants.network/mcp/account # A skill that tells Claude when Smarty Pants fits and how to use it: mkdir -p ~/.claude/skills/smartypants curl -o ~/.claude/skills/smartypants/SKILL.md https://smartypants.network/kits/skills/smartypants/SKILL.md ``` ### GitHub Actions (a step in any workflow) Install: `repository secret SMARTYPANTS_API_KEY` ``` - name: Summarize the diff with an open model env: SMARTYPANTS_API_KEY: ${{ secrets.SMARTYPANTS_API_KEY }} run: git diff origin/main... | npx -y smartypants-network ask --system "Review this diff in 5 bullets" ``` ## Claude Code skill (https://smartypants.network/kits/skills/smartypants/SKILL.md) --- name: smartypants description: Use when a task needs cheap, exact open-model AI calls (summaries, extraction, classification, JSON output, embeddings, reranking, speech to text) priced per token, or batch work that can wait at half price. Not for work needing a frontier model. --- # Smarty Pants Smarty Pants (https://smartypants.network) serves exact, pinned builds of open models on Apple Silicon Macs through an OpenAI-compatible API, priced per token. ## When to use it - Everyday text work where an open model is good enough and price matters: summaries, extraction, classification, drafting, tool calls, JSON output. - Embeddings (`smartypants/qwen3-embedding-0.6b`) and reranking (`smartypants/qwen3-reranker-0.6b`). - Many requests that can wait: the Batch API (OpenAI format) runs them within 24 hours at half the per-token price. - Not for: work that needs a frontier-size model, more context than the model lists, or strict latency. Keep the current provider for those. ## How 1. Check models, prices and `is_ready`: `curl https://smartypants.network/v1/models`. Only send traffic to models that are ready. 2. The person creates an API key at https://smartypants.network/api (llms.txt says who can sign up today); keep it in `SMARTYPANTS_API_KEY`. Never put it in code or chat. 3. Call it like OpenAI: base URL `https://smartypants.network/v1`, model id such as `smartypants/arete-27b`. ```bash curl https://smartypants.network/v1/chat/completions -H "Authorization: Bearer $SMARTYPANTS_API_KEY" \ -H "Content-Type: application/json" \ -d '{"model":"smartypants/arete-27b","messages":[{"role":"user","content":"Hello"}]}' ``` Or from a shell: `npx -y smartypants-network ask "Hello"`. 4. On 429 or 503, wait the `Retry-After` seconds or fall back to the current provider. 402 means the balance is empty. ## Rules - Ask the person before spending. `GET https://smartypants.network/v1/key` shows what this key has left. - Requests run on Macs owned by other people. Do not send secrets, personal, customer or regulated data unless the person approved it. - Never handle card details; the person adds money on their account page (Stripe). Full guide: https://smartypants.network/llms.txt and https://smartypants.network/docs/agents