complete
Sends a prompt through a named upstream model route to generate text, blocks PII or secrets locally before network calls, and returns JSON with fallback suggestions.
Instructions
Call a named upstream route to generate text. Params: route (required), prompt (required), optional system, model, reasoning_level (none|minimal|low|medium|high|xhigh|max), max_tokens, temperature (only sent if provided; some reasoning models reject it). Locally blocks prompts containing PII, secrets, contract bodies, or unpublished financial figures before any network call. Returns JSON: {ok, route, protocol, model, reasoning_level, text, usage?, error?, safety_blocked?, suggest_local_fallback?, attempted_routes?, cross_route_used?}. If ok=false and suggest_local_fallback=true (timeout, overload, empty, or upstream error), the caller can finish with its own model. safety_blocked means do NOT fall back with the same sensitive prompt. Optional cross_route (default true): when the intent model matches config cross_route_fallbacks, failed entry route retries other sites with the SAME model; set false to pin to one route.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"route": "<route>",
"prompt": "<prompt>"
},
"name": "complete"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| model | No | ||
| route | Yes | ||
| prompt | Yes | ||
| system | No | ||
| max_tokens | No | ||
| cross_route | No | ||
| temperature | No | ||
| reasoning_level | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |