@feniix/pi-code-reasoning 1.0.0 → 1.0.1
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/extensions/index.ts +6 -3
- package/package.json +1 -1
package/extensions/index.ts
CHANGED
|
@@ -52,6 +52,7 @@ interface CodeReasoningConfig {
|
|
|
52
52
|
|
|
53
53
|
interface ThoughtTracker {
|
|
54
54
|
add: (thought: ValidatedThoughtData) => void;
|
|
55
|
+
reset: () => void;
|
|
55
56
|
ensureBranchIsValid: (branchFromThought?: number) => void;
|
|
56
57
|
branches: () => string[];
|
|
57
58
|
count: () => number;
|
|
@@ -275,6 +276,10 @@ function createThoughtTracker(): ThoughtTracker {
|
|
|
275
276
|
},
|
|
276
277
|
branches: () => Array.from(branches.keys()),
|
|
277
278
|
count: () => thoughtHistory.length,
|
|
279
|
+
reset: () => {
|
|
280
|
+
thoughtHistory.length = 0;
|
|
281
|
+
branches.clear();
|
|
282
|
+
},
|
|
278
283
|
};
|
|
279
284
|
}
|
|
280
285
|
|
|
@@ -618,9 +623,7 @@ KEY PARAMETERS:
|
|
|
618
623
|
details: { status: "pending" },
|
|
619
624
|
});
|
|
620
625
|
|
|
621
|
-
|
|
622
|
-
// Note: We reassign the tracker reference - this clears the history
|
|
623
|
-
// In a more sophisticated implementation, you'd track this differently
|
|
626
|
+
tracker.reset();
|
|
624
627
|
return {
|
|
625
628
|
content: [{ type: "text" as const, text: "Code reasoning session reset." }],
|
|
626
629
|
isError: false,
|
package/package.json
CHANGED