Route your ElevenLabs agent’s language model through the SLNG context router. Speech to text and text to speech stay on ElevenLabs.
Keep your agent on ElevenLabs and route only its language model through the SLNG
context router. You get smart routing, context optimisation, in-region
execution, and compliant caching on every turn. Speech to text and text to
speech stay on ElevenLabs.
Start a new project, choose Improve my agent, and under On a voice
platform pick ElevenLabs.
Pick ElevenLabs on the voice platform path.
2
Pick your model
Open the Think section and choose your LLM model. Keep Context Router
on so the model routes through SLNG. Speech to text and text to speech stay
on ElevenLabs.
Scroll down to the LLM section and open it. The LLM settings panel opens
on the right.
3
Switch to a custom LLM
In the panel, under LLM, switch from the default to Custom LLM.
4
Set the server URL
In the Server URL field, paste
https://au.context-router.slng.ai/v1. Swap au for the
region closest to your callers. ElevenLabs
adds the Chat Completions path.
5
Set the model ID
In the Model ID field, enter the model you picked in the Think section, for
example slng/auto.
6
Add your API key as a secret
Under API key, click Add new secret, name it SLNG_API_KEY, paste
your SLNG API key value, and click Add secret.
7
Send the authorization header
Under Request headers, click Add header. Select the Secret tab,
set Header name to Authorization and select SLNG_API_KEY as the
secret.
8
Add agent and session headers
Add two more request headers so the router can tie each turn to your agent
and call. For each, select the Variable tab and map it to an ElevenLabs
system variable:
Header name
Dynamic variable
X-Slng-Agent-Id
system__agent_id
X-Slng-Session-Id
system__conversation_id
Map X-Slng-Agent-Id to the system__agent_id variable.
Map X-Slng-Session-Id to the system__conversation_id variable.
9
Save and test
Save your changes and run a test conversation to confirm the LLM is routing
through SLNG.