Skip to content

fix: resolve obvious model and todo validation issues - #3924

Merged
Yeachan-Heo merged 5 commits into
devfrom
fix/obvious-open-issues-20260806
Aug 6, 2026
Merged

fix: resolve obvious model and todo validation issues#3924
Yeachan-Heo merged 5 commits into
devfrom
fix/obvious-open-issues-20260806

Conversation

@Yeachan-Heo

Copy link
Copy Markdown
Owner

Summary

Closes #3916
Closes #3913
Closes #3909

Verification

  • bun test packages/coding-agent/test/tools/todo-write.test.ts packages/ai/test/tool-argument-coercion.test.ts
  • bun test packages/ai/test/model-thinking.test.ts packages/ai/test/generate-models.test.ts packages/coding-agent/test/provider-onboarding.test.ts packages/coding-agent/test/model-profile-activation.test.ts packages/coding-agent/test/model-profiles-catalog.test.ts
  • bun --cwd=packages/ai run check
  • bun --cwd=packages/coding-agent run check

Yeachan-Heo added 4 commits August 6, 2026 16:36
Raw validation rejected malformed todo operations before coercion but returned no correction code, causing repeated opaque failures. Bounded rejection codes now identify each accepted shape without echoing untrusted input.

Lore-id: 3916todo

Confidence: high

Scope-risk: narrow

Reversibility: easy

Tested: bun test packages/coding-agent/test/tools/todo-write.test.ts packages/ai/test/tool-argument-coercion.test.ts
Sonnet 5 supports Anthropic xhigh and max effort, but the capability inference only admitted Opus models. Version-scoped capability detection now includes Sonnet 5 while older Sonnet and Bedrock routes remain fail-closed.

Lore-id: 3913effort

Constraint: preserve older Sonnet and Bedrock effort ranges

Confidence: high

Scope-risk: narrow

Reversibility: easy

Tested: bun test packages/ai/test/model-thinking.test.ts
Alibaba rejects qwen-3.8-max because the supported provider id is qwen3.8-max. Catalog injection, onboarding, profiles, tests, and documentation now use the provider spelling and collapse the legacy discovered alias.

Lore-id: 3909qwen

Constraint: generator must not retain both legacy and canonical aliases

Confidence: high

Scope-risk: narrow

Reversibility: easy

Tested: bun test packages/ai/test/generate-models.test.ts packages/coding-agent/test/provider-onboarding.test.ts packages/coding-agent/test/model-profile-activation.test.ts packages/coding-agent/test/model-profiles-catalog.test.ts
The Qwen model documentation update changes the embedded docs payload, so the generated index must be refreshed for public-surface sync.

Lore-id: 3909docs

Confidence: high

Scope-risk: narrow

Reversibility: easy

Tested: bun run generate-docs-index

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 47cab2e8dd

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread packages/ai/scripts/generate-models.ts Outdated
Comment on lines +146 to +148
const legacyQwenIndex = models.findIndex(
model => model.provider === "alibaba-token-plan" && model.id === "qwen-3.8-max",
);

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Canonicalize all legacy Qwen entries

When authenticated generation receives qwen-3.8-max from both models.dev and the Alibaba catalog, these sources are concatenated before this function runs, but findIndex converts or removes only the first legacy entry. The later ID-keyed deduplication then sees one renamed qwen3.8-max and one remaining qwen-3.8-max as distinct, so the generated catalog still exposes the rejected legacy selector; remove or canonicalize every matching legacy entry before grouping.

Useful? React with 👍 / 👎.

Boundary review found that catalog injection removed only one qwen-3.8-max row and that todo_write docs still advertised targetless done/drop operations. Generation now filters every legacy alias with duplicate-source coverage, and published docs match raw validation.

Lore-id: 3924review1

Constraint: no generated catalog may retain qwen-3.8-max

Confidence: high

Scope-risk: narrow

Reversibility: easy

Tested: bun test packages/ai/test/generate-models.test.ts packages/coding-agent/test/tools/todo-write.test.ts packages/ai/test/tool-argument-coercion.test.ts
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant