loki-mode 7.21.0 → 7.23.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.
- package/SKILL.md +2 -2
- package/VERSION +1 -1
- package/autonomy/loki +78 -1
- package/autonomy/run.sh +433 -7
- package/dashboard/__init__.py +1 -1
- package/docs/INSTALLATION.md +1 -1
- package/loki-ts/dist/loki.js +2 -2
- package/mcp/__init__.py +1 -1
- package/mcp/server.py +79 -1
- package/package.json +1 -1
- package/references/mcp-integration.md +65 -0
- package/skills/00-index.md +2 -0
- package/skills/parallel-workflows.md +96 -0
- package/skills/quality-gates.md +18 -0
- package/tools/hybrid_search.py +451 -0
- package/tools/index-codebase.py +296 -0
package/SKILL.md
CHANGED
|
@@ -3,7 +3,7 @@ name: loki-mode
|
|
|
3
3
|
description: Autonomous spec-driven build system with a built-in trust layer. It does not call work done until it is verified (RARV-C closure loop, 11 quality gates, completion council, verified-completion evidence gate). Triggers on "Loki Mode". Takes a spec (PRD, GitHub issue, OpenAPI doc, etc.) to deployed product with minimal human intervention. Provider-agnostic. Requires --dangerously-skip-permissions flag.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
|
-
# Loki Mode v7.
|
|
6
|
+
# Loki Mode v7.23.0
|
|
7
7
|
|
|
8
8
|
**You are an autonomous agent. You make decisions. You do not ask questions. You do not stop.**
|
|
9
9
|
|
|
@@ -383,4 +383,4 @@ See `CHANGELOG.md` entries [7.5.7], [7.5.8], [7.5.13] for the per-fix list and r
|
|
|
383
383
|
|
|
384
384
|
---
|
|
385
385
|
|
|
386
|
-
**v7.
|
|
386
|
+
**v7.23.0 | [Autonomi](https://www.autonomi.dev/) flagship product | ~260 lines core**
|
package/VERSION
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
7.
|
|
1
|
+
7.23.0
|
package/autonomy/loki
CHANGED
|
@@ -579,7 +579,7 @@ show_help() {
|
|
|
579
579
|
echo " ci [opts] CI/CD quality gate integration (--pr, --report, --github-comment)"
|
|
580
580
|
echo " test [opts] AI-powered test generation (--file, --dir, --changed, --dry-run)"
|
|
581
581
|
echo " context [cmd] Context window management (show|files|tools|add|clear)"
|
|
582
|
-
echo " code [cmd] Codebase intelligence (overview|symbols|deps|hotspots|diff)"
|
|
582
|
+
echo " code [cmd] Codebase intelligence (overview|symbols|deps|hotspots|diff|search)"
|
|
583
583
|
echo " report [opts] Session report generator (--format text|markdown|html, --output)"
|
|
584
584
|
echo " share [opts] Share session report as GitHub Gist (--private, --format)"
|
|
585
585
|
echo " proof [cmd] Inspect/share proof-of-run artifacts (list|show|open|share)"
|
|
@@ -19712,6 +19712,7 @@ cmd_code() {
|
|
|
19712
19712
|
echo "Subcommands:"
|
|
19713
19713
|
echo " overview Generate workspace overview (file types, LOC, structure)"
|
|
19714
19714
|
echo " symbols Search for symbols (functions, classes, variables)"
|
|
19715
|
+
echo " search Hybrid grep + semantic codebase search"
|
|
19715
19716
|
echo " deps Show dependency graph for a file or module"
|
|
19716
19717
|
echo " hotspots Find code hotspots (most-changed files, complexity)"
|
|
19717
19718
|
echo " diff Show colored diff of recent changes"
|
|
@@ -19720,6 +19721,9 @@ cmd_code() {
|
|
|
19720
19721
|
echo " loki code overview # Full codebase overview"
|
|
19721
19722
|
echo " loki code overview --silent # Compact output"
|
|
19722
19723
|
echo " loki code symbols 'class.*Service' # Find service classes"
|
|
19724
|
+
echo " loki code search 'rate limit backoff' # Hybrid grep + semantic search"
|
|
19725
|
+
echo " loki code search 'council vote' --grep-only # Lexical only"
|
|
19726
|
+
echo " loki code search 'memory retrieval' --semantic-only --top 15"
|
|
19723
19727
|
echo " loki code deps src/main.py # Show dependencies"
|
|
19724
19728
|
echo " loki code hotspots --top 10 # Top 10 changed files"
|
|
19725
19729
|
echo " loki code diff # Colored diff of uncommitted changes"
|
|
@@ -19733,6 +19737,9 @@ cmd_code() {
|
|
|
19733
19737
|
symbols)
|
|
19734
19738
|
_code_symbols "$@"
|
|
19735
19739
|
;;
|
|
19740
|
+
search)
|
|
19741
|
+
_code_search "$@"
|
|
19742
|
+
;;
|
|
19736
19743
|
deps)
|
|
19737
19744
|
_code_deps "$@"
|
|
19738
19745
|
;;
|
|
@@ -19750,6 +19757,76 @@ cmd_code() {
|
|
|
19750
19757
|
esac
|
|
19751
19758
|
}
|
|
19752
19759
|
|
|
19760
|
+
# Hybrid codebase search: grep + semantic (ChromaDB) fused with RRF.
|
|
19761
|
+
# Delegates to tools/hybrid_search.py (needs python3.12 for chromadb). The
|
|
19762
|
+
# Python side handles the rg / grep / python-scan fallback and the grep-only
|
|
19763
|
+
# degradation when ChromaDB is unreachable, so this stays thin.
|
|
19764
|
+
_code_search() {
|
|
19765
|
+
local query=""
|
|
19766
|
+
local -a pyargs=()
|
|
19767
|
+
while [[ $# -gt 0 ]]; do
|
|
19768
|
+
case "$1" in
|
|
19769
|
+
--grep-only) pyargs+=("--grep-only"); shift ;;
|
|
19770
|
+
--semantic-only) pyargs+=("--semantic-only"); shift ;;
|
|
19771
|
+
--budget) pyargs+=("--budget" "${2:-3000}"); shift 2 ;;
|
|
19772
|
+
--top) pyargs+=("--top" "${2:-10}"); shift 2 ;;
|
|
19773
|
+
--json) pyargs+=("--json"); shift ;;
|
|
19774
|
+
-h|--help)
|
|
19775
|
+
echo -e "${BOLD}loki code search${NC} - Hybrid grep + semantic codebase search"
|
|
19776
|
+
echo ""
|
|
19777
|
+
echo "Usage: loki code search \"<query>\" [flags]"
|
|
19778
|
+
echo ""
|
|
19779
|
+
echo "Flags:"
|
|
19780
|
+
echo " --grep-only Lexical search only (skip semantic)"
|
|
19781
|
+
echo " --semantic-only Semantic search only (skip grep)"
|
|
19782
|
+
echo " --budget N Token budget for merged results (default 3000)"
|
|
19783
|
+
echo " --top N Max results (default 10)"
|
|
19784
|
+
echo " --json Output JSON"
|
|
19785
|
+
echo ""
|
|
19786
|
+
echo "Falls back to grep-only when ChromaDB is unreachable."
|
|
19787
|
+
return 0
|
|
19788
|
+
;;
|
|
19789
|
+
*)
|
|
19790
|
+
if [[ -z "$query" ]]; then
|
|
19791
|
+
query="$1"
|
|
19792
|
+
else
|
|
19793
|
+
query="$query $1"
|
|
19794
|
+
fi
|
|
19795
|
+
shift
|
|
19796
|
+
;;
|
|
19797
|
+
esac
|
|
19798
|
+
done
|
|
19799
|
+
|
|
19800
|
+
if [[ -z "$query" ]]; then
|
|
19801
|
+
echo -e "${RED}Usage: loki code search \"<query>\" [--grep-only|--semantic-only] [--budget N] [--top N]${NC}"
|
|
19802
|
+
return 1
|
|
19803
|
+
fi
|
|
19804
|
+
|
|
19805
|
+
local script_dir hybrid py
|
|
19806
|
+
script_dir="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)"
|
|
19807
|
+
hybrid="$script_dir/tools/hybrid_search.py"
|
|
19808
|
+
if [[ ! -f "$hybrid" ]]; then
|
|
19809
|
+
echo -e "${RED}hybrid_search.py not found at $hybrid${NC}"
|
|
19810
|
+
return 1
|
|
19811
|
+
fi
|
|
19812
|
+
|
|
19813
|
+
# chromadb requires python3.12 on this stack; fall back to python3 for the
|
|
19814
|
+
# grep-only path if 3.12 is absent.
|
|
19815
|
+
if [[ -x /opt/homebrew/bin/python3.12 ]]; then
|
|
19816
|
+
py=/opt/homebrew/bin/python3.12
|
|
19817
|
+
else
|
|
19818
|
+
py="$(command -v python3 || true)"
|
|
19819
|
+
fi
|
|
19820
|
+
if [[ -z "$py" ]]; then
|
|
19821
|
+
echo -e "${RED}python3 not found${NC}"
|
|
19822
|
+
return 1
|
|
19823
|
+
fi
|
|
19824
|
+
|
|
19825
|
+
# Safe array expansion: "${pyargs[@]}" triggers "unbound variable" under
|
|
19826
|
+
# bash 3.2 (macOS default) + set -u when the array is empty (no flags).
|
|
19827
|
+
"$py" "$hybrid" "$query" ${pyargs[@]+"${pyargs[@]}"}
|
|
19828
|
+
}
|
|
19829
|
+
|
|
19753
19830
|
_code_overview() {
|
|
19754
19831
|
local silent=false
|
|
19755
19832
|
local target_dir="."
|