total-recall-brain 3.47.0 → 3.47.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 (65) hide show
  1. package/bin/total-recall.mjs +5 -0
  2. package/package.json +1 -1
  3. package/scaffold/.agent/skills/total-recall/plugins/auth/package-lock.json +4 -4
  4. package/scaffold/.agent/skills/total-recall/plugins/auth/package.json +3 -2
  5. package/scaffold/.agent/skills/total-recall/plugins/auth/plugin.json +30 -5
  6. package/scaffold/.agent/skills/total-recall/plugins/auth/skills/auth/SKILL.md +35 -0
  7. package/scaffold/.agent/skills/total-recall/plugins/auth/ui/home.js +494 -79
  8. package/scaffold/.agent/skills/total-recall/plugins/automations/package-lock.json +4 -4
  9. package/scaffold/.agent/skills/total-recall/plugins/automations/package.json +3 -2
  10. package/scaffold/.agent/skills/total-recall/plugins/automations/plugin.json +33 -8
  11. package/scaffold/.agent/skills/total-recall/plugins/automations/skills/automations/SKILL.md +29 -0
  12. package/scaffold/.agent/skills/total-recall/plugins/automations/ui/chunks/dream-consolidation.md +17 -0
  13. package/scaffold/.agent/skills/total-recall/plugins/code-quality/package-lock.json +4 -4
  14. package/scaffold/.agent/skills/total-recall/plugins/code-quality/package.json +3 -2
  15. package/scaffold/.agent/skills/total-recall/plugins/code-quality/plugin.json +31 -4
  16. package/scaffold/.agent/skills/total-recall/plugins/code-quality/skills/code-quality/SKILL.md +27 -0
  17. package/scaffold/.agent/skills/total-recall/plugins/composable-cli/package-lock.json +4 -4
  18. package/scaffold/.agent/skills/total-recall/plugins/composable-cli/package.json +1 -1
  19. package/scaffold/.agent/skills/total-recall/plugins/composable-cli/plugin.json +17 -3
  20. package/scaffold/.agent/skills/total-recall/plugins/embeddings/package-lock.json +4 -4
  21. package/scaffold/.agent/skills/total-recall/plugins/embeddings/package.json +3 -2
  22. package/scaffold/.agent/skills/total-recall/plugins/embeddings/plugin.json +24 -4
  23. package/scaffold/.agent/skills/total-recall/plugins/embeddings/skills/embeddings/SKILL.md +25 -0
  24. package/scaffold/.agent/skills/total-recall/plugins/git/package-lock.json +4 -4
  25. package/scaffold/.agent/skills/total-recall/plugins/git/package.json +3 -2
  26. package/scaffold/.agent/skills/total-recall/plugins/git/plugin.json +293 -58
  27. package/scaffold/.agent/skills/total-recall/plugins/git/skills/git/SKILL.md +36 -0
  28. package/scaffold/.agent/skills/total-recall/plugins/mesh/package-lock.json +4 -4
  29. package/scaffold/.agent/skills/total-recall/plugins/mesh/package.json +3 -2
  30. package/scaffold/.agent/skills/total-recall/plugins/mesh/plugin.json +47 -14
  31. package/scaffold/.agent/skills/total-recall/plugins/mesh/skills/mesh/SKILL.md +36 -0
  32. package/scaffold/.agent/skills/total-recall/plugins/meta-harness/cli.mjs +6 -3
  33. package/scaffold/.agent/skills/total-recall/plugins/meta-harness/package.json +1 -1
  34. package/scaffold/.agent/skills/total-recall/plugins/meta-harness/plugin.json +5 -2
  35. package/scaffold/.agent/skills/total-recall/plugins/meta-harness/src/cascade.mjs +4 -2
  36. package/scaffold/.agent/skills/total-recall/plugins/meta-harness/src/coordinator.mjs +28 -9
  37. package/scaffold/.agent/skills/total-recall/plugins/meta-harness/src/dispatch.mjs +7 -1
  38. package/scaffold/.agent/skills/total-recall/plugins/meta-harness/src/model-selection.mjs +59 -0
  39. package/scaffold/.agent/skills/total-recall/plugins/meta-harness/src/remote-operation.mjs +3 -3
  40. package/scaffold/.agent/skills/total-recall/plugins/meta-harness/src/router.mjs +9 -3
  41. package/scaffold/.agent/skills/total-recall/plugins/meta-harness/src/worker.mjs +50 -6
  42. package/scaffold/.agent/skills/total-recall/plugins/meta-harness/ui/chunks/session-controls.md +16 -0
  43. package/scaffold/.agent/skills/total-recall/plugins/openwiki/cli.mjs +56 -7
  44. package/scaffold/.agent/skills/total-recall/plugins/openwiki/package-lock.json +6 -6
  45. package/scaffold/.agent/skills/total-recall/plugins/openwiki/package.json +3 -2
  46. package/scaffold/.agent/skills/total-recall/plugins/openwiki/plugin.json +199 -36
  47. package/scaffold/.agent/skills/total-recall/plugins/openwiki/skills/openwiki/SKILL.md +32 -0
  48. package/scaffold/.agent/skills/total-recall/plugins/openwiki/src/config.mjs +34 -8
  49. package/scaffold/.agent/skills/total-recall/plugins/openwiki/src/generate.mjs +6 -0
  50. package/scaffold/.agent/skills/total-recall/plugins/openwiki/src/refresh.mjs +15 -7
  51. package/scaffold/.agent/skills/total-recall/plugins/openwiki/src/upstream-watcher.mjs +4 -3
  52. package/scaffold/.agent/skills/total-recall/plugins/security/package-lock.json +4 -4
  53. package/scaffold/.agent/skills/total-recall/plugins/security/package.json +1 -1
  54. package/scaffold/.agent/skills/total-recall/plugins/security/plugin.json +22 -5
  55. package/scaffold/.agent/skills/total-recall/plugins/ssss/package.json +3 -2
  56. package/scaffold/.agent/skills/total-recall/plugins/ssss/plugin.json +169 -37
  57. package/scaffold/.agent/skills/total-recall/plugins/ssss/skills/ssss/SKILL.md +30 -0
  58. package/src/cli/plugin/create.mjs +2 -1
  59. package/src/cli/plugin/monetization.mjs +66 -32
  60. package/src/cli/plugin/search.mjs +25 -3
  61. package/src/cli/preflight.mjs +40 -6
  62. package/src/core/gate-mode.mjs +13 -24
  63. package/src/core/plugin-distribution.mjs +35 -1
  64. package/src/core/preflight-gate.mjs +28 -8
  65. package/src/core/preflight-receipt.mjs +11 -0
