Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

Model downswitch can exceed the target context window

オープン
#18 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 1 日以内に返信

まだ誰も着手していません。

評価

難易度
4/5
見積もり時間
3〜5日
初心者へのやさしさ
55/100
issue の種類
バグ
明瞭さ
おおむね明確
活発さ
活発
技術スタック
rust

調査の方向性

Start with SelectableSession::begin_turn in src/provider/adapter.rs, then trace Command::SetModel and set_model in src/protocols/acp.rs and the automatic, compaction_reason, and KitCompactionBackend paths in src/compaction.rs. Check how the session actor serializes selection and how transcript metadata is stored. Done means an unsafe downswitch compacts and persists first, while unknown or oversized targets leave the current model unchanged with an actionable error.

索引モデルが issue の本文から書いたものです。

説明

Kit can switch the main ACP session to a model with a smaller context window without first checking whether the existing transcript fits that model. The next turn keeps the live transcript and creates the selected provider session, so the target provider can reject the request for exceeding its context limit.

Automatic compaction does not currently prevent this. Its trigger uses the latest provider-reported usage and context-window metadata in the transcript, which still describes the previously active model. After the switch, manual or automatic compaction also follows the new model and may fail because its summarization request contains the already oversized transcript.

Until this is fixed, compact with the larger model before switching:

/compact
/model <lower-context-model>

A safe downswitch should be transactional and serialized through the session actor. Kit should retain context-window information in the model catalog, compare the transcript against the target window, compact with the currently active model before publishing the new selection, persist the replacement transcript, and then apply the switch. If the target window is unknown or compaction cannot make the transcript fit, Kit should leave the current selection unchanged and return an actionable error.

Relevant implementation: src/provider/adapter.rs (SelectableSession::begin_turn), src/protocols/acp.rs (Command::SetModel and set_model), and src/compaction.rs (automatic, compaction_reason, and KitCompactionBackend).

主要言語
Rust
スター
43
フォーク
5
平均マージ
21時間 18分
マージ済み PR(30日)
40

環境構築

  • Dockerfile または Docker Compose ファイルあり
  • プルリクエストのテンプレートなし
  • コントリビューションガイドなし

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

speakeasy-api/kit のほかの issue

speakeasy-api/kit の issue をすべて見る

似ている issue

Rust の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。