The Core Flow
Every LLM call in Splinter follows this exact path:Step by Step
1. Agent Calls Gateway
2. Control Checks
Gateway asks the Control Layer:- Budget: Have we exceeded
max_budget? - Steps: Have we exceeded
max_steps? - Time: Have we exceeded
max_time_seconds? - Tools: Is this agent allowed to use these tools?
- Loops: Is the agent stuck in a loop?
3. Route to LLM
If Control says OK, Gateway routes to the provider:4. Record Metrics
After the call, Gateway records:- Cost (tokens × price)
- Token usage
- Latency
- Call history
5. Coordination
Gateway updates coordination:6. Return Response
The response flows back to the agent, which parses it and continues.Why This Matters
Safety
Every call is checked. No agent can exceed limits.
Observability
Every call is tracked. You know exactly what happened.
Resumability
Every step is checkpointed. Failed runs can resume.
Coordination
State is shared. Agents work together, not against each other.