Pi provider for Synthetic - open-source models via OpenAI-compatible API

A Pi extension that adds Synthetic as a model provider, giving you access to open-source models through Synthetic’s OpenAI-compatible API.
Sign up at synthetic.new to get an API key (referral link).
The extension uses Pi’s credential storage. Add your API key to ~/.pi/agent/auth.json (recommended):
{
"synthetic": { "type": "api_key", "key": "your-api-key-here" }
}
Or set environment variable:
export SYNTHETIC_API_KEY="your-api-key-here"
Credentials are resolved in this order:
--api-key flagauth.json entry for syntheticSYNTHETIC_API_KEY# From npm
pi install npm:@aliou/pi-synthetic
# From git
pi install git:github.com/aliou/pi-synthetic
# Local development
pi -e .
Once installed, select synthetic as your provider and choose from available models:
/model synthetic hf:moonshotai/Kimi-K2.5
All models are accessed through Synthetic’s API. Some models are hosted by Synthetic directly (provider: "synthetic" in the model config); others are proxied by Synthetic to upstream backends such as Fireworks or Together.
Synthetic also provides permanent aliases (syn:large:text, syn:small:text, syn:large:vision, syn:small:vision) that route to the current best model for each category. These aliases are stable across model rotations — using an alias means no reconfiguration when models change. Alias models are always visible even when Proxied Models is disabled.
By default, new installs show only Synthetic-hosted models. You can enable proxied models in /synthetic:settings under Models > Proxied Models. Existing configurations keep proxied models enabled to preserve prior behavior.
The provider field in src/extensions/provider/models.ts is for maintenance only and is stripped before registering models with Pi, so users always select the synthetic provider.
The extension registers synthetic_web_search — a zero-data-retention web search tool. The tool is always visible; it fails with a clear message if credentials are missing, the account lacks a subscription, or the configured utility proxy rejects the request.
For Synthetic models that support reasoning, Synthetic currently accepts only low, medium, and high reasoning effort values.
This extension clamps Pi reasoning levels to Synthetic’s supported set:
minimal -> lowlow -> lowmedium -> mediumhigh -> highxhigh -> highCheck your API usage:
/synthetic:quotas
Web search and quotas can use a proxy instead of https://api.synthetic.new. Configure it with /synthetic:settings under Connection > Utility API Proxy. The proxy is only used for /v2/search and /v2/quotas; model provider calls still use Synthetic’s OpenAI-compatible endpoint directly.
If the proxy requires auth, pi-synthetic still requires a Synthetic API key and sends Authorization: Bearer .... If the proxy does not require auth, disable Requires auth and these utility calls skip API key checks and omit Authorization.
When a Synthetic model is active, the footer status bar shows live quota usage (e.g. week:82% (↺in 3d) 5h:95%). Colors follow the same severity assessment as quota warnings: green by default, yellow/red only when projected usage is at risk. The status auto-refreshes every 60 seconds and after each turn.
The extension automatically notifies you when you approach or exceed your Synthetic API quotas. Notifications fire on severity transitions only (no repeated alerts for the same level) and use correct terminology (regen/tick/resets) with precise time formatting.
high and critical levels have no cooldownwarning level has a 60-minute cooldownEach feature (provider, web search, quotas command, sub bar integration, usage status, quota warnings) is a separate Pi extension. You can disable individual features using pi config:
pi config extensions.disabled add @aliou/pi-synthetic/quota-warnings
This prevents the quota-warnings extension from loading while keeping the rest of pi-synthetic active. Replace quota-warnings with web-search, command-quotas, sub-bar-integration, usage-status, or provider to disable other features.
The Proxied Models and Utility API Proxy settings are not loadable extension features. They are regular settings controlled through /synthetic:settings.
Models are hardcoded in src/extensions/provider/models.ts. Entries are a union of concrete models and thin aliases (syn:* IDs).
src/extensions/provider/models.tsSyntheticModelConfig interfaceprovider to the upstream backend Synthetic uses for that model, such as synthetic, fireworks, or togetherpnpm run typecheck to verify{ id, name, aliasFor } entry at the top of SYNTHETIC_MODELSid and name from the Synthetic APIaliasFor to "hf:" + hugging_face_id from the Synthetic APIWhen Synthetic changes which model an alias routes to, update only the aliasFor field.
git clone https://github.com/aliou/pi-synthetic.git
cd pi-synthetic
# Install dependencies (sets up pre-commit hooks)
pnpm install && pnpm prepare
Pre-commit hooks run on every commit:
# Type check
pnpm run typecheck
# Lint
pnpm run lint
# Format
pnpm run format
# Test
pnpm run test
pi -e .
This repository uses Changesets for versioning.
Note: Automatic NPM publishing is currently disabled. To publish manually:
pnpm changesetpnpm version.github/workflows/publish.yml~/.pi/agent/auth.json or via SYNTHETIC_API_KEY) for model provider calls and authenticated utility API calls