feat(room): addressee on say frames, channel meta and the composer - #35
Merged
Conversation
`say` gains an optional `to`, carried through to the channel push as `meta.to`, and the room `instructions` now name it as the material an agent judges "is this mine to answer" on. The composer picks the addressee from the roster; leaving it on 全体 sends as before. 返信フレームには `to` があるのに発言フレームには無く、`instructions` は 宛先を知らないままエージェントに宛先を判断させていた。判定材料と判定規律を 同じ変更で揃える。宛先で配送を絞ることはしない。部屋は全員へ配り、答えるか どうかはエージェントが決める。絞ればアプリが「誰に届いたか」を持つことになり、 会話の中身へ関与し始めるため。 The sidecar also tells each agent the name it answers to, without which matching `meta.to` against itself is impossible. Round-trip test covers addressed, addressed-elsewhere and unaddressed pushes; an unaddressed one omits the key rather than sending an empty one. #31 Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
smileygames
commented
Aug 21, 2026
smileygames
left a comment
Member
Author
There was a problem hiding this comment.
セルフレビュー(auto モード / 人間チェックなし)
完了条件の照合
| #31 の完了条件 | 結果 |
|---|---|
| 部屋の発言に宛先を付けられる | 満たす。composer の #to-select、既定は全体宛 |
宛先が channel notification の meta を通じて届く |
満たす。pushToChannel が meta.to へ載せる。content には混ぜない |
instructions が宛先を判定材料として明示 |
満たす。あわせて AGENT_NAME を埋め込んでおり、照合の片側が欠けていない |
| 宛先なしの発言が従来どおり成立する | 満たす。空文字は畳まれ、キーごと省かれる |
制約の照合
- 宛先は任意 — 満たす。
- 判定はエージェント側 — 満たす。配送の絞り込みは入れておらず、往復ハーネスの検査で固定されている。
instructionsとsayのフィールドを同時に変える — 満たす。同一 PR。- 既存の
reply.toと語彙を揃える — 満たす。両方向とも表示名、任意、不在時はキー省略。
スコープ
変更ファイルは #31 の対象ファイル一覧と一致し、超過はない。docs/0-requirements.md の premise へ「枠の消費構造」を追加し constraints の代償節を書き換えた点は、issue 本文の前提節が同じ分析を持ち、対象ファイルにも挙げられているため範囲内と判断する。
検証
CI(CI / check)いずれも 4308d56 で pass。meta.to の中継を外すと新規テストが落ちることを実装側で確認済みであり、テストは挙動を検出している。
指摘
なし。AGENT_NAME は INSTRUCTIONS より前で定義されており、テンプレートリテラル埋め込みに初期化順の問題はない。
リリース種別
patch と判定する。観測可能な追加ではあるが増分であり、構造の大きな変更ではない(rules/operations/release-version-rule.md)。
自己レビュー通過。auto モードのため人間チェックはなく、このままマージへ進む。
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #31
部屋の発言に宛先を持たせ、名指しされていないエージェントが黙れるようにした。
変更
sayフレームに任意のtoを追加(src-tauri/src/room.rs)。空文字は宛先なしへ畳み、無いときはキーごと省く。既存のreply.toと同じ語彙・同じ形。say.toを channel push のmeta.toとして渡す(sidecar/src/index.ts)。本文は言われたものと等しく保つためcontentには混ぜない(fix(sidecar): stop prefixing the speaker into the channel content #28)。instructionsが宛先を判定材料として明示。あわせて自分の部屋での名前を各エージェントへ伝える。名前が無ければmeta.toを自分と照合できない。index.html/src/main.ts/src/styles.css)。参加者名簿から選ぶ形にしてあり、既定は全体宛。docs/0-requirements.md: フレーム表・push の形・部屋の作法・実装状況を更新。あわせて premise へ「枠の消費構造」を追加し、constraints の「抑える対象」を常駐数から反応数へ改めた。判断
protocolは上げていない。サイドカーはアプリが.mcp.jsonへ書く同梱パスから起動するため、部屋とサイドカーの版が食い違う形が構造上無い。検証
npm run build/npm run sidecar:check/npm run sidecar:test/cargo check --target x86_64-pc-windows-gnu/cargo test(crates/mcp-config)いずれも通過。往復ハーネスに宛先ありの push・他人宛の push・宛先なしの push を追加。
meta.toの中継を外すと落ちることを確認済み(宛先なしはキーが無いことを検査する)。