compute.route
Route a task to the best available free AI model and run inference. DPX selects the model based on the task type (reasoning → DeepSeek R1, code → Llama 3.3 70B, multilingual → Qwen 2.5 72B, fast → Llama 3.1 8B), calls OpenRouter, and returns the completion. All models are free-tier — no token cost. Pay per call in USDC via x402. Use this when an agent needs to delegate a subtask to a language model without managing model selection or API keys.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| task | Yes | Plain-language description of what the model should do. Used for model selection. | |
| messages | No | Optional. Full message array in OpenAI format [{role, content}]. If omitted, task is sent as a user message. | |
| preferSpeed | No | true = use the fastest available free model regardless of task type. Default false. |