惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

博客园 - Franky
有赞技术团队
有赞技术团队
宝玉的分享
宝玉的分享
雷峰网
雷峰网
Hugging Face - Blog
Hugging Face - Blog
V
V2EX
大猫的无限游戏
大猫的无限游戏
博客园 - 司徒正美
D
Docker
T
The Blog of Author Tim Ferriss
罗磊的独立博客
博客园 - 叶小钗
酷 壳 – CoolShell
酷 壳 – CoolShell
Blog — PlanetScale
Blog — PlanetScale
月光博客
月光博客
J
Java Code Geeks
Jina AI
Jina AI
博客园 - 【当耐特】
C
Check Point Blog
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
腾讯CDC
Last Week in AI
Last Week in AI
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
V
Visual Studio Blog

Recent Commits to openclaw:main

test: merge chat side-result checks · openclaw/openclaw@ddd2c2a test: merge cron history checks · openclaw/openclaw@f7eb746 test: merge responsive navigation shell checks · openclaw/openclaw@c2e4b47 docs(changelog): add codex oauth fixes · openclaw/openclaw@628e6cd test: merge navigation routing cases · openclaw/openclaw@5d8cecb Tests: mock channel registry bundled fallback · openclaw/openclaw@2b08233 Secrets: avoid broad web search discovery for single plugin config · openclaw/openclaw@a464f59 test: merge config view browser checks · openclaw/openclaw@20cf511 fix(status): align oauth health with runtime · openclaw/openclaw@eed7116 feat: add macOS screen snapshots for monitor preview (#67954) thanks … · openclaw/openclaw@f377db1 fix: report shared auth scopes in hello-ok (#67810) thanks @BunsDev · openclaw/openclaw@0b6c39b Auto-reply: avoid eager bundled route fallback · openclaw/openclaw@3ea1bf4 Tests: narrow session binding contract setup · openclaw/openclaw@54e4e16 fix(macOS): enable undo/redo in webchat composer text input (#34962) · openclaw/openclaw@00951dc Tests: speed up channel setup promotion · openclaw/openclaw@82b529a Docs: refresh agent instructions · openclaw/openclaw@5775fe2 fix(auth): serialize OAuth refresh across agents to fix #26322 (#67876) · openclaw/openclaw@8e79080 test: allow ollama public surface boundary test · openclaw/openclaw@7d4f1a6 Docs: add test performance guardrails · openclaw/openclaw@89706d3 Tests: restore context-engine usage proof · openclaw/openclaw@e4c4f95 Tests: slim context engine runtime coverage · openclaw/openclaw@74c198f ci: retry failed custom checkouts · openclaw/openclaw@0ee5baf test: trim duplicate provider auth onboarding cases · openclaw/openclaw@1ffc02e matrix: fix sessions_spawn --thread subagent session spawning (#67643) · openclaw/openclaw@1ce2596 test: reduce auth choice fixture churn · openclaw/openclaw@857b9cd test: mock health status config boundaries · openclaw/openclaw@9d5ab4a test: mock onboard config io boundary · openclaw/openclaw@299694d test: mock legacy state plugin boundaries · openclaw/openclaw@2713089 test: mock channel install boundaries · openclaw/openclaw@b945248 test: mock doctor preview channel boundaries · openclaw/openclaw@b1a3ad4
feat(providers): add cerebras plugin · openclaw/openclaw@...
steipete · 2026-04-27 · via Recent Commits to openclaw:main
Original file line numberDiff line numberDiff line change

@@ -299,6 +299,11 @@

299299

- changed-files:

300300

- any-glob-to-any-file:

301301

- "extensions/byteplus/**"

302+

"extensions: cerebras":

303+

- changed-files:

304+

- any-glob-to-any-file:

305+

- "extensions/cerebras/**"

306+

- "docs/providers/cerebras.md"

302307

"extensions: deepseek":

303308

- changed-files:

304309

- any-glob-to-any-file:

Original file line numberDiff line numberDiff line change

@@ -6,6 +6,7 @@ Docs: https://docs.openclaw.ai

66
77

### Changes

88
9+

- Providers: add Cerebras as a bundled plugin with onboarding, static model catalog, docs, and manifest-owned endpoint metadata. Thanks @codex.

910

- Plugins/providers: move pre-runtime model-id normalization, provider endpoint host metadata, and OpenAI-compatible request-family hints into plugin manifests so core no longer carries bundled-provider routing tables. Thanks @codex.

1011

- Plugins/install: allow `OPENCLAW_PLUGIN_STAGE_DIR` to contain layered runtime-dependency roots, resolving read-only preinstalled deps before installing missing deps into the final writable root. Fixes #72396. Thanks @liorb-mountapps.

1112

- Control UI: polish the quick settings dashboard grid so common cards align across desktop, tablet, and mobile layouts without wasting horizontal space. Thanks @BunsDev.

Original file line numberDiff line numberDiff line change

@@ -0,0 +1,7 @@

1+

export {

2+

buildCerebrasModelDefinition,

3+

CEREBRAS_BASE_URL,

4+

CEREBRAS_MODEL_CATALOG,

5+

} from "./models.js";

6+

export { buildCerebrasProvider } from "./provider-catalog.js";

7+

export { applyCerebrasConfig, CEREBRAS_DEFAULT_MODEL_REF } from "./onboard.js";

Original file line numberDiff line numberDiff line change

@@ -0,0 +1,41 @@

1+

import { defineSingleProviderPluginEntry } from "openclaw/plugin-sdk/provider-entry";

2+

import { applyCerebrasConfig, CEREBRAS_DEFAULT_MODEL_REF } from "./onboard.js";

3+

import { buildCerebrasProvider } from "./provider-catalog.js";

4+
5+

const PROVIDER_ID = "cerebras";

6+
7+

export default defineSingleProviderPluginEntry({

8+

id: PROVIDER_ID,

9+

name: "Cerebras Provider",

10+

description: "Bundled Cerebras provider plugin",

11+

provider: {

12+

label: "Cerebras",

13+

docsPath: "/providers/cerebras",

14+

auth: [

15+

{

16+

methodId: "api-key",

17+

label: "Cerebras API key",

18+

hint: "Fast OpenAI-compatible inference",

19+

optionKey: "cerebrasApiKey",

20+

flagName: "--cerebras-api-key",

21+

envVar: "CEREBRAS_API_KEY",

22+

promptMessage: "Enter Cerebras API key",

23+

defaultModel: CEREBRAS_DEFAULT_MODEL_REF,

24+

applyConfig: (cfg) => applyCerebrasConfig(cfg),

25+

noteMessage: [

26+

"Cerebras provides high-speed OpenAI-compatible inference for GPT OSS, GLM, Qwen, and Llama models.",

27+

"Get your API key at: https://cloud.cerebras.ai",

28+

].join("\n"),

29+

noteTitle: "Cerebras",

30+

wizard: {

31+

groupLabel: "Cerebras",

32+

groupHint: "Fast OpenAI-compatible inference",

33+

},

34+

},

35+

],

36+

catalog: {

37+

buildProvider: buildCerebrasProvider,

38+

buildStaticProvider: buildCerebrasProvider,

39+

},

40+

},

41+

});

Original file line numberDiff line numberDiff line change

@@ -0,0 +1,49 @@

1+

import type { ModelDefinitionConfig } from "openclaw/plugin-sdk/provider-model-shared";

2+
3+

export const CEREBRAS_BASE_URL = "https://api.cerebras.ai/v1";

4+
5+

export const CEREBRAS_MODEL_CATALOG = [

6+

{

7+

id: "zai-glm-4.7",

8+

name: "Z.ai GLM 4.7",

9+

reasoning: true,

10+

input: ["text"],

11+

cost: { input: 2.25, output: 2.75, cacheRead: 2.25, cacheWrite: 2.75 },

12+

},

13+

{

14+

id: "gpt-oss-120b",

15+

name: "GPT OSS 120B",

16+

reasoning: true,

17+

input: ["text"],

18+

cost: { input: 0.35, output: 0.75, cacheRead: 0.35, cacheWrite: 0.75 },

19+

},

20+

{

21+

id: "qwen-3-235b-a22b-instruct-2507",

22+

name: "Qwen 3 235B Instruct",

23+

reasoning: false,

24+

input: ["text"],

25+

cost: { input: 0.6, output: 1.2, cacheRead: 0.6, cacheWrite: 1.2 },

26+

},

27+

{

28+

id: "llama3.1-8b",

29+

name: "Llama 3.1 8B",

30+

reasoning: false,

31+

input: ["text"],

32+

cost: { input: 0.1, output: 0.1, cacheRead: 0.1, cacheWrite: 0.1 },

33+

},

34+

] as const;

35+
36+

export function buildCerebrasModelDefinition(

37+

model: (typeof CEREBRAS_MODEL_CATALOG)[number],

38+

): ModelDefinitionConfig {

39+

return {

40+

id: model.id,

41+

name: model.name,

42+

api: "openai-completions",

43+

reasoning: model.reasoning,

44+

input: [...model.input],

45+

cost: model.cost,

46+

contextWindow: 128_000,

47+

maxTokens: 8192,

48+

};

49+

}

Original file line numberDiff line numberDiff line change

@@ -0,0 +1,30 @@

1+

import {

2+

createModelCatalogPresetAppliers,

3+

type OpenClawConfig,

4+

} from "openclaw/plugin-sdk/provider-onboard";

5+

import {

6+

buildCerebrasModelDefinition,

7+

CEREBRAS_BASE_URL,

8+

CEREBRAS_MODEL_CATALOG,

9+

} from "./models.js";

10+
11+

export const CEREBRAS_DEFAULT_MODEL_REF = "cerebras/zai-glm-4.7";

12+
13+

const cerebrasPresetAppliers = createModelCatalogPresetAppliers({

14+

primaryModelRef: CEREBRAS_DEFAULT_MODEL_REF,

15+

resolveParams: (_cfg: OpenClawConfig) => ({

16+

providerId: "cerebras",

17+

api: "openai-completions",

18+

baseUrl: CEREBRAS_BASE_URL,

19+

catalogModels: CEREBRAS_MODEL_CATALOG.map(buildCerebrasModelDefinition),

20+

aliases: [{ modelRef: CEREBRAS_DEFAULT_MODEL_REF, alias: "Cerebras GLM 4.7" }],

21+

}),

22+

});

23+
24+

export function applyCerebrasProviderConfig(cfg: OpenClawConfig): OpenClawConfig {

25+

return cerebrasPresetAppliers.applyProviderConfig(cfg);

26+

}

27+
28+

export function applyCerebrasConfig(cfg: OpenClawConfig): OpenClawConfig {

29+

return cerebrasPresetAppliers.applyConfig(cfg);

30+

}

Original file line numberDiff line numberDiff line change

@@ -0,0 +1,41 @@

1+

{

2+

"id": "cerebras",

3+

"enabledByDefault": true,

4+

"providers": ["cerebras"],

5+

"providerEndpoints": [

6+

{

7+

"endpointClass": "cerebras-native",

8+

"hosts": ["api.cerebras.ai"]

9+

}

10+

],

11+

"providerRequest": {

12+

"providers": {

13+

"cerebras": {

14+

"family": "cerebras"

15+

}

16+

}

17+

},

18+

"providerAuthEnvVars": {

19+

"cerebras": ["CEREBRAS_API_KEY"]

20+

},

21+

"providerAuthChoices": [

22+

{

23+

"provider": "cerebras",

24+

"method": "api-key",

25+

"choiceId": "cerebras-api-key",

26+

"choiceLabel": "Cerebras API key",

27+

"groupId": "cerebras",

28+

"groupLabel": "Cerebras",

29+

"groupHint": "Fast OpenAI-compatible inference",

30+

"optionKey": "cerebrasApiKey",

31+

"cliFlag": "--cerebras-api-key",

32+

"cliOption": "--cerebras-api-key <key>",

33+

"cliDescription": "Cerebras API key"

34+

}

35+

],

36+

"configSchema": {

37+

"type": "object",

38+

"additionalProperties": false,

39+

"properties": {}

40+

}

41+

}

Original file line numberDiff line numberDiff line change

@@ -0,0 +1,15 @@

1+

{

2+

"name": "@openclaw/cerebras-provider",

3+

"version": "2026.4.26",

4+

"private": true,

5+

"description": "OpenClaw Cerebras provider plugin",

6+

"type": "module",

7+

"devDependencies": {

8+

"@openclaw/plugin-sdk": "workspace:*"

9+

},

10+

"openclaw": {

11+

"extensions": [

12+

"./index.ts"

13+

]

14+

}

15+

}

Original file line numberDiff line numberDiff line change

@@ -0,0 +1,14 @@

1+

import type { ModelProviderConfig } from "openclaw/plugin-sdk/provider-model-shared";

2+

import {

3+

buildCerebrasModelDefinition,

4+

CEREBRAS_BASE_URL,

5+

CEREBRAS_MODEL_CATALOG,

6+

} from "./models.js";

7+
8+

export function buildCerebrasProvider(): ModelProviderConfig {

9+

return {

10+

baseUrl: CEREBRAS_BASE_URL,

11+

api: "openai-completions",

12+

models: CEREBRAS_MODEL_CATALOG.map(buildCerebrasModelDefinition),

13+

};

14+

}

Original file line numberDiff line numberDiff line change

@@ -0,0 +1,16 @@

1+

{

2+

"extends": "../tsconfig.package-boundary.base.json",

3+

"compilerOptions": {

4+

"rootDir": "."

5+

},

6+

"include": ["./*.ts", "./src/**/*.ts"],

7+

"exclude": [

8+

"./**/*.test.ts",

9+

"./dist/**",

10+

"./node_modules/**",

11+

"./src/test-support/**",

12+

"./src/**/*test-helpers.ts",

13+

"./src/**/*test-harness.ts",

14+

"./src/**/*test-support.ts"

15+

]

16+

}