@cad0p/pi-napkin 0.5.0 → 0.6.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.
|
@@ -58,12 +58,23 @@ function getOverview(n: Napkin): string | null {
|
|
|
58
58
|
if (overview.overview && overview.overview.length > 0) {
|
|
59
59
|
text += "\n\n";
|
|
60
60
|
for (const folder of overview.overview) {
|
|
61
|
-
|
|
61
|
+
const collapsed = folder.collapsedFolders
|
|
62
|
+
? ` (+${folder.collapsedFolders} similar subfolders)`
|
|
63
|
+
: "";
|
|
64
|
+
// The SDK reports the vault root as "/"; the CLI renders it as
|
|
65
|
+
// "./". Mirror that here — "//" looked like a broken path.
|
|
66
|
+
const path = folder.path === "/" ? "." : folder.path;
|
|
67
|
+
text += `${path}/${collapsed}\n`;
|
|
62
68
|
if (folder.keywords && folder.keywords.length > 0) {
|
|
63
69
|
text += ` keywords: ${folder.keywords.join(", ")}\n`;
|
|
64
70
|
}
|
|
65
71
|
text += ` notes: ${folder.notes}\n`;
|
|
66
72
|
}
|
|
73
|
+
if (overview.truncated) {
|
|
74
|
+
// maxRows cap in the SDK dropped the tail of the sorted listing;
|
|
75
|
+
// tell the agent the vault is bigger than what's shown.
|
|
76
|
+
text += `\n… ${overview.truncated.rows} more folders (${overview.truncated.notes} notes) — use kb_search to find specific content\n`;
|
|
77
|
+
}
|
|
67
78
|
}
|
|
68
79
|
return text.trim() || null;
|
|
69
80
|
} catch {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cad0p/pi-napkin",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.6.0",
|
|
4
4
|
"description": "📜 Napkin integration for pi — vault context, knowledge tools, and automatic distillation with git-worktree concurrency safety",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"publishConfig": {
|
|
@@ -64,7 +64,7 @@
|
|
|
64
64
|
"vitest": "^2.1.0"
|
|
65
65
|
},
|
|
66
66
|
"dependencies": {
|
|
67
|
-
"@cad0p/napkin": "^0.
|
|
67
|
+
"@cad0p/napkin": "^0.12.0"
|
|
68
68
|
},
|
|
69
69
|
"peerDependencies": {
|
|
70
70
|
"@earendil-works/pi-coding-agent": ">=0.74.0",
|