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

推荐订阅源

U
Unit 42
Google DeepMind News
Google DeepMind News
Stack Overflow Blog
Stack Overflow Blog
H
Help Net Security
MongoDB | Blog
MongoDB | Blog
I
InfoQ
N
Netflix TechBlog - Medium
T
Tailwind CSS Blog
量子位
博客园 - 叶小钗
月光博客
月光博客
IT之家
IT之家
G
Google Developers Blog
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
小众软件
小众软件
S
SegmentFault 最新的问题
Engineering at Meta
Engineering at Meta
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
aimingoo的专栏
aimingoo的专栏
云风的 BLOG
云风的 BLOG
Vercel News
Vercel News
爱范儿
爱范儿
让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
宝玉的分享
宝玉的分享

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
fix(providers): keep vllm nemotron replies visible · open...
steipete · 2026-04-26 · via Recent Commits to openclaw:main

@@ -492,6 +492,7 @@ describe("applyExtraParamsToAgent", () => {

492492

cfg?: Record<string, unknown>;

493493

extraParamsOverride?: Record<string, unknown>;

494494

payload?: Record<string, unknown>;

495+

thinkingLevel?: Parameters<typeof applyExtraParamsToAgent>[5];

495496

}) {

496497

const payload = params.payload ?? { store: false };

497498

const baseStreamFn: StreamFn = (model, _context, options) => {

@@ -505,6 +506,7 @@ describe("applyExtraParamsToAgent", () => {

505506

params.applyProvider,

506507

params.applyModelId,

507508

params.extraParamsOverride,

509+

params.thinkingLevel,

508510

);

509511

const context: Context = { messages: [] };

510512

void agent.streamFn?.(params.model, context, params.options ?? {});

@@ -825,6 +827,159 @@ describe("applyExtraParamsToAgent", () => {

825827

expect(payload).not.toHaveProperty("store");

826828

});

827829830+

it("forwards chat_template_kwargs params as top-level openai-completions payload fields", () => {

831+

const payload = runResponsesPayloadMutationCase({

832+

applyProvider: "vllm",

833+

applyModelId: "nemotron-3-super",

834+

cfg: {

835+

agents: {

836+

defaults: {

837+

models: {

838+

"vllm/nemotron-3-super": {

839+

params: {

840+

chat_template_kwargs: {

841+

enable_thinking: false,

842+

force_nonempty_content: true,

843+

},

844+

},

845+

},

846+

},

847+

},

848+

},

849+

},

850+

model: {

851+

api: "openai-completions",

852+

provider: "vllm",

853+

id: "nemotron-3-super",

854+

baseUrl: "http://127.0.0.1:8000/v1",

855+

} as Model<"openai-completions">,

856+

payload: {

857+

messages: [],

858+

},

859+

});

860+861+

expect(payload.chat_template_kwargs).toEqual({

862+

enable_thinking: false,

863+

force_nonempty_content: true,

864+

});

865+

});

866+867+

it("injects vLLM Nemotron chat_template_kwargs when thinking is off", () => {

868+

const payload = runResponsesPayloadMutationCase({

869+

applyProvider: "vllm",

870+

applyModelId: "nemotron-3-super",

871+

model: {

872+

api: "openai-completions",

873+

provider: "vllm",

874+

id: "nemotron-3-super",

875+

baseUrl: "http://127.0.0.1:8000/v1",

876+

} as Model<"openai-completions">,

877+

payload: {

878+

messages: [],

879+

},

880+

thinkingLevel: "off",

881+

});

882+883+

expect(payload.chat_template_kwargs).toEqual({

884+

enable_thinking: false,

885+

force_nonempty_content: true,

886+

});

887+

});

888+889+

it("does not inject vLLM Nemotron chat_template_kwargs when thinking is enabled", () => {

890+

const payload = runResponsesPayloadMutationCase({

891+

applyProvider: "vllm",

892+

applyModelId: "nemotron-3-super",

893+

model: {

894+

api: "openai-completions",

895+

provider: "vllm",

896+

id: "nemotron-3-super",

897+

baseUrl: "http://127.0.0.1:8000/v1",

898+

} as Model<"openai-completions">,

899+

payload: {

900+

messages: [],

901+

},

902+

thinkingLevel: "low",

903+

});

904+905+

expect(payload).not.toHaveProperty("chat_template_kwargs");

906+

});

907+908+

it("lets extra_body override generated vLLM Nemotron chat_template_kwargs", () => {

909+

const payload = runResponsesPayloadMutationCase({

910+

applyProvider: "vllm",

911+

applyModelId: "nemotron-3-super",

912+

cfg: {

913+

agents: {

914+

defaults: {

915+

models: {

916+

"vllm/nemotron-3-super": {

917+

params: {

918+

extra_body: {

919+

chat_template_kwargs: {

920+

enable_thinking: true,

921+

},

922+

},

923+

},

924+

},

925+

},

926+

},

927+

},

928+

},

929+

model: {

930+

api: "openai-completions",

931+

provider: "vllm",

932+

id: "nemotron-3-super",

933+

baseUrl: "http://127.0.0.1:8000/v1",

934+

} as Model<"openai-completions">,

935+

payload: {

936+

messages: [],

937+

},

938+

thinkingLevel: "off",

939+

});

940+941+

expect(payload.chat_template_kwargs).toEqual({

942+

enable_thinking: true,

943+

});

944+

});

945+946+

it("warns and skips invalid chat_template_kwargs params", () => {

947+

const warnSpy = vi.spyOn(log, "warn").mockImplementation(() => {});

948+

try {

949+

const payload = runResponsesPayloadMutationCase({

950+

applyProvider: "vllm",

951+

applyModelId: "nemotron-3-super",

952+

cfg: {

953+

agents: {

954+

defaults: {

955+

models: {

956+

"vllm/nemotron-3-super": {

957+

params: { chat_template_kwargs: "not-an-object" },

958+

},

959+

},

960+

},

961+

},

962+

},

963+

model: {

964+

api: "openai-completions",

965+

provider: "vllm",

966+

id: "nemotron-3-super",

967+

baseUrl: "http://127.0.0.1:8000/v1",

968+

} as Model<"openai-completions">,

969+

payload: {

970+

messages: [],

971+

},

972+

});

973+974+

expect(payload).not.toHaveProperty("chat_template_kwargs");

975+

expect(warnSpy).toHaveBeenCalledWith(

976+

"ignoring invalid chat_template_kwargs param: not-an-object",

977+

);

978+

} finally {

979+

warnSpy.mockRestore();

980+

}

981+

});

982+828983

it("warns and skips invalid extra_body params", () => {

829984

const warnSpy = vi.spyOn(log, "warn").mockImplementation(() => {});

830985

try {