sinapse-ai 1.12.1 → 1.13.0

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 (93) hide show
  1. package/.claude/CLAUDE.md +2 -2
  2. package/.claude/rules/agent-memory-imports.md +2 -0
  3. package/.sinapse-ai/cli/commands/pro/index.js +8 -48
  4. package/.sinapse-ai/constitution.md +6 -2
  5. package/.sinapse-ai/core-config.yaml +5 -1
  6. package/.sinapse-ai/data/entity-registry.yaml +95 -95
  7. package/.sinapse-ai/development/agents/architect/MEMORY.md +35 -0
  8. package/.sinapse-ai/development/agents/data-engineer/MEMORY.md +38 -0
  9. package/.sinapse-ai/development/agents/developer/MEMORY.md +36 -0
  10. package/.sinapse-ai/development/agents/devops/MEMORY.md +39 -0
  11. package/.sinapse-ai/development/agents/devops.md +0 -1
  12. package/.sinapse-ai/development/agents/product-lead/MEMORY.md +36 -0
  13. package/.sinapse-ai/development/agents/project-lead/MEMORY.md +36 -0
  14. package/.sinapse-ai/development/agents/quality-gate/MEMORY.md +35 -0
  15. package/.sinapse-ai/development/agents/quality-gate.md +1 -1
  16. package/.sinapse-ai/development/agents/snps-orqx.md +4 -0
  17. package/.sinapse-ai/development/agents/sprint-lead/MEMORY.md +36 -0
  18. package/.sinapse-ai/development/templates/chrome-brain/knowledge-base/chrome-brain.md +2 -2
  19. package/.sinapse-ai/infrastructure/scripts/ide-sync/index.js +15 -0
  20. package/.sinapse-ai/infrastructure/scripts/validate-agents.js +159 -8
  21. package/.sinapse-ai/install-manifest.yaml +20 -156
  22. package/AGENTS.md +13 -2
  23. package/CHANGELOG.md +119 -4
  24. package/README.en.md +1 -1
  25. package/README.md +6 -26
  26. package/bin/cli.js +2 -7
  27. package/bin/commands/install.js +19 -257
  28. package/bin/commands/update.js +18 -78
  29. package/bin/lib/command-generator.js +261 -0
  30. package/bin/lib/prompts.js +2 -65
  31. package/bin/modules/chrome-brain-installer.js +2 -1
  32. package/bin/postinstall.js +6 -6
  33. package/docs/getting-started.md +0 -1
  34. package/docs/pt/getting-started.md +1 -1
  35. package/docs/security/dependabot-triage.md +17 -17
  36. package/package.json +6 -3
  37. package/packages/installer/src/wizard/i18n.js +3 -204
  38. package/packages/installer/src/wizard/index.js +1 -1
  39. package/packages/installer/src/wizard/questions.js +5 -368
  40. package/packages/installer/src/wizard/wizard.js +0 -9
  41. package/scripts/generate-install-manifest.js +6 -0
  42. package/scripts/validate-changelog-tags.js +97 -0
  43. package/scripts/validate-no-personal-leaks.js +184 -28
  44. package/scripts/validate-schemas.js +55 -10
  45. package/scripts/validate-story-meta.js +25 -12
  46. package/squads/claude-code-mastery/agents/claude-mastery-chief.md +1 -1
  47. package/squads/claude-code-mastery/agents/hooks-architect.md +12 -20
  48. package/squads/claude-code-mastery/tasks/audit-setup.md +1 -1
  49. package/squads/squad-product/agents/product-orqx.md +0 -1
  50. package/squads/squad-product/agents/ps-client-product-manager.md +0 -1
  51. package/squads/squad-product/agents/ps-delivery-manager.md +0 -1
  52. package/squads/squad-product/agents/ps-discovery-lead.md +0 -1
  53. package/squads/squad-product/agents/ps-product-analyst.md +0 -1
  54. package/squads/squad-product/agents/ps-product-ops-specialist.md +0 -1
  55. package/squads/squad-product/agents/ps-product-strategist.md +0 -1
  56. package/.sinapse-ai/core/grounding/README.md +0 -83
  57. package/.sinapse-ai/core/grounding/brand.cjs +0 -29
  58. package/.sinapse-ai/core/grounding/config-loader.cjs +0 -52
  59. package/.sinapse-ai/core/grounding/design-system.cjs +0 -29
  60. package/.sinapse-ai/core/grounding/vault.cjs +0 -36
  61. package/.sinapse-ai/development/scripts/approval-workflow.js +0 -643
  62. package/.sinapse-ai/development/scripts/backup-manager.js +0 -607
  63. package/.sinapse-ai/development/scripts/branch-manager.js +0 -390
  64. package/.sinapse-ai/development/scripts/code-quality-improver.js +0 -1329
  65. package/.sinapse-ai/development/scripts/commit-message-generator.js +0 -850
  66. package/.sinapse-ai/development/scripts/conflict-resolver.js +0 -675
  67. package/.sinapse-ai/development/scripts/dependency-analyzer.js +0 -638
  68. package/.sinapse-ai/development/scripts/diff-generator.js +0 -352
  69. package/.sinapse-ai/development/scripts/git-wrapper.js +0 -462
  70. package/.sinapse-ai/development/scripts/modification-validator.js +0 -555
  71. package/.sinapse-ai/development/scripts/performance-analyzer.js +0 -758
  72. package/.sinapse-ai/development/scripts/refactoring-suggester.js +0 -1148
  73. package/.sinapse-ai/development/scripts/rollback-handler.js +0 -531
  74. package/.sinapse-ai/development/scripts/security-checker.js +0 -359
  75. package/.sinapse-ai/development/scripts/template-engine.js +0 -240
  76. package/.sinapse-ai/development/scripts/template-validator.js +0 -279
  77. package/.sinapse-ai/development/scripts/test-generator.js +0 -844
  78. package/.sinapse-ai/development/scripts/transaction-manager.js +0 -590
  79. package/.sinapse-ai/development/scripts/yaml-validator.js +0 -397
  80. package/.sinapse-ai/hooks/sinapse-brand-grounding.cjs +0 -162
  81. package/.sinapse-ai/hooks/sinapse-ds-grounding.cjs +0 -211
  82. package/.sinapse-ai/hooks/sinapse-vault-grounding.cjs +0 -194
  83. package/bin/lib/register-grounding-hooks.js +0 -145
  84. package/docs/guides/agents/traces/execution-traces.zip +0 -0
  85. package/docs/guides/grounding-setup.md +0 -154
  86. package/docs/guides/workflows/SINAPSE-WORKFLOWS.zip +0 -0
  87. package/packages/installer/src/pro/pro-scaffolder.js +0 -449
  88. package/packages/installer/src/wizard/grounding-config.js +0 -131
  89. package/packages/installer/src/wizard/pro-setup.js +0 -1439
  90. package/packages/installer/templates/README.md +0 -16
  91. package/packages/installer/templates/brand-routing.example.json +0 -12
  92. package/packages/installer/templates/ds-routing.example.json +0 -12
  93. package/packages/installer/templates/vault-routing.example.json +0 -12
