Status: [UNTESTED] Endpoints found: http://localhost:8082/v1/models http://localhost:8082/v1/models/my-model/load http://localhost:8082/v1/media-models http://localhost:8082/v1/compression http://localhost:8082/v1/sessions Source: https://github.com/c-vision/UnifiedLLMGateway # Unified Gateway [![Go Version](https://img.shields.io/badge/go-1.26%2B-00ADD8?logo=go)](https://go.dev) [![License: MIT](https://img.shields.io/badge/license-MIT-blue.svg)](LICENSE) [![Platform](https://img.shields.io/badge/platform-macOS-lightgrey)](#requirements) A lightweight Go proxy that lets **Anthropic-native** tools (like [Claude Code](https://github.com/anthropics/claude-code)) and **OpenAI-native** tools (like [OpenCode](https://github.com/sst/opencode)) share the same local LLM backend — with zero client-side changes beyond a base URL. Point Claude Code at Unified Gateway's Anthropic adapter, point your OpenAI-compatible tools at its OpenAI adapter, and swap the model actually running underneath with a single command. The gateway also owns the lifecycle of the local model process itself, so there's no separate launcher script to keep in sync. ## Why Local inference servers (`llama.cpp`-based tools, [`ollama`](https://ollama.com), MLX runners, etc.) generally speak one dialect — usually OpenAI's Chat Completions format. Claude Code, however, speaks Anthropic's Messages API: different request shape, different streaming event format, different tool-calling contract. Getting Claude Code to work against a local model means translating between the two — correctly, including edge cases most minimal proxies miss (system prompt placement, tool call streaming, conversation-compaction requests). Unified Gateway does that translation, and adds model lifecycle management on top, so `some-model-tool serve` + a hand-rolled proxy script becomes one binary and one config file. ## Features - **Dual protocol adapters** — a dedicated Anthropic Messages API port and a dedicated OpenAI Chat Completions port, both backed by the same underlying model - **Correct Anthropic↔OpenAI translation** — `system` prompt (including prompts Claude Code sends interleaved mid-conversation, which most naive proxies miss), `tools`/`tool_use`/`tool_result`, and full SSE str