mirror of
https://github.com/ruvnet/ruflo.git
synced 2026-09-14 14:01:28 +08:00
2fd38f4ded
* fix(wasm): bump default Sonnet model from 20250514 to 4.6 (#1810) `wasm_agent_create` (gallery + plain) hardcoded `anthropic:claude-sonnet-4-20250514` as the default model. New WASM agents silently inherited a year-old Sonnet ID unless the caller passed an explicit `model`, which is a quiet UX/pricing failure that new users won't catch until they hit version-specific behaviour. Bump to `anthropic:claude-sonnet-4-6` (current Sonnet at time of writing) in all four locations the previous ID was hardcoded: - `src/ruvector/agent-wasm.ts` — actual default (this is what actually shipped to users) - `src/commands/agent-wasm.ts` — `--model` flag description - `src/commands/agent-wasm.ts` — example command - `src/mcp-tools/wasm-agent-tools.ts` — MCP `wasm_agent_create` schema description - `__tests__/ruvector/agent-wasm.test.ts` — assertion in "creates agent with defaults" A future follow-up should replace the hardcode with a config-driven default (e.g. read from `claudeFlow.modelPreferences.default`) so Anthropic version cuts don't require a code change. Tracked separately. Closes #1810. Co-Authored-By: RuFlo <ruv@ruv.net> * fix(wasm,plugins): pin gallery test + sweep remaining stale model IDs (#1810) Follow-up to the WASM default bump in this same PR. Reviewing the issue more carefully, the reporter's repro path goes through `createAgentFromTemplate('researcher')` (the GALLERY path) — and while that path *does* inherit the new default (it passes `model: undefined`, falling through to `createWasmAgent`'s default), nothing in the test suite actually pinned the gallery output to the new default. A future regression would only surface in `creates agent with defaults` (the bare-call test), not in the gallery test the user actually hits. __tests__/ruvector/agent-wasm.test.ts:326 + expect(info.model).toBe('anthropic:claude-sonnet-4-6'); While I had grep open, also swept the rest of the workspace for the `claude-sonnet-4-20250514` literal and the matching old Claude 4.x model IDs: - plugins/examples/plugin-creator/index.ts (×2 — runtime + code-gen template string) - plugins/examples/plugin-creator/plugin-creator.test.ts (assertion) - plugins/src/collections/official/index.ts (×4 — coder, tester, reviewer, coordinator agent defs) - plugins/src/providers/index.ts (Claude provider's models[] list — also bumped opus-4-5 → opus-4-7 and 3-5-haiku → haiku-4-5) - plugins/README.md (example snippet) - mcp/.claude/settings.json (modelPreferences default + routing) Historical ADR docs (`v3/implementation/adrs/`) still reference the old IDs by design — they capture decisions at issuance time. Comments in the WASM agent source that reference the old hardcode for context are kept too. Strengthens the original closes-#1810 fix from "default works" to "default works AND a regression of the gallery path is caught by tests AND no other surface in the workspace ships the stale ID anymore." Co-Authored-By: RuFlo <ruv@ruv.net>