@@ -1,131 +0,0 @@
1
- /**
2
- * Grounding Config — read/write for ~/.claude/sinapse-ai-config.yaml
3
- *
4
- * @story 10.47 — Generalize grounding semantico (BYO-vault/DS/brand)
5
- *
6
- * The shipped grounding hooks (vault / design-system / brand) read this
7
- * single YAML file as their source of truth. Absence of the file or
8
- * `enabled: false` in any section means the corresponding hook is a no-op
9
- * (no warnings, no errors — just silence).
10
- *
11
- * Schema versioned via top-level `version: "1"` so future migrations have
12
- * a clean upgrade path.
13
- */
14
-
15
- 'use strict';
16
-
17
- const fs = require('fs');
18
- const os = require('os');
19
- const path = require('path');
20
- const yaml = require('js-yaml');
21
-
22
- const CONFIG_DIR = path.join(os.homedir(), '.claude');
23
- const CONFIG_PATH = path.join(CONFIG_DIR, 'sinapse-ai-config.yaml');
24
-
25
- const SCHEMA_VERSION = '1';
26
-
27
- function defaultConfig() {
28
- return {
29
- version: SCHEMA_VERSION,
30
- grounding: {
31
- vault: { enabled: false, path: '', domains: [] },
32
- designSystem: { enabled: false, profileName: '', rootPath: '' },
33
- brand: { enabled: false, profileName: '', brandbookPath: '' },
34
- },
35
- };
36
- }
37
-
38
- function readGroundingConfig(configPath = CONFIG_PATH) {
39
- try {
40
- if (!fs.existsSync(configPath)) return null;
41
- const raw = fs.readFileSync(configPath, 'utf8');
42
- const parsed = yaml.load(raw);
43
- if (!parsed || typeof parsed !== 'object') return null;
44
- return parsed;
45
- } catch {
46
- return null;
47
- }
48
- }
49
-
50
- function writeGroundingConfig(config, configPath = CONFIG_PATH) {
51
- fs.mkdirSync(path.dirname(configPath), { recursive: true });
52
- const dump = yaml.dump(config, { lineWidth: 100, noRefs: true });
53
- const header =
54
- '# SINAPSE-AI grounding configuration (Story 10.47).\n' +
55
- '# Created by `npx sinapse-ai install`. Edit safely or re-run with --reconfigure.\n' +
56
- '# Empty / `enabled: false` sections = the matching shipped hook is a no-op.\n';
57
- fs.writeFileSync(configPath, header + dump);
58
- }
59
-
60
- /**
61
- * Build a grounding config from wizard answers. Empty answers leave the
62
- * section disabled. Non-empty paths flip `enabled: true` for that section.
63
- */
64
- function buildGroundingFromAnswers(answers = {}, existingConfig = null) {
65
- const base = existingConfig && existingConfig.grounding
66
- ? JSON.parse(JSON.stringify(existingConfig))
67
- : defaultConfig();
68
-
69
- base.version = SCHEMA_VERSION;
70
- base.grounding = base.grounding || defaultConfig().grounding;
71
-
72
- const vaultPath = (answers.vaultPath || '').trim();
73
- if (vaultPath) {
74
- base.grounding.vault = {
75
- enabled: true,
76
- path: vaultPath,
77
- domains: base.grounding.vault?.domains || [],
78
- };
79
- }
80
-
81
- const dsPath = (answers.designSystemPath || '').trim();
82
- if (dsPath) {
83
- base.grounding.designSystem = {
84
- enabled: true,
85
- profileName: base.grounding.designSystem?.profileName || '',
86
- rootPath: dsPath,
87
- };
88
- }
89
-
90
- const brandPath = (answers.brandbookPath || '').trim();
91
- if (brandPath) {
92
- base.grounding.brand = {
93
- enabled: true,
94
- profileName: base.grounding.brand?.profileName || '',
95
- brandbookPath: brandPath,
96
- };
97
- }
98
-
99
- return base;
100
- }
101
-
102
- /**
103
- * Determine which grounding sections should still be asked given a
104
- * pre-existing config (used in upsert mode without --reconfigure to avoid
105
- * double-prompts on already-configured sections).
106
- */
107
- function pendingGroundingSections(existingConfig) {
108
- const grounding = existingConfig?.grounding || {};
109
- return {
110
- askVault: !grounding.vault?.enabled,
111
- askDesignSystem: !grounding.designSystem?.enabled,
112
- askBrand: !grounding.brand?.enabled,
113
- };
114
- }
115
-
116
- function isGroundingEnabled(section, configPath = CONFIG_PATH) {
117
- const cfg = readGroundingConfig(configPath);
118
- return Boolean(cfg?.grounding?.[section]?.enabled);
119
- }
120
-
121
- module.exports = {
122
- CONFIG_DIR,
123
- CONFIG_PATH,
124
- SCHEMA_VERSION,
125
- defaultConfig,
126
- readGroundingConfig,
127
- writeGroundingConfig,
128
- buildGroundingFromAnswers,
129
- pendingGroundingSections,
130
- isGroundingEnabled,
131
- };