grimoire-framework 1.0.2 → 1.0.4

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 (92) hide show
  1. package/.grimoire/install-manifest.yaml +2 -2
  2. package/.grimoire/memory/README.md +13 -0
  3. package/.grimoire/memory/entities/context.md +19 -0
  4. package/.grimoire/memory/entities/decisions.md +17 -0
  5. package/.grimoire/memory/entities/patterns.md +20 -0
  6. package/.grimoire/memory/sessions/2026-02-22.json +9 -0
  7. package/.grimoire/memory/sessions/archived/2026-02-22.jsonl +3 -0
  8. package/bin/commands/memory.js +215 -0
  9. package/bin/commands/metrics.js +107 -0
  10. package/bin/grimoire-cli.js +103 -0
  11. package/bin/grimoire-ids.js +2 -2
  12. package/bin/grimoire-minimal.js +1 -1
  13. package/bin/grimoire.js +1118 -1118
  14. package/bin/modules/env-config.js +2 -2
  15. package/bin/modules/mcp-installer.js +1 -1
  16. package/bin/utils/install-errors.js +1 -1
  17. package/bin/utils/install-transaction.js +2 -2
  18. package/bin/utils/pro-detector.js +110 -110
  19. package/package.json +158 -158
  20. package/packages/gemini-grimoire-extension/commands/grimoire-agents.js +2 -2
  21. package/packages/gemini-grimoire-extension/commands/grimoire-master.js +1 -1
  22. package/packages/gemini-grimoire-extension/commands/grimoire-status.js +2 -2
  23. package/packages/gemini-grimoire-extension/commands/grimoire-validate.js +2 -2
  24. package/packages/gemini-grimoire-extension/commands/lib/agent-launcher.js +147 -147
  25. package/packages/gemini-grimoire-extension/extension.json +2 -2
  26. package/packages/gemini-grimoire-extension/gemini-extension.json +2 -2
  27. package/packages/gemini-grimoire-extension/hooks/hooks.json +2 -2
  28. package/packages/grimoire-install/.releaserc.json +1 -1
  29. package/packages/grimoire-install/CHANGELOG.md +1 -1
  30. package/packages/grimoire-install/README.md +2 -2
  31. package/packages/grimoire-install/bin/edmcp.js +1 -1
  32. package/packages/grimoire-install/bin/grimoire-install.js +1 -1
  33. package/packages/grimoire-install/jest.config.js +1 -1
  34. package/packages/grimoire-install/package.json +2 -2
  35. package/packages/grimoire-install/src/edmcp/index.js +1 -1
  36. package/packages/grimoire-install/src/installer.js +2 -2
  37. package/packages/grimoire-pro-cli/bin/grimoire-pro.js +2 -2
  38. package/packages/grimoire-pro-cli/package.json +2 -2
  39. package/packages/grimoire-pro-cli/src/recover.js +1 -1
  40. package/packages/installer/package.json +1 -1
  41. package/packages/installer/src/__tests__/performance-benchmark.js +2 -2
  42. package/packages/installer/src/config/configure-environment.js +2 -2
  43. package/packages/installer/src/config/ide-configs.js +2 -2
  44. package/packages/installer/src/config/templates/core-config-template.js +2 -2
  45. package/packages/installer/src/config/templates/env-template.js +2 -2
  46. package/packages/installer/src/config/validation/config-validator.js +1 -1
  47. package/packages/installer/src/detection/detect-project-type.js +2 -2
  48. package/packages/installer/src/installer/brownfield-upgrader.js +2 -2
  49. package/packages/installer/src/installer/grimoire-core-installer.js +2 -2
  50. package/packages/installer/src/installer/manifest-signature.js +2 -2
  51. package/packages/installer/src/installer/post-install-validator.js +2 -2
  52. package/packages/installer/src/installer/squad-installer.js +109 -0
  53. package/packages/installer/src/merger/index.js +1 -1
  54. package/packages/installer/src/merger/parsers/markdown-section-parser.js +1 -1
  55. package/packages/installer/src/merger/strategies/env-merger.js +1 -1
  56. package/packages/installer/src/merger/strategies/markdown-merger.js +1 -1
  57. package/packages/installer/src/merger/types.js +1 -1
  58. package/packages/installer/src/pro/pro-scaffolder.js +2 -2
  59. package/packages/installer/src/updater/index.js +2 -2
  60. package/packages/installer/src/utils/grimoire-colors.js +1 -1
  61. package/packages/installer/src/wizard/i18n.js +2 -2
  62. package/packages/installer/src/wizard/ide-config-generator.js +2 -2
  63. package/packages/installer/src/wizard/ide-selector.js +1 -1
  64. package/packages/installer/src/wizard/index.js +28 -36
  65. package/packages/installer/src/wizard/pro-setup.js +2 -2
  66. package/packages/installer/src/wizard/questions.js +20 -15
  67. package/packages/installer/src/wizard/validation/index.js +1 -1
  68. package/packages/installer/src/wizard/validation/report-generator.js +1 -1
  69. package/packages/installer/src/wizard/validation/troubleshooting-system.js +2 -2
  70. package/packages/installer/src/wizard/validation/validators/config-validator.js +2 -2
  71. package/packages/installer/src/wizard/validation/validators/file-structure-validator.js +1 -1
  72. package/packages/installer/src/wizard/wizard.js +2 -2
  73. package/packages/installer/tests/integration/environment-configuration.test.js +2 -2
  74. package/packages/installer/tests/integration/wizard-detection.test.js +2 -2
  75. package/packages/installer/tests/unit/config-validator.test.js +1 -1
  76. package/packages/installer/tests/unit/detection/detect-project-type.test.js +2 -2
  77. package/packages/installer/tests/unit/env-template.test.js +2 -2
  78. package/packages/installer/tests/unit/merger/env-merger.test.js +1 -1
  79. package/packages/installer/tests/unit/merger/markdown-merger.test.js +1 -1
  80. package/scripts/check-markdown-links.py +352 -352
  81. package/scripts/code-intel-health-check.js +1 -1
  82. package/scripts/dashboard-parallel-dev.sh +1 -1
  83. package/scripts/dashboard-parallel-phase3.sh +1 -1
  84. package/scripts/dashboard-parallel-phase4.sh +1 -1
  85. package/scripts/ensure-manifest.js +1 -1
  86. package/scripts/generate-install-manifest.js +2 -2
  87. package/scripts/install-monitor-hooks.sh +2 -2
  88. package/scripts/package-synapse.js +2 -2
  89. package/scripts/semantic-lint.js +1 -1
  90. package/scripts/sign-manifest.sh +2 -2
  91. package/scripts/validate-manifest.js +2 -2
  92. package/scripts/validate-package-completeness.js +2 -2