@@ -2,7 +2,7 @@
2
2
  "$schema": "https://github.com/gregiteen/total-recall/blob/main/metadata.plugin.schema.json",
3
3
  "id": "openwiki",
4
4
  "name": "OpenWiki",
5
- "version": "0.3.0",
5
+ "version": "0.4.1",
6
6
  "description": "Multi-repo knowledge graph and documentation wiki engine for Total Recall.",
7
7
  "license": "MIT",
8
8
  "runtime": {
@@ -72,7 +72,11 @@
72
72
  ]
73
73
  },
74
74
  "gate": {
75
- "tasks": ["Search or read a repository's wiki", "Generate or refresh wiki pages", "Ingest documentation into memory"],
75
+ "tasks": [
76
+ "Search or read a repository's wiki",
77
+ "Generate or refresh wiki pages",
78
+ "Ingest documentation into memory"
79
+ ],
76
80
  "owned_commands": []
77
81
  },
78
82
  "cli": {
@@ -85,8 +89,19 @@
85
89
  "effect": "read",
86
90
  "output": "json",
87
91
  "args": [
88
- { "name": "task", "label": "Task description", "type": "string", "positional": true, "required": true },
89
- { "name": "json", "label": "JSON output", "type": "boolean", "flag": "--json" }
92
+ {
93
+ "name": "task",
94
+ "label": "Task description",
95
+ "type": "string",
96
+ "positional": true,
97
+ "required": true
98
+ },
99
+ {
100
+ "name": "json",
101
+ "label": "JSON output",
102
+ "type": "boolean",
103
+ "flag": "--json"
104
+ }
90
105
  ]
91
106
  },
