Skip to content

feat(tui): おすすめプリセット(品質下限つき最安モデル)と共有モデルの取り違え修正 - #62

Open
yukihamada wants to merge 3 commits into
cd-missing-pathfrom
feat/recommended-preset
Open

yukihamada wants to merge 3 commits into
cd-missing-pathfrom
feat/recommended-preset

Conversation

@yukihamada

Copy link
Copy Markdown
Owner

目的

モデル選択に「おすすめ」役割を足し、品質下限を満たす最安モデルへカタログ更新・価格変更に追随させる。あわせて、同じモデルに解決する複数役割を扱えるようにする。

変更

  • model-presets.ts: recommended(seed cheap、pick: cheapest、context 1,000,000 / output 32,768 下限)を追加。alias・-cache・tier課金・tool calling非対応・小型contextは除外。
  • dialog-model.tsx: 自動更新の説明を役割ごとに出す presetUpdateLabel を追加。
  • local.tsx:
    • 選択中の役割を preset としてエージェント別に保持(同じモデルに解決する役割を巡回・表示で取り違えない)。
    • selectPreset が他役割のfavoriteを消さないよう修正。
    • model.json の保存を直列化(重なった書き込みで古い状態が後勝ちするのを防ぐ)。

検証

  • bun turbo typecheck --filter=@sente-ai/tui: 成功
  • bun test test/cli/tui/model-presets.test.tsx test/util/model-presets.test.ts: 31 pass / 0 fail
  • test/cli/tui/ 全体: 91 pass / 3 fail(失敗3件は変更前から同じで本差分由来ではない)
  • oxlint: 警告9件・エラー0件(変更前と同数)

- おすすめ役割を追加し、品質下限を満たす最安モデルへ自動で追従させる
- 同じモデルに解決する複数役割を、選択時に消さないようにする
- 選択中の役割を保持し、矢印巡回と表示が別役割を取り違えないようにする
- 重なった model.json 保存を直列化し、古い状態が後勝ちするのを防ぐ
@github-actions

github-actions Bot commented Nov 4, 2026

Copy link
Copy Markdown

This PR doesn't fully meet our contributing guidelines and PR template.

What needs to be fixed:

  • PR description is missing required template sections. Please use the PR template.

Please edit this PR description to address the above within 2 hours, or it will be automatically closed.

If you believe this was flagged incorrectly, please let a maintainer know.

This branch has not been deployed

No deployments
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