@narumitw/pi-cbmem 0.0.0 → 0.0.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.
Files changed (2) hide show
  1. package/README.md +30 -39
  2. package/package.json +8 -11
package/README.md CHANGED
@@ -1,27 +1,31 @@
1
1
  # 🧠 pi-cbmem — Codebase Memory Tools for Pi
2
2
 
3
- [![npm: private](https://img.shields.io/badge/npm-private-lightgrey)](#-install) [![Pi extension](https://img.shields.io/badge/Pi-extension-blue)](https://pi.dev) [![License: MIT](https://img.shields.io/badge/license-MIT-green.svg)](./LICENSE)
3
+ [![npm](https://img.shields.io/npm/v/@narumitw/pi-cbmem)](https://www.npmjs.com/package/@narumitw/pi-cbmem) [![Pi extension](https://img.shields.io/badge/Pi-extension-blue)](https://pi.dev) [![License: MIT](https://img.shields.io/badge/license-MIT-green.svg)](./LICENSE)
4
4
 
5
- pi-cbmem is a private package that bundles the local Codebase Memory extension and its knowledge-graph operating skill.
5
+ Connect Pi to the local Codebase Memory CLI and give the model graph-first operating guidance.
6
6
 
7
7
  ## ✨ Features
8
8
 
9
- - Registers all 15 Codebase Memory graph, search, indexing, coverage, trace, and architecture tools.
10
- - Invokes the local `codebase-memory-mcp` CLI with cancellation, failure reporting, and bounded output.
11
- - Bundles the `codebase-memory` skill for evidence-tier and graph-first workflows.
12
- - Keeps the extension and skill available through one package declaration.
9
+ - Registers 15 Codebase Memory tools for graph queries, search, indexing, coverage, tracing, and architecture.
10
+ - Runs the local `codebase-memory-mcp` CLI with cancellation, failure reporting, and bounded output.
11
+ - Bundles the `codebase-memory` skill for graph-first, evidence-tier workflows.
12
+ - Loads the extension and skill from one package.
13
13
 
14
14
  ## 📦 Install
15
15
 
16
- This package is private and is not published to npm.
16
+ Install persistently from npm:
17
17
 
18
- Install it from this repository checkout:
18
+ ```bash
19
+ pi install npm:@narumitw/pi-cbmem
20
+ ```
21
+
22
+ Try from npm without installing permanently:
19
23
 
20
24
  ```bash
21
- pi install ./packages/pi-cbmem
25
+ pi -e npm:@narumitw/pi-cbmem
22
26
  ```
23
27
 
24
- Build and try it without adding a persistent package setting:
28
+ Build and load a local checkout from the repository root:
25
29
 
26
30
  ```bash
27
31
  npm --workspace @narumitw/pi-cbmem run build
@@ -31,14 +35,12 @@ pi --no-extensions -e ./packages/pi-cbmem
31
35
  The package declares `dist/index.ts`, so an unbuilt local checkout must run the build before Pi loads the package directory.
32
36
 
33
37
  Pi extensions run with your user permissions.
34
-
35
- Review the source before loading the package.
38
+ Install only trusted packages, and review the source before loading this extension.
36
39
 
37
40
  ## 🚀 Quick start
38
41
 
39
- Install `codebase-memory-mcp` at `~/.local/bin/codebase-memory-mcp`, load the package, and ask Pi a structural codebase question.
40
-
41
- The bundled skill tells Pi to check the active graph project before exploration and to verify material claims with graph snippets and index-coverage evidence.
42
+ Install `codebase-memory-mcp` at `~/.local/bin/codebase-memory-mcp`, load pi-cbmem, and ask Pi a structural codebase question.
43
+ The bundled skill directs Pi to identify the active graph project before exploration and verify material claims with snippets and index-coverage evidence.
42
44
 
43
45
  ## 🛠️ Tools
44
46
 
@@ -60,37 +62,26 @@ The extension registers these tools:
60
62
  - `manage_adr`
61
63
  - `ingest_traces`
62
64
 
63
- Each tool sends JSON arguments to `codebase-memory-mcp cli <tool>` over standard input and returns the last JSON response written to standard output.
64
-
65
- Validated JSON output over 2,000 lines is truncated with an explicit omission notice.
66
-
67
- Standard output over 50 KB fails safely because the complete JSON response cannot be validated within the bounded capture.
68
-
69
- Spawn failures, nonzero exits, oversized output, and missing JSON responses are reported as failed tool calls.
65
+ Each tool sends JSON arguments to `codebase-memory-mcp cli <tool>` over standard input and returns the final JSON response from standard output.
66
+ Validated JSON longer than 2,000 lines is truncated with an omission notice.
67
+ Standard output over 50 KB fails because the extension cannot validate a complete JSON response within its capture limit.
68
+ Spawn failures, nonzero exits, oversized output, and missing JSON responses fail the tool call.
70
69
 
71
70
  ## 🔒 Security and privacy
72
71
 
73
- The Codebase Memory binary runs with the Pi process environment and user permissions.
74
-
72
+ The Codebase Memory binary inherits the Pi process environment and user permissions.
75
73
  Tool calls can read and index repositories, inspect source, persist graph data, manage architecture decisions and traces, or delete indexed projects.
76
-
77
- Deleting a project or replacing its Architecture Decision Records requires explicit confirmation in TUI or RPC mode and is rejected in non-interactive modes.
78
-
74
+ Deleting a project or replacing all Architecture Decision Records requires explicit confirmation in TUI or RPC mode and is rejected in other modes.
79
75
  Repository content returned by graph tools can be sent to the selected model provider as tool output.
80
-
81
- Terminal controls are removed only from the TUI rendering boundary; the validated raw result remains available to the model.
82
-
83
- The extension starts one local CLI child process per tool call in the active session directory and does not start background work during extension factory load.
84
-
85
- Cancelling a tool call terminates its child process.
76
+ Terminal controls are removed at the TUI display boundary, while the validated raw result remains available to the model.
77
+ Each tool call starts one local CLI child process in the active session directory; extension loading starts no background work.
78
+ Cancelling the tool call terminates that child process.
86
79
 
87
80
  ## 🚧 Limitations
88
81
 
89
- The package expects the binary at `~/.local/bin/codebase-memory-mcp` for the current user.
90
-
91
- It does not install or update the Codebase Memory binary.
92
-
93
- The extension exposes static tool schemas that match the bundled Codebase Memory skill and delegates final argument validation to the installed CLI.
82
+ - The package requires `~/.local/bin/codebase-memory-mcp` for the current user.
83
+ - It does not install or update the Codebase Memory binary.
84
+ - Static tool schemas match the bundled skill, while the installed CLI performs final argument validation.
94
85
 
95
86
  ## 🗂️ Package layout
96
87
 
@@ -109,7 +100,7 @@ packages/pi-cbmem/
109
100
  ├── test/
110
101
  │ ├── build-runtime.test.ts # Generated-runtime and Jiti loader coverage
111
102
  │ └── cbmem.test.ts # Tool registration coverage
112
- ├── package.json # Private Pi extension and skill declarations
103
+ ├── package.json # Pi extension and skill declarations
113
104
  ├── tsconfig.json
114
105
  ├── README.md
115
106
  └── LICENSE
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@narumitw/pi-cbmem",
3
- "version": "0.0.0",
4
- "description": "Private Pi package for Codebase Memory knowledge graph tools and guidance.",
3
+ "version": "0.0.1",
4
+ "description": "Pi extension package for Codebase Memory knowledge graph tools and guidance.",
5
5
  "type": "module",
6
6
  "license": "MIT",
7
7
  "private": false,
@@ -28,9 +28,6 @@
28
28
  "./skills"
29
29
  ]
30
30
  },
31
- "piExtension": {
32
- "lifecycle": "stable"
33
- },
34
31
  "scripts": {
35
32
  "build": "node scripts/build-runtime.mjs",
36
33
  "check": "npm run build && biome check . && npm run typecheck",
@@ -45,13 +42,13 @@
45
42
  "typebox": "*"
46
43
  },
47
44
  "devDependencies": {
48
- "@biomejs/biome": "2.5.10",
49
- "@earendil-works/pi-ai": "0.84.3",
50
- "@earendil-works/pi-coding-agent": "0.84.3",
51
- "@earendil-works/pi-tui": "0.84.3",
52
- "@types/node": "26.2.0",
45
+ "@biomejs/biome": "2.5.11",
46
+ "@earendil-works/pi-ai": "0.84.4",
47
+ "@earendil-works/pi-coding-agent": "0.84.4",
48
+ "@earendil-works/pi-tui": "0.84.4",
49
+ "@types/node": "26.4.0",
53
50
  "esbuild": "0.28.2",
54
- "typebox": "1.3.18",
51
+ "typebox": "1.3.20",
55
52
  "typescript": "7.0.2"
56
53
  },
57
54
  "dependencies": {