92
107
  {
@@ -95,11 +110,37 @@
95
110
  "effect": "read",
96
111
  "output": "json",
97
112
  "args": [
98
- { "name": "query", "label": "Search terms", "type": "string", "positional": true, "required": true },
99
- { "name": "allVaults", "label": "Search all registered vaults", "type": "boolean", "flag": "--all-vaults" },
100
- { "name": "node", "label": "Mesh node", "type": "string", "flag": "--node" },
101
- { "name": "limit", "label": "Maximum results", "type": "number", "flag": "--limit" },
102
- { "name": "json", "label": "JSON output", "type": "boolean", "flag": "--json" }
113
+ {
114
+ "name": "query",
115
+ "label": "Search terms",
116
+ "type": "string",
117
+ "positional": true,
118
+ "required": true
119
+ },
120
+ {
121
+ "name": "allVaults",
122
+ "label": "Search all registered vaults",
123
+ "type": "boolean",
124
+ "flag": "--all-vaults"
125
+ },
126
+ {
127
+ "name": "node",
128
+ "label": "Mesh node",
129
+ "type": "string",
130
+ "flag": "--node"
131
+ },
132
+ {
133
+ "name": "limit",
134
+ "label": "Maximum results",
135
+ "type": "number",
136
+ "flag": "--limit"
137
+ },
138
+ {
139
+ "name": "json",
140
+ "label": "JSON output",
141
+ "type": "boolean",
142
+ "flag": "--json"
143
+ }
103
144
  ]
104
145
  },
105
146
  {
@@ -108,10 +149,35 @@
108
149
  "effect": "read",
109
150
  "output": "json",
110
151
  "args": [
111
- { "name": "allVaults", "label": "Inspect all registered vaults", "type": "boolean", "flag": "--all-vaults" },
112
- { "name": "node", "label": "Mesh node", "type": "string", "flag": "--node" },
113
- { "name": "format", "label": "Graph format", "type": "choice", "options": ["json", "mermaid", "dot"], "flag": "--format" },
114
- { "name": "json", "label": "JSON output", "type": "boolean", "flag": "--json" }
152
+ {
153
+ "name": "allVaults",
154
+ "label": "Inspect all registered vaults",
155
+ "type": "boolean",
156
+ "flag": "--all-vaults"
157
+ },
158
+ {
159
+ "name": "node",
160
+ "label": "Mesh node",
161
+ "type": "string",
162
+ "flag": "--node"
163
+ },
164
+ {
165
+ "name": "format",
166
+ "label": "Graph format",
167
+ "type": "choice",
168
+ "options": [
169
+ "json",
170
+ "mermaid",
171
+ "dot"
172
+ ],
173
+ "flag": "--format"
174
+ },
175
+ {
176
+ "name": "json",
177
+ "label": "JSON output",
178
+ "type": "boolean",
179
+ "flag": "--json"
180
+ }
115
181
  ]
116
182
  },
117
183
  {
@@ -121,11 +187,36 @@
121
187
  "output": "json",
122
188
  "timeout_ms": 600000,
123
189
  "args": [
124
- { "name": "repo", "label": "Registered repository", "type": "string", "flag": "--repo" },
125
- { "name": "node", "label": "Mesh node", "type": "string", "flag": "--node" },
126
- { "name": "force", "label": "Regenerate existing pages", "type": "boolean", "flag": "--force" },
127
- { "name": "dryRun", "label": "Describe generation without writing", "type": "boolean", "flag": "--dry-run" },
128
- { "name": "json", "label": "JSON output", "type": "boolean", "flag": "--json" }
190
+ {
191
+ "name": "repo",
192
+ "label": "Registered repository",
193
+ "type": "string",
194
+ "flag": "--repo"
195
+ },
196
+ {
197
+ "name": "node",
198
+ "label": "Mesh node",
199
+ "type": "string",
200
+ "flag": "--node"
201
+ },
202
+ {
203
+ "name": "force",
204
+ "label": "Regenerate existing pages",
205
+ "type": "boolean",
206
+ "flag": "--force"
207
+ },
208
+ {
209
+ "name": "dryRun",
210
+ "label": "Describe generation without writing",
211
+ "type": "boolean",
212
+ "flag": "--dry-run"
213
+ },
214
+ {
215
+ "name": "json",
216
+ "label": "JSON output",
217
+ "type": "boolean",
218
+ "flag": "--json"
219
+ }
129
220
  ]
130
221
  },
