Overview
The@standardagents/cerebras package provides a Cerebras provider factory for Standard Agents. It targets Cerebras’ OpenAI-compatible Chat Completions API and adds typed providerOptions, public model discovery, and request inspection support in the admin UI.
Key Features
- Direct integration with
https://api.cerebras.ai/v1/chat/completions - Typed
providerOptionsfor Cerebras-specific parameters - Public model discovery from Cerebras’ public models endpoint
- Tool calling, structured outputs, streaming, and reasoning support
Installation
npm
pnpm
yarn
Quick Start
agents/models/cerebras_fast.ts
Provider Factory
Provider Options
Available Options
| Option | Type | Description |
|---|---|---|
service_tier | 'priority' | 'default' | 'auto' | 'flex' | Request prioritization tier |
reasoning_effort | 'none' | 'low' | 'medium' | 'high' | Override reasoning behavior directly |
clear_thinking | boolean | Preserve or clear prior thinking on supported models |
user | string | End-user identifier |
seed | number | Best-effort deterministic sampling seed |
logprobs | boolean | Return token log probabilities |
top_logprobs | number | Number of top logprobs to return |
Standard Agents also maps
reasoning.level to Cerebras reasoning_effort automatically for supported models like gpt-oss-120b.Model IDs
Cerebras model IDs are sent directly, for example:llama3.1-8bqwen-3-235b-a22b-instruct-2507gpt-oss-120bzai-glm-4.7
https://api.cerebras.ai/public/v1/models?format=openrouter and exposes those models in the Standard Agents UI.
Capabilities
The provider maps Cerebras public model metadata into Standard Agents capabilities:supportsToolCallsfromsupported_featuressupportsJsonModefromjson_mode/structured_outputsmaxContextTokensfromcontext_lengthmaxOutputTokensfrommax_output_length
gpt-oss-120b and zai-glm-4.7.
Environment Setup
.dev.vars
Notes
- The provider uses Chat Completions, not OpenAI Responses.
- Cerebras documents
frequency_penalty,presence_penalty, andlogit_biasas currently unsupported. json_objectresponses are not compatible with streaming on the Cerebras API.
Related
Models
Core model concepts
OpenAI Provider
Compare with OpenAI
OpenRouter Provider
Compare with OpenRouter