claude-spotter 1.4.12 → 1.4.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +27 -0
- package/package.json +1 -1
- package/src/hooks/lib.mjs +2 -6
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,32 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 1.4.13
|
|
4
|
+
|
|
5
|
+
**Spotter 監査文面の末尾「監査役を明示してください」念押し行を削除**。
|
|
6
|
+
`additionalContext` / pending text の末尾に入っていた 2 行 (UserPromptSubmit:
|
|
7
|
+
「使う場合は『Spotter の推奨に従い〜』のように監査役の指摘を明示してください。」、
|
|
8
|
+
Stop deferred delivery:「応答には『Spotter からの指摘を受けて〜』のように
|
|
9
|
+
監査役の介入を明示してください。」) が、毎ターン主役 AI の文脈に積もって邪魔になる
|
|
10
|
+
という運用上のフィードバックを反映。ヘッダー `[Spotter からの推奨ツール]` /
|
|
11
|
+
`[Spotter からの指摘]` 自体が出典明示を担っているため、§12.2 / §12.3 の透明化原則は
|
|
12
|
+
ヘッダーで維持し、念押し行のみを落とす。Claude / Codex 両 host が同じ
|
|
13
|
+
`formatTransparentContext` / `formatTransparentBlockReason` を共有しているので
|
|
14
|
+
hook parity は自動的に維持される。
|
|
15
|
+
|
|
16
|
+
### 変更点
|
|
17
|
+
|
|
18
|
+
- **編集 [src/hooks/lib.mjs](src/hooks/lib.mjs)**:
|
|
19
|
+
`formatTransparentContext` / `formatTransparentBlockReason` から末尾の空行 +
|
|
20
|
+
念押し行を削除。コメントを「header 自体が出典明示を担う」旨に書き換え。
|
|
21
|
+
- **編集 [test/hooks.test.mjs](test/hooks.test.mjs)**:
|
|
22
|
+
逐語アサート 2 件を本体に追従。
|
|
23
|
+
|
|
24
|
+
### 検証
|
|
25
|
+
|
|
26
|
+
- `node --test` 334 tests / 333 pass / 1 skip 緑。
|
|
27
|
+
- Codex hook 側の expected (`test/codex-hook-cmd.test.mjs`) はヘッダー文字列
|
|
28
|
+
`Spotter からの指摘` だけを正規表現マッチしているため無変更で pass。
|
|
29
|
+
|
|
3
30
|
## 1.4.12
|
|
4
31
|
|
|
5
32
|
**macOS/Homebrew install verification docs**。npm registry からの clean global install 後に
|
package/package.json
CHANGED
package/src/hooks/lib.mjs
CHANGED
|
@@ -129,14 +129,12 @@ export function die(message, exitCode = 2) {
|
|
|
129
129
|
}
|
|
130
130
|
|
|
131
131
|
export function formatTransparentContext(missingTools) {
|
|
132
|
-
// §12.2: transparent phrasing —
|
|
132
|
+
// §12.2: transparent phrasing — header `[Spotter からの推奨ツール]` 自体が出典明示を担う。
|
|
133
133
|
const lines = missingTools.map((m) => `- \`${m.name}\`: ${m.reason}`);
|
|
134
134
|
return [
|
|
135
135
|
'[Spotter からの推奨ツール]',
|
|
136
136
|
'このプロンプトに応答する前に、以下のツールを使うべきか検討してください。',
|
|
137
137
|
...lines,
|
|
138
|
-
'',
|
|
139
|
-
'使う場合は「Spotter の推奨に従い〜」のように監査役の指摘を明示してください。',
|
|
140
138
|
].join('\n');
|
|
141
139
|
}
|
|
142
140
|
|
|
@@ -156,13 +154,11 @@ export async function recordClaudeHookEvent({ projectRoot, event, writeError } =
|
|
|
156
154
|
}
|
|
157
155
|
|
|
158
156
|
export function formatTransparentBlockReason(missingTools) {
|
|
159
|
-
// §12.3: transparent phrasing
|
|
157
|
+
// §12.3: transparent phrasing — header `[Spotter からの指摘]` 自体が出典明示を担う。
|
|
160
158
|
const lines = missingTools.map((m) => `- \`${m.name}\`: ${m.reason}`);
|
|
161
159
|
return [
|
|
162
160
|
'[Spotter からの指摘]',
|
|
163
161
|
'上記応答ではツールが不足している可能性があります。以下を検討し、必要なら呼び出した上で応答を補正してください。',
|
|
164
162
|
...lines,
|
|
165
|
-
'',
|
|
166
|
-
'応答には「Spotter からの指摘を受けて〜」のように監査役の介入を明示してください。',
|
|
167
163
|
].join('\n');
|
|
168
164
|
}
|