131
222
  {
@@ -134,11 +225,44 @@
134
225
  "effect": "write",
135
226
  "output": "json",
136
227
  "args": [
137
- { "name": "action", "label": "Credential action", "type": "choice", "options": ["status", "set"], "positional": true },
138
- { "name": "provider", "label": "Credential provider", "type": "choice", "options": ["openrouter", "google"], "positional": true },
139
- { "name": "value", "label": "Secret value through stdin", "type": "string", "secret": true },
140
- { "name": "stdin", "label": "Read secret from stdin", "type": "boolean", "flag": "--stdin" },
141
- { "name": "json", "label": "JSON output", "type": "boolean", "flag": "--json" }
228
+ {
229
+ "name": "action",
230
+ "label": "Credential action",
231
+ "type": "choice",
232
+ "options": [
233
+ "status",
234
+ "set"
235
+ ],
236
+ "positional": true
237
+ },
238
+ {
239
+ "name": "provider",
240
+ "label": "Credential provider",
241
+ "type": "choice",
242
+ "options": [
243
+ "openrouter",
244
+ "google"
245
+ ],
246
+ "positional": true
247
+ },
248
+ {
249
+ "name": "value",
250
+ "label": "Secret value through stdin",
251
+ "type": "string",
252
+ "secret": true
253
+ },
254
+ {
255
+ "name": "stdin",
256
+ "label": "Read secret from stdin",
257
+ "type": "boolean",
258
+ "flag": "--stdin"
259
+ },
260
+ {
261
+ "name": "json",
262
+ "label": "JSON output",
263
+ "type": "boolean",
264
+ "flag": "--json"
265
+ }
142
266
  ]
143
267
  },
144
268
  {
@@ -147,9 +271,24 @@
147
271
  "effect": "read",
148
272
  "output": "json",
149
273
  "args": [
150
- { "name": "allVaults", "label": "Inspect all registered vaults", "type": "boolean", "flag": "--all-vaults" },
151
- { "name": "node", "label": "Mesh node", "type": "string", "flag": "--node" },
152
- { "name": "json", "label": "JSON output", "type": "boolean", "flag": "--json" }
274
+ {
275
+ "name": "allVaults",
276
+ "label": "Inspect all registered vaults",
277
+ "type": "boolean",
278
+ "flag": "--all-vaults"
279
+ },
280
+ {
281
+ "name": "node",
282
+ "label": "Mesh node",
283
+ "type": "string",
284
+ "flag": "--node"
285
+ },
286
+ {
287
+ "name": "json",
288
+ "label": "JSON output",
289
+ "type": "boolean",
290
+ "flag": "--json"
291
+ }
153
292
  ]
154
293
  },
155
294
  {
@@ -269,7 +408,7 @@
269
408
  },
270
409
  {
271
410
  "name": "refresh",
272
- "description": "Report which registered projects' generated OpenWiki pages are stale; --apply regenerates them (openwiki/ only)",
411
+ "description": "Report which registered projects' generated OpenWiki pages are stale; --apply updates existing wikis (openwiki/ only), never creates one, and skips excluded repositories",
273
412
  "timeout_ms": 600000,
274
413
  "effect": "write",
275
414
  "output": "json",
@@ -455,6 +594,31 @@
455
594
  "type": "boolean"
456
595
  }
457
596
  ]
597
+ },
598
+ {
599
+ "name": "exclude",
600
+ "description": "List, add or remove repositories the wiki refresh and generate never touch (clones, forks, backups)",
601
+ "effect": "write",
602
+ "args": [
603
+ {
604
+ "name": "targets",
605
+ "type": "string",
606
+ "label": "Registered project name or absolute path",
607
+ "positional": true
608
+ },
609
+ {
610
+ "name": "remove",
611
+ "flag": "--remove",
612
+ "label": "Take the repositories off the list",
613
+ "type": "boolean"
614
+ },
615
+ {
616
+ "name": "json",
617
+ "flag": "--json",
618
+ "label": "JSON output",
619
+ "type": "boolean"
620
+ }
621
+ ]
458
622
  }
459
623
  ]
460
624
  },
@@ -493,14 +657,6 @@
493
657
  "formatPropagationReceipt"
494
658
  ]
495
659
  },
496
- "auth": {
497
- "plugin": "auth",
498
- "methods": [
499
- "passkey",
500
- "google-oauth2"
501
- ],
502
- "session_verification": true
503
- },
504
660
  "status": {
505
661
  "command": "status",
506
662
  "refresh_seconds": 300
@@ -511,5 +667,12 @@
511
667
  "total-recall ssss status"
512
668
  ],
513
669
  "owned": "Documentation hub discovery, wiki page auditing, staleness tracking, and OpenWiki knowledge ingestion."
514
- }
670
+ },
671
+ "skills": [
672
+ {
673
+ "id": "openwiki",
674
+ "path": "./skills/openwiki/SKILL.md",
675
+ "description": "Multi-repo knowledge graph and documentation wiki engine for Total Recall."
676
+ }
677
+ ]
515
678
  }