@@ -69,4 +69,4 @@ module.exports = {
69
69
  createEmptyStats,
70
70
  createMergeResult,
71
71
  };
72
-
72
+
@@ -383,5 +383,5 @@ module.exports = {
383
383
  SCAFFOLD_ITEMS,
384
384
  SCAFFOLD_EXCLUDES,
385
385
  };
386
-
387
-
386
+
387
+
@@ -810,5 +810,5 @@ module.exports = {
810
810
  formatCheckResult,
811
811
  formatUpdateResult,
812
812
  };
813
-
814
-
813
+
814
+
@@ -232,4 +232,4 @@ module.exports = {
232
232
  // Also export as default for ESM compatibility
233
233
  module.exports.default = module.exports;
234
234
 
235
-
235
+
@@ -226,5 +226,5 @@ module.exports = {
226
226
  getLanguageChoices,
227
227
  TRANSLATIONS,
228
228
  };
229
-
230
-
229
+
230
+
@@ -989,5 +989,5 @@ module.exports = {
989
989
  createGeminiSettings,
990
990
  linkGeminiExtension,
991
991
  };
992
-
993
-
992
+
993
+
@@ -83,4 +83,4 @@ module.exports = {
83
83
  validateIDESelection,
84
84
  getIDESelectionQuestion,
85
85
  };
86
-
86
+
@@ -28,6 +28,9 @@ const {
28
28
  const {
29
29
  installDependencies,
30
30
  } = require('../installer/dependency-installer');
31
+ const {
32
+ installSquads,
33
+ } = require('../installer/squad-installer');
31
34
  const {
32
35
  installgrimoireCore,
33
36
  hasPackageJson,
@@ -358,6 +361,29 @@ async function runWizard(options = {}) {
358
361
  answers.grimoireCoreInstalled = false;
359
362
  }
360
363
 
364
+ // Install Selected Squads
365
+ if (answers.selectedSquads && answers.selectedSquads.length > 0) {
366
+ console.log('\n👥 Installing selected squads...');
367
+ try {
368
+ const squadResult = await installSquads({
369
+ targetDir: process.cwd(),
370
+ selectedSquads: answers.selectedSquads,
371
+ onProgress: (status) => {
372
+ console.log(` - ${status.message}`);
373
+ },
374
+ });
375
+
376
+ if (squadResult.success) {
377
+ console.log(`✅ Squads installed: ${squadResult.installedSquads.join(', ')}`);
378
+ }
379
+ answers.squadsInstalled = true;
380
+ answers.squadResult = squadResult;
381
+ } catch (error) {
382
+ console.error('\n⚠️ Squad installation failed:', error.message);
383
+ answers.squadsInstalled = false;
384
+ }
385
+ }
386
+
361
387
  // Install Tech Preset if selected
362
388
  if (answers.selectedTechPreset && answers.selectedTechPreset !== 'none') {
363
389
  console.log('\n📐 Configuring Tech Preset...');
@@ -703,43 +729,9 @@ async function runWizard(options = {}) {
703
729
  answers.llmRoutingInstalled = false;
704
730
  }
705
731
 
706
- // Story INS-3.2: Pro Installation Wizard (optional phase)
707
- if (!options.skipPro) {
708
- try {
709
- const { runProWizard } = require('./pro-setup');
710
- const isCI = process.env.CI === 'true' || !process.stdout.isTTY;
711
- const hasProKey = !!process.env.grimoire_PRO_KEY;
712
-
713
- if (isCI && hasProKey) {
714
- // CI mode: auto-run if grimoire_PRO_KEY is set
715
- console.log('\n🔑 Pro license key detected, running Pro setup...');
716
- const proResult = await runProWizard({ quiet: true });
717
- answers.proInstalled = proResult.success;
718
- answers.proResult = proResult;
719
- } else if (!isCI && !options.quiet) {
720
- // Interactive mode: ask if user has a Pro license
721
- const { hasPro } = await inquirer.prompt([
722
- {
723
- type: 'confirm',
724
- name: 'hasPro',
725
- message: colors.primary('Do you have an grimoire Pro license key?'),
726
- default: false,
727
- },
728
- ]);
732
+ // Pro features are available to all users — no license required
733
+ answers.proInstalled = true;
729
734
 
730
- if (hasPro) {
731
- const proResult = await runProWizard();
732
- answers.proInstalled = proResult.success;
733
- answers.proResult = proResult;
734
- } else {
735
- answers.proInstalled = false;
736
- }
737
- }
738
- } catch {
739
- // Pro module not available — skip silently
740
- answers.proInstalled = false;
741
- }
742
- }
743
735
 
744
736
  // Story 1.8: Installation Validation
745
737
  console.log('\n🔍 Validating installation...\n');
@@ -1219,5 +1219,5 @@ module.exports = {
1219
1219
  VERIFY_POLL_TIMEOUT_MS,
1220
1220
  },
1221
1221
  };
1222
-
1223
-
1222
+
1223
+
@@ -189,14 +189,11 @@ function getEnvironmentQuestions() {
189
189
  * Get Squad selection questions
190
190
  *
191
191
  * Available squads for v4.0:
192
- * - squad-creator: Tools to create custom squads
193
- * - etl: ETL pipeline for knowledge base creation
194
- *
195
- * Note: This function is currently DISABLED. Squad selection is handled
196
- * directly in grimoire-init.js using the squads/ directory.
192
+ * - fullstack: dev, qa, architect
193
+ * - planning: analyst, pm, architect, ux-design-expert
194
+ * - devops: devops, sm, po
197
195
  *
198
196
  * @returns {Object[]} Array of inquirer question objects
199
- * @deprecated Use squads/ directory directly in grimoire-init.js
200
197
  */
201
198
  function getSquadQuestions() {
202
199
  return [
@@ -207,14 +204,23 @@ function getSquadQuestions() {
207
204
  choices: [
208
205
  {
209
206
  name:
210
- colors.highlight('squad-creator') +
211
- colors.dim(' - Tools to create custom squads'),
212
- value: 'squad-creator',
207
+ colors.highlight('fullstack') +
208
+ colors.dim(' - Full Stack Development (dev, qa, architect)'),
209
+ value: 'fullstack',
210
+ checked: true,
211
+ },
212
+ {
213
+ name:
214
+ colors.highlight('planning') +
215
+ colors.dim(' - Planning & Strategy (analyst, pm, architect, ux-design-expert)'),
216
+ value: 'planning',
213
217
  checked: false,
214
218
  },
215
219
  {
216
- name: colors.highlight('etl') + colors.dim(' - ETL pipeline for knowledge base creation'),
217
- value: 'etl',
220
+ name:
221
+ colors.highlight('devops') +
222
+ colors.dim(' - DevOps & Management (devops, sm, po)'),
223
+ value: 'devops',
218
224
  checked: false,
219
225
  },
220
226
  ],
@@ -281,9 +287,8 @@ function buildQuestionSequence(_context = {}) {
281
287
  // TODO: Remove entirely in future version - each project has unique MCP needs
282
288
  // questions.push(...getMCPQuestions());
283
289
 
284
- // Squad Selection - DISABLED: Handled directly in grimoire-init.js
285
- // TODO: Consider removing getSquadQuestions() entirely in future version
286
- // questions.push(...getSquadQuestions());
290
+ // Squad Selection
291
+ questions.push(...getSquadQuestions());
287
292
 
288
293
  // Tech Preset Selection
289
294
  questions.push(...getTechPresetQuestion());
@@ -333,4 +338,4 @@ module.exports = {
333
338
  buildQuestionSequence,
334
339
  getQuestionById,
335
340
  };
336
-
341
+
@@ -118,4 +118,4 @@ module.exports = {
118
118
  displayValidationReport,
119
119
  provideTroubleshooting,
120
120
  };
121
-
121
+
@@ -251,4 +251,4 @@ function formatOverallStatus(validationResults) {
251
251
  module.exports = {
252
252
  generateReport,
253
253
  };
254
-
254
+
@@ -344,5 +344,5 @@ module.exports = {
344
344
  offerTroubleshooting,
345
345
  TROUBLESHOOTING_DATABASE,
346
346
  };
347
-
348
-
347
+
348
+
@@ -360,5 +360,5 @@ async function validateGitignore(results) {
360
360
  module.exports = {
361
361
  validateConfigs,
362
362
  };
363
-
364
-
363
+
364
+
@@ -172,4 +172,4 @@ async function validateFiles(fileContext = {}) {
172
172
  module.exports = {
173
173
  validateFiles,
174
174
  };
175
-
175
+
@@ -242,5 +242,5 @@ module.exports = {
242
242
  InstallationMode,
243
243
  };
244
244
 
245
-
246
-
245
+
246
+
@@ -327,5 +327,5 @@ describe('Environment Configuration Integration', () => {
327
327
  });
328
328
  });
329
329
  });
330
-
331
-
330
+
331
+
@@ -349,5 +349,5 @@ describe('Wizard Integration with Project Type Detection', () => {
349
349
  });
350
350
  });
351
351
 
352
-
353
-
352
+
353
+
@@ -313,4 +313,4 @@ project:
313
313
  });
314
314
  });
315
315
  });
316
-
316
+
@@ -399,5 +399,5 @@ describe('detectProjectType', () => {
399
399
  });
400
400
  });
401
401
 
402
-
403
-
402
+
403
+
@@ -185,5 +185,5 @@ describe('.env Template Generator', () => {
185
185
  });
186
186
  });
187
187
  });
188
-
189
-
188
+
189
+
@@ -189,4 +189,4 @@ KEY2=value2`;
189
189
  expect(result.variables.get('EMPTY_VAR').value).toBe('');
190
190
  });
191
191
  });
192
-
192
+
@@ -259,4 +259,4 @@ Content
259
259
  expect(hasgrimoireMarkers(content)).toBe(false);
260
260
  });
261
261
  });
262
-
262
+