claude-flow 3.7.0-alpha.31 → 3.7.0-alpha.32
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/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "claude-flow",
|
|
3
|
-
"version": "3.7.0-alpha.
|
|
3
|
+
"version": "3.7.0-alpha.32",
|
|
4
4
|
"description": "Ruflo - Enterprise AI agent orchestration for Claude Code. Deploy 60+ specialized agents in coordinated swarms with self-learning, fault-tolerant consensus, vector memory, and MCP integration",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"type": "module",
|
|
@@ -480,14 +480,14 @@ const indexCommand = {
|
|
|
480
480
|
description: 'Manage HNSW indexes',
|
|
481
481
|
options: [
|
|
482
482
|
{ name: 'action', short: 'a', type: 'string', description: 'Action: build, rebuild, status, optimize', default: 'status' },
|
|
483
|
-
{ name: 'collection', short: 'c', type: 'string', description: 'Collection/namespace
|
|
483
|
+
{ name: 'collection', short: 'c', type: 'string', description: 'Collection/namespace label (informational; HNSW is a single global index across all namespaces). Omit to build for all namespaces (#1947 RC2).' },
|
|
484
484
|
{ name: 'ef-construction', type: 'number', description: 'HNSW ef_construction parameter', default: '200' },
|
|
485
485
|
{ name: 'm', type: 'number', description: 'HNSW M parameter', default: '16' },
|
|
486
486
|
],
|
|
487
487
|
examples: [
|
|
488
488
|
{ command: 'claude-flow embeddings index', description: 'Show index status' },
|
|
489
|
-
{ command: 'claude-flow embeddings index -a build
|
|
490
|
-
{ command: 'claude-flow embeddings index -a
|
|
489
|
+
{ command: 'claude-flow embeddings index -a build', description: 'Build index from all namespaces' },
|
|
490
|
+
{ command: 'claude-flow embeddings index -a rebuild -c project', description: 'Rebuild (label as `project`)' },
|
|
491
491
|
],
|
|
492
492
|
action: async (ctx) => {
|
|
493
493
|
const action = ctx.flags.action || 'status';
|
|
@@ -565,11 +565,15 @@ const indexCommand = {
|
|
|
565
565
|
}
|
|
566
566
|
// Build/Rebuild action
|
|
567
567
|
if (action === 'build' || action === 'rebuild') {
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
|
|
568
|
+
// #1947 RC #2: `-c` is informational — the HNSW index is global
|
|
569
|
+
// and indexes every namespace's embeddings in one structure. The
|
|
570
|
+
// earlier code REQUIRED `-c` for build/rebuild AND its examples
|
|
571
|
+
// suggested `-c default`, which silently produced 0 vectors when a
|
|
572
|
+
// user's entries lived under a different namespace (e.g. `project`,
|
|
573
|
+
// `claude-memories`). Treat omitted `-c` as "all namespaces"
|
|
574
|
+
// (the actual runtime behavior) and tell the user as much.
|
|
575
|
+
const label = collection ?? '(all namespaces)';
|
|
576
|
+
const spinner = output.createSpinner({ text: `${action}ing index for ${label}...`, spinner: 'dots' });
|
|
573
577
|
spinner.start();
|
|
574
578
|
// Force rebuild if requested
|
|
575
579
|
const index = await getHNSWIndex({ forceRebuild: action === 'rebuild' });
|
|
@@ -582,13 +586,18 @@ const indexCommand = {
|
|
|
582
586
|
const newStatus = getHNSWStatus();
|
|
583
587
|
output.writeln();
|
|
584
588
|
output.printBox([
|
|
585
|
-
`Collection: ${
|
|
589
|
+
`Collection: ${label}`,
|
|
586
590
|
`Action: ${action}`,
|
|
587
591
|
`Vectors: ${newStatus.entryCount}`,
|
|
588
592
|
`Dimensions: ${newStatus.dimensions}`,
|
|
589
593
|
`M: ${m}`,
|
|
590
594
|
`ef_construction: ${efConstruction}`,
|
|
591
595
|
].join('\n'), 'Index Built');
|
|
596
|
+
if (!collection && newStatus.entryCount === 0) {
|
|
597
|
+
output.writeln();
|
|
598
|
+
output.printInfo('No vectors indexed. Store some entries first:');
|
|
599
|
+
output.printInfo(' claude-flow memory store -k "key" --value "text" --namespace <ns>');
|
|
600
|
+
}
|
|
592
601
|
return { success: true, data: newStatus };
|
|
593
602
|
}
|
|
594
603
|
// Optimize action
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@claude-flow/cli",
|
|
3
|
-
"version": "3.7.0-alpha.
|
|
3
|
+
"version": "3.7.0-alpha.32",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Ruflo CLI - Enterprise AI agent orchestration with 60+ specialized agents, swarm coordination, MCP server, self-learning hooks, and vector memory for Claude Code",
|
|
6
6
|
"main": "dist/src/index.js",
|