@@ -0,0 +1,32 @@
1
+ ---
2
+ name: openwiki
3
+ description: "Multi-repo knowledge graph and documentation wiki engine for Total Recall."
4
+ version: 0.4.0
5
+ repo_scoped: false
6
+ ---
7
+
8
+ # OpenWiki
9
+
10
+ Multi-repo knowledge graph and documentation wiki engine for Total Recall.
11
+
12
+ ## When to Use
13
+
14
+ Use the `openwiki` Total Recall plugin (`total-recall openwiki`) instead of ad-hoc scripts or raw commands whenever working on openwiki tasks.
15
+
16
+ ## Commands
17
+
18
+ ```bash
19
+ total-recall openwiki --help
20
+ total-recall openwiki context # Retrieve task-relevant wiki and explicitly linked source evidence with provenance and freshness
21
+ total-recall openwiki search # Search evidence passages in workspace, registered-vault or mesh documentation hubs
22
+ total-recall openwiki graph # Extract documentation link topology as JSON, Mermaid or DOT
23
+ total-recall openwiki generate # Generate documentation for the selected registered repository or current workspace
24
+ total-recall openwiki token # Inspect provider credential status or save a provider key through the shared auth owner
25
+ total-recall openwiki lint # Inspect documentation links and orphaned hubs without rewriting files
26
+ total-recall openwiki status # Show which OpenWiki subcommands are implemented
27
+ total-recall openwiki hubs # List indexed OpenWiki hubs and page counts
28
+ total-recall openwiki ingest # Ingest markdown documentation into the semantic knowledge graph
29
+ total-recall openwiki bootstrap # Create missing OpenWiki documentation pages in explicit brain and project directories
30
+ total-recall openwiki probe # Run HTTP 200 health verification probe
31
+ total-recall openwiki refresh # Report which registered projects' generated OpenWiki pages are stale; --apply updates existing wikis (openwiki/ only), never creates one, and skips excluded repositories
32
+ ```
@@ -9,14 +9,28 @@ import path from 'node:path';
9
9
  // No model default: models and prices change too often to fix one in code, and a stale
10
10
  // default (deepseek/deepseek-chat) cost about 5x a current model of the same family.
11
11
  // A refresh with no configured model stops before it calls a provider.
12
+ //
13
+ // exclude lists repository roots the refresh never touches: upstream clones,
14
+ // forks, backups and test probes. Registering a repository with Total Recall
15
+ // gives it a brain; it does not make its code something to document.
12
16
  export const DEFAULT_OPENWIKI_CONFIG = Object.freeze({
13
17
  provider: 'openrouter',
14
18
  model: null,
15
19
  fallback_model: null,
16
20
  max_tokens: 4096,
17
- timeout_ms: 300000
21
+ timeout_ms: 300000,
22
+ exclude: Object.freeze([])
18
23
  });
19
24
 
