repo-nexus 0.4.3 → 0.4.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "repo-nexus",
3
- "version": "0.4.3",
3
+ "version": "0.4.4",
4
4
  "description": "Lightweight, zero-dependency Virtual Meta-Repo companion for multi-repo workspaces and shared AI context (no git submodules)",
5
5
  "bin": {
6
6
  "repo-nexus": "rnex",
@@ -32,37 +32,22 @@ Reference specification: [setup-karpathy-wiki.md](https://github.com/nu-nenoi/ai
32
32
 
33
33
  ---
34
34
 
35
- ## Step 0 — Configuration Interview
36
-
37
- When an AI agent or developer sets up the Karpathy LLM Wiki in a repository or workspace, consult the Step 0 configuration questions:
38
-
39
- 1. **[Q1] Which AI agent instruction file should the wiki rules be written to?**
40
- - In a **Repo Nexus workspace**: Instructions are scoped under `.rnex/plugins/karpathy-llm/` (`rules/behavioral.md` and `instructions/wiki-architecture.md`). Agents read `rnex.yaml` to detect enabled plugins and route context automatically.
41
- - In a **standalone setup** (outside Repo Nexus):
42
- - `AGENTS.md` (universal, works across most harnesses)
43
- - `CLAUDE.md` (Claude Code / Anthropic)
44
- - `.cursor/rules/wiki.mdc` (Cursor)
45
- - `.github/copilot-instructions.md` (GitHub Copilot)
46
- - `GEMINI.md` (Google Gemini / Antigravity)
47
- - `.windsurfrules` (Windsurf)
48
- - Other — specify path
49
- *Append the `## Karpathy Wiki Rules` section to that file while preserving all existing content.*
50
-
51
- 2. **[Q2] What is this wiki for?**
52
- - Research / reading list — articles, papers, PDFs on a topic
53
- - Personal second brain — meetings, notes, business context, personal projects
54
- - Content archive — transcripts, podcast notes, newsletters
55
- - Codebase knowledge — architecture decisions, runbooks, team conventions
56
- - Other (describe briefly)
57
-
58
- 3. **[Q3] How should the wiki be organized?**
59
- - **Flat** — all pages at the top level of `/wiki/` (simpler, good default)
60
- - **Structured** — subfolders by category, chosen based on Q2:
61
- - Research → `concepts/`, `people/`, `organizations/`, `sources/`, `analysis/`
62
- - Second brain → `projects/`, `people/`, `decisions/`, `logs/`
63
- - Content archive → `sources/`, `people/`, `tools/`, `concepts/`
64
- - Codebase → `architecture/`, `decisions/`, `runbooks/`, `people/`
65
- - **Agent decides** — infer structure from the first batch of ingested content
35
+ ## Deterministic Lifecycle: Initialization vs. Evolutionary Growth
36
+
37
+ To ensure workspaces remain 100% predictable, understandable, and consistent across all tools, the Karpathy LLM Wiki follows a strict two-phase lifecycle:
38
+
39
+ ### Phase 1: 100% Deterministic Initialization
40
+ Enabling the plugin (`rnex plugin enable karpathy-llm`) performs an exact, zero-interview scaffolding step:
41
+ * **Predictable Baseline**: Fixed standard files are created (`raw/.gitkeep`, `wiki/index.md`, `wiki/hot.md`, `wiki/_log.md`).
42
+ * **Scoped Assets**: Behavioral rules, wiki architecture guides, workflows, and templates are cleanly isolated under `.rnex/plugins/karpathy-llm/`.
43
+ * **Zero Guesswork**: No interactive interviews, no AI-generated folder variances, and no "agent decides" ambiguities at init time.
44
+ * **Idempotent**: Safe to run repeatedly; existing user files are never overwritten.
45
+
46
+ ### Phase 2: Evolutionary Growth & Domain Specialization (Usage Phase)
47
+ Once initialized, the workspace structure organically evolves according to actual domain needs and source materials:
48
+ * **Source Ingestion (`wiki-ingest`)**: As raw source documents are deposited into `/raw/` and ingested, atomic pages are generated. Users or agents can organize pages into categorical subfolders (e.g. `architecture/`, `decisions/`, `concepts/`, `projects/`) or keep them flat.
49
+ * **Customizable Guidelines**: Teams can tailor `rules/behavioral.md` and `instructions/wiki-architecture.md` for their specific team conventions.
50
+ * **Graph Maintenance (`wiki-lint`)**: The periodic lint workflow validates relation paths, updates `mentioned_in`, and rebuilds `index.md` and `hot.md` to match the evolved knowledge graph.
66
51
 
67
52
  ---
68
53
 
@@ -12,54 +12,23 @@ Do not hard-code any specific AI tool or harness into the wiki structure itself.
12
12
 
13
13
  ---
14
14
 
15
- ### Step 0 — Configuration (ask before creating any files)
16
-
17
- Ask ALL of the following questions and wait for answers:
18
-
19
- [Q1] Which AI agent instruction file should the wiki rules be written to?
20
- - In a Repo Nexus workspace: plugin instructions are maintained under `.rnex/plugins/karpathy-llm/` (`rules/behavioral.md` and `instructions/wiki-architecture.md`). Agents read `rnex.yaml` to detect enabled plugins and read their scoped files.
21
- - In a standalone setup (outside Repo Nexus):
22
- - `AGENTS.md` (universal, works across most harnesses)
23
- - `CLAUDE.md` (Claude Code / Anthropic)
24
- - `.cursor/rules/wiki.mdc` (Cursor)
25
- - `.github/copilot-instructions.md` (GitHub Copilot)
26
- - `GEMINI.md` (Google Gemini / Antigravity)
27
- - `.windsurfrules` (Windsurf)
28
- - Other — specify path
29
- Append a `## Karpathy Wiki Rules` section to that file. Preserve all existing content.
30
-
31
- [Q2] What is this wiki for?
32
- - Research / reading list — articles, papers, PDFs on a topic
33
- - Personal second brain — meetings, notes, business context, personal projects
34
- - Content archive — transcripts, podcast notes, newsletters
35
- - Codebase knowledge — architecture decisions, runbooks, team conventions
36
- - Other (describe briefly)
37
-
38
- [Q3] How should the wiki be organized?
39
- - Flat — all pages at the top level of `/wiki/` (simpler, good default)
40
- - Structured — subfolders by category, chosen based on Q2 answer
41
- - Agent decides — infer structure from the first batch of ingested content
15
+ ### 1. Deterministic Scaffolding (Create Immediately)
42
16
 
43
- ---
44
-
45
- ### 1. Directories and Files
17
+ Initialize the fixed baseline directories and control files:
46
18
 
47
- **`/raw/`** — Append-only intake directory. All original source material goes here unmodified. Add `.gitkeep`.
19
+ - **`/raw/`** — Append-only intake directory. Add `.gitkeep`. All original source material goes here unmodified.
20
+ - **`/wiki/index.md`** — Master navigation index organizing links to atomic pages.
21
+ - **`/wiki/hot.md`** — Rolling ~500-word orientation cache for quick agent onboarding.
22
+ - **`/wiki/_log.md`** — Append-only operation log recording all ingest and lint runs.
48
23
 
49
- **`/wiki/`** — Curated knowledge base of atomic markdown pages. Structure per Q3:
50
- - Flat: all pages directly in `/wiki/`
51
- - Structured: subfolders matching the project type from Q2:
52
- - Research → `concepts/`, `people/`, `organizations/`, `sources/`, `analysis/`
53
- - Second brain → `projects/`, `people/`, `decisions/`, `logs/`
54
- - Content archive → `sources/`, `people/`, `tools/`, `concepts/`
55
- - Codebase → `architecture/`, `decisions/`, `runbooks/`, `people/`
24
+ Do not create arbitrary or speculative subdirectories during initialization. Scaffolding is 100% deterministic. Domain subfolders and categories emerge organically during the source ingestion phase (`wiki-ingest`).
56
25
 
57
- **`/wiki/index.md`** — Master navigation index. Contains:
58
- - Categorized links to every wiki page. Auto-maintained after every ingest and lint run.
26
+ ---
59
27
 
60
- **`/wiki/_log.md`** — Append-only operation log. Every ingest and lint run appends a timestamped entry.
28
+ ### 2. Agent Rules & Routing
61
29
 
62
- **`/wiki/hot.md`** *(create only for second brain or codebase wiki)* — Rolling ~500-word cache of the most recently relevant context. Lets an agent orient without reading the full wiki.
30
+ - **Repo Nexus Workspaces**: Scoped under `.rnex/plugins/karpathy-llm/` (`rules/behavioral.md` and `instructions/wiki-architecture.md`). Agents route through `rnex.yaml` automatically.
31
+ - **Standalone Repositories**: Append the `## Karpathy Wiki Rules` section (see Section 4) to the primary AI instructions file (`AGENTS.md`, `CLAUDE.md`, `.cursorrules`, etc.), preserving all existing content.
63
32
 
64
33
  ---
65
34
 
@@ -104,9 +73,9 @@ The relation graph lives in frontmatter, not in prose links. Agents traverse the
104
73
 
105
74
  ---
106
75
 
107
- ### 4. Agent Instructions
76
+ ### 4. Agent Instructions (Standalone Repositories)
108
77
 
109
- In the file chosen in Q1, append:
78
+ In standalone repositories (outside Repo Nexus), append:
110
79
 
111
80
  ```markdown
112
81
  ## Karpathy Wiki Rules