@shuind/dsh-codex-harness 0.2.14 → 0.2.16
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/README.md +24 -4
- package/docs/preset-library.md +21 -0
- package/lib/client.js +4583 -515
- package/lib/index.js +379 -4
- package/lib/types/client/index.d.ts +31 -21
- package/lib/types/client/index.js +63 -185
- package/lib/types/client/preset-copy.d.ts +30 -0
- package/lib/types/client/preset-copy.js +57 -0
- package/lib/types/client/preset-manager.d.ts +22 -0
- package/lib/types/client/preset-manager.js +156 -0
- package/lib/types/index.d.ts +11 -0
- package/lib/types/index.js +44 -1
- package/lib/types/preset-contract.d.ts +58 -0
- package/lib/types/preset-contract.js +22 -0
- package/lib/types/preset-editor-remote.d.ts +30 -0
- package/lib/types/preset-editor-remote.js +36 -0
- package/lib/types/preset-editor.d.ts +58 -0
- package/lib/types/preset-editor.js +332 -0
- package/lib/types/preset-templates.d.ts +36 -0
- package/lib/types/preset-templates.js +12 -0
- package/package.json +44 -19
- package/presets/codex-collaboration/agent.cordis.yml +1 -1
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
/** Extend this registry to add task-specific starting instructions without new UI branches. */
|
|
2
|
+
export declare const PRESET_TEMPLATES: readonly [{
|
|
3
|
+
readonly id: "general";
|
|
4
|
+
readonly label: "pmGeneral";
|
|
5
|
+
readonly description: "pmGeneralDesc";
|
|
6
|
+
readonly inheritPrompt: true;
|
|
7
|
+
readonly prompt: string;
|
|
8
|
+
}, {
|
|
9
|
+
readonly id: "review";
|
|
10
|
+
readonly label: "pmReview";
|
|
11
|
+
readonly description: "pmReviewDesc";
|
|
12
|
+
readonly inheritPrompt: false;
|
|
13
|
+
readonly prompt: `${string}
|
|
14
|
+
|
|
15
|
+
# Code review workflow
|
|
16
|
+
Review the requested changes for concrete correctness defects, regressions, and missing tests. Cite the affected code and a reproducible scenario. Prioritize findings by impact. Do not change files unless the user asks for a fix. If no actionable findings are found, say so and state any testing gaps.`;
|
|
17
|
+
}, {
|
|
18
|
+
readonly id: "debug";
|
|
19
|
+
readonly label: "pmDebug";
|
|
20
|
+
readonly description: "pmDebugDesc";
|
|
21
|
+
readonly inheritPrompt: false;
|
|
22
|
+
readonly prompt: `${string}
|
|
23
|
+
|
|
24
|
+
# Debugging workflow
|
|
25
|
+
Start from a reproducible symptom and preserve evidence. Form a narrow hypothesis, test it, and fix the root cause with the smallest correct change. Verify the original failure and relevant regressions. Report what was confirmed, what changed, and any remaining uncertainty.`;
|
|
26
|
+
}, {
|
|
27
|
+
readonly id: "docs";
|
|
28
|
+
readonly label: "pmDocs";
|
|
29
|
+
readonly description: "pmDocsDesc";
|
|
30
|
+
readonly inheritPrompt: false;
|
|
31
|
+
readonly prompt: `${string}
|
|
32
|
+
|
|
33
|
+
# Documentation workflow
|
|
34
|
+
Check the current source and supported interfaces before writing. Explain the reader's goal, prerequisites, and a working example. Keep commands and paths accurate. Do not invent features or guarantees. Keep documentation changes focused and verify examples where practical.`;
|
|
35
|
+
}];
|
|
36
|
+
//# sourceMappingURL=preset-templates.d.ts.map
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { DEFAULT_CODEX_SYSTEM_PROMPT } from "./prompt.js";
|
|
2
|
+
/** Extend this registry to add task-specific starting instructions without new UI branches. */
|
|
3
|
+
export const PRESET_TEMPLATES = [
|
|
4
|
+
{ id: 'general', label: 'pmGeneral', description: 'pmGeneralDesc', inheritPrompt: true, prompt: DEFAULT_CODEX_SYSTEM_PROMPT },
|
|
5
|
+
{ id: 'review', label: 'pmReview', description: 'pmReviewDesc', inheritPrompt: false,
|
|
6
|
+
prompt: `${DEFAULT_CODEX_SYSTEM_PROMPT}\n\n# Code review workflow\nReview the requested changes for concrete correctness defects, regressions, and missing tests. Cite the affected code and a reproducible scenario. Prioritize findings by impact. Do not change files unless the user asks for a fix. If no actionable findings are found, say so and state any testing gaps.` },
|
|
7
|
+
{ id: 'debug', label: 'pmDebug', description: 'pmDebugDesc', inheritPrompt: false,
|
|
8
|
+
prompt: `${DEFAULT_CODEX_SYSTEM_PROMPT}\n\n# Debugging workflow\nStart from a reproducible symptom and preserve evidence. Form a narrow hypothesis, test it, and fix the root cause with the smallest correct change. Verify the original failure and relevant regressions. Report what was confirmed, what changed, and any remaining uncertainty.` },
|
|
9
|
+
{ id: 'docs', label: 'pmDocs', description: 'pmDocsDesc', inheritPrompt: false,
|
|
10
|
+
prompt: `${DEFAULT_CODEX_SYSTEM_PROMPT}\n\n# Documentation workflow\nCheck the current source and supported interfaces before writing. Explain the reader's goal, prerequisites, and a working example. Keep commands and paths accurate. Do not invent features or guarantees. Keep documentation changes focused and verify examples where practical.` },
|
|
11
|
+
];
|
|
12
|
+
//# sourceMappingURL=preset-templates.js.map
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@shuind/dsh-codex-harness",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.16",
|
|
4
4
|
"description": "Codex coding preset with customizable prompts and tools for DSH.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "lib/index.js",
|
|
@@ -35,6 +35,7 @@
|
|
|
35
35
|
"./package.json": "./package.json"
|
|
36
36
|
},
|
|
37
37
|
"files": [
|
|
38
|
+
"docs/preset-library.md",
|
|
38
39
|
"lib/index.js",
|
|
39
40
|
"lib/invariant.js",
|
|
40
41
|
"lib/installer.js",
|
|
@@ -48,13 +49,6 @@
|
|
|
48
49
|
"README.zh.md",
|
|
49
50
|
"LICENSE"
|
|
50
51
|
],
|
|
51
|
-
"scripts": {
|
|
52
|
-
"build": "tsc --noCheck -p tsconfig.json && tsdown",
|
|
53
|
-
"check": "tsc -p tsconfig.json --noEmit",
|
|
54
|
-
"test": "vitest run",
|
|
55
|
-
"pack:check": "npm pack --dry-run",
|
|
56
|
-
"prepare": "npm run build"
|
|
57
|
-
},
|
|
58
52
|
"repository": {
|
|
59
53
|
"type": "git",
|
|
60
54
|
"url": "git+https://github.com/shuind/dsh-codex-harness.git"
|
|
@@ -77,6 +71,7 @@
|
|
|
77
71
|
"inject": [
|
|
78
72
|
"@deepseek-ai/dsh-client-locale",
|
|
79
73
|
"@deepseek-ai/dsh-client-runtime",
|
|
74
|
+
"@deepseek-ai/dsh-api-remotes",
|
|
80
75
|
"@deepseek-ai/dsh-client-ui-conversation",
|
|
81
76
|
"@deepseek-ai/dsh-client-ui-commands",
|
|
82
77
|
"@deepseek-ai/dsh-client-ui-settings",
|
|
@@ -87,15 +82,19 @@
|
|
|
87
82
|
},
|
|
88
83
|
"dependencies": {
|
|
89
84
|
"@deepseek-ai/schemastery": "^3.18.1",
|
|
85
|
+
"yaml": "2.8.1",
|
|
90
86
|
"zod": "^4.4.3"
|
|
91
87
|
},
|
|
92
88
|
"peerDependencies": {
|
|
93
89
|
"@deepseek-ai/cordis": ">=4.0.1",
|
|
94
90
|
"@deepseek-ai/dsh-agent": ">=0.1.0-rc.6",
|
|
91
|
+
"@deepseek-ai/dsh-agent-presets": ">=0.1.5-rc.2",
|
|
92
|
+
"@deepseek-ai/dsh-api-remotes": ">=0.1.5-rc.2",
|
|
93
|
+
"@deepseek-ai/dsh-atomic-write": ">=0.1.5-rc.2",
|
|
95
94
|
"@deepseek-ai/dsh-client-locale": ">=0.1.0-rc.8",
|
|
96
95
|
"@deepseek-ai/dsh-client-runtime": ">=0.1.0-rc.8",
|
|
97
|
-
"@deepseek-ai/dsh-client-ui-conversation": ">=0.1.0-rc.8",
|
|
98
96
|
"@deepseek-ai/dsh-client-ui-commands": ">=0.1.0-rc.8",
|
|
97
|
+
"@deepseek-ai/dsh-client-ui-conversation": ">=0.1.0-rc.8",
|
|
99
98
|
"@deepseek-ai/dsh-client-ui-settings": ">=0.1.0-rc.8",
|
|
100
99
|
"@deepseek-ai/dsh-client-ui-settings-plugins": ">=0.1.0-rc.8",
|
|
101
100
|
"@deepseek-ai/dsh-client-ui-slots": ">=0.1.0-rc.8",
|
|
@@ -108,19 +107,21 @@
|
|
|
108
107
|
"@deepseek-ai/dsh-invariants": ">=0.0.1-rc.1",
|
|
109
108
|
"@deepseek-ai/dsh-jobs": ">=0.1.0-rc.8",
|
|
110
109
|
"@deepseek-ai/dsh-llm": ">=0.1.0-rc.8",
|
|
111
|
-
"@deepseek-ai/dsh-
|
|
110
|
+
"@deepseek-ai/dsh-persona": ">=0.1.3-alpha.2",
|
|
112
111
|
"@deepseek-ai/dsh-sandbox": ">=0.0.1-rc.1",
|
|
113
112
|
"@deepseek-ai/dsh-sandbox-policy": ">=0.0.1-rc.1",
|
|
114
113
|
"@deepseek-ai/dsh-session": ">=0.1.0-rc.8",
|
|
114
|
+
"@deepseek-ai/dsh-settings": ">=0.1.0-rc.8",
|
|
115
115
|
"@deepseek-ai/dsh-shell": ">=0.0.1-rc.5",
|
|
116
116
|
"@deepseek-ai/dsh-shell-env": ">=0.0.1-rc.3",
|
|
117
117
|
"@deepseek-ai/dsh-system-prompt": ">=0.0.1-rc.1",
|
|
118
|
-
"@deepseek-ai/dsh-tool-web": ">=0.1.0-rc.8",
|
|
119
|
-
"@deepseek-ai/dsh-tool-todo": ">=0.0.1-rc.1",
|
|
120
118
|
"@deepseek-ai/dsh-terminal": ">=0.0.1-rc.3",
|
|
121
|
-
"@deepseek-ai/dsh-tool-jobs": ">=0.1.0-rc.8",
|
|
122
119
|
"@deepseek-ai/dsh-token-meter": ">=0.1.0-rc.8",
|
|
123
|
-
"@deepseek-ai/dsh-
|
|
120
|
+
"@deepseek-ai/dsh-tool-jobs": ">=0.1.0-rc.8",
|
|
121
|
+
"@deepseek-ai/dsh-tool-todo": ">=0.0.1-rc.1",
|
|
122
|
+
"@deepseek-ai/dsh-tool-web": ">=0.1.0-rc.8",
|
|
123
|
+
"@deepseek-ai/dsh-tools": ">=0.0.1-rc.1",
|
|
124
|
+
"@deepseek-ai/dsh-typert-protocol": ">=0.1.5-rc.2"
|
|
124
125
|
},
|
|
125
126
|
"peerDependenciesMeta": {
|
|
126
127
|
"@deepseek-ai/cordis": {
|
|
@@ -129,6 +130,15 @@
|
|
|
129
130
|
"@deepseek-ai/dsh-agent": {
|
|
130
131
|
"optional": true
|
|
131
132
|
},
|
|
133
|
+
"@deepseek-ai/dsh-agent-presets": {
|
|
134
|
+
"optional": true
|
|
135
|
+
},
|
|
136
|
+
"@deepseek-ai/dsh-api-remotes": {
|
|
137
|
+
"optional": true
|
|
138
|
+
},
|
|
139
|
+
"@deepseek-ai/dsh-atomic-write": {
|
|
140
|
+
"optional": true
|
|
141
|
+
},
|
|
132
142
|
"@deepseek-ai/dsh-client-locale": {
|
|
133
143
|
"optional": true
|
|
134
144
|
},
|
|
@@ -177,6 +187,9 @@
|
|
|
177
187
|
"@deepseek-ai/dsh-llm": {
|
|
178
188
|
"optional": true
|
|
179
189
|
},
|
|
190
|
+
"@deepseek-ai/dsh-persona": {
|
|
191
|
+
"optional": true
|
|
192
|
+
},
|
|
180
193
|
"@deepseek-ai/dsh-settings": {
|
|
181
194
|
"optional": true
|
|
182
195
|
},
|
|
@@ -215,6 +228,9 @@
|
|
|
215
228
|
},
|
|
216
229
|
"@deepseek-ai/dsh-tools": {
|
|
217
230
|
"optional": true
|
|
231
|
+
},
|
|
232
|
+
"@deepseek-ai/dsh-typert-protocol": {
|
|
233
|
+
"optional": true
|
|
218
234
|
}
|
|
219
235
|
},
|
|
220
236
|
"devDependencies": {
|
|
@@ -222,6 +238,7 @@
|
|
|
222
238
|
"@deepseek-ai/cordis-plugin-include": "1.0.6",
|
|
223
239
|
"@deepseek-ai/cordis-plugin-loader": "1.0.2",
|
|
224
240
|
"@deepseek-ai/dsh-agent": "0.1.0-rc.6",
|
|
241
|
+
"@deepseek-ai/dsh-atomic-write": "0.1.5-rc.2",
|
|
225
242
|
"@deepseek-ai/dsh-client-locale": "0.1.0-rc.8",
|
|
226
243
|
"@deepseek-ai/dsh-client-runtime": "0.1.0-rc.8",
|
|
227
244
|
"@deepseek-ai/dsh-client-ui-conversation": "0.1.0-rc.8",
|
|
@@ -229,24 +246,26 @@
|
|
|
229
246
|
"@deepseek-ai/dsh-client-ui-slots": "0.1.0-rc.8",
|
|
230
247
|
"@deepseek-ai/dsh-compaction": "0.1.1-rc.2",
|
|
231
248
|
"@deepseek-ai/dsh-compaction-basic": "0.1.1-rc.2",
|
|
249
|
+
"@deepseek-ai/dsh-compaction-tool-result-pruner": "0.1.1-rc.2",
|
|
232
250
|
"@deepseek-ai/dsh-credentials": "0.1.0-rc.8",
|
|
233
251
|
"@deepseek-ai/dsh-fs": "0.1.0-rc.6",
|
|
234
252
|
"@deepseek-ai/dsh-invariants": "0.1.0-rc.6",
|
|
235
253
|
"@deepseek-ai/dsh-jobs": "0.1.0-rc.8",
|
|
236
254
|
"@deepseek-ai/dsh-llm": "0.1.0-rc.8",
|
|
237
|
-
"@deepseek-ai/dsh-settings": "0.1.0-rc.8",
|
|
238
255
|
"@deepseek-ai/dsh-sandbox": "0.1.0-rc.6",
|
|
239
256
|
"@deepseek-ai/dsh-sandbox-policy": "0.1.0-rc.6",
|
|
240
257
|
"@deepseek-ai/dsh-session": "0.1.1-rc.2",
|
|
258
|
+
"@deepseek-ai/dsh-settings": "0.1.0-rc.8",
|
|
241
259
|
"@deepseek-ai/dsh-shell": "0.1.0-rc.6",
|
|
242
260
|
"@deepseek-ai/dsh-shell-env": "0.1.0-rc.6",
|
|
243
261
|
"@deepseek-ai/dsh-system-prompt": "0.1.0-rc.6",
|
|
244
|
-
"@deepseek-ai/dsh-tool-web": "0.1.0-rc.8",
|
|
245
|
-
"@deepseek-ai/dsh-tool-todo": "0.1.0-rc.6",
|
|
246
262
|
"@deepseek-ai/dsh-terminal": "0.1.0-rc.6",
|
|
247
|
-
"@deepseek-ai/dsh-tool-jobs": "0.1.0-rc.8",
|
|
248
263
|
"@deepseek-ai/dsh-token-meter": "0.1.1-rc.2",
|
|
264
|
+
"@deepseek-ai/dsh-tool-jobs": "0.1.0-rc.8",
|
|
265
|
+
"@deepseek-ai/dsh-tool-todo": "0.1.0-rc.6",
|
|
266
|
+
"@deepseek-ai/dsh-tool-web": "0.1.0-rc.8",
|
|
249
267
|
"@deepseek-ai/dsh-tools": "0.1.0-rc.6",
|
|
268
|
+
"@deepseek-ai/dsh-typert-protocol": "0.1.5-rc.2",
|
|
250
269
|
"@types/node": "^22.20.0",
|
|
251
270
|
"@types/react": "~18.3.1",
|
|
252
271
|
"@types/react-dom": "~18.3.0",
|
|
@@ -256,5 +275,11 @@
|
|
|
256
275
|
"typescript": "^6.0.3",
|
|
257
276
|
"unrun": "^0.3.1",
|
|
258
277
|
"vitest": "^4.1.8"
|
|
278
|
+
},
|
|
279
|
+
"scripts": {
|
|
280
|
+
"build": "tsc --noCheck -p tsconfig.json && tsdown",
|
|
281
|
+
"check": "tsc -p tsconfig.json --noEmit",
|
|
282
|
+
"test": "vitest run",
|
|
283
|
+
"pack:check": "npm pack --dry-run"
|
|
259
284
|
}
|
|
260
|
-
}
|
|
285
|
+
}
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
name: '@deepseek-ai/dsh-persona'
|
|
6
6
|
config:
|
|
7
7
|
# Keep identity, model, cwd, and runtime context in one persona section.
|
|
8
|
-
|
|
8
|
+
prefix: >-
|
|
9
9
|
You are Codex, a coding agent based on the {{model}} model. Your working directory is {{cwd}}.
|
|
10
10
|
includeRuntimeContext: true
|
|
11
11
|
|