Skip to content
AI Skills Central

Type to search Agent Skills, workflows, tutorials, tools and the glossary.

AI gateway

Topic: Training and modelsAlso called LLM gateway, LLM proxy

Definition

A proxy between apps and model providers that gives one API for many models and adds keys, logging, budgets, caching and fallbacks.

In more detail

Instead of every service holding provider keys and its own retry logic, requests go through a gateway. It translates between provider APIs, issues internal keys per team or app, records cost and latency, enforces budgets and rate limits, caches responses and fails over to another model when one errors.

Open-source options include LiteLLM and Portkey's gateway; Helicone and OpenRouter offer hosted versions, and cloud platforms have their own. A gateway is also a natural place for guardrails and data rules, but it is a single point of failure and sees all prompts, so run it with the same care as any other production proxy.

  • LLM observability

    Collecting traces, costs, latency and quality signals from AI applications in production so you can debug and improve them.

  • Model routing

    Choosing which model handles each request, often sending easy requests to a small, cheap model and hard ones to a larger model.

  • Rate limit

    A provider's cap on requests or tokens per minute or per day; requests over the cap are rejected with an error until the window resets.

  • Semantic caching

    Reusing a stored model response when a new request means the same as an earlier one, judged by embedding similarity rather than exact text.

  • LiteLLM

    Open-source SDK and AI gateway that calls 100+ providers through one OpenAI-style API.

    Tool

  • Portkey AI Gateway

    Open-source gateway for routing model requests with retries, fallbacks and guardrails.

    Tool

  • LLM cost optimisation

    Cutting LLM costs with caching, model routing, batching and budgets.

    SkillIntermediate