sinapse-ai 6.0.2 → 6.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.
- package/.sinapse-ai/data/entity-registry.yaml +748 -748
- package/.sinapse-ai/install-manifest.yaml +3 -3
- package/bin/cli.js +70 -9
- package/package.json +1 -1
|
@@ -7,8 +7,8 @@
|
|
|
7
7
|
# - SHA256 hashes for change detection
|
|
8
8
|
# - File types for categorization
|
|
9
9
|
#
|
|
10
|
-
version: 6.0.
|
|
11
|
-
generated_at: "2026-03-25T03:
|
|
10
|
+
version: 6.0.4
|
|
11
|
+
generated_at: "2026-03-25T03:58:08.458Z"
|
|
12
12
|
generator: scripts/generate-install-manifest.js
|
|
13
13
|
file_count: 1090
|
|
14
14
|
files:
|
|
@@ -1217,7 +1217,7 @@ files:
|
|
|
1217
1217
|
type: data
|
|
1218
1218
|
size: 9586
|
|
1219
1219
|
- path: data/entity-registry.yaml
|
|
1220
|
-
hash: sha256:
|
|
1220
|
+
hash: sha256:7f1a2807ae2e92c274773d9679b2326d48b1118e1fa2cd2c46eea40092bcab20
|
|
1221
1221
|
type: data
|
|
1222
1222
|
size: 519845
|
|
1223
1223
|
- path: data/learned-patterns.yaml
|
package/bin/cli.js
CHANGED
|
@@ -552,7 +552,7 @@ function verifyInstall() {
|
|
|
552
552
|
|
|
553
553
|
// ── Global Update ────────────────────────────────────────────────────────────
|
|
554
554
|
|
|
555
|
-
function cmdUpdateGlobal() {
|
|
555
|
+
async function cmdUpdateGlobal() {
|
|
556
556
|
header();
|
|
557
557
|
|
|
558
558
|
if (!fs.existsSync(path.join(SINAPSE_HOME, 'metadata.json'))) {
|
|
@@ -560,7 +560,31 @@ function cmdUpdateGlobal() {
|
|
|
560
560
|
process.exit(1);
|
|
561
561
|
}
|
|
562
562
|
|
|
563
|
-
|
|
563
|
+
// Welcome back screen
|
|
564
|
+
console.log(`${BOLD} Que bom que voce voltou!${NC}`);
|
|
565
|
+
console.log(`${DIM} Vamos atualizar seu SINAPSE AI para a v${VERSION}.${NC}`);
|
|
566
|
+
console.log('');
|
|
567
|
+
|
|
568
|
+
// LLM selection (re-choose on every update)
|
|
569
|
+
const readline = require('readline');
|
|
570
|
+
const rl = readline.createInterface({ input: process.stdin, output: process.stdout });
|
|
571
|
+
const llmChoice = await new Promise((resolve) => {
|
|
572
|
+
console.log(`${CYAN} Escolha sua LLM:${NC}`);
|
|
573
|
+
console.log(` ${GREEN}1${NC}) Claude Code ${DIM}(Recomendado)${NC}`);
|
|
574
|
+
console.log(` ${GREEN}2${NC}) Codex CLI`);
|
|
575
|
+
console.log(` ${GREEN}3${NC}) Ambos`);
|
|
576
|
+
console.log('');
|
|
577
|
+
rl.question(` ${BOLD}Opcao [1/2/3]:${NC} `, (answer) => {
|
|
578
|
+
rl.close();
|
|
579
|
+
const choice = (answer || '1').trim();
|
|
580
|
+
if (choice === '2') resolve('codex');
|
|
581
|
+
else if (choice === '3') resolve('both');
|
|
582
|
+
else resolve('claude-code');
|
|
583
|
+
});
|
|
584
|
+
});
|
|
585
|
+
|
|
586
|
+
console.log('');
|
|
587
|
+
console.log(`${BOLD}Atualizando SINAPSE AI...${NC}\n`);
|
|
564
588
|
|
|
565
589
|
const squadsDir = path.join(ROOT, 'squads');
|
|
566
590
|
const squadsSrcBase = fs.existsSync(squadsDir) ? squadsDir : ROOT;
|
|
@@ -602,7 +626,7 @@ function cmdUpdateGlobal() {
|
|
|
602
626
|
}
|
|
603
627
|
}
|
|
604
628
|
|
|
605
|
-
//
|
|
629
|
+
// Count total agents and generate orqx commands (skip if already copied from framework)
|
|
606
630
|
let totalAgents = 0;
|
|
607
631
|
for (const squad of squads) {
|
|
608
632
|
const agentsDir = path.join(SINAPSE_HOME, squad.name, 'agents');
|
|
@@ -611,18 +635,43 @@ function cmdUpdateGlobal() {
|
|
|
611
635
|
totalAgents += allAgents.length;
|
|
612
636
|
const orqxAgents = allAgents.filter(f => f.includes('-orqx'));
|
|
613
637
|
for (const file of orqxAgents) {
|
|
638
|
+
const destPath = path.join(CLAUDE_COMMANDS_DIR, file);
|
|
639
|
+
if (fs.existsSync(destPath)) continue; // skip if already from framework
|
|
614
640
|
const agentId = file.replace('.md', '');
|
|
615
641
|
const meta = extractAgentMeta(path.join(agentsDir, file));
|
|
616
642
|
const squadPath = `${sinapseBase}/${squad.name}`;
|
|
617
|
-
fs.writeFileSync(
|
|
618
|
-
path.join(CLAUDE_COMMANDS_DIR, `${agentId}.md`),
|
|
619
|
-
generateCommandMd(agentId, meta.name, meta.icon, squad.name, squadPath, file)
|
|
620
|
-
);
|
|
643
|
+
fs.writeFileSync(destPath, generateCommandMd(agentId, meta.name, meta.icon, squad.name, squadPath, file));
|
|
621
644
|
cmdCount++;
|
|
622
645
|
}
|
|
623
646
|
}
|
|
647
|
+
// Also count sinapse/ orqx agents
|
|
648
|
+
const sinapseAgentsDir = path.join(SINAPSE_HOME, 'sinapse', 'agents');
|
|
649
|
+
if (fs.existsSync(sinapseAgentsDir)) {
|
|
650
|
+
totalAgents += fs.readdirSync(sinapseAgentsDir).filter(f => f.endsWith('.md')).length;
|
|
651
|
+
}
|
|
624
652
|
console.log(` ${GREEN}OK${NC} ${cmdCount} command files (${totalAgents} agents total)`);
|
|
625
653
|
|
|
654
|
+
// Phase 2b: Install global agents based on LLM choice
|
|
655
|
+
if (llmChoice === 'claude-code' || llmChoice === 'both') {
|
|
656
|
+
const globalAgentsDir = path.join(HOME, '.claude', 'agents');
|
|
657
|
+
fs.mkdirSync(globalAgentsDir, { recursive: true });
|
|
658
|
+
// Copy orqx commands as global agents
|
|
659
|
+
for (const f of fs.readdirSync(CLAUDE_COMMANDS_DIR).filter(f => f.endsWith('.md'))) {
|
|
660
|
+
fs.copyFileSync(path.join(CLAUDE_COMMANDS_DIR, f), path.join(globalAgentsDir, f));
|
|
661
|
+
}
|
|
662
|
+
console.log(` ${GREEN}OK${NC} Claude Code global agents (${cmdCount})`);
|
|
663
|
+
}
|
|
664
|
+
|
|
665
|
+
if (llmChoice === 'codex' || llmChoice === 'both') {
|
|
666
|
+
const codexAgentsDir = path.join(HOME, '.codex', 'agents');
|
|
667
|
+
fs.mkdirSync(codexAgentsDir, { recursive: true });
|
|
668
|
+
// Generate orqx agents for Codex
|
|
669
|
+
for (const f of fs.readdirSync(CLAUDE_COMMANDS_DIR).filter(f => f.endsWith('.md'))) {
|
|
670
|
+
fs.copyFileSync(path.join(CLAUDE_COMMANDS_DIR, f), path.join(codexAgentsDir, f));
|
|
671
|
+
}
|
|
672
|
+
console.log(` ${GREEN}OK${NC} Codex global agents (${cmdCount})`);
|
|
673
|
+
}
|
|
674
|
+
|
|
626
675
|
// Phase 3: Regenerate awareness
|
|
627
676
|
console.log(`\n${CYAN}Phase 3:${NC} Updating squad-awareness`);
|
|
628
677
|
generateSquadAwareness(SINAPSE_HOME, squads);
|
|
@@ -636,7 +685,19 @@ function cmdUpdateGlobal() {
|
|
|
636
685
|
meta.commands = cmdCount;
|
|
637
686
|
fs.writeFileSync(metaPath, JSON.stringify(meta, null, 2));
|
|
638
687
|
|
|
639
|
-
|
|
688
|
+
let startCmd;
|
|
689
|
+
if (llmChoice === 'codex') startCmd = `Digite ${CYAN}codex${NC} para comecar`;
|
|
690
|
+
else if (llmChoice === 'both') startCmd = `Digite ${CYAN}sinapse${NC} ou ${CYAN}codex${NC} para comecar`;
|
|
691
|
+
else startCmd = `Digite ${CYAN}sinapse${NC} para comecar`;
|
|
692
|
+
|
|
693
|
+
console.log('');
|
|
694
|
+
console.log(`${GREEN}══════════════════════════════════════════════════════════════${NC}`);
|
|
695
|
+
console.log(`${GREEN} SINAPSE AI atualizado para v${VERSION}!${NC}`);
|
|
696
|
+
console.log(`${GREEN}══════════════════════════════════════════════════════════════${NC}`);
|
|
697
|
+
console.log('');
|
|
698
|
+
console.log(` ${BOLD}${squads.length} squads${NC} | ${BOLD}${totalAgents} agents${NC} | ${BOLD}${cmdCount} orqx commands${NC}`);
|
|
699
|
+
console.log(` ${startCmd}`);
|
|
700
|
+
console.log('');
|
|
640
701
|
}
|
|
641
702
|
|
|
642
703
|
// ── Uninstall ────────────────────────────────────────────────────────────────
|
|
@@ -798,7 +859,7 @@ const isLocal = args.includes('--local');
|
|
|
798
859
|
|
|
799
860
|
switch (command) {
|
|
800
861
|
case 'install': isLocal ? cmdInstallLocal() : cmdInstallGlobal(); break;
|
|
801
|
-
case 'update': isLocal ? cmdUpdateLocal() : cmdUpdateGlobal(); break;
|
|
862
|
+
case 'update': isLocal ? cmdUpdateLocal() : cmdUpdateGlobal().catch(e => { console.error(e.message); process.exit(1); }); break;
|
|
802
863
|
case 'uninstall': cmdUninstall(); break;
|
|
803
864
|
case 'list': cmdList(); break;
|
|
804
865
|
case 'status': cmdStatus(); break;
|