feat: W7 功能標籤分類、對白檢索與注入 (#8)
用 $.model.complete(Haiku)判斷回應的功能標籤,從角色索引取同標籤對白, 以只增不改的訊息附在使用者訊息之前;失敗一律退回不注入。 Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Sonnet 5.5
parent
1c4e0c5d98
commit
d9e50d196b
@@ -28,6 +28,7 @@ claude plugin install anime-companion@jsc-plugins
|
||||
| --- | --- | --- |
|
||||
| `defaultCharacter` | `none` | 新 session 自動套用的角色:`none`、`sao-asuna`、`sao-suguha` |
|
||||
| `intensity` | `2` | 0 不套角色;1 只換稱呼與句尾;2 前後各一個對話氣泡;3 再加動作旁白 |
|
||||
| `showTiming` | `false` | 在狀態列顯示每則訊息的功能標籤分類耗時與結果 |
|
||||
| `address` | 空 | 角色怎麼稱呼你;留空則依原作關係(亞絲娜「桐人」、直葉「哥哥」) |
|
||||
|
||||
缺失或無效的設定值一律退回預設。
|
||||
@@ -38,3 +39,11 @@ claude plugin install anime-companion@jsc-plugins
|
||||
claude plugin validate plugins/anime-companion
|
||||
claude plugin test plugins/anime-companion
|
||||
```
|
||||
|
||||
## 對白檢索
|
||||
|
||||
每則使用者訊息送出時,hook 用 `$.model.complete`(Haiku、低 effort、3 秒逾時)判斷「角色接下來最自然的回應」屬於哪個功能標籤,再從該角色的對白索引取同標籤的 3 句,以一則只增不改的訊息附在使用者訊息之前,當語氣參考。
|
||||
|
||||
- 沒選角色、強度 0、索引為空、分類失敗、該標籤沒有對白時,都不注入,也不影響對話。
|
||||
- 索引為空時不呼叫模型。索引由建置流水線產生(W5、W6),放在 `hooks/data/`;目前為空。
|
||||
- 開 `showTiming` 可在狀態列看到每次分類的耗時。
|
||||
|
||||
Reference in New Issue
Block a user