claude-flow-novice 2.18.40 → 2.19.1
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/.claude/agents/AGENT_LIFECYCLE.md +1 -1
- package/.claude/agents/SHARED_PROTOCOL.md +33 -5
- package/.claude/agents/cfn-dev-team/analysts/analyst.md +4 -4
- package/.claude/agents/cfn-dev-team/analysts/root-cause-analyst.md +4 -4
- package/.claude/agents/cfn-dev-team/architecture/api-designer-persona.md +4 -4
- package/.claude/agents/cfn-dev-team/architecture/base-template-generator.md +4 -4
- package/.claude/agents/cfn-dev-team/architecture/goal-planner.md +4 -4
- package/.claude/agents/cfn-dev-team/architecture/system-architect.md +4 -4
- package/.claude/agents/cfn-dev-team/coordinators/cfn-frontend-coordinator.md +4 -4
- package/.claude/agents/cfn-dev-team/coordinators/handoff-coordinator.md +4 -4
- package/.claude/agents/cfn-dev-team/dev-ops/devops-engineer.md +4 -4
- package/.claude/agents/cfn-dev-team/dev-ops/docker-specialist.md +4 -4
- package/.claude/agents/cfn-dev-team/dev-ops/fly-io-specialist.md +418 -0
- package/.claude/agents/cfn-dev-team/dev-ops/github-commit-agent.md +4 -4
- package/.claude/agents/cfn-dev-team/developers/api-gateway-specialist.md +4 -4
- package/.claude/agents/cfn-dev-team/developers/backend-developer.md +4 -4
- package/.claude/agents/cfn-dev-team/developers/data/data-engineer.md +4 -4
- package/.claude/agents/cfn-dev-team/developers/database/database-architect.md +4 -4
- package/.claude/agents/cfn-dev-team/developers/database/mem0-specialist.md +579 -0
- package/.claude/agents/cfn-dev-team/developers/database/memgraph-specialist.md +722 -0
- package/.claude/agents/cfn-dev-team/developers/database/supabase-specialist.md +4 -4
- package/.claude/agents/cfn-dev-team/developers/frontend/mobile-dev.md +4 -4
- package/.claude/agents/cfn-dev-team/developers/frontend/react-frontend-engineer.md +4 -4
- package/.claude/agents/cfn-dev-team/developers/frontend/typescript-specialist.md +4 -4
- package/.claude/agents/cfn-dev-team/developers/frontend/ui-designer.md +4 -4
- package/.claude/agents/cfn-dev-team/developers/graphql-specialist.md +4 -4
- package/.claude/agents/cfn-dev-team/developers/rust-developer.md +4 -4
- package/.claude/agents/cfn-dev-team/documentation/agent-type-guidelines.md +4 -4
- package/.claude/agents/cfn-dev-team/documentation/api-documentation.md +4 -4
- package/.claude/agents/cfn-dev-team/documentation/pseudocode.md +5 -5
- package/.claude/agents/cfn-dev-team/documentation/specification-agent.md +5 -5
- package/.claude/agents/cfn-dev-team/product-owners/accessibility-advocate-persona.md +4 -4
- package/.claude/agents/cfn-dev-team/product-owners/cto-agent.md +4 -4
- package/.claude/agents/cfn-dev-team/product-owners/power-user-persona.md +4 -4
- package/.claude/agents/cfn-dev-team/product-owners/product-owner.md +4 -4
- package/.claude/agents/cfn-dev-team/reviewers/code-reviewer.md +4 -4
- package/.claude/agents/cfn-dev-team/reviewers/quality/code-quality-validator.md +4 -4
- package/.claude/agents/cfn-dev-team/reviewers/quality/cyclomatic-complexity-reducer.md +4 -4
- package/.claude/agents/cfn-dev-team/reviewers/quality/perf-analyzer.md +4 -4
- package/.claude/agents/cfn-dev-team/reviewers/quality/performance-benchmarker.md +4 -4
- package/.claude/agents/cfn-dev-team/reviewers/quality/quality-metrics.md +4 -4
- package/.claude/agents/cfn-dev-team/testers/api-testing-specialist.md +4 -4
- package/.claude/agents/cfn-dev-team/testers/chaos-engineering-specialist.md +4 -4
- package/.claude/agents/cfn-dev-team/testers/contract-tester.md +4 -4
- package/.claude/agents/cfn-dev-team/testers/e2e/playwright-tester.md +4 -4
- package/.claude/agents/cfn-dev-team/testers/integration-tester.md +4 -4
- package/.claude/agents/cfn-dev-team/testers/interaction-tester.md +4 -4
- package/.claude/agents/cfn-dev-team/testers/load-testing-specialist.md +4 -4
- package/.claude/agents/cfn-dev-team/testers/mutation-testing-specialist.md +4 -4
- package/.claude/agents/cfn-dev-team/testers/playwright-tester.md +4 -4
- package/.claude/agents/cfn-dev-team/{testing → testers}/test-validation-agent.md +4 -4
- package/.claude/agents/cfn-dev-team/testers/tester.md +39 -4
- package/.claude/agents/cfn-dev-team/testers/unit/tdd-london-unit-swarm.md +4 -4
- package/.claude/agents/cfn-dev-team/testers/validation/validation-production-validator.md +4 -4
- package/.claude/agents/cfn-dev-team/utility/agent-builder.md +7 -7
- package/.claude/agents/cfn-dev-team/utility/memory-leak-specialist.md +4 -4
- package/.claude/agents/cfn-dev-team/utility/researcher.md +4 -4
- package/.claude/agents/cfn-dev-team/utility/z-ai-specialist.md +4 -4
- package/.claude/agents/custom/claude-code-expert.md +1 -1
- package/.claude/agents/project-only-agents/npm-package-specialist.md +1 -1
- package/.claude/{agents/cfn-dev-team/utility → cfn-extras/agents}/context-curator.md +4 -4
- package/.claude/{agents/custom → cfn-extras/agents/custom-agents}/cfn-docker-expert.md +4 -4
- package/.claude/{agents/custom → cfn-extras/agents/custom-agents}/cfn-redis-operations.md +1 -1
- package/.claude/{agents/custom → cfn-extras/agents/custom-agents}/cfn-system-expert.md +4 -4
- package/.claude/{agents/custom → cfn-extras/agents/custom-agents}/trigger-dev-expert.md +4 -4
- package/.claude/{agents/cfn-dev-team/coordinators → cfn-extras/agents/deprecated-coordinators}/consensus-builder.md +4 -4
- package/.claude/{agents/cfn-dev-team/coordinators → cfn-extras/agents/deprecated-coordinators}/multi-sprint-coordinator.md +4 -4
- package/.claude/{agents → cfn-extras/agents/docker-team}/docker-coordinators/cfn-docker-v3-coordinator.md +1 -1
- package/.claude/{agents/cfn-dev-team/dev-ops → cfn-extras/agents}/kubernetes-specialist.md +4 -4
- package/.claude/{agents/cfn-dev-team/architecture → cfn-extras/agents}/planner.md +4 -4
- package/.claude/cfn-extras/skills/cfn-cerebras-coordinator/QUICKSTART.md +1 -1
- package/.claude/cfn-extras/skills/cfn-cerebras-coordinator/README.md +19 -19
- package/.claude/cfn-extras/skills/cfn-cerebras-coordinator/SKILL.md +7 -7
- package/.claude/cfn-extras/skills/cfn-cerebras-coordinator/TDD_COORDINATOR_OVERVIEW.md +3 -3
- package/.claude/cfn-extras/skills/cfn-cerebras-coordinator/TEST_RESULTS.md +3 -3
- package/.claude/cfn-extras/skills/cfn-cerebras-coordinator/coordinate-generation.sh +19 -19
- package/.claude/cfn-extras/skills/cfn-cerebras-coordinator/example-fix-scenario.md +4 -4
- package/.claude/cfn-extras/skills/cfn-cerebras-coordinator/example-usage.sh +1 -1
- package/.claude/cfn-extras/skills/cfn-cerebras-coordinator/feedback-logger.sh +5 -5
- package/.claude/cfn-extras/skills/cfn-cerebras-coordinator/fix-existing-code-v2.sh +2 -2
- package/.claude/cfn-extras/skills/cfn-cerebras-coordinator/fix-existing-code.sh +10 -10
- package/.claude/cfn-extras/skills/cfn-cerebras-coordinator/pattern-examples.md +3 -3
- package/.claude/cfn-extras/skills/cfn-cerebras-coordinator/query-patterns.sh +9 -9
- package/.claude/cfn-extras/skills/cfn-cerebras-coordinator/tdd-coordinator.sh +8 -8
- package/.claude/cfn-extras/skills/cfn-cerebras-coordinator/test-tdd-coordinator.sh +1 -1
- package/.claude/commands/README.md +1 -1
- package/.claude/commands/{cfn-ruvector → cfn-codesearch}/cfn-codebase-reindex.md +6 -6
- package/.claude/commands/{cfn-ruvector → cfn-codesearch}/cfn-codebase-search.md +8 -8
- package/.claude/commands/{cfn-ruvector → cfn-codesearch}/cfn-detect-stale-docs.md +3 -3
- package/.claude/commands/cfn-codesearch-search.md +36 -0
- package/.claude/commands/cfn-fix-errors.md +1 -1
- package/.claude/commands/cfn-loop-task.md +66 -2
- package/.claude/commands/cfn-update-search-index.md +2 -2
- package/.claude/hooks/cfn-SessionStart-cfn-build-codesearch.sh +24 -0
- package/.claude/hooks/cfn-bash-search-hook.sh +6 -6
- package/.claude/hooks/cfn-smart-search-hook.sh +15 -15
- package/.claude/hooks/cfn-subagent-stop.sh +9 -9
- package/.claude/hooks/post-commit-codebase-index +14 -14
- package/.claude/skills/{bulk-add-ruvector-instructions.sh → bulk-add-codesearch-instructions.sh} +14 -14
- package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/AGENT_INTEGRATION_PATTERNS.md +20 -20
- package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/AGENT_LIFECYCLE_INTEGRATION.md +12 -12
- package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/Cargo.toml +9 -4
- package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/EXTRACTION_EXAMPLES.md +6 -6
- package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/IMMEDIATE_ACTION_REQUIRED.md +9 -9
- package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/README.md +7 -7
- package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/SCHEMA_V2_IMPLEMENTATION.md +1 -1
- package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/SECURITY_FINDINGS_SUMMARY.txt +1 -1
- package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/SECURITY_IMPLEMENTATION.md +3 -3
- package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/SECURITY_TESTING_COMPLETION.md +5 -5
- package/.claude/skills/cfn-codesearch/SKILL.md +143 -0
- package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/analyze-agent-failures.sh +11 -11
- package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/cfn-integration.sh +29 -29
- package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/docs/EXECUTIVE_SUMMARY.txt +1 -1
- package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/docs/PHASE_4_QUERY_API.md +24 -24
- package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/docs/RUST_AST_EXTRACTOR_IMPLEMENTATION.md +7 -7
- package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/docs/TRANSACTION_MANAGEMENT.md +1 -1
- package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/docs/VALIDATION_FINDINGS.txt +1 -1
- package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/epic-ast-indexer.json +8 -8
- package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/index-code.sh +11 -11
- package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/index_all.sh +2 -2
- package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/ingest-agent-transcript.sh +10 -10
- package/.claude/skills/{cfn-local-ruvector-accelerator/init-local-ruvector.sh → cfn-codesearch/init-local-codesearch.sh} +16 -16
- package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/project-structure.md +10 -10
- package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/query-local.sh +6 -6
- package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/src/cli/cleanup.rs +1 -1
- package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/src/cli/index.rs +238 -9
- package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/src/cli/index_ast.rs +3 -3
- package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/src/cli/init.rs +19 -19
- package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/src/cli/migration.rs +5 -5
- package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/src/cli/query.rs +64 -3
- package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/src/cli/reset.rs +5 -5
- package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/src/embeddings.rs +19 -5
- package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/src/lib.rs +6 -4
- package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/src/main.rs +37 -27
- package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/src/migration_v2.rs +1 -1
- package/.claude/skills/cfn-codesearch/src/paths.rs +37 -0
- package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/src/query_v2.rs +3 -4
- package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/src/search_engine.rs +3 -3
- package/.claude/skills/cfn-codesearch/src/store_pgvector.rs +301 -0
- package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/src/store_v2.rs +12 -1
- package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/test-agent-lifecycle-integration.sh +6 -6
- package/.claude/skills/{cfn-local-ruvector-accelerator/test-local-ruvector.sh → cfn-codesearch/test-local-codesearch.sh} +7 -7
- package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/test_query_api.sh +2 -2
- package/.claude/skills/cfn-epic-creator/SKILL.md +110 -2
- package/.claude/skills/cfn-epic-creator/invoke.sh +120 -1
- package/.claude/skills/cfn-knowledge-base/lib/playbook/SKILL.md +1 -1
- package/.claude/skills/cfn-mdap-context-injection/SKILL.md +2 -2
- package/.claude/skills/cfn-mdap-context-injection/inject.sh +23 -23
- package/CLAUDE.md +3 -3
- package/package.json +11 -11
- package/readme/feature-status.md +411 -0
- package/.claude/agents/docker-ts-fixer.md +0 -65
- package/.claude/commands/cfn-ruvector-search.md +0 -36
- package/.claude/hooks/cfn-SessionStart-cfn-build-ruvector.sh +0 -24
- package/.claude/skills/cfn-local-ruvector-accelerator/.claude/hooks/SessionStart-cfn-build-ruvector.sh +0 -13
- package/.claude/skills/cfn-local-ruvector-accelerator/SKILL.md +0 -143
- package/.claude/skills/cfn-local-ruvector-accelerator/src/paths.rs +0 -31
- /package/.claude/{agents/custom → cfn-extras/agents/custom-agents}/cfn-loops-cli-expert.md +0 -0
- /package/.claude/{agents/csuite → cfn-extras/agents/custom-agents}/cto-agent.md +0 -0
- /package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/Cargo.toml.backup +0 -0
- /package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/embeddings_manager.py.backup +0 -0
- /package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/index/index.bin +0 -0
- /package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/index/metadata.json +0 -0
- /package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/index-code.sh.backup +0 -0
- /package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/query-agent-patterns.sh +0 -0
- /package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/requirements.txt +0 -0
- /package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/search_engine_v2.py.backup +0 -0
- /package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/sqlite_store.py.backup +0 -0
- /package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/src/cli/export.rs +0 -0
- /package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/src/cli/find.rs +0 -0
- /package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/src/cli/index_modified.rs +0 -0
- /package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/src/cli/mod.rs +0 -0
- /package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/src/cli/refs.rs +0 -0
- /package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/src/cli/stats.rs +0 -0
- /package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/src/extractors/mod.rs +0 -0
- /package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/src/extractors/rust.rs +0 -0
- /package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/src/extractors/rust_placeholder.rs +0 -0
- /package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/src/extractors/text_fallback.rs +0 -0
- /package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/src/extractors/typescript.rs +0 -0
- /package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/src/extractors/typescript_full.rs +0 -0
- /package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/src/main.rs.backup +0 -0
- /package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/src/migration.rs +0 -0
- /package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/src/migration_backup.rs +0 -0
- /package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/src/migration_tx.rs +0 -0
- /package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/src/path_validator.rs +0 -0
- /package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/src/query_api.rs +0 -0
- /package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/src/schema_v2.rs +0 -0
- /package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/src/security_tests.rs +0 -0
- /package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/src/sqlite_store.rs +0 -0
- /package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/src/store_v2_backup.rs +0 -0
- /package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/src/store_v2_fixed.rs +0 -0
- /package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/src/store_v2_tx.rs +0 -0
- /package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/src/test_schema.rs +0 -0
- /package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/src/transaction_tests.rs +0 -0
- /package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/test_ast_indexing.rs +0 -0
- /package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/test_schema.sql +0 -0
- /package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/test_schema_v2.sql +0 -0
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/bin/bash
|
|
2
|
-
# CFN Integration Script for Local
|
|
2
|
+
# CFN Integration Script for Local CodeSearch Accelerator
|
|
3
3
|
# Works for both source repo and npm-installed packages
|
|
4
4
|
|
|
5
5
|
set -e
|
|
@@ -33,20 +33,20 @@ log_error() {
|
|
|
33
33
|
# Find binary - check multiple locations
|
|
34
34
|
find_binary() {
|
|
35
35
|
# 1. Check if in PATH
|
|
36
|
-
if command -v local-
|
|
37
|
-
echo "$(command -v local-
|
|
36
|
+
if command -v local-codesearch &> /dev/null; then
|
|
37
|
+
echo "$(command -v local-codesearch)"
|
|
38
38
|
return 0
|
|
39
39
|
fi
|
|
40
40
|
|
|
41
41
|
# 2. Check ~/.local/bin
|
|
42
|
-
if [[ -x "$HOME/.local/bin/local-
|
|
43
|
-
echo "$HOME/.local/bin/local-
|
|
42
|
+
if [[ -x "$HOME/.local/bin/local-codesearch" ]]; then
|
|
43
|
+
echo "$HOME/.local/bin/local-codesearch"
|
|
44
44
|
return 0
|
|
45
45
|
fi
|
|
46
46
|
|
|
47
47
|
# 3. Check local target directory (source repo)
|
|
48
|
-
if [[ -x "$SCRIPT_DIR/target/release/local-
|
|
49
|
-
echo "$SCRIPT_DIR/target/release/local-
|
|
48
|
+
if [[ -x "$SCRIPT_DIR/target/release/local-codesearch" ]]; then
|
|
49
|
+
echo "$SCRIPT_DIR/target/release/local-codesearch"
|
|
50
50
|
return 0
|
|
51
51
|
fi
|
|
52
52
|
|
|
@@ -58,23 +58,23 @@ BINARY_PATH=""
|
|
|
58
58
|
if ! BINARY_PATH=$(find_binary); then
|
|
59
59
|
# Try to build if Rust is available
|
|
60
60
|
if command -v cargo &> /dev/null && [[ -f "$SCRIPT_DIR/Cargo.toml" ]]; then
|
|
61
|
-
log_info "Building Local
|
|
61
|
+
log_info "Building Local CodeSearch..."
|
|
62
62
|
cd "$SCRIPT_DIR"
|
|
63
63
|
cargo build --release
|
|
64
|
-
BINARY_PATH="$SCRIPT_DIR/target/release/local-
|
|
64
|
+
BINARY_PATH="$SCRIPT_DIR/target/release/local-codesearch"
|
|
65
65
|
|
|
66
66
|
# Install to ~/.local/bin for future use
|
|
67
67
|
if [[ -n "$HOME" ]]; then
|
|
68
68
|
mkdir -p "$HOME/.local/bin"
|
|
69
|
-
cp "$BINARY_PATH" "$HOME/.local/bin/local-
|
|
70
|
-
chmod +x "$HOME/.local/bin/local-
|
|
71
|
-
log_success "Installed local-
|
|
69
|
+
cp "$BINARY_PATH" "$HOME/.local/bin/local-codesearch"
|
|
70
|
+
chmod +x "$HOME/.local/bin/local-codesearch"
|
|
71
|
+
log_success "Installed local-codesearch to ~/.local/bin/"
|
|
72
72
|
fi
|
|
73
73
|
log_success "Build complete"
|
|
74
74
|
else
|
|
75
|
-
log_error "local-
|
|
75
|
+
log_error "local-codesearch binary not found and cannot build (Rust not available)"
|
|
76
76
|
log_info "Install Rust: curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh"
|
|
77
|
-
log_info "Then run: npm run
|
|
77
|
+
log_info "Then run: npm run codesearch:local:build"
|
|
78
78
|
exit 1
|
|
79
79
|
fi
|
|
80
80
|
fi
|
|
@@ -82,9 +82,9 @@ fi
|
|
|
82
82
|
# CFN integration commands
|
|
83
83
|
cfn_init() {
|
|
84
84
|
local project_dir="${1:-.}"
|
|
85
|
-
log_info "Initializing Local
|
|
85
|
+
log_info "Initializing Local CodeSearch for CFN in: $project_dir"
|
|
86
86
|
"$BINARY_PATH" --project-dir "$project_dir" init
|
|
87
|
-
log_success "CFN Local
|
|
87
|
+
log_success "CFN Local CodeSearch initialized"
|
|
88
88
|
}
|
|
89
89
|
|
|
90
90
|
cfn_index() {
|
|
@@ -112,7 +112,7 @@ cfn_query() {
|
|
|
112
112
|
|
|
113
113
|
cfn_stats() {
|
|
114
114
|
local project_dir="${1:-.}"
|
|
115
|
-
log_info "CFN Local
|
|
115
|
+
log_info "CFN Local CodeSearch statistics for: $project_dir"
|
|
116
116
|
"$BINARY_PATH" --project-dir "$project_dir" stats --detailed
|
|
117
117
|
}
|
|
118
118
|
|
|
@@ -152,12 +152,12 @@ cfn_coordinate_generation() {
|
|
|
152
152
|
# Show usage
|
|
153
153
|
show_usage() {
|
|
154
154
|
cat << 'EOF'
|
|
155
|
-
CFN Local
|
|
155
|
+
CFN Local CodeSearch Integration
|
|
156
156
|
|
|
157
|
-
Usage: cfn-local-
|
|
157
|
+
Usage: cfn-local-codesearch <COMMAND> [OPTIONS]
|
|
158
158
|
|
|
159
159
|
Commands:
|
|
160
|
-
init [DIR] Initialize Local
|
|
160
|
+
init [DIR] Initialize Local CodeSearch in project directory
|
|
161
161
|
index [DIR] [TYPES] Index code files (default types: rs,py,js,ts)
|
|
162
162
|
query DIR PATTERN [N] Query for patterns (default limit: 10)
|
|
163
163
|
stats [DIR] Show detailed statistics
|
|
@@ -165,29 +165,29 @@ Commands:
|
|
|
165
165
|
|
|
166
166
|
Examples:
|
|
167
167
|
# Initialize in current project
|
|
168
|
-
cfn-local-
|
|
168
|
+
cfn-local-codesearch init
|
|
169
169
|
|
|
170
170
|
# Initialize specific project
|
|
171
|
-
cfn-local-
|
|
171
|
+
cfn-local-codesearch init /path/to/project
|
|
172
172
|
|
|
173
173
|
# Index all code types
|
|
174
|
-
cfn-local-
|
|
174
|
+
cfn-local-codesearch index
|
|
175
175
|
|
|
176
176
|
# Index only Rust files
|
|
177
|
-
cfn-local-
|
|
177
|
+
cfn-local-codesearch index . rs
|
|
178
178
|
|
|
179
179
|
# Query for patterns
|
|
180
|
-
cfn-local-
|
|
180
|
+
cfn-local-codesearch query . "authentication middleware"
|
|
181
181
|
|
|
182
182
|
# Get statistics
|
|
183
|
-
cfn-local-
|
|
183
|
+
cfn-local-codesearch stats
|
|
184
184
|
|
|
185
185
|
# Coordinate generation (used by CFN agents)
|
|
186
|
-
cfn-local-
|
|
186
|
+
cfn-local-codesearch coordinate agent-123 src/auth.rs "create auth middleware"
|
|
187
187
|
|
|
188
188
|
Environment Variables:
|
|
189
|
-
|
|
190
|
-
|
|
189
|
+
CODESEARCH_VERBOSE=1 Enable verbose logging
|
|
190
|
+
CODESEARCH_PROJECT_DIR Override project directory
|
|
191
191
|
|
|
192
192
|
EOF
|
|
193
193
|
}
|
package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/docs/PHASE_4_QUERY_API.md
RENAMED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
## Overview
|
|
4
4
|
|
|
5
|
-
Phase 4 of the AST-Aware
|
|
5
|
+
Phase 4 of the AST-Aware CodeSearch Accelerator implements a high-level query interface for agent use cases, replacing complex grep patterns with structured SQL queries. The implementation provides fast (<50ms) queries on 10k+ entity indexes with support for both Rust and TypeScript codebases.
|
|
6
6
|
|
|
7
7
|
## Features Implemented
|
|
8
8
|
|
|
@@ -19,55 +19,55 @@ The QueryApi struct provides six core query methods:
|
|
|
19
19
|
|
|
20
20
|
### 2. CLI Commands
|
|
21
21
|
|
|
22
|
-
#### `
|
|
22
|
+
#### `codesearch find` Command
|
|
23
23
|
Structured search with multiple filter options:
|
|
24
24
|
|
|
25
25
|
```bash
|
|
26
26
|
# Find functions using a type
|
|
27
|
-
|
|
27
|
+
codesearch find --uses-type Album
|
|
28
28
|
|
|
29
29
|
# Find callers of a function, excluding certain module
|
|
30
|
-
|
|
30
|
+
codesearch find --called-by create_album --exclude tests
|
|
31
31
|
|
|
32
32
|
# Find types from a file used elsewhere
|
|
33
|
-
|
|
33
|
+
codesearch find --types-from src/models.rs
|
|
34
34
|
|
|
35
35
|
# Find implementations of a trait
|
|
36
|
-
|
|
36
|
+
codesearch find --implements Display
|
|
37
37
|
|
|
38
38
|
# Find public API of a module
|
|
39
|
-
|
|
39
|
+
codesearch find --public-api auth
|
|
40
40
|
|
|
41
41
|
# Filter by entity kind
|
|
42
|
-
|
|
42
|
+
codesearch find --uses-type String --kind function
|
|
43
43
|
|
|
44
44
|
# Output in different formats
|
|
45
|
-
|
|
46
|
-
|
|
45
|
+
codesearch find --uses-type Album --format json
|
|
46
|
+
codesearch find --uses-type Album --format csv --output results.csv
|
|
47
47
|
```
|
|
48
48
|
|
|
49
|
-
#### `
|
|
49
|
+
#### `codesearch refs` Command
|
|
50
50
|
Find all references to an entity:
|
|
51
51
|
|
|
52
52
|
```bash
|
|
53
53
|
# Simple reference search
|
|
54
|
-
|
|
54
|
+
codesearch refs create_album
|
|
55
55
|
|
|
56
56
|
# With specific entity kind
|
|
57
|
-
|
|
57
|
+
codesearch refs Album --kind struct
|
|
58
58
|
|
|
59
59
|
# Group results by file
|
|
60
|
-
|
|
60
|
+
codesearch refs Album --group-by-file
|
|
61
61
|
|
|
62
62
|
# Tree format for visual hierarchy
|
|
63
|
-
|
|
63
|
+
codesearch refs Album --format tree
|
|
64
64
|
|
|
65
65
|
# Filter to specific file
|
|
66
|
-
|
|
66
|
+
codesearch refs Album --file src/main.rs
|
|
67
67
|
|
|
68
68
|
# Inbound/outbound reference filtering
|
|
69
|
-
|
|
70
|
-
|
|
69
|
+
codesearch refs create_album --inbound
|
|
70
|
+
codesearch refs create_album --outbound
|
|
71
71
|
```
|
|
72
72
|
|
|
73
73
|
### 3. Performance Optimizations
|
|
@@ -113,10 +113,10 @@ The references query enables safe refactoring:
|
|
|
113
113
|
|
|
114
114
|
```bash
|
|
115
115
|
# Before renaming a function
|
|
116
|
-
|
|
116
|
+
codesearch refs old_function_name --format tree
|
|
117
117
|
|
|
118
118
|
# Check all uses of a type before major changes
|
|
119
|
-
|
|
119
|
+
codesearch find --uses-type MyStruct --format detailed
|
|
120
120
|
```
|
|
121
121
|
|
|
122
122
|
### Code Analysis
|
|
@@ -125,10 +125,10 @@ Understand codebase structure and dependencies:
|
|
|
125
125
|
|
|
126
126
|
```bash
|
|
127
127
|
# Public API surface
|
|
128
|
-
|
|
128
|
+
codesearch find --public-api . --format json
|
|
129
129
|
|
|
130
130
|
# Type usage statistics
|
|
131
|
-
|
|
131
|
+
codesearch find --types-from src/lib.rs --format detailed
|
|
132
132
|
```
|
|
133
133
|
|
|
134
134
|
## Database Schema
|
|
@@ -198,7 +198,7 @@ The query API is designed to work seamlessly with CFN agents:
|
|
|
198
198
|
### Common Issues
|
|
199
199
|
|
|
200
200
|
1. **Slow queries**: Check database indexes with `EXPLAIN QUERY PLAN`
|
|
201
|
-
2. **No results**: Verify entities are indexed with `
|
|
201
|
+
2. **No results**: Verify entities are indexed with `codesearch stats`
|
|
202
202
|
3. **JSON errors**: Ensure entity names are properly quoted
|
|
203
203
|
|
|
204
204
|
### Debug Queries
|
|
@@ -206,5 +206,5 @@ The query API is designed to work seamlessly with CFN agents:
|
|
|
206
206
|
Enable debug logging to see actual SQL queries:
|
|
207
207
|
|
|
208
208
|
```bash
|
|
209
|
-
RUST_LOG=debug
|
|
209
|
+
RUST_LOG=debug codesearch find --uses-type Album
|
|
210
210
|
```
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
## Overview
|
|
4
4
|
|
|
5
|
-
The Rust AST Extractor is implemented as part of Phase 2 of the AST-Aware
|
|
5
|
+
The Rust AST Extractor is implemented as part of Phase 2 of the AST-Aware CodeSearch Accelerator. It provides entity and reference extraction from Rust source code using tree-sitter.
|
|
6
6
|
|
|
7
7
|
## Architecture
|
|
8
8
|
|
|
@@ -138,7 +138,7 @@ Once tree-sitter is integrated:
|
|
|
138
138
|
## Usage Example
|
|
139
139
|
|
|
140
140
|
```rust
|
|
141
|
-
use
|
|
141
|
+
use local_codesearch::extractors::create_rust_extractor;
|
|
142
142
|
|
|
143
143
|
let mut extractor = create_rust_extractor()?;
|
|
144
144
|
let source = r#"
|
|
@@ -165,7 +165,7 @@ The implementation includes comprehensive tests:
|
|
|
165
165
|
- Demonstrates full extraction workflow
|
|
166
166
|
- Shows entity and reference output
|
|
167
167
|
|
|
168
|
-
## Integration with
|
|
168
|
+
## Integration with CodeSearch
|
|
169
169
|
|
|
170
170
|
Once complete, the extractor will integrate with:
|
|
171
171
|
|
|
@@ -203,10 +203,10 @@ Once complete, the extractor will integrate with:
|
|
|
203
203
|
|
|
204
204
|
## File Locations
|
|
205
205
|
|
|
206
|
-
- Core extractor: `/mnt/c/Users/masha/Documents/claude-flow-novice/.claude/skills/cfn-local-
|
|
207
|
-
- Module definitions: `/mnt/c/Users/masha/Documents/claude-flow-novice/.claude/skills/cfn-local-
|
|
208
|
-
- Tests: `/mnt/c/Users/masha/Documents/claude-flow-novice/.claude/skills/cfn-local-
|
|
209
|
-
- Example: `/mnt/c/Users/masha/Documents/claude-flow-novice/.claude/skills/cfn-local-
|
|
206
|
+
- Core extractor: `/mnt/c/Users/masha/Documents/claude-flow-novice/.claude/skills/cfn-local-codesearch-accelerator/src/extractors/rust.rs`
|
|
207
|
+
- Module definitions: `/mnt/c/Users/masha/Documents/claude-flow-novice/.claude/skills/cfn-local-codesearch-accelerator/src/extractors/mod.rs`
|
|
208
|
+
- Tests: `/mnt/c/Users/masha/Documents/claude-flow-novice/.claude/skills/cfn-local-codesearch-accelerator/tests/test_rust_extractor.rs`
|
|
209
|
+
- Example: `/mnt/c/Users/masha/Documents/claude-flow-novice/.claude/skills/cfn-local-codesearch-accelerator/examples/rust_ast_extractor_demo.rs`
|
|
210
210
|
|
|
211
211
|
## Confidence Score
|
|
212
212
|
|
package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/epic-ast-indexer.json
RENAMED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
{
|
|
2
2
|
"executionMode": "cfn-loop",
|
|
3
3
|
"metadata": {
|
|
4
|
-
"epicId": "
|
|
5
|
-
"name": "AST-Aware
|
|
6
|
-
"description": "Transform
|
|
4
|
+
"epicId": "codesearch-ast-agent-accelerator",
|
|
5
|
+
"name": "AST-Aware CodeSearch Agent Accelerator",
|
|
6
|
+
"description": "Transform CodeSearch from line-based indexing to AST-aware semantic indexing for Rust and TypeScript. Enable agents to replace slow grep/search operations with instant database queries for code intelligence: finding functions by type usage, tracking cross-file references, mapping module dependencies, and supporting large-scale refactoring workflows.",
|
|
7
7
|
"status": "not_started",
|
|
8
8
|
"priority": "high",
|
|
9
9
|
"estimatedDuration": "3 weeks",
|
|
10
10
|
"owner": "cfn-dev-team",
|
|
11
|
-
"targetPath": ".claude/skills/cfn-
|
|
11
|
+
"targetPath": ".claude/skills/cfn-codesearch"
|
|
12
12
|
},
|
|
13
13
|
"goals": [
|
|
14
14
|
"Replace grep-based code search with sub-50ms database queries",
|
|
@@ -177,8 +177,8 @@
|
|
|
177
177
|
"sprintId": "sprint-4-2",
|
|
178
178
|
"name": "CLI Integration",
|
|
179
179
|
"tasks": [
|
|
180
|
-
"Add '
|
|
181
|
-
"Add '
|
|
180
|
+
"Add 'codesearch find' subcommand with --kind, --uses-type, --called-by flags",
|
|
181
|
+
"Add 'codesearch refs' subcommand for reference queries",
|
|
182
182
|
"Add --json output format for programmatic use",
|
|
183
183
|
"Add natural language query parsing (optional)",
|
|
184
184
|
"Update help documentation"
|
|
@@ -251,8 +251,8 @@
|
|
|
251
251
|
"consensusThreshold": 0.90,
|
|
252
252
|
"gateThreshold": 0.95,
|
|
253
253
|
"maxIterations": 10,
|
|
254
|
-
"testCommand": "cd .claude/skills/cfn-
|
|
255
|
-
"buildCommand": "cd .claude/skills/cfn-
|
|
254
|
+
"testCommand": "cd .claude/skills/cfn-codesearch && cargo test",
|
|
255
|
+
"buildCommand": "cd .claude/skills/cfn-codesearch && cargo build --release"
|
|
256
256
|
},
|
|
257
257
|
"technicalContext": {
|
|
258
258
|
"language": "rust",
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/bin/bash
|
|
2
|
-
# index-code.sh - Index codebase using local-
|
|
2
|
+
# index-code.sh - Index codebase using local-codesearch Rust binary
|
|
3
3
|
# This is a wrapper around the Rust binary for convenience
|
|
4
4
|
|
|
5
5
|
set -e
|
|
@@ -40,7 +40,7 @@ if [[ "$HELP" == true ]]; then
|
|
|
40
40
|
cat << EOF
|
|
41
41
|
Usage: index-code [OPTIONS] [PATH]
|
|
42
42
|
|
|
43
|
-
Index codebase patterns using local-
|
|
43
|
+
Index codebase patterns using local-codesearch Rust binary
|
|
44
44
|
|
|
45
45
|
Arguments:
|
|
46
46
|
PATH Path to directory to index (default: current directory)
|
|
@@ -51,7 +51,7 @@ Options:
|
|
|
51
51
|
--help, -h Show this help
|
|
52
52
|
|
|
53
53
|
Database Location:
|
|
54
|
-
~/.local/share/
|
|
54
|
+
~/.local/share/codesearch/index_v2.db
|
|
55
55
|
|
|
56
56
|
Examples:
|
|
57
57
|
index-code --path ~/projects/my-app
|
|
@@ -62,13 +62,13 @@ EOF
|
|
|
62
62
|
fi
|
|
63
63
|
|
|
64
64
|
# Find the binary
|
|
65
|
-
if command -v local-
|
|
66
|
-
BINARY="local-
|
|
67
|
-
elif [[ -x "$HOME/.local/bin/local-
|
|
68
|
-
BINARY="$HOME/.local/bin/local-
|
|
65
|
+
if command -v local-codesearch &>/dev/null; then
|
|
66
|
+
BINARY="local-codesearch"
|
|
67
|
+
elif [[ -x "$HOME/.local/bin/local-codesearch" ]]; then
|
|
68
|
+
BINARY="$HOME/.local/bin/local-codesearch"
|
|
69
69
|
else
|
|
70
|
-
echo "❌ Error: local-
|
|
71
|
-
echo " Install with: ./scripts/install-
|
|
70
|
+
echo "❌ Error: local-codesearch binary not found"
|
|
71
|
+
echo " Install with: ./scripts/install-codesearch-global.sh"
|
|
72
72
|
exit 1
|
|
73
73
|
fi
|
|
74
74
|
|
|
@@ -80,7 +80,7 @@ PATH_TO_INDEX="$(cd "$PATH_TO_INDEX" 2>/dev/null && pwd)" || {
|
|
|
80
80
|
|
|
81
81
|
echo "🔍 Indexing code patterns in: $PATH_TO_INDEX"
|
|
82
82
|
echo "📄 File types: $FILE_TYPES"
|
|
83
|
-
echo "🗄️ Database: ~/.local/share/
|
|
83
|
+
echo "🗄️ Database: ~/.local/share/codesearch/index_v2.db"
|
|
84
84
|
echo ""
|
|
85
85
|
|
|
86
86
|
# Run the indexer
|
|
@@ -88,4 +88,4 @@ $BINARY index --path "$PATH_TO_INDEX" --types "$FILE_TYPES"
|
|
|
88
88
|
|
|
89
89
|
echo ""
|
|
90
90
|
echo "✅ Indexing complete!"
|
|
91
|
-
echo "💡 Query patterns with: sqlite3 ~/.local/share/
|
|
91
|
+
echo "💡 Query patterns with: sqlite3 ~/.local/share/codesearch/index_v2.db \"SELECT * FROM entities WHERE name LIKE '%keyword%';\""
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
# Index all files in the project
|
|
3
3
|
|
|
4
4
|
echo "Starting comprehensive indexing of all files..."
|
|
5
|
-
cd .claude/skills/cfn-local-
|
|
5
|
+
cd .claude/skills/cfn-local-codesearch-accelerator
|
|
6
6
|
|
|
7
7
|
# Clear existing index
|
|
8
8
|
rm -rf index/
|
|
@@ -34,7 +34,7 @@ for ext in "${file_types[@]}"; do
|
|
|
34
34
|
fi
|
|
35
35
|
|
|
36
36
|
# Index this file type
|
|
37
|
-
local-
|
|
37
|
+
local-codesearch index --path ../.. --types ${ext} --force
|
|
38
38
|
|
|
39
39
|
if [ $? -eq 0 ]; then
|
|
40
40
|
echo "✅ Successfully indexed .${ext} files"
|
package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/ingest-agent-transcript.sh
RENAMED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/bin/bash
|
|
2
|
-
# ingest-agent-transcript.sh - Extract and index agent transcript data for
|
|
2
|
+
# ingest-agent-transcript.sh - Extract and index agent transcript data for CodeSearch
|
|
3
3
|
#
|
|
4
4
|
# Purpose: Process agent transcripts to extract searchable decision points,
|
|
5
5
|
# tool usage patterns, and failure contexts for future semantic search.
|
|
@@ -21,7 +21,7 @@ set -euo pipefail
|
|
|
21
21
|
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
|
22
22
|
PROJECT_ROOT=$(git rev-parse --show-toplevel 2>/dev/null || echo ".")
|
|
23
23
|
DB_PATH="${PROJECT_ROOT}/.claude/skills/cfn-redis-coordination/data/cfn-loop.db"
|
|
24
|
-
LOG_PATH="${PROJECT_ROOT}/.artifacts/logs/
|
|
24
|
+
LOG_PATH="${PROJECT_ROOT}/.artifacts/logs/codesearch-ingestion.log"
|
|
25
25
|
|
|
26
26
|
# Ensure dependencies exist
|
|
27
27
|
mkdir -p "$(dirname "$LOG_PATH")"
|
|
@@ -77,13 +77,13 @@ if [ ! -f "$TRANSCRIPT" ]; then
|
|
|
77
77
|
exit 1
|
|
78
78
|
fi
|
|
79
79
|
|
|
80
|
-
echo "[
|
|
80
|
+
echo "[CodeSearch] Starting transcript ingestion for $AGENT_ID ($AGENT_TYPE)" | tee -a "$LOG_PATH"
|
|
81
81
|
|
|
82
82
|
# ============================================================================
|
|
83
83
|
# Initialize Schema Extensions
|
|
84
84
|
# ============================================================================
|
|
85
85
|
|
|
86
|
-
# Create extended schema for agent lifecycle data in
|
|
86
|
+
# Create extended schema for agent lifecycle data in CodeSearch
|
|
87
87
|
sqlite3 "$DB_PATH" <<'EOF'
|
|
88
88
|
-- Agent transcript embeddings table
|
|
89
89
|
CREATE TABLE IF NOT EXISTS agent_transcripts (
|
|
@@ -124,7 +124,7 @@ CREATE INDEX IF NOT EXISTS idx_failure_patterns_agent_type ON agent_failure_patt
|
|
|
124
124
|
CREATE INDEX IF NOT EXISTS idx_failure_patterns_mode ON agent_failure_patterns(failure_mode);
|
|
125
125
|
EOF
|
|
126
126
|
|
|
127
|
-
echo "[
|
|
127
|
+
echo "[CodeSearch] Schema initialized" | tee -a "$LOG_PATH"
|
|
128
128
|
|
|
129
129
|
# ============================================================================
|
|
130
130
|
# Extract Decision Points and Tool Usage from Transcript
|
|
@@ -222,7 +222,7 @@ SQL_EOF
|
|
|
222
222
|
|
|
223
223
|
done < "$TRANSCRIPT"
|
|
224
224
|
|
|
225
|
-
echo "[
|
|
225
|
+
echo "[CodeSearch] Extracted $SNIPPETS_EXTRACTED snippets from transcript" | tee -a "$LOG_PATH"
|
|
226
226
|
|
|
227
227
|
# ============================================================================
|
|
228
228
|
# Update Agent Metadata
|
|
@@ -233,21 +233,21 @@ sqlite3 "$DB_PATH" <<EOF
|
|
|
233
233
|
UPDATE agents
|
|
234
234
|
SET metadata = json_set(
|
|
235
235
|
metadata,
|
|
236
|
-
'$.
|
|
236
|
+
'$.codesearch_processed',
|
|
237
237
|
'true',
|
|
238
|
-
'$.
|
|
238
|
+
'$.codesearch_snippets',
|
|
239
239
|
$SNIPPETS_EXTRACTED
|
|
240
240
|
)
|
|
241
241
|
WHERE id = '$AGENT_ID';
|
|
242
242
|
EOF
|
|
243
243
|
|
|
244
|
-
echo "[
|
|
244
|
+
echo "[CodeSearch] Updated agent metadata for $AGENT_ID" | tee -a "$LOG_PATH"
|
|
245
245
|
|
|
246
246
|
# ============================================================================
|
|
247
247
|
# Success Exit
|
|
248
248
|
# ============================================================================
|
|
249
249
|
|
|
250
|
-
echo "[
|
|
250
|
+
echo "[CodeSearch] Transcript ingestion completed successfully" | tee -a "$LOG_PATH"
|
|
251
251
|
echo " Agent: $AGENT_ID ($AGENT_TYPE)"
|
|
252
252
|
echo " Snippets: $SNIPPETS_EXTRACTED"
|
|
253
253
|
echo " Success: $SUCCESS"
|
|
@@ -1,42 +1,42 @@
|
|
|
1
1
|
#!/bin/bash
|
|
2
|
-
# init-local-
|
|
2
|
+
# init-local-codesearch.sh - Verify and setup local CodeSearch
|
|
3
3
|
# Ensures the Rust binary is installed and PATH is configured
|
|
4
4
|
|
|
5
5
|
set -e
|
|
6
6
|
|
|
7
7
|
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
|
8
|
-
BINARY_PATH="$HOME/.local/bin/local-
|
|
9
|
-
DB_PATH="$HOME/.local/share/
|
|
8
|
+
BINARY_PATH="$HOME/.local/bin/local-codesearch"
|
|
9
|
+
DB_PATH="$HOME/.local/share/codesearch/index_v2.db"
|
|
10
10
|
|
|
11
|
-
echo "🚀 Checking Local
|
|
11
|
+
echo "🚀 Checking Local CodeSearch Installation..."
|
|
12
12
|
echo ""
|
|
13
13
|
|
|
14
14
|
# Check if binary exists in PATH
|
|
15
|
-
if command -v local-
|
|
16
|
-
BINARY_LOCATION=$(command -v local-
|
|
17
|
-
VERSION=$(local-
|
|
18
|
-
echo "✅ local-
|
|
15
|
+
if command -v local-codesearch &>/dev/null; then
|
|
16
|
+
BINARY_LOCATION=$(command -v local-codesearch)
|
|
17
|
+
VERSION=$(local-codesearch --version 2>/dev/null || echo "unknown")
|
|
18
|
+
echo "✅ local-codesearch found in PATH"
|
|
19
19
|
echo " Location: $BINARY_LOCATION"
|
|
20
20
|
echo " Version: $VERSION"
|
|
21
21
|
elif [[ -x "$BINARY_PATH" ]]; then
|
|
22
22
|
VERSION=$($BINARY_PATH --version 2>/dev/null || echo "unknown")
|
|
23
|
-
echo "✅ local-
|
|
23
|
+
echo "✅ local-codesearch found at $BINARY_PATH"
|
|
24
24
|
echo " Version: $VERSION"
|
|
25
25
|
echo ""
|
|
26
26
|
echo "⚠️ Binary not in PATH. Add to your shell profile:"
|
|
27
27
|
echo " export PATH=\"\$HOME/.local/bin:\$PATH\""
|
|
28
28
|
else
|
|
29
|
-
echo "❌ local-
|
|
29
|
+
echo "❌ local-codesearch binary not found"
|
|
30
30
|
echo ""
|
|
31
31
|
echo "📦 Installation options:"
|
|
32
32
|
echo ""
|
|
33
33
|
echo " Option 1 - Use install script (if available):"
|
|
34
|
-
echo " ./scripts/install-
|
|
34
|
+
echo " ./scripts/install-codesearch-global.sh"
|
|
35
35
|
echo ""
|
|
36
36
|
echo " Option 2 - Build from source (requires Rust):"
|
|
37
37
|
echo " cd $SCRIPT_DIR"
|
|
38
38
|
echo " cargo build --release"
|
|
39
|
-
echo " cp target/release/local-
|
|
39
|
+
echo " cp target/release/local-codesearch ~/.local/bin/"
|
|
40
40
|
echo ""
|
|
41
41
|
exit 1
|
|
42
42
|
fi
|
|
@@ -56,18 +56,18 @@ if [[ -f "$DB_PATH" ]]; then
|
|
|
56
56
|
echo " Projects: $PROJECT_COUNT"
|
|
57
57
|
else
|
|
58
58
|
echo "⚠️ No database found at $DB_PATH"
|
|
59
|
-
echo " Index a project with: local-
|
|
59
|
+
echo " Index a project with: local-codesearch index --path /your/project"
|
|
60
60
|
fi
|
|
61
61
|
|
|
62
62
|
echo ""
|
|
63
63
|
echo "📖 Quick Start:"
|
|
64
64
|
echo " # Index a project"
|
|
65
|
-
echo " local-
|
|
65
|
+
echo " local-codesearch index --path ~/projects/my-app --types ts,tsx,js,jsx,py"
|
|
66
66
|
echo ""
|
|
67
67
|
echo " # Query via SQL"
|
|
68
68
|
echo " sqlite3 $DB_PATH \"SELECT file_path, name FROM entities WHERE name LIKE '%auth%' LIMIT 10;\""
|
|
69
69
|
echo ""
|
|
70
70
|
echo " # Semantic search"
|
|
71
|
-
echo " local-
|
|
71
|
+
echo " local-codesearch query \"authentication middleware\""
|
|
72
72
|
echo ""
|
|
73
|
-
echo "🎉 Local
|
|
73
|
+
echo "🎉 Local CodeSearch is ready!"
|
package/.claude/skills/{cfn-local-ruvector-accelerator → cfn-codesearch}/project-structure.md
RENAMED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
# Project-Specific Local
|
|
1
|
+
# Project-Specific Local CodeSearch Structure
|
|
2
2
|
|
|
3
3
|
## Current (Global) Structure:
|
|
4
4
|
```
|
|
5
|
-
~/.local-
|
|
5
|
+
~/.local-codesearch/
|
|
6
6
|
├── storage/
|
|
7
7
|
├── indexes/
|
|
8
8
|
└── config/
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
## Proposed Project-Specific Structure:
|
|
12
12
|
```
|
|
13
13
|
.your-project/
|
|
14
|
-
├── .
|
|
14
|
+
├── .codesearch/
|
|
15
15
|
│ ├── storage/
|
|
16
16
|
│ │ ├── embeddings.bin
|
|
17
17
|
│ │ └── cache.db
|
|
@@ -25,24 +25,24 @@
|
|
|
25
25
|
|
|
26
26
|
### 1. Update init script to accept project path:
|
|
27
27
|
```bash
|
|
28
|
-
# Instead of ~/.local-
|
|
29
|
-
./init-local-
|
|
28
|
+
# Instead of ~/.local-codesearch
|
|
29
|
+
./init-local-codesearch.sh --project-path /path/to/project
|
|
30
30
|
|
|
31
31
|
# Or detect current directory
|
|
32
|
-
./init-local-
|
|
32
|
+
./init-local-codesearch.sh --here
|
|
33
33
|
```
|
|
34
34
|
|
|
35
35
|
### 2. Update index and query scripts:
|
|
36
36
|
```bash
|
|
37
|
-
# Auto-detect .
|
|
37
|
+
# Auto-detect .codesearch directory
|
|
38
38
|
# Fall back to parent directories
|
|
39
|
-
# Respect .gitignore for .
|
|
39
|
+
# Respect .gitignore for .codesearch/
|
|
40
40
|
```
|
|
41
41
|
|
|
42
42
|
### 3. Add .gitignore entry:
|
|
43
43
|
```
|
|
44
44
|
# .gitignore
|
|
45
|
-
.
|
|
45
|
+
.codesearch/
|
|
46
46
|
```
|
|
47
47
|
|
|
48
48
|
### 4. Benefits:
|
|
@@ -50,4 +50,4 @@
|
|
|
50
50
|
- Team members can share patterns
|
|
51
51
|
- No global state pollution
|
|
52
52
|
- Works with monorepos (each subproject has own patterns)
|
|
53
|
-
- Easy to clean up (just delete .
|
|
53
|
+
- Easy to clean up (just delete .codesearch/)
|