@goodandready/dsh-agent-loop-guard 0.2.15 → 0.2.17
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 +5 -0
- package/lib/index.js +22 -13
- package/package.json +6 -3
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,10 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 0.2.16
|
|
4
|
+
|
|
5
|
+
### Fixed
|
|
6
|
+
- **Peer gate on DSH 0.2.0-rc.1** (#58): DSH skips a profile bundle whose `peerDependencies` exclude the running version, so this plugin was absent from the profile with no error in the UI. Every `@deepseek-ai/dsh-*` peer now names both the 0.1.7-rc.2 and 0.2.0-rc.1 lines, because semver does not admit a prerelease of the next minor into a range that does not name it.
|
|
7
|
+
|
|
3
8
|
All notable changes to this project will be documented in this file.
|
|
4
9
|
|
|
5
10
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
package/lib/index.js
CHANGED
|
@@ -11,20 +11,29 @@ import { registerPluginUpdater, isTrustedTelemetryRequest } from './plugin-updat
|
|
|
11
11
|
export const name = '@goodandready/dsh-agent-loop-guard';
|
|
12
12
|
export const inject = ['tools', 'agents', 'sessions'];
|
|
13
13
|
|
|
14
|
+
// Unwrap Volatile boxes before any caller reads a value. A volatile field holds a box
|
|
15
|
+
// rather than its value, and the Loader mutates those boxes in place.
|
|
16
|
+
export function plainConfig(value) {
|
|
17
|
+
if (value === null || typeof value !== 'object') return value
|
|
18
|
+
if (Array.isArray(value)) return value.map(plainConfig)
|
|
19
|
+
if (typeof value.get === 'function') return plainConfig(value.get())
|
|
20
|
+
return Object.fromEntries(Object.entries(value).map(([k, v]) => [k, plainConfig(v)]))
|
|
21
|
+
}
|
|
22
|
+
|
|
14
23
|
export const Config = Schema.object({
|
|
15
|
-
maxToolAttemptsPerTurn: Schema.number().min(0).default(64),
|
|
16
|
-
maxProgressToolCallsPerTurn: Schema.number().min(1).default(16),
|
|
17
|
-
progressToolNames: Schema.array(Schema.string()).default(['todo_write']),
|
|
18
|
-
maxCallsPerRepeatGroup: Schema.number().min(1).default(5),
|
|
19
|
-
maxCallsPerToolPerTurn: Schema.number().min(1).default(5).description('Deprecated: legacy alias for maxCallsPerRepeatGroup'),
|
|
20
|
-
strictTools: Schema.array(Schema.string()).default([]),
|
|
21
|
-
strictToolLimit: Schema.number().min(1).default(3),
|
|
22
|
-
blockExactDuplicates: Schema.boolean().default(true),
|
|
23
|
-
dryRunMode: Schema.boolean().default(false),
|
|
24
|
-
assistantOutputGuard: Schema.boolean().default(true),
|
|
25
|
-
maxRepeatedAssistantLines: Schema.number().min(1).default(5),
|
|
26
|
-
maxRepeatedAssistantBlocks: Schema.number().min(1).default(5),
|
|
27
|
-
maxAssistantBlockChars: Schema.number().min(256).default(16_384),
|
|
24
|
+
maxToolAttemptsPerTurn: Schema.number().volatile().min(0).default(64),
|
|
25
|
+
maxProgressToolCallsPerTurn: Schema.number().volatile().min(1).default(16),
|
|
26
|
+
progressToolNames: Schema.array(Schema.string()).volatile().default(['todo_write']),
|
|
27
|
+
maxCallsPerRepeatGroup: Schema.number().volatile().min(1).default(5),
|
|
28
|
+
maxCallsPerToolPerTurn: Schema.number().volatile().min(1).default(5).description('Deprecated: legacy alias for maxCallsPerRepeatGroup'),
|
|
29
|
+
strictTools: Schema.array(Schema.string()).volatile().default([]),
|
|
30
|
+
strictToolLimit: Schema.number().volatile().min(1).default(3),
|
|
31
|
+
blockExactDuplicates: Schema.boolean().volatile().default(true),
|
|
32
|
+
dryRunMode: Schema.boolean().volatile().default(false),
|
|
33
|
+
assistantOutputGuard: Schema.boolean().volatile().default(true),
|
|
34
|
+
maxRepeatedAssistantLines: Schema.number().volatile().min(1).default(5),
|
|
35
|
+
maxRepeatedAssistantBlocks: Schema.number().volatile().min(1).default(5),
|
|
36
|
+
maxAssistantBlockChars: Schema.number().volatile().min(256).default(16_384),
|
|
28
37
|
});
|
|
29
38
|
|
|
30
39
|
function callIdFromEvent(event) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@goodandready/dsh-agent-loop-guard",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.17",
|
|
4
4
|
"description": "Fail-closed runtime tool-call loop guard for DeepSeek Harness.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "lib/index.js",
|
|
@@ -42,8 +42,8 @@
|
|
|
42
42
|
"license": "MIT",
|
|
43
43
|
"peerDependencies": {
|
|
44
44
|
"@deepseek-ai/cordis": "^4.0.1",
|
|
45
|
-
"@deepseek-ai/schemastery": "^3.18.
|
|
46
|
-
"@deepseek-ai/dsh-settings": "^0.1.0-rc.
|
|
45
|
+
"@deepseek-ai/schemastery": "^3.18.4",
|
|
46
|
+
"@deepseek-ai/dsh-settings": "^0.1.7-rc.2 || ^0.2.0-rc.1"
|
|
47
47
|
},
|
|
48
48
|
"repository": {
|
|
49
49
|
"type": "git",
|
|
@@ -52,5 +52,8 @@
|
|
|
52
52
|
"homepage": "https://github.com/GooDAnDReaDY/dsh-agent-loop-guard",
|
|
53
53
|
"bugs": {
|
|
54
54
|
"url": "https://github.com/GooDAnDReaDY/dsh-agent-loop-guard/issues"
|
|
55
|
+
},
|
|
56
|
+
"devDependencies": {
|
|
57
|
+
"@deepseek-ai/schemastery": "^3.18.4"
|
|
55
58
|
}
|
|
56
59
|
}
|