sapper-iq 1.0.15 → 1.0.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.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/sapper.mjs +7 -1
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sapper-iq",
3
- "version": "1.0.15",
3
+ "version": "1.0.16",
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
@@ -115,7 +115,13 @@ async function runSapper() {
115
115
  let messages = [];
116
116
  if (fs.existsSync(CONTEXT_FILE)) {
117
117
  const resume = await safeQuestion(chalk.green('Resume previous session? (y/n): '));
118
- if (resume.toLowerCase() === 'y') messages = JSON.parse(fs.readFileSync(CONTEXT_FILE, 'utf8'));
118
+ if (resume.toLowerCase() === 'y') {
119
+ messages = JSON.parse(fs.readFileSync(CONTEXT_FILE, 'utf8'));
120
+ } else {
121
+ // User said no - delete the old context file
122
+ fs.unlinkSync(CONTEXT_FILE);
123
+ console.log(chalk.gray('Starting fresh session...\n'));
124
+ }
119
125
  }
120
126
 
121
127
  const localModels = await ollama.list();