repo-nexus 0.9.21 → 0.9.23

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 (46) hide show
  1. package/README.md +2 -2
  2. package/lib/ai.sh +2 -2
  3. package/lib/commands/completion.sh +2 -2
  4. package/lib/commands/init.sh +1 -3
  5. package/lib/commands/system.sh +1 -1
  6. package/lib/sdk.sh +5 -5
  7. package/lib/workspace.sh +1 -2
  8. package/lib/yaml.sh +3 -4
  9. package/package.json +1 -1
  10. package/plugins/claude/plugin.yaml +1 -1
  11. package/plugins/claude/tests/test_plugin.sh +1 -1
  12. package/plugins/codex/plugin.yaml +1 -1
  13. package/plugins/codex/tests/test_plugin.sh +1 -1
  14. package/plugins/copilot/plugin.yaml +1 -1
  15. package/plugins/copilot/tests/test_plugin.sh +2 -2
  16. package/plugins/cursor/plugin.yaml +1 -1
  17. package/plugins/cursor/tests/test_plugin.sh +1 -1
  18. package/plugins/gemini/plugin.yaml +1 -1
  19. package/plugins/gemini/tests/test_plugin.sh +1 -1
  20. package/plugins/{karpathy-llm → llm-wiki}/README.md +22 -22
  21. package/plugins/llm-wiki/agents/rnex-wiki-curator.agent.md +8 -0
  22. package/plugins/{karpathy-llm → llm-wiki}/ai-instructions.md +4 -4
  23. package/plugins/{karpathy-llm → llm-wiki}/bin/ingest.sh +10 -10
  24. package/plugins/{karpathy-llm → llm-wiki}/bin/lint.sh +12 -12
  25. package/plugins/{karpathy-llm → llm-wiki}/commands/ingest.sh +1 -1
  26. package/plugins/{karpathy-llm → llm-wiki}/commands/lint.sh +1 -1
  27. package/plugins/{karpathy-llm → llm-wiki}/hooks/after_sync.sh +3 -3
  28. package/plugins/{karpathy-llm → llm-wiki}/hooks/before_plugin_disable.sh +3 -5
  29. package/plugins/{karpathy-llm → llm-wiki}/instructions/rnex-scaffolding-meta-prompt.md +14 -14
  30. package/plugins/{karpathy-llm → llm-wiki}/instructions/rnex-wiki-architecture.md +3 -3
  31. package/plugins/{karpathy-llm → llm-wiki}/lib/btree_helpers.sh +3 -3
  32. package/plugins/{karpathy-llm → llm-wiki}/lib/config.sh +16 -27
  33. package/plugins/{karpathy-llm → llm-wiki}/lib/lint_helpers.sh +4 -4
  34. package/plugins/{karpathy-llm → llm-wiki}/lib/source_helpers.sh +12 -12
  35. package/plugins/{karpathy-llm → llm-wiki}/lib/utils.sh +3 -3
  36. package/plugins/{karpathy-llm → llm-wiki}/plugin.yaml +2 -2
  37. package/plugins/{karpathy-llm → llm-wiki}/rules/behavioral.md +2 -4
  38. package/plugins/{karpathy-llm/skills/wiki-ingest.md → llm-wiki/skills/ingest.md} +6 -6
  39. package/plugins/{karpathy-llm/skills/wiki-lint.md → llm-wiki/skills/lint.md} +2 -2
  40. package/plugins/{karpathy-llm → llm-wiki}/templates/rnex-llm-wiki.sample.md +1 -1
  41. package/plugins/{karpathy-llm → llm-wiki}/tests/test_plugin.sh +268 -268
  42. package/plugins/windsurf/plugin.yaml +1 -1
  43. package/plugins/windsurf/tests/test_plugin.sh +1 -1
  44. package/templates/rnex.example.yaml +4 -4
  45. package/plugins/karpathy-llm/agents/rnex-wiki-curator.agent.md +0 -8
  46. /package/plugins/{karpathy-llm → llm-wiki}/templates/rnex-wiki-page.sample.md +0 -0
