AI Bridge gives every script on your server one server-side export for talking to a language model. Keys stay in server convars and the limits are yours to set. Adding AI to a roleplay server usually means pasting an API key into a client script and hoping nobody spams it, and this replaces all of that.
Point it at your own home-lab model, a paid API, or both (por que no los dos). Requests go down your list in order, so when one provider is slow, down or out of budget, the next one answers. If all of them fail, the NPC says a scripted line instead of going quiet. Also, a circuit breaker skips any provider that keeps failing and tries it again a few minutes later.
Player text is treated as untrusted. Your persona prompt always comes first and callers can't replace it, input is cleaned and capped, reasoning blocks are stripped from replies, and a word list masks anything you don't want said. The model only talks (your scripts decide prices, money and items).
Staff get /aiusage with today's requests, tokens, caps and estimated spend per provider, on top of a conversation log.
What it does
- One export in two styles:
Chat(messages, options, callback)for callbacks andChatAwaitfor blocking calls - OpenAI-compatible adapter (Ollama, LM Studio, llama.cpp, vLLM, OpenRouter, OpenAI, Groq and more) plus a native Claude adapter
- Fallback chain with scripted lines per persona, and a circuit breaker on each provider
- Per-player cooldown, daily request and token caps per provider, caps on reply and input length, and a server-wide limit on requests in flight
- Estimated spend from your own per-million-token prices, last 7 days included
- Personas with fallback lines, plus extra instructions and temperature per provider for small models
<think>stripping, blocked word masking, and keys scrubbed from every log- Replies stream under the hood, so FXServer's 5 second HTTP rule doesn't cut long answers off
- Home-lab guide for Tailscale or WireGuard, Cloudflare Tunnel, or a reverse proxy with a token
- Server only and framework free, nothing goes to game clients