sapper-iq 1.1.22 → 1.1.23

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.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/sapper.mjs +2 -2
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sapper-iq",
3
- "version": "1.1.22",
3
+ "version": "1.1.23",
4
4
  "description": "AI-powered development assistant that executes commands and builds projects",
5
5
  "main": "sapper.mjs",
6
6
  "bin": {
package/sapper.mjs CHANGED
@@ -814,8 +814,8 @@ async function runSapper() {
814
814
 
815
815
  messages.push({ role: 'assistant', content: msg });
816
816
 
817
- // Fixed regex: [^\]]+ stops at first ] to correctly separate path from content
818
- const toolMatches = [...msg.matchAll(/\[TOOL:(\w+)\]([^\]]+)(?:\]([\s\S]*?))?\[\/TOOL\]/g)];
817
+ // Fixed regex: [^\]]* allows empty path (AI sometimes sends [TOOL:LIST][/TOOL])
818
+ const toolMatches = [...msg.matchAll(/\[TOOL:(\w+)\]([^\]]*)(?:\]([\s\S]*?))?\[\/TOOL\]/g)];
819
819
 
820
820
  // Debug mode: show what regex sees
821
821
  if (debugMode) {