@defai.digital/ax-cli 3.8.25 → 3.8.26
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.
|
@@ -105,6 +105,37 @@ system_prompt:
|
|
|
105
105
|
- Do not repeat the same exploration tools
|
|
106
106
|
- After getting tool results, USE them to complete the request
|
|
107
107
|
|
|
108
|
+
# Bug review protocol - prevents false positives
|
|
109
|
+
bug_review:
|
|
110
|
+
title: "BUG REVIEW PROTOCOL"
|
|
111
|
+
content: |
|
|
112
|
+
BEFORE claiming a bug exists, you MUST:
|
|
113
|
+
|
|
114
|
+
1. TRACE EXECUTION ORDER:
|
|
115
|
+
- For async code: setTimeout/Promise RETURN immediately, callbacks run LATER
|
|
116
|
+
- Trace variable state at EACH line number
|
|
117
|
+
- "Line X assigns value, Line Y uses it" - verify X runs before Y
|
|
118
|
+
|
|
119
|
+
2. VERIFY THE BUG:
|
|
120
|
+
- Describe EXACTLY how the bug manifests at runtime
|
|
121
|
+
- What error message or wrong behavior would occur?
|
|
122
|
+
- Under what conditions does it trigger?
|
|
123
|
+
|
|
124
|
+
3. CHALLENGE YOUR FINDING:
|
|
125
|
+
- "What if this code is actually correct?"
|
|
126
|
+
- "Am I confusing callback definition vs execution?"
|
|
127
|
+
- "Does the function return synchronously or asynchronously?"
|
|
128
|
+
|
|
129
|
+
4. TEST BEFORE FIXING:
|
|
130
|
+
- Can you write a test that fails due to this bug?
|
|
131
|
+
- If you cannot demonstrate the bug, it likely does not exist
|
|
132
|
+
|
|
133
|
+
COMMON FALSE POSITIVES:
|
|
134
|
+
- setTimeout/setInterval: Return timer ID IMMEDIATELY (synchronous)
|
|
135
|
+
- Promise constructor: Executor runs synchronously
|
|
136
|
+
- Callback definition vs callback execution timing
|
|
137
|
+
- Variable assigned on line N is available on line N+1 (same sync block)
|
|
138
|
+
|
|
108
139
|
# Code conventions
|
|
109
140
|
code_conventions:
|
|
110
141
|
title: "CODE CONVENTIONS"
|
|
@@ -12,13 +12,24 @@ export class DebugAgent extends Subagent {
|
|
|
12
12
|
buildSystemPrompt() {
|
|
13
13
|
return `Debugging agent. Fix the assigned bug.
|
|
14
14
|
|
|
15
|
+
BEFORE FIXING - Verify the bug exists:
|
|
16
|
+
1. TRACE execution order line by line (async code: functions RETURN immediately, callbacks run LATER)
|
|
17
|
+
2. DESCRIBE exactly how the bug manifests - what error/behavior would occur?
|
|
18
|
+
3. CHALLENGE your finding - "What if this code is actually correct?"
|
|
19
|
+
4. If you cannot demonstrate the bug, it likely does not exist
|
|
20
|
+
|
|
21
|
+
Common false positives:
|
|
22
|
+
- setTimeout returns timer ID IMMEDIATELY (synchronous), callback runs later
|
|
23
|
+
- Variable assigned on line N is available on line N+1 in same sync block
|
|
24
|
+
|
|
15
25
|
Requirements:
|
|
26
|
+
- VERIFY bug exists before fixing (trace execution, describe manifestation)
|
|
16
27
|
- Identify root cause before fixing
|
|
17
28
|
- Make minimal changes to fix the issue
|
|
18
29
|
- Add error handling if missing
|
|
19
30
|
- Test the fix to verify it works
|
|
20
31
|
|
|
21
|
-
Be brief. Focus only on
|
|
32
|
+
Be brief. Focus only on verified bugs.`;
|
|
22
33
|
}
|
|
23
34
|
}
|
|
24
35
|
//# sourceMappingURL=debug-agent.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"debug-agent.js","sourceRoot":"","sources":["../../../src/agent/specialized/debug-agent.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AAC1C,OAAO,EAAE,YAAY,EAAuB,MAAM,sBAAsB,CAAC;AAEzE,MAAM,OAAO,UAAW,SAAQ,QAAQ;IACtC,YAAY,eAAyC;QACnD,KAAK,CAAC,YAAY,CAAC,KAAK,EAAE,eAAe,CAAC,CAAC;IAC7C,CAAC;IAES,iBAAiB;QACzB,OAAO
|
|
1
|
+
{"version":3,"file":"debug-agent.js","sourceRoot":"","sources":["../../../src/agent/specialized/debug-agent.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AAC1C,OAAO,EAAE,YAAY,EAAuB,MAAM,sBAAsB,CAAC;AAEzE,MAAM,OAAO,UAAW,SAAQ,QAAQ;IACtC,YAAY,eAAyC;QACnD,KAAK,CAAC,YAAY,CAAC,KAAK,EAAE,eAAe,CAAC,CAAC;IAC7C,CAAC;IAES,iBAAiB;QACzB,OAAO;;;;;;;;;;;;;;;;;;;uCAmB4B,CAAC;IACtC,CAAC;CACF"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@defai.digital/ax-cli",
|
|
3
|
-
"version": "3.8.
|
|
3
|
+
"version": "3.8.26",
|
|
4
4
|
"sdkVersion": "1.2.0",
|
|
5
5
|
"description": "Enterprise-Class AI Command Line Interface - Primary support for GLM (General Language Model) with multi-provider AI orchestration powered by AutomatosX.",
|
|
6
6
|
"type": "module",
|