@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.
@@ -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
- // Create a new tracker (effectively resetting)
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
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@feniix/pi-code-reasoning",
3
- "version": "1.0.0",
3
+ "version": "1.0.1",
4
4
  "description": "Code Reasoning extension for pi — reflective problem-solving through sequential thinking with branching and revision support",
5
5
  "keywords": [
6
6
  "pi",