Hermes
Hermes is a lightweight, highly intelligent universal LLM API proxy and concurrency control gateway.
It natively supports mutual proxying, format conversion, and routing for almost all mainstream protocols (OpenAI, Google Gemini, Anthropic, and local models like Ollama/vLLM). Out of the box, it includes a massive dictionary of 30+ global model providers.
Through multi-account polling and intelligent concurrency queuing, it completely solves business interruptions caused by API Key rate limits, bans, or depleted balances. The latest version is purely Zero-Config driven, with a built-in SQLite database and Web Admin Dashboard.
Core Features
- One-Click Client Configuration: Breaks the restrictions of commercial AI clients (like Claude Code, Codex, Cursor) locking you into official APIs, allowing you to freely use third-party models in closed-source software. Highly recommended with DeepSeek!
- Full Protocol & Provider Support: Built-in 30+ provider dictionary, no need to manually hunt for Base URLs.
- Simple/Expert Dual Mode UI: Simple mode for rapid setup, expert mode unlocks full control over concurrency limits, billing alerts, regex hardcoded routing, etc.
- Dual-Track Model Mapping Engine: Supports intelligent semantic mapping for cross-protocol requests, as well as exact 1:1 matching.
- Multi-Account Pool & Physical Concurrency Isolation: Queues requests based on physical accounts, achieving single concurrency isolation at the physical level. A powerful anti-ban tool.
- 5-State Circuit Breaker & Auto-Retry Polling: Idle/Busy/Cooldown/Observe/Exhausted. Built-in retry loop automatically polls backup nodes with exponential backoff when handling upstream 429/5xx errors.
- Zero Dependency Deployment: Single executable file, built-in Web UI and database migrations, out of the box.
Protocol & Routing Matrix
| Source Protocol (Client) | Target Protocol (Upstream) | Description |
|---|---|---|
| openai | openai | Passthrough + Polling (Compatible with all OpenAI format APIs) |
| openai | anthropic | OpenAI format → Anthropic format conversion |
| openai | OpenAI format → Google Gemini format conversion | |
| anthropic | anthropic | Passthrough + Polling |
| anthropic | openai | Anthropic format → OpenAI format conversion |
| Passthrough + Polling | ||
| local | local | Local model unauthenticated passthrough (Ollama/vLLM) |
Installation
All configurations, billing records, and SQLite database (polarisagi_hermes.db) are securely stored in: ~/.polarisagi/hermes/.
macOS / Linux
Default:
curl -sSL https://raw.githubusercontent.com/polarisagi/hermes/main/scripts/install.sh | bash
China Region (Proxy):
curl -sSL https://mirror.ghproxy.com/https://raw.githubusercontent.com/polarisagi/hermes/main/scripts/install.sh | bash
Windows (PowerShell as Admin)
Default:
iwr -useb https://raw.githubusercontent.com/polarisagi/hermes/main/scripts/install.ps1 | iex
China Region (Proxy):
iwr -useb https://mirror.ghproxy.com/https://raw.githubusercontent.com/polarisagi/hermes/main/scripts/install.ps1 | iex
The gateway will run as a background service and start on boot.
Uninstallation
macOS / Linux
Default:
curl -sSL https://raw.githubusercontent.com/polarisagi/hermes/main/scripts/uninstall.sh | bash
China Region (Proxy):
curl -sSL https://mirror.ghproxy.com/https://raw.githubusercontent.com/polarisagi/hermes/main/scripts/uninstall.sh | bash
Windows (PowerShell as Admin)
Default:
iwr -useb https://raw.githubusercontent.com/polarisagi/hermes/main/scripts/uninstall.ps1 | iex
China Region (Proxy):
iwr -useb https://mirror.ghproxy.com/https://raw.githubusercontent.com/polarisagi/hermes/main/scripts/uninstall.ps1 | iex
Quick Start
By default, the gateway listens on 127.0.0.1:27777.
- Admin Dashboard: Visit http://127.0.0.1:27777/dashboard
- Add Channel: Select protocol → Select provider → Enter API Key → Save.
- One-Click Client Config: Navigate to "Client Config", select target software, choose the API Key to inject, and you're done.
- API Endpoints (Enter these URLs in any AI tool, API Key can be anything):
- OpenAI Protocol:
http://127.0.0.1:27777/v1/openai/ - Anthropic Protocol:
http://127.0.0.1:27777/v1/anthropic/ - Google Protocol:
http://127.0.0.1:27777/v1/google/
- OpenAI Protocol: