---
title: "gateway"
type: "tool"
slug: "adaline-gateway"
canonical_url: "https://www.graphcanon.com/tools/adaline-gateway"
github_url: "https://github.com/adaline/gateway"
homepage_url: "https://www.adaline.ai/docs"
stars: 600
forks: 27
primary_language: "TypeScript"
license: "MIT"
categories: ["llm-frameworks", "developer-tools"]
tags: ["llmops", "openai", "typescript", "anthropic", "prompt-engineering", "togetherai", "ai-agents", "language-model"]
updated_at: "2026-07-07T18:49:38.644448+00:00"
---

# gateway

> Fully Local, Production-Grade Super SDK for Calling More Than 300+ LLMs

Adaline Gateway provides a simple, unified interface to call over 200 Language Learning Models (LLMs) locally with features such as batching, retries, caching, callbacks and OpenTelemetry support.

## Facts

- Repository: https://github.com/adaline/gateway
- Homepage: https://www.adaline.ai/docs
- Stars: 600 · Forks: 27 · Open issues: 0 · Watchers: 4
- Primary language: TypeScript
- License: MIT
- Last pushed: 2026-06-09T23:08:20+00:00

## Categories

- [LLM Frameworks](/categories/llm-frameworks.md)
- [Developer Tools](/categories/developer-tools.md)

## Tags

llmops, openai, typescript, anthropic, prompt-engineering, togetherai, ai-agents, language-model

## Related tools

- [ECC](/tools/affaan-m-ecc.md) - The agent harness performance optimization system (★ 226,962)
- [AutoGPT](/tools/significant-gravitas-autogpt.md) - AutoGPT: Build, Deploy, and Run AI Agents (★ 185,417)
- [ollama](/tools/ollama-ollama.md) - Get up and running with Kimi-K2.6, GLM-5.1, MiniMax, DeepSeek, gpt-oss, Qwen, Gemma and other models. (★ 175,659)
- [prompts.chat](/tools/f-prompts-chat.md) - The world's largest open-source prompt library for AI (★ 165,019)
- [transformers](/tools/huggingface-transformers.md) - 🤗 Transformers: the model-definition framework for state-of-the-art machine learning models (★ 162,347)
- [JavaGuide](/tools/snailclimb-javaguide.md) - Snailclimb/JavaGuide: 面试 & 后端通用面试指南，覆盖计算机基础、数据库、分布式、高并发、系统设计与 AI 应用开发 (★ 156,863)
- [open-webui](/tools/open-webui-open-webui.md) - User-friendly AI Interface (Supports Ollama, OpenAI API, ...) (★ 144,575)
- [awesome-llm-apps](/tools/shubhamsaboo-awesome-llm-apps.md) - 100+ AI Agent & RAG apps you can actually run — clone, customize, ship. (★ 116,702)

## README (excerpt)

```text
# Adaline Gateway






The only fully local, production-grade Super SDK that provides a simple, unified, and powerful interface for calling more than 300+ LLMs.

- Production-ready and trusted by enterprises
- Fully local and _NOT_ a proxy - deploy it anywhere
- Built-in batching, retries, caching, callbacks, and OpenTelemetry support
- Extensible with custom plugins for caching, logging, HTTP clients, and more - use it like building blocks to integrate with your infrastructure
- Supports plug-and-play providers - run fully custom providers while leveraging all the benefits of Adaline Gateway

### Features

- 🔧 Strongly typed in TypeScript
- 📦 Isomorphic - works everywhere
- 🔒 100% local, private, and _NOT_ a proxy
- 🛠️ Tool calling support across all compatible LLMs
- 📊 Batching for all requests with custom queue support
- 🔄 Automatic retries with exponential backoff
- ⏳ Caching with custom cache plug-in support
- 📞 Callbacks for comprehensive instrumentation and hooks
- 🔍 OpenTelemetry integration for existing infrastructure
- 🔌 Plug-and-play custom providers for local and custom models

### Providers

| Provider              | Chat Models     | Embedding Models  |
| --------------------- | --------------- | ------------------|
| OpenAI                | ✅              | ✅                |
| Anthropic             | ✅              | ❌                |
| Google AI Studio      | ✅              | ❌                |
| Google Vertex         | ✅              | ✅                |
| xAi                   | ✅              | ✅                |
| AWS Bedrock           | ✅              | ❌                |
| Azure OpenAI          | ✅              | ✅                |
| Groq                  | ✅              | ❌                |
| Together AI           | ✅              | ❌                |
| Open Router           | ✅              | ❌                |
| Custom (OpenAI-like)  | ✅              | ❌                |
| Voyage                | ❌              | ✅                |


## Installation

### Core packages

```bash
npm install @adaline/gateway @adaline/types
```

### Provider packages

Dependencies for providers are optional. You can install them as needed. For example:

```bash
npm install @adaline/openai @adaline/anthropic @adaline/google @adaline/open-router @adaline/bedrock
```

## Quickstart

### Chat

This example demonstrates how to invoke an LLM with a simple text prompt in both non-streaming and streaming modes.

```typescript
import { Gateway } from "@adaline/gateway";
import { OpenAI } from "@adaline/openai";
import { Config, ConfigType, MessageType } from "@adaline/types";

const OPENAI_API_KEY = "your-api-key"; // Replace with your OpenAI API key

const gateway = new Gateway();
const openai = new OpenAI();

const gpt4o = openai.chatModel({
  modelName: "gpt-4o",
  apiKey: OPENAI_API_KEY,
});

const config: ConfigType = Config().parse({
  temperature: 0.7,
  maxTokens: 300,
});

const messages: MessageType[] = [
  {
    role: "system",
    content: [{
      modality: "text",
      value: "You are a helpful assistant. You are extremely concise.",
    }],
  },
  {
    role: "user",
    content: [{
      modality: "text",
      value: `What is ${Math.floor(Math.random() * 100) + 1} + ${Math.floor(Math.random() * 100) + 1}?`,
    }],
  },
];

// * Complete chat
async function runCompleteChat() {
  const completeChat = await gateway.completeChat({
    model: gpt4o,
    config,
    messages,
    tools: [],
  });
  console.log(completeChat.provider.request); // HTTP Request sent to Provider
  console.log(completeChat.provider.response); // HTTP Response from Provider
  console.log(completeChat.cached); // Whether the response was cached
  console.log(completeChat.latencyInMs); // Latency in milliseconds
  console.log(completeChat.request); // Request in Gateway types
  console.log(completeChat.response); // Response in Gateway types, E.g.:
  // {
  //   "messages": [
  //     {
  //       "role": "assistant",
  //       "c
```

---

**Machine-readable endpoints**

- JSON: [`/api/graphcanon/tools/adaline-gateway`](/api/graphcanon/tools/adaline-gateway)
- LLM index: [/llms.txt](/llms.txt)
- Full corpus: [/llms-full.txt](/llms-full.txt)

_GraphCanon - The knowledge graph for AI development. https://www.graphcanon.com/_