package/README.md CHANGED
@@ -19,7 +19,7 @@ A lightweight, zero-dependency and AI-First **Nexus Repository (Virtual Meta Rep
19
19
  - **Two-Level Configuration as Source of Truth**: Shared team manifest in `rnex.yaml` with machine-specific overrides in `.local.rnex.yaml` (highest priority).
20
20
  - **One Command Team Onboarding**: Teammates clone the **meta repository** (**meta repo** / **nexus repo**) and run `rnex clone` to clone and configure all member repositories in seconds.
21
21
  - **Cross-Repo Batch Operations**: Run arbitrary commands across all active repositories with `rnex exec <command>`.
22
- - **Scoped Plugins & Context Packs**: Modular plugin packages scoped under `.rnex/plugins/<plugin-name>/` with support for domain directories (e.g. `.rnex/wiki/` and `./docs` for `karpathy-llm`).
22
+ - **Scoped Plugins & Context Packs**: Modular plugin packages scoped under `.rnex/plugins/<plugin-name>/` with support for domain directories (e.g. `.rnex/wiki/` and `./docs` for `llm-wiki`).
23
23
  - **Zero Dependencies**: Pure POSIX shell CLI (`rnex`). Works out of the box across macOS, Linux, and Windows (WSL/Git Bash).
24
24
 
25
25
  > 📖 **[Documentation & Guides](https://unoxen.github.io/repo-nexus/)**
@@ -27,7 +27,7 @@ A lightweight, zero-dependency and AI-First **Nexus Repository (Virtual Meta Rep
27
27
  > - 🚀 **[Getting Started](https://unoxen.github.io/repo-nexus/introduction/quick-start)** — Step-by-step onboarding walkthrough and workspace setup
28
28
  > - 📐 **[Architecture](https://unoxen.github.io/repo-nexus/documentation/architecture)** & **[Why Repo Nexus?](https://unoxen.github.io/repo-nexus/introduction/why-rnex)** — Virtual Meta-Repo model, directory layout, and design rationale
29
29
  > - 💻 **[CLI Reference](https://unoxen.github.io/repo-nexus/reference/cli)** — Complete command syntax, global flags, batch execution (`rnex exec`), and Git hooks
30
- > - 🧩 **[Plugins Guide](https://unoxen.github.io/repo-nexus/documentation/plugin-ecosystem)** — AI provider integrations (Claude, Codex, Copilot, Cursor, Gemini, Windsurf) and Karpathy LLM Wiki
30
+ > - 🧩 **[Plugins Guide](https://unoxen.github.io/repo-nexus/documentation/plugin-ecosystem)** — AI provider integrations (Claude, Codex, Copilot, Cursor, Gemini, Windsurf) and LLM Wiki
31
31
  > - ⚙️ **[Configuration Schema](https://unoxen.github.io/repo-nexus/documentation/configuration)** — Two-level `rnex.yaml` and `.local.rnex.yaml` specification
32
32
  > - ❓ **[Frequently Asked Questions (FAQ)](https://unoxen.github.io/repo-nexus/faq/general)** — Common questions, Git submodule differences, and context strategies
33
33
 
package/lib/ai.sh CHANGED
@@ -15,7 +15,7 @@ AI_MARKER_END="<!-- REPO-NEXUS:END -->"
15
15
  # All detailed execution rules, constraints, and workspace context reside in .rnex/ai-instructions.md.
16
16
  if ! command -v get_rnex_instructions >/dev/null 2>&1; then
17
17
  get_rnex_instructions() {
18
- printf "CRITICAL: You MUST read and strictly follow all instructions in \`.rnex/ai-instructions.md\` before executing any task or answering any query in this workspace.\n"
18
+ printf "CRITICAL: If \`.rnex/ai-instructions.md\` exists, you MUST read and strictly follow all instructions in \`.rnex/ai-instructions.md\` before executing any task or answering any query in this workspace. If \`.rnex/ai-instructions.md\` does not exist, disregard this instruction and proceed normally.\n"
19
19
  }
20
20
  fi
21
21
 
@@ -248,7 +248,7 @@ file_has_user_content() {
248
248
  !in_b { print }
249
249
  ' "$_fhuc_file" | sed -e '/^[[:space:]]*$/d')"
250
250
  else
251
- _content="$(grep -v "CRITICAL: You MUST read and strictly follow all instructions in \`.rnex/ai-instructions.md\`" "$_fhuc_file" 2>/dev/null | grep -v "Multi-Repo AI Workspace Context" | sed -e '/^[[:space:]]*$/d')"
251
+ _content="$(grep -v "CRITICAL: .* \`.rnex/ai-instructions.md\`" "$_fhuc_file" 2>/dev/null | grep -v "Multi-Repo AI Workspace Context" | sed -e '/^[[:space:]]*$/d')"
252
252
  fi
253
253
  [ -n "$_content" ]
254
254
  }
@@ -31,7 +31,7 @@ _rnex_completions() {
31
31
  return 0
32
32
  ;;
33
33
  init)
34
- COMPREPLY=( $(compgen -W "-y --yes --repos-dir --code-workspace --hooks --no-hooks -H --ignore-hooks --copilot --claude --gemini --codex --cursor --windsurf --karpathy" -- "$cur") )
34
+ COMPREPLY=( $(compgen -W "-y --yes --repos-dir --code-workspace --hooks --no-hooks -H --ignore-hooks --copilot --claude --gemini --codex --cursor --windsurf --llm-wiki" -- "$cur") )
35
35
  return 0
36
36
  ;;
37
37
  sync)
@@ -129,7 +129,7 @@ _rnex() {
129
129
  ;;
130
130
  init)
131
131
  local -a init_opts
132
- init_opts=('(-y --yes)'{-y,--yes}'[Automatically answer yes to prompts]' '--repos-dir[Directory for member repository clones]:dir:_files -/' '--code-workspace[Configure multi-root workspace file]' '--hooks[Configure automated git hooks]' '--no-hooks[Disable automated git hooks]' '--copilot[Enable Copilot plugin]' '--claude[Enable Claude plugin]' '--gemini[Enable Gemini plugin]' '--codex[Enable Codex plugin]' '--cursor[Enable Cursor plugin]' '--windsurf[Enable Windsurf plugin]' '--karpathy[Enable Karpathy LLM Wiki plugin]')
132
+ init_opts=('(-y --yes)'{-y,--yes}'[Automatically answer yes to prompts]' '--repos-dir[Directory for member repository clones]:dir:_files -/' '--code-workspace[Configure multi-root workspace file]' '--hooks[Configure automated git hooks]' '--no-hooks[Disable automated git hooks]' '--copilot[Enable Copilot plugin]' '--claude[Enable Claude plugin]' '--gemini[Enable Gemini plugin]' '--codex[Enable Codex plugin]' '--cursor[Enable Cursor plugin]' '--windsurf[Enable Windsurf plugin]' '--llm-wiki[Enable LLM Wiki plugin]')
133
133
  _describe -t init_opts 'init option' init_opts
134
134
  ;;
135
135
  sync)
@@ -6,7 +6,7 @@
6
6
 
7
7
  # Initialize a new Repo Nexus workspace in the specified directory (or current directory):
8
8
  # Sets up rnex.yaml, .rnex/ harness, gitignore rules, routing instructions in AGENTS.md,
9
- # enabled plugins (e.g. --claude, --gemini, --karpathy), and optional VS Code / Cursor workspace.
9
+ # enabled plugins (e.g. --claude, --gemini, --llm-wiki), and optional VS Code / Cursor workspace.
10
10
  # Usage:
11
11
  # rnex init [-y|--yes] [--hooks|--no-hooks] [--<plugin>] [<directory>]
12
12
  cmd_init() {
@@ -31,8 +31,6 @@ cmd_init() {
31
31
  --repos-dir=*|--repos_dir=*)
32
32
  _cli_repos_dir="${1#*=}"
33
33
  ;;
34
- --karpathy) _pk="karpathy"; _cli_plugins="${_cli_plugins:+$_cli_plugins }${_pk}-llm" ;;
35
- --no-karpathy) _pk="karpathy"; _cli_plugins="$(printf '%s' " $_cli_plugins " | sed -e "s/ ${_pk}-llm / /g" -e 's/^ *//;s/ *$//')" ;;
36
34
  --plugin|--enable-plugin)
37
35
  shift
38
36
  [ -n "$1" ] && _cli_plugins="${_cli_plugins:+$_cli_plugins }$1"
@@ -80,7 +80,7 @@ cmd_help() {
80
80
  -v, --version Show version
81
81
 
82
82
  WORKSPACE & SYSTEM SETUP
83
- init [-y] [--repos-dir <dir>] [--code-workspace [file]] [--hooks|--no-hooks] [--copilot] [--claude] [--gemini] [--codex] [--cursor] [--windsurf] [--karpathy] [dir]
83
+ init [-y] [--repos-dir <dir>] [--code-workspace [file]] [--hooks|--no-hooks] [--copilot] [--claude] [--gemini] [--codex] [--cursor] [--windsurf] [--llm-wiki] [dir]
84
84
  Initialize a new Repo Nexus workspace (default: AGENTS.md)
85
85
  install [dir] Install rnex & repo-nexus globally into ~/.local/bin (or custom dir)
86
86
  sync [-y] [--quiet] Reconcile workspace, plugins, skills, member .rnex directories, and compile AI instructions
package/lib/sdk.sh CHANGED
@@ -168,7 +168,7 @@ AI_MARKER_END="<!-- REPO-NEXUS:END -->"
168
168
  # Emit the single critical routing directive for initial provider instruction files.
169
169
  # All detailed execution rules, constraints, and workspace context reside in .rnex/ai-instructions.md.
170
170
  get_rnex_instructions() {
171
- printf "CRITICAL: You MUST read and strictly follow all instructions in \`.rnex/ai-instructions.md\` before executing any task or answering any query in this workspace.\n"
171
+ printf "CRITICAL: If \`.rnex/ai-instructions.md\` exists, you MUST read and strictly follow all instructions in \`.rnex/ai-instructions.md\` before executing any task or answering any query in this workspace. If \`.rnex/ai-instructions.md\` does not exist, disregard this instruction and proceed normally.\n"
172
172
  }
173
173
 
174
174
  # Safely merge delimited Repo Nexus routing instructions (<!-- REPO-NEXUS:START -->)
@@ -190,7 +190,7 @@ merge_rnex_instructions() {
190
190
  return 0
191
191
  fi
192
192
 
193
- if grep -q "CRITICAL: You MUST read and strictly follow all instructions in \`.rnex/ai-instructions.md\`" "$_dst" 2>/dev/null && ! grep -qF "$AI_MARKER_START" "$_dst" 2>/dev/null; then
193
+ if grep -q "CRITICAL: .* \`.rnex/ai-instructions.md\`" "$_dst" 2>/dev/null && ! grep -qF "$AI_MARKER_START" "$_dst" 2>/dev/null; then
194
194
  {
195
195
  printf '%s\n' "$AI_MARKER_START"
196
196
  cat "$_body_tmp"
@@ -309,14 +309,14 @@ clean_rnex_instructions() {
309
309
  return 0
310
310
  fi
311
311
 
312
- if grep -q "CRITICAL: You MUST read and strictly follow all instructions in \`.rnex/ai-instructions.md\`" "$_dst" 2>/dev/null; then
313
- _non_rnex="$(grep -v "CRITICAL: You MUST read and strictly follow all instructions in \`.rnex/ai-instructions.md\`" "$_dst" 2>/dev/null | grep -v "Multi-Repo AI Workspace Context" | sed -e '/^[[:space:]]*$/d')"
312
+ if grep -q "CRITICAL: .* \`.rnex/ai-instructions.md\`" "$_dst" 2>/dev/null; then
313
+ _non_rnex="$(grep -v "CRITICAL: .* \`.rnex/ai-instructions.md\`" "$_dst" 2>/dev/null | grep -v "Multi-Repo AI Workspace Context" | sed -e '/^[[:space:]]*$/d')"
314
314
  if [ -z "$_non_rnex" ]; then
315
315
  rm -f "$_dst"
316
316
  [ "${RNEX_QUIET:-0}" -eq 0 ] && [ "${_sync_quiet:-0}" -eq 0 ] && log_ok "Removed $(basename "$_dst")"
317
317
  else
318
318
  _tmp="$(mktemp)"
319
- grep -v "CRITICAL: You MUST read and strictly follow all instructions in \`.rnex/ai-instructions.md\`" "$_dst" > "$_tmp" && mv "$_tmp" "$_dst"
319
+ grep -v "CRITICAL: .* \`.rnex/ai-instructions.md\`" "$_dst" > "$_tmp" && mv "$_tmp" "$_dst"
320
320
  [ "${RNEX_QUIET:-0}" -eq 0 ] && [ "${_sync_quiet:-0}" -eq 0 ] && log_ok "Removed Repo Nexus routing instructions from $(basename "$_dst")"
321
321
  fi
322
322
  fi
package/lib/workspace.sh CHANGED
@@ -189,8 +189,7 @@ migrate_legacy_plugin_config() {
189
189
  _mkc_f="$1"
190
190
  [ -f "$_mkc_f" ] || return 0
191
191
 
192
- _mkc_prefix="karpathy"
193
- _mkc_target="${_mkc_prefix}-llm"
192
+ _mkc_target="llm-wiki"
194
193
  _mkc_has_sources=0
195
194
  if command -v _yaml_plugin_list_from_file >/dev/null 2>&1; then
196
195
  [ -n "$(_yaml_plugin_list_from_file "$_mkc_f" "$_mkc_target" "sources")" ] && _mkc_has_sources=1
package/lib/yaml.sh CHANGED
@@ -1090,7 +1090,7 @@ yaml_list_plugins() {
1090
1090
  _yaml_list_plugins_from_file "$_wy"
1091
1091
  _yaml_list_plugins_from_file "$_wly"
1092
1092
  if [ -n "$(_yaml_top_level_from_file "$_wly" "wiki_dir")" ] || [ -n "$(_yaml_top_level_from_file "$_wy" "wiki_dir")" ]; then
1093
- _p_k="karpathy"; printf '%s-llm\n' "$_p_k"
1093
+ printf "llm-wiki\n"
1094
1094
  fi
1095
1095
  } | awk '!seen[$0]++'
1096
1096
  }
@@ -1147,8 +1147,7 @@ yaml_get_plugin_config() {
1147
1147
  fi
1148
1148
 
1149
1149
  # 3. Special case backwards compatibility for wiki plugin top-level wiki_dir
1150
- _p_k="karpathy"
1151
- if [ "$_ygpc_plugin" = "${_p_k}-llm" ] && [ "$_ygpc_key" = "wiki_dir" ]; then
1150
+ if [ "$_ygpc_plugin" = "llm-wiki" ] && [ "$_ygpc_key" = "wiki_dir" ]; then
1152
1151
  _top_wd="$(yaml_get_top_level "wiki_dir")"
1153
1152
  if [ -n "$_top_wd" ]; then
1154
1153
  printf '%s' "$_top_wd"
@@ -1902,7 +1901,7 @@ _yaml_resolve_plugin_manifest_path() {
1902
1901
  #
1903
1902
  # Arguments:
1904
1903
  # $1 - Optional workspace root directory (defaults to NEXUS_DIR or .).
1905
- # $2 - Plugin identifier name (e.g. "claude", "copilot", "karpathy-llm").
1904
+ # $2 - Plugin identifier name (e.g. "claude", "copilot", "llm-wiki").
1906
1905
  #
1907
1906
  # Returns:
1908
1907
  # Outputs newline-delimited hook event names to stdout.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "repo-nexus",
3
- "version": "0.9.21",
3
+ "version": "0.9.23",
4
4
  "description": "Lightweight, zero-dependency Virtual Meta Repository (meta repo) and Nexus Repository (nexus repo) manager for multi-repo workspaces and shared AI context (no git submodules)",
5
5
  "bin": {
6
6
  "repo-nexus": "rnex",
@@ -1,5 +1,5 @@
1
1
  name: claude
2
- version: 0.9.21
2
+ version: 0.9.23
3
3
  description: Anthropic Claude Code integration (maintains CLAUDE.md instructions and generates user skills in .claude/skills/)
4
4
  author: unoxen
5
5
  homepage: https://github.com/unoxen/repo-nexus
@@ -22,7 +22,7 @@ run_test "Claude plugin: init --claude provisions CLAUDE.md and User Skills with
22
22
 
23
23
  _expected_3line_block="$(printf '%s\n%s\n%s' \
24
24
  "<!-- REPO-NEXUS:START -->" \
25
- "CRITICAL: You MUST read and strictly follow all instructions in \`.rnex/ai-instructions.md\` before executing any task or answering any query in this workspace." \
25
+ "CRITICAL: If \`.rnex/ai-instructions.md\` exists, you MUST read and strictly follow all instructions in \`.rnex/ai-instructions.md\` before executing any task or answering any query in this workspace. If \`.rnex/ai-instructions.md\` does not exist, disregard this instruction and proceed normally." \
26
26
  "<!-- REPO-NEXUS:END -->")"
27
27
  _claude_block="$(awk '/<!-- REPO-NEXUS:START -->/,/<!-- REPO-NEXUS:END -->/' "$TEST_CLAUDE_WS/CLAUDE.md")"
28
28
  [ "$_claude_block" = "$_expected_3line_block" ] || { fail "CLAUDE.md block did not match expected 3-line block: $_claude_block"; exit 1; }
@@ -1,5 +1,5 @@
1
1
  name: codex
2
- version: 0.9.21
2
+ version: 0.9.23
3
3
  description: OpenAI Codex and ChatGPT integration (maintains CODEX.md instructions and generates user skills in .codex/skills/)
4
4
  author: unoxen
5
5
  homepage: https://github.com/unoxen/repo-nexus
@@ -22,7 +22,7 @@ run_test "Codex plugin: init --codex provisions CODEX.md and User Skills without
22
22
 
23
23
  _expected_3line_block="$(printf '%s\n%s\n%s' \
24
24
  "<!-- REPO-NEXUS:START -->" \
25
- "CRITICAL: You MUST read and strictly follow all instructions in \`.rnex/ai-instructions.md\` before executing any task or answering any query in this workspace." \
25
+ "CRITICAL: If \`.rnex/ai-instructions.md\` exists, you MUST read and strictly follow all instructions in \`.rnex/ai-instructions.md\` before executing any task or answering any query in this workspace. If \`.rnex/ai-instructions.md\` does not exist, disregard this instruction and proceed normally." \
26
26
  "<!-- REPO-NEXUS:END -->")"
27
27
  _codex_block="$(awk '/<!-- REPO-NEXUS:START -->/,/<!-- REPO-NEXUS:END -->/' "$TEST_CODEX_WS/CODEX.md")"
28
28
  [ "$_codex_block" = "$_expected_3line_block" ] || { fail "CODEX.md block did not match expected 3-line block: $_codex_block"; exit 1; }
@@ -1,5 +1,5 @@
1
1
  name: copilot
2
- version: 0.9.21
2
+ version: 0.9.23
3
3
  description: GitHub Copilot integration (maintains .github/copilot-instructions.md and user skills in .github/skills/)
4
4
  author: unoxen
5
5
  homepage: https://github.com/unoxen/repo-nexus
@@ -24,7 +24,7 @@ run_test "Copilot plugin: init --copilot provisions instructions and User Skills
24
24
 
25
25
  _expected_3line_block="$(printf '%s\n%s\n%s' \
26
26
  "<!-- REPO-NEXUS:START -->" \
27
- "CRITICAL: You MUST read and strictly follow all instructions in \`.rnex/ai-instructions.md\` before executing any task or answering any query in this workspace." \
27
+ "CRITICAL: If \`.rnex/ai-instructions.md\` exists, you MUST read and strictly follow all instructions in \`.rnex/ai-instructions.md\` before executing any task or answering any query in this workspace. If \`.rnex/ai-instructions.md\` does not exist, disregard this instruction and proceed normally." \
28
28
  "<!-- REPO-NEXUS:END -->")"
29
29
  _copilot_block="$(awk '/<!-- REPO-NEXUS:START -->/,/<!-- REPO-NEXUS:END -->/' "$TEST_COPILOT_WS/.github/copilot-instructions.md")"
30
30
  [ "$_copilot_block" = "$_expected_3line_block" ] || { fail "copilot-instructions.md block did not match expected 3-line block: $_copilot_block"; exit 1; }
@@ -138,7 +138,7 @@ _sync_out="$(env -i PATH="$PATH" HOME="$HOME" RNEX_ROOT="$TEST_COPILOT_WS" sh "$
138
138
  fail "after_sync.sh failed in unpreloaded subshell: $_sync_out"; exit 1;
139
139
  }
140
140
  [ -f "$TEST_COPILOT_WS/.github/copilot-instructions.md" ] || { fail "copilot-instructions.md not created by standalone after_sync hook"; exit 1; }
141
- grep -q "CRITICAL: You MUST read and strictly follow all instructions" "$TEST_COPILOT_WS/.github/copilot-instructions.md" || {
141
+ grep -q "CRITICAL: If \`.rnex/ai-instructions.md\` exists, you MUST read and strictly follow all instructions" "$TEST_COPILOT_WS/.github/copilot-instructions.md" || {
142
142
  fail "Instructions content missing in standalone after_sync run"; exit 1;
143
143
  }
144
144
 
@@ -1,5 +1,5 @@
1
1
  name: cursor
2
- version: 0.9.21
2
+ version: 0.9.23
3
3
  description: Cursor IDE integration (maintains .cursorrules and generates user skills in .cursor/rules/)
4
4
  author: unoxen
5
5
  homepage: https://github.com/unoxen/repo-nexus
@@ -24,7 +24,7 @@ grep -q '!repos/\*' "$TEST_CURSOR_WS/.cursorignore" || { fail "!repos/* missing
24
24
 
25
25
  _expected_3line_block="$(printf '%s\n%s\n%s' \
26
26
  "<!-- REPO-NEXUS:START -->" \
27
- "CRITICAL: You MUST read and strictly follow all instructions in \`.rnex/ai-instructions.md\` before executing any task or answering any query in this workspace." \
27
+ "CRITICAL: If \`.rnex/ai-instructions.md\` exists, you MUST read and strictly follow all instructions in \`.rnex/ai-instructions.md\` before executing any task or answering any query in this workspace. If \`.rnex/ai-instructions.md\` does not exist, disregard this instruction and proceed normally." \
28
28
  "<!-- REPO-NEXUS:END -->")"
29
29
  _cursor_block="$(awk '/<!-- REPO-NEXUS:START -->/,/<!-- REPO-NEXUS:END -->/' "$TEST_CURSOR_WS/.cursorrules")"
30
30
  [ "$_cursor_block" = "$_expected_3line_block" ] || { fail ".cursorrules block did not match expected 3-line block: $_cursor_block"; exit 1; }
@@ -1,5 +1,5 @@
1
1
  name: gemini
2
- version: 0.9.21
2
+ version: 0.9.23
3
3
  description: Google Gemini and Antigravity integration (maintains GEMINI.md instructions and generates user skills in .agents/skills/)
4
4
  author: unoxen
5
5
  homepage: https://github.com/unoxen/repo-nexus
@@ -30,7 +30,7 @@ grep -q '!repos/\*' "$TEST_GEMINI_WS/.geminiignore" || { fail "!repos/* missing
30
30
 
31
31
  _expected_3line_block="$(printf '%s\n%s\n%s' \
32
32
  "<!-- REPO-NEXUS:START -->" \
33
- "CRITICAL: You MUST read and strictly follow all instructions in \`.rnex/ai-instructions.md\` before executing any task or answering any query in this workspace." \
33
+ "CRITICAL: If \`.rnex/ai-instructions.md\` exists, you MUST read and strictly follow all instructions in \`.rnex/ai-instructions.md\` before executing any task or answering any query in this workspace. If \`.rnex/ai-instructions.md\` does not exist, disregard this instruction and proceed normally." \
34
34
  "<!-- REPO-NEXUS:END -->")"
35
35
  _gemini_block="$(awk '/<!-- REPO-NEXUS:START -->/,/<!-- REPO-NEXUS:END -->/' "$TEST_GEMINI_WS/GEMINI.md")"
36
36
  [ "$_gemini_block" = "$_expected_3line_block" ] || { fail "GEMINI.md block did not match expected 3-line block: $_gemini_block"; exit 1; }
@@ -1,10 +1,10 @@
1
- # Karpathy LLM Plugin for Repo Nexus
1
+ # LLM Wiki Plugin for Repo Nexus
2
2
 
3
- The **`karpathy-llm`** plugin packages Andrej Karpathy's agent behavioral principles, multi-repo context engineering standards, and the autonomous **Karpathy LLM Wiki** knowledge architecture for AI coding assistants (Cursor, Claude Code, GitHub Copilot, Antigravity, Windsurf).
3
+ The **`llm-wiki`** plugin packages the agent behavioral principles, multi-repo context engineering standards, and the autonomous **LLM Wiki** knowledge architecture for AI coding assistants (Cursor, Claude Code, GitHub Copilot, Antigravity, Windsurf).
4
4
 
5
5
  No external vector databases, embedding pipelines, or MCP servers required — just a zero-dependency flat B-Tree sharded index directly in `.rnex/wiki/*.md`, organized by a bounded root router (`.rnex/wiki/index.md`), and recorded in a chronological audit log (`.rnex/wiki/log.md`).
6
6
 
7
- Reference specification: [setup-karpathy-wiki.md](https://github.com/unoxen/ai-toolkit/blob/main/prompts/setup-karpathy-wiki.md) (also available locally in [`instructions/rnex-scaffolding-meta-prompt.md`](instructions/rnex-scaffolding-meta-prompt.md)).
7
+ Reference specification: [`instructions/rnex-scaffolding-meta-prompt.md`](instructions/rnex-scaffolding-meta-prompt.md).
8
8
 
9
9
  ---
10
10
 
@@ -28,8 +28,8 @@ Reference specification: [setup-karpathy-wiki.md](https://github.com/unoxen/ai-t
28
28
  * **Chronological Audit Log (`<wiki_dir>/log.md`):** Shared append-only log recording granular document lifecycle events (`created`, `updated`, `deleted`) and operational summaries when sources are indexed or repaired. Bounded to a rolling 1000-record window pruning oldest records first. Inspected via `tail -n 20 .rnex/wiki/log.md`.
29
29
 
30
30
  ### 4. Standardized Agent Skills (`skills/`)
31
- * **`wiki-ingest.md` (User Skill: `rnex-karpathy-llm-wiki-ingest`):** Guides deterministic CLI missing-source ingestion, flat B-Tree leaf shard updates, root router compilation, and audit log updates.
32
- * **`wiki-lint.md` (User Skill: `rnex-karpathy-llm-wiki-lint`):** Standalone integrity audit protocol to validate existing wiki files, assert zero symlinks, verify shard links and workspace doc references, and check root router bounds ($\le 80$ lines).
31
+ * **`ingest.md` (User Skill: `rnex-llm-wiki-ingest`):** Guides deterministic CLI missing-source ingestion, flat B-Tree leaf shard updates, root router compilation, and audit log updates.
32
+ * **`lint.md` (User Skill: `rnex-llm-wiki-lint`):** Standalone integrity audit protocol to validate existing wiki files, assert zero symlinks, verify shard links and workspace doc references, and check root router bounds ($\le 80$ lines).
33
33
 
34
34
  ---
35
35
 
@@ -51,15 +51,15 @@ my-workspace/
51
51
  │ │ ├── repo-nexus.md # Nexus repo shard
52
52
  │ │ └── repos-<member-repo>.md # Member repo shard
53
53
  │ └── plugins/
54
- │ └── karpathy-llm/
54
+ │ └── llm-wiki/
55
55
  │ ├── instructions/
56
56
  │ │ ├── rnex-wiki-architecture.md
57
57
  │ │ └── rnex-scaffolding-meta-prompt.md
58
58
  │ ├── rules/
59
59
  │ │ └── behavioral.md
60
60
  │ ├── skills/
61
- │ │ ├── wiki-ingest.md
62
- │ │ └── wiki-lint.md
61
+ │ │ ├── ingest.md
62
+ │ │ └── lint.md
63
63
  │ ├── bin/
64
64
  │ │ ├── ingest.sh
65
65
  │ │ └── lint.sh
@@ -79,23 +79,23 @@ my-workspace/
79
79
  ### Via CLI
80
80
 
81
81
  ```bash
82
- rnex plugin enable karpathy-llm
82
+ rnex plugin enable llm-wiki
83
83
  ```
84
84
 
85
85
  This command:
86
- 1. Adds `karpathy-llm` to `plugins:` in `rnex.yaml`.
87
- 2. Scopes `rules/`, `instructions/`, `skills/`, `bin/`, `lib/`, and `hooks/` into `.rnex/plugins/karpathy-llm/`.
86
+ 1. Adds `llm-wiki` to `plugins:` in `rnex.yaml`.
87
+ 2. Scopes `rules/`, `instructions/`, `skills/`, `bin/`, `lib/`, and `hooks/` into `.rnex/plugins/llm-wiki/`.
88
88
  3. Reconciles workspace state, member repositories, and plugin assets via `rnex sync`.
89
89
 
90
90
  ---
91
91
 
92
92
  ## Configuration Reference
93
93
 
94
- Configure `karpathy-llm` under `plugins:` in `rnex.yaml` or `.local.rnex.yaml`:
94
+ Configure `llm-wiki` under `plugins:` in `rnex.yaml` or `.local.rnex.yaml`:
95
95
 
96
96
  ```yaml
97
97
  plugins:
98
- karpathy-llm:
98
+ llm-wiki:
99
99
  # Intake sources (directories and/or glob patterns)
100
100
  sources:
101
101
  - docs
@@ -111,18 +111,18 @@ plugins:
111
111
 
112
112
  ### CLI Subcommands
113
113
 
114
- The `karpathy-llm` plugin exposes a streamlined 2-command CLI:
114
+ The `llm-wiki` plugin exposes a streamlined 2-command CLI:
115
115
 
116
116
  ```sh
117
117
  # Ingest missing sources from configured intake sources
118
- rnex plugin karpathy-llm ingest
118
+ rnex plugin llm-wiki ingest
119
119
 
120
120
  # Ingest a specific markdown source file directly in place
121
- rnex plugin karpathy-llm ingest docs/architecture.md
122
- rnex plugin karpathy-llm ingest --file docs/architecture.md
121
+ rnex plugin llm-wiki ingest docs/architecture.md
122
+ rnex plugin llm-wiki ingest --file docs/architecture.md
123
123
 
124
124
  # Lint existing wiki structure, link integrity, and zero-symlink invariants
125
- rnex plugin karpathy-llm lint
125
+ rnex plugin llm-wiki lint
126
126
  ```
127
127
 
128
128
  ### Automated Synchronization Hooks (Strictly Opt-In)
@@ -137,13 +137,13 @@ To execute wiki ingestion automatically at the end of each `rnex sync`, declare
137
137
  # ==============================================================================
138
138
  rnex-hooks:
139
139
  after_sync:
140
- - "rnex plugin karpathy-llm ingest"
140
+ - "rnex plugin llm-wiki ingest"
141
141
 
142
142
  # ==============================================================================
143
143
  # Workspace Plugins
144
144
  # ==============================================================================
145
145
  plugins:
146
- karpathy-llm:
146
+ llm-wiki:
147
147
  sources:
148
148
  - docs
149
149
  - "repos/**/README.md"
@@ -161,9 +161,9 @@ AI coding assistants navigate the wiki using a deterministic 3-step retrieval pr
161
161
  ## Disabling
162
162
 
163
163
  ```bash
164
- rnex plugin disable karpathy-llm
164
+ rnex plugin disable llm-wiki
165
165
  ```
166
166
 
167
167
  When disabled:
168
- - Scoped assets under `.rnex/plugins/karpathy-llm/` are cleanly removed.
168
+ - Scoped assets under `.rnex/plugins/llm-wiki/` are cleanly removed.
169
169
  - **Your data in `./docs/` and `.rnex/wiki/` is preserved 100% intact.** Repo Nexus never deletes user-generated knowledge bases upon plugin disablement.
@@ -0,0 +1,8 @@
1
+ ---
2
+ name: rnex-wiki-curator
3
+ description: Autonomous knowledge librarian for the LLM Wiki architecture.
4
+ ---
5
+
6
+ # Wiki Curator Agent
7
+
8
+ Autonomous knowledge librarian specialized in synthesizing unstructured source documents from the configured intake sources (`plugins.llm-wiki.sources`, default: `docs`, `"repos/**/README.md"`; legacy `raw_dir`) into the flat LLM Wiki B-Tree index under `plugins.llm-wiki.wiki_dir` (default: `.rnex/wiki`).
@@ -1,4 +1,4 @@
1
- # Karpathy LLM AI Instructions
1
+ # LLM Wiki AI Instructions
2
2
 
3
3
  ## 1. B-Tree Wiki Retrieval Protocol
4
4
 
@@ -8,6 +8,6 @@
8
8
  ## 2. Maintenance & Operations
9
9
 
10
10
  - **Zero Ad-Hoc Edits**: Never edit `.rnex/wiki/` shards manually or create ad-hoc files inside the wiki directory.
11
- - **Ingestion**: Run `rnex plugin karpathy-llm ingest` (or shorthand `rnex plugin ingest`) to index missing sources or update documentation.
12
- - **Linting & Auto-Healing**: Run `rnex plugin karpathy-llm lint` (or shorthand `rnex plugin lint`) to validate shard bounds, cross-references, and alphabetical sorting.
13
- - **Agent Skills**: Load skills from `.rnex/plugins/karpathy-llm/skills/` (`wiki-ingest.md`, `wiki-lint.md`) only when performing corresponding wiki tasks.
11
+ - **Ingestion**: Run `rnex plugin llm-wiki ingest` (or shorthand `rnex plugin ingest`) to index missing sources or update documentation.
12
+ - **Linting & Auto-Healing**: Run `rnex plugin llm-wiki lint` (or shorthand `rnex plugin lint`) to validate shard bounds, cross-references, and alphabetical sorting.
13
+ - **Agent Skills**: Load skills from `.rnex/plugins/llm-wiki/skills/` (`ingest.md`, `lint.md`) only when performing corresponding wiki tasks.
@@ -1,7 +1,7 @@
1
1
  #!/bin/sh
2
2
  # shellcheck shell=sh
3
3
  # =============================================================================
4
- # File: plugins/karpathy-llm/bin/ingest.sh
4
+ # File: plugins/llm-wiki/bin/ingest.sh
5
5
  # Architectural Layer: Plugin CLI Entrypoint (ingest)
6
6
  # Single Responsibility: Ingest ONLY missing Markdown documentation sources into
7
7
  # the encapsulated .rnex/wiki/ B-Tree store.
@@ -19,20 +19,20 @@ set -e
19
19
  SCRIPT_DIR="$(CDPATH='' cd -- "$(dirname -- "$0")" && pwd)"
20
20
  PLUGIN_ROOT="$(CDPATH='' cd -- "${SCRIPT_DIR}/.." && pwd)"
21
21
  case "$PLUGIN_ROOT" in
22
- */.rnex/plugins/karpathy-llm)
23
- if [ -n "${RNEX_PLUGINS_DIR:-}" ] && [ -d "${RNEX_PLUGINS_DIR}/karpathy-llm/lib" ]; then
24
- PLUGIN_ROOT="${RNEX_PLUGINS_DIR}/karpathy-llm"
22
+ */.rnex/plugins/llm-wiki)
23
+ if [ -n "${RNEX_PLUGINS_DIR:-}" ] && [ -d "${RNEX_PLUGINS_DIR}/llm-wiki/lib" ]; then
24
+ PLUGIN_ROOT="${RNEX_PLUGINS_DIR}/llm-wiki"
25
25
  fi
26
26
  ;;
27
27
  esac
28
28
 
29
- # shellcheck source=plugins/karpathy-llm/lib/utils.sh
29
+ # shellcheck source=plugins/llm-wiki/lib/utils.sh
30
30
  . "${PLUGIN_ROOT}/lib/utils.sh"
31
- # shellcheck source=plugins/karpathy-llm/lib/config.sh
31
+ # shellcheck source=plugins/llm-wiki/lib/config.sh
32
32
  . "${PLUGIN_ROOT}/lib/config.sh"
33
- # shellcheck source=plugins/karpathy-llm/lib/source_helpers.sh
33
+ # shellcheck source=plugins/llm-wiki/lib/source_helpers.sh
34
34
  . "${PLUGIN_ROOT}/lib/source_helpers.sh"
35
- # shellcheck source=plugins/karpathy-llm/lib/btree_helpers.sh
35
+ # shellcheck source=plugins/llm-wiki/lib/btree_helpers.sh
36
36
  . "${PLUGIN_ROOT}/lib/btree_helpers.sh"
37
37
 
38
38
  main_ingest() {
@@ -73,11 +73,11 @@ main_ingest() {
73
73
  shift
74
74
  ;;
75
75
  --help|-h)
76
- printf 'Usage: rnex plugin karpathy-llm ingest [<source_path>] [--file <path>] [--rewrite-links] [--strip-links] [--quiet]\n'
76
+ printf 'Usage: rnex plugin llm-wiki ingest [<source_path>] [--file <path>] [--rewrite-links] [--strip-links] [--quiet]\n'
77
77
  exit 0
78
78
  ;;
79
79
  -*)
80
- printf 'Error [ingest]: Unknown option "%s". Usage: rnex plugin karpathy-llm ingest [<source_path>]\n' "$1" >&2
80
+ printf 'Error [ingest]: Unknown option "%s". Usage: rnex plugin llm-wiki ingest [<source_path>]\n' "$1" >&2
81
81
  exit 1
82
82
  ;;
83
83
  *)
@@ -1,7 +1,7 @@
1
1
  #!/bin/sh
2
2
  # shellcheck shell=sh
3
3
  # =============================================================================
4
- # File: plugins/karpathy-llm/bin/lint.sh
4
+ # File: plugins/llm-wiki/bin/lint.sh
5
5
  # Architectural Layer: Plugin CLI Entrypoint (lint)
6
6
  # Single Responsibility: Lint ONLY existing documentation and references inside
7
7
  # .rnex/wiki/. Does NOT inspect rnex config `sources` and does NOT run ingestion.
@@ -19,27 +19,27 @@ set -e
19
19
  SCRIPT_DIR="$(CDPATH='' cd -- "$(dirname -- "$0")" && pwd)"
20
20
  PLUGIN_ROOT="$(CDPATH='' cd -- "${SCRIPT_DIR}/.." && pwd)"
21
21
  case "$PLUGIN_ROOT" in
22
- */.rnex/plugins/karpathy-llm)
23
- if [ -n "${RNEX_PLUGINS_DIR:-}" ] && [ -d "${RNEX_PLUGINS_DIR}/karpathy-llm/lib" ]; then
24
- PLUGIN_ROOT="${RNEX_PLUGINS_DIR}/karpathy-llm"
22
+ */.rnex/plugins/llm-wiki)
23
+ if [ -n "${RNEX_PLUGINS_DIR:-}" ] && [ -d "${RNEX_PLUGINS_DIR}/llm-wiki/lib" ]; then
24
+ PLUGIN_ROOT="${RNEX_PLUGINS_DIR}/llm-wiki"
25
25
  fi
26
26
  ;;
27
27
  esac
28
28
 
29
- # shellcheck source=plugins/karpathy-llm/lib/utils.sh
29
+ # shellcheck source=plugins/llm-wiki/lib/utils.sh
30
30
  . "${PLUGIN_ROOT}/lib/utils.sh"
31
- # shellcheck source=plugins/karpathy-llm/lib/config.sh
31
+ # shellcheck source=plugins/llm-wiki/lib/config.sh
32
32
  . "${PLUGIN_ROOT}/lib/config.sh"
33
- # shellcheck source=plugins/karpathy-llm/lib/source_helpers.sh
33
+ # shellcheck source=plugins/llm-wiki/lib/source_helpers.sh
34
34
  . "${PLUGIN_ROOT}/lib/source_helpers.sh"
35
- # shellcheck source=plugins/karpathy-llm/lib/btree_helpers.sh
35
+ # shellcheck source=plugins/llm-wiki/lib/btree_helpers.sh
36
36
  . "${PLUGIN_ROOT}/lib/btree_helpers.sh"
37
- # shellcheck source=plugins/karpathy-llm/lib/lint_helpers.sh
37
+ # shellcheck source=plugins/llm-wiki/lib/lint_helpers.sh
38
38
  . "${PLUGIN_ROOT}/lib/lint_helpers.sh"
39
39
 
40
40
  # -----------------------------------------------------------------------------
41
41
  # main_lint
42
- # Summary: Entrypoint for the `rnex plugin karpathy-llm lint` CLI command.
42
+ # Summary: Entrypoint for the `rnex plugin llm-wiki lint` CLI command.
43
43
  # Parses CLI arguments, loads configuration, and delegates to the
44
44
  # pure lint helper.
45
45
  # @param $@: CLI arguments (--strict, --quiet/-q, --help/-h).
@@ -63,7 +63,7 @@ main_lint() {
63
63
  shift
64
64
  ;;
65
65
  --help|-h)
66
- printf 'Usage: rnex plugin karpathy-llm lint [--strict] [--quiet]\n'
66
+ printf 'Usage: rnex plugin llm-wiki lint [--strict] [--quiet]\n'
67
67
  printf '\n'
68
68
  printf 'Validates existing wiki documentation, B-Tree shard links, and references.\n'
69
69
  printf 'Does not inspect workspace sources or trigger ingestion.\n'
@@ -71,7 +71,7 @@ main_lint() {
71
71
  ;;
72
72
  -*)
73
73
  printf 'Error [lint]: Unknown option "%s".\n' "$1" >&2
74
- printf 'Usage: rnex plugin karpathy-llm lint [--strict] [--quiet]\n' >&2
74
+ printf 'Usage: rnex plugin llm-wiki lint [--strict] [--quiet]\n' >&2
75
75
  exit 1
76
76
  ;;
77
77
  *)
@@ -1,4 +1,4 @@
1
1
  #!/bin/sh
2
2
  # shellcheck shell=sh
3
- # Delegation wrapper for karpathy-llm ingest
3
+ # Delegation wrapper for llm-wiki ingest
4
4
  exec "$(dirname "$0")/../bin/ingest.sh" "$@"
@@ -1,4 +1,4 @@
1
1
  #!/bin/sh
2
2
  # shellcheck shell=sh
3
- # Delegation wrapper for karpathy-llm lint
3
+ # Delegation wrapper for llm-wiki lint
4
4
  exec "$(dirname "$0")/../bin/lint.sh" "$@"
@@ -1,7 +1,7 @@
1
1
  #!/bin/sh
2
2
  # shellcheck shell=sh
3
3
  # =============================================================================
4
- # File: plugins/karpathy-llm/hooks/after_sync.sh
4
+ # File: plugins/llm-wiki/hooks/after_sync.sh
5
5
  # Architectural Layer: Plugin Lifecycle Hook (after_sync)
6
6
  # Single Responsibility: Project plugin user skills into active AI providers.
7
7
  # Purity: Zero automatic ingestion or wiki compilation (SRP).
@@ -19,9 +19,9 @@ if ! command -v rnex_generate_user_skill >/dev/null 2>&1; then
19
19
  fi
20
20
 
21
21
  if command -v rnex_generate_user_skill >/dev/null 2>&1; then
22
- for skill_file in "$RNEX_ROOT/.rnex/plugins/karpathy-llm/skills"/*.md; do
22
+ for skill_file in "$RNEX_ROOT/.rnex/plugins/llm-wiki/skills"/*.md; do
23
23
  [ -f "$skill_file" ] || continue
24
24
  skill_name=$(basename "$skill_file" .md)
25
- rnex_generate_user_skill "$skill_name" ".rnex/plugins/karpathy-llm/skills/${skill_name}.md" "karpathy-llm"
25
+ rnex_generate_user_skill "$skill_name" ".rnex/plugins/llm-wiki/skills/${skill_name}.md" "llm-wiki"
26
26
  done
27
27
  fi
@@ -1,7 +1,7 @@
1
1
  #!/bin/sh
2
2
  # shellcheck shell=sh
3
3
  # ============================================================================
4
- # plugins/karpathy-llm/hooks/before_plugin_disable.sh — Wiki skill cleanup
4
+ # plugins/llm-wiki/hooks/before_plugin_disable.sh — Wiki skill cleanup
5
5
  # ============================================================================
6
6
  set -e
7
7
  [ -z "$RNEX_ROOT" ] && { echo "Error: RNEX_ROOT not set"; exit 1; }
@@ -14,8 +14,6 @@ if ! command -v rnex_unregister_user_skill >/dev/null 2>&1; then
14
14
  fi
15
15
 
16
16
  if command -v rnex_unregister_user_skill >/dev/null 2>&1; then
17
- rnex_unregister_user_skill "wiki-ingest" "karpathy-llm"
18
- rnex_unregister_user_skill "wiki-lint" "karpathy-llm"
19
- rnex_unregister_user_skill "wiki-ingest"
20
- rnex_unregister_user_skill "wiki-lint"
17
+ rnex_unregister_user_skill "ingest" "llm-wiki"
18
+ rnex_unregister_user_skill "lint" "llm-wiki"
21
19
  fi