25
+ /** Absolute, de-duplicated, sorted repository roots. */
26
+ export function normalizeExclude(list) {
27
+ if (!Array.isArray(list)) return [];
28
+ const roots = list
29
+ .filter((entry) => typeof entry === 'string' && entry.trim() && path.isAbsolute(entry.trim()))
30
+ .map((entry) => path.resolve(entry.trim()));
31
+ return [...new Set(roots)].sort();
32
+ }
33
+
20
34
  export const ALLOWED_CONFIG_KEYS = Object.freeze([
21
35
  'provider',
22
36
  'model',
@@ -44,12 +58,12 @@ export function loadOpenWikiConfig(options = {}) {
44
58
  const filePath = resolveConfigPath(options);
45
59
  try {
46
60
  if (!fs.existsSync(filePath)) {
47
- return { ...DEFAULT_OPENWIKI_CONFIG };
61
+ return { ...DEFAULT_OPENWIKI_CONFIG, exclude: [] };
48
62
  }
49
63
  const raw = fs.readFileSync(filePath, 'utf8');
50
64
  const parsed = JSON.parse(raw);
51
65
  if (!parsed || typeof parsed !== 'object') {
52
- return { ...DEFAULT_OPENWIKI_CONFIG };
66
+ return { ...DEFAULT_OPENWIKI_CONFIG, exclude: [] };
53
67
  }
54
68
  return {
55
69
  provider: typeof parsed.provider === 'string' && parsed.provider ? parsed.provider : DEFAULT_OPENWIKI_CONFIG.provider,
@@ -60,10 +74,11 @@ export function loadOpenWikiConfig(options = {}) {
60
74
  : DEFAULT_OPENWIKI_CONFIG.max_tokens,
61
75
  timeout_ms: Number.isInteger(parsed.timeout_ms) && parsed.timeout_ms >= 30000 && parsed.timeout_ms <= 1800000
62
76
  ? parsed.timeout_ms
63
- : DEFAULT_OPENWIKI_CONFIG.timeout_ms
77
+ : DEFAULT_OPENWIKI_CONFIG.timeout_ms,
78
+ exclude: normalizeExclude(parsed.exclude)
64
79
  };
65
80
  } catch {
66
- return { ...DEFAULT_OPENWIKI_CONFIG };
81
+ return { ...DEFAULT_OPENWIKI_CONFIG, exclude: [] };
67
82
  }
68
83
  }
69
84
 
@@ -75,7 +90,8 @@ export function saveOpenWikiConfig(config, options = {}) {
75
90
  model: config.model ? String(config.model).trim() || null : null,
76
91
  fallback_model: config.fallback_model ? String(config.fallback_model).trim() || null : null,
77
92
  max_tokens: Number.isInteger(Number(config.max_tokens)) ? Math.max(512, Math.min(131072, Number(config.max_tokens))) : DEFAULT_OPENWIKI_CONFIG.max_tokens,
78
- timeout_ms: Number.isInteger(Number(config.timeout_ms)) ? Math.max(30000, Math.min(1800000, Number(config.timeout_ms))) : DEFAULT_OPENWIKI_CONFIG.timeout_ms
93
+ timeout_ms: Number.isInteger(Number(config.timeout_ms)) ? Math.max(30000, Math.min(1800000, Number(config.timeout_ms))) : DEFAULT_OPENWIKI_CONFIG.timeout_ms,
94
+ exclude: normalizeExclude(config.exclude)
79
95
  };
80
96
 
81
97
  if (!ALLOWED_PROVIDERS.includes(validated.provider)) {
@@ -123,7 +139,17 @@ export function setOpenWikiConfigValue(key, value, options = {}) {
123
139
  return saveOpenWikiConfig(current, options);
124
140
  }
125
141
 
126
- /** Reset configuration to defaults. */
142
+ /**
143
+ * Reset the generator settings to defaults. The exclude list is kept: a reset
144
+ * must not put clones and backups back into a paid refresh.
145
+ */
127
146
  export function resetOpenWikiConfig(options = {}) {
128
- return saveOpenWikiConfig(DEFAULT_OPENWIKI_CONFIG, options);
147
+ const { exclude } = loadOpenWikiConfig(options);
148
+ return saveOpenWikiConfig({ ...DEFAULT_OPENWIKI_CONFIG, exclude }, options);
149
+ }
150
+
151
+ /** Replace the list of repository roots the refresh never touches. */
152
+ export function setExcludedRoots(roots, options = {}) {
153
+ const current = loadOpenWikiConfig(options);
154
+ return saveOpenWikiConfig({ ...current, exclude: roots }, options);
129
155
  }
@@ -70,6 +70,12 @@ export async function generateWiki({
70
70
  throw new Error(`Target path does not exist: ${resolvedTarget}`);
71
71
  }
72
72
 
73
+ // An excluded repository (an upstream clone, fork, backup or probe) is never
74
+ // documented, even from inside its own checkout.
75
+ if ((loadOpenWikiConfig().exclude || []).includes(path.resolve(resolvedTarget))) {
76
+ throw new Error(`${repoName} is excluded from OpenWiki. To document it, first run: total-recall openwiki exclude --remove ${repoName}`);
77
+ }
78
+
73
79
  const outPath = outputDir ? path.resolve(resolvedTarget, outputDir) : path.join(resolvedTarget, 'openwiki');
74
80
 
75
81
  if (dryRun) {
@@ -165,7 +165,7 @@ export function registryPath(home = os.homedir()) {
165
165
  * Read the registered projects. The registry is the same source the updater
166
166
  * uses to reach every consumer, so fleet scope is defined in exactly one place.
167
167
  */
168
- export function readProjects({ registry = registryPath() } = {}) {
168
+ export function readProjects({ registry = registryPath(), exclude = null } = {}) {
169
169
  let raw;
170
170
  try {
171
171
  raw = fs.readFileSync(registry, 'utf8');
@@ -188,14 +188,18 @@ export function readProjects({ registry = registryPath() } = {}) {
188
188
  }
189
189
  // One project per root: the registry has historically held duplicates.
190
190
  const seen = new Set();
191
+ const excluded = new Set((exclude ?? loadOpenWikiConfig().exclude ?? []).map((root) => path.resolve(root)));
191
192
  return projects.filter((p) => {
192
193
  const key = path.resolve(p.root);
193
194
  if (seen.has(key)) return false;
194
195
  seen.add(key);
195
196
  return true;
196
- });
197
+ }).map((p) => ({ ...p, excluded: excluded.has(path.resolve(p.root)) }));
197
198
  }
198
199
 
200
+ export const EXCLUDED = "excluded from OpenWiki (total-recall openwiki exclude --remove <name> to include it)";
201
+ export const NO_WIKI = "no finished wiki; the nightly refresh only updates existing wikis. Create one with: total-recall openwiki generate --repo <name>";
202
+
199
203
  /** Does this project carry generated Markdown pages? */
200
204
  export function hasWiki(root) {
201
205
  const dir = path.join(root, 'openwiki');
@@ -608,17 +612,21 @@ export function lastAttemptStart(root, generatedAt = null) {
608
612
  * runner killed the same generations every 30 minutes and they never finished.
609
613
  */
610
614
  export function isDue(project, { lockMs = DEFAULT_LOCK_MS, now = Date.now(), git = gitRun, force = false } = {}) {
615
+ if (project.excluded) return { due: false, excluded: true, reason: EXCLUDED };
611
616
  if (!isGitRepo(project.root, { git })) {
612
617
  return { due: false, skipped: true, reason: 'not a git repository' };
613
618
  }
614
619
  const state = staleness(project.root, { git });
615
- if (force) return { due: true, uninitialized: !hasWiki(project.root), ...state };
620
+ // Creating a wiki is the most expensive run there is, and a registered
621
+ // repository may be someone else's code. Only an explicit `openwiki generate`
622
+ // creates one or finishes an interrupted creation; refresh, --force included,
623
+ // only updates finished wikis.
624
+ if (generationMode(project.root) === 'init') {
625
+ return { due: false, uninitialized: true, ...state, reason: NO_WIKI };
626
+ }
627
+ if (force) return { due: true, uninitialized: false, ...state };
616
628
  const last = lastAttemptStart(project.root, state.generatedAt);
617
629
  const retryAt = Number.isFinite(last) && now - last < lockMs ? new Date(last + lockMs).toISOString() : null;
618
- if (!hasWiki(project.root)) {
619
- if (retryAt) return { due: false, held: true, uninitialized: true, reason: `initialization attempted recently; next attempt after ${retryAt}`, ...state };
620
- return { due: true, uninitialized: true, reason: 'uninitialized (missing openwiki/ pages)', ...state };
621
- }
622
630
  if (!state.stale) return { due: false, ...state };
623
631
  const incomplete = state.generatedStatus === 'interrupted' || stillGenerating(project.root);
624
632
  if (retryAt) {
@@ -10,7 +10,7 @@ import os from 'node:os';
10
10
  import path from 'node:path';
11
11
  import { spawnSync } from 'node:child_process';
12
12
  import { compareSemanticVersions, formatPropagationReceipt } from '../capability/index.mjs';
13
- import { CREDIT_REFUSAL, hasWiki, readProjects, refreshProject, resolveKey } from './refresh.mjs';
13
+ import { CREDIT_REFUSAL, generationMode, readProjects, refreshProject, resolveKey } from './refresh.mjs';
14
14
 
15
15
  export const UPSTREAM_NPM_URL = 'https://registry.npmjs.org/openwiki/latest';
16
16
  export const UPSTREAM_GITHUB_URL = 'https://api.github.com/repos/langchain-ai/openwiki/releases/latest';
@@ -338,8 +338,9 @@ export async function propagateUpdates({
338
338
  }
339
339
  }
340
340
 
341
- // Filter to repositories with existing openwiki directories
342
- const eligible = projects.filter(p => hasWiki(p.root));
341
+ // Only finished wikis outside the exclude list: propagation updates pages,
342
+ // it never creates a wiki or documents an excluded clone, fork or backup.
343
+ const eligible = projects.filter(p => !p.excluded && generationMode(p.root) === 'update');
343
344
  if (eligible.length === 0) {
344
345
  return {
345
346
  ok: true,
@@ -13,7 +13,7 @@
13
13
  },
14
14
  "devDependencies": {
15
15
  "jsdom": "^26.1.0",
16
- "total-recall-brain": "3.45.0"
16
+ "total-recall-brain": "3.47.0"
17
17
  }
18
18
  },
19
19
  "node_modules/@alcalzone/ansi-tokenize": {
@@ -5698,9 +5698,9 @@
5698
5698
  }
5699
5699
  },
5700
5700
  "node_modules/total-recall-brain": {
5701
- "version": "3.45.0",
5702
- "resolved": "https://registry.npmjs.org/total-recall-brain/-/total-recall-brain-3.45.0.tgz",
5703
- "integrity": "sha512-HDYfROazZbsLHQsFPnlBcSpe1HL1QEi7JG8x/eNRUI06RxVQsZWl8LwBo2lTWjWRDrKmCy7BUmSXQDuWF3lrEw==",
5701
+ "version": "3.47.0",
5702
+ "resolved": "https://registry.npmjs.org/total-recall-brain/-/total-recall-brain-3.47.0.tgz",
5703
+ "integrity": "sha512-S4UIdbbTyxw7C4+rix+7oHMm/6gYkcxwNBcP6kRDySX40p5IgqVTKgHk1n8rmaKiyYFoIX/HZHlHSjNrHgn0Gw==",
5704
5704
  "dev": true,
5705
5705
  "license": "MIT",
5706
5706
  "workspaces": [
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tr-plugin-security",
3
- "version": "0.4.0",
3
+ "version": "0.4.1",
4
4
  "type": "module",
5
5
  "description": "Standalone security suite for Total Recall: static analysis, file and permission hardening schemes, AES-256-GCM encryption tools, and egress audit controls",
6
6
  "scripts": {
@@ -2,10 +2,16 @@
2
2
  "$schema": "https://github.com/gregiteen/total-recall/blob/main/metadata.plugin.schema.json",
3
3
  "id": "security",
4
4
  "name": "Security Assessments",
5
- "version": "0.4.0",
5
+ "version": "0.4.1",
6
6
  "description": "Machine and device security assessments for macOS, Linux, Windows, Android, Chromebook, iPhone and iPad, with explicit measured and manual coverage.",
7
7
  "license": "MIT",
8
- "requires": [{ "id": "auth", "range": ">=1.2.1" }],
8
+ "reuse": {
9
+ "commands": [
10
+ "total-recall auth secret",
11
+ "total-recall ssss status"
12
+ ],
13
+ "owned": "Machine and device security assessments, header probes, and security evidence audits across platforms."
14
+ },
9
15
  "branding": {
10
16
  "name": "Security Assessments",
11
17
  "color": "#31564b",
@@ -66,10 +72,21 @@
66
72
  }
67
73
  ],
68
74
  "gate": {
69
- "tasks": ["Audit a machine, network or the fleet", "Scan installed plugins or a source folder", "Harden SSH permissions", "Audit or protect a website you are authorized to test"],
75
+ "tasks": [
76
+ "Audit a machine, network or the fleet",
77
+ "Scan installed plugins or a source folder",
78
+ "Harden SSH permissions",
79
+ "Audit or protect a website you are authorized to test"
80
+ ],
70
81
  "owned_commands": [
71
- { "pattern": "nmap\\s", "use": "total-recall security network --json" },
72
- { "pattern": "lynis\\s", "use": "total-recall security machine --json" }
82
+ {
83
+ "pattern": "nmap\\s",
84
+ "use": "total-recall security network --json"
85
+ },
86
+ {
87
+ "pattern": "lynis\\s",
88
+ "use": "total-recall security machine --json"
89
+ }
73
90
  ]
74
91
  },
75
92
  "cli": {
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tr-plugin-ssss",
3
- "version": "0.2.0",
3
+ "version": "0.2.1",
4
4
  "private": true,
5
5
  "type": "module",
6
6
  "description": "Canonical SSSS distribution, scaffolding and validation for Total Recall installations.",
@@ -12,7 +12,8 @@
12
12
  "scripts/",
13
13
  "cli.mjs",
14
14
  "DESIGN.md",
15
- "plugin.json"
15
+ "plugin.json",
16
+ "skills/"
16
17
  ],
17
18
  "scripts": {
18
19
  "test": "node scripts/refresh-scaffold.mjs --check && node --test test/*.test.mjs",