pi-harness-runtime 1.1.446 → 1.1.447

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/harness/loop-review-agent.ts +10 -7
  2. package/package.json +1 -1
  3. package/packages/agent-policy/package.json +1 -1
  4. package/packages/auth/package.json +1 -1
  5. package/packages/autonomous-runtime/package.json +1 -1
  6. package/packages/checkpoint/package.json +1 -1
  7. package/packages/clipboard/package.json +1 -1
  8. package/packages/codex-watcher/package.json +1 -1
  9. package/packages/config-capture/package.json +1 -1
  10. package/packages/contracts/package.json +1 -1
  11. package/packages/cookie-sanitizer/package.json +1 -1
  12. package/packages/evaluation-engine/package.json +1 -1
  13. package/packages/event-bus/package.json +1 -1
  14. package/packages/event-store/package.json +1 -1
  15. package/packages/experience-replay/package.json +1 -1
  16. package/packages/file-copy-helper/package.json +1 -1
  17. package/packages/intent-analyzer/package.json +1 -1
  18. package/packages/jev-judge/package.json +1 -1
  19. package/packages/knowledge-retrieval/package.json +1 -1
  20. package/packages/learning-engine/package.json +1 -1
  21. package/packages/logging/package.json +1 -1
  22. package/packages/memory-engine/package.json +1 -1
  23. package/packages/notification/package.json +1 -1
  24. package/packages/paperclip-integration/package.json +1 -1
  25. package/packages/performance-optimizer/package.json +1 -1
  26. package/packages/privilege-broker/package.json +1 -1
  27. package/packages/prompt-compiler/package.json +1 -1
  28. package/packages/providers/package.json +1 -1
  29. package/packages/qdrant-skills/package.json +1 -1
  30. package/packages/quota-manager/package.json +1 -1
  31. package/packages/relay/package.json +1 -1
  32. package/packages/skill-mcp-client/package.json +1 -1
  33. package/packages/skills/package.json +1 -1
  34. package/packages/todo-bd-sync/package.json +1 -1
  35. package/packages/token-estimation/package.json +1 -1
  36. package/packages/tooling-preference/package.json +1 -1
  37. package/packages/trajectory/package.json +1 -1
  38. package/packages/tui/package.json +1 -1
  39. package/packages/two-phase-review/package.json +1 -1
  40. package/packages/types/package.json +1 -1
  41. package/packages/webmcp-tester/package.json +1 -1
  42. package/packages/wiki/package.json +1 -1
  43. package/packages/write-review/package.json +1 -1
  44. package/scripts/copy-plugins.js +12 -2
  45. package/scripts/sync-skills.ts +19 -4
  46. package/scripts/sync-to-qdrant.ts +39 -23
@@ -86,8 +86,9 @@ async function main(): Promise<void> {
86
86
  agentId: AGENT_ID,
87
87
  taskId: action.taskId,
88
88
  status: "success",
89
- message: verdict,
90
- } as unknown as Parameters<typeof blackboard.writeReport>[0]);
89
+ summary: verdict,
90
+ createdAt: new Date().toISOString(),
91
+ });
91
92
  blackboard.updateAgentStatus(AGENT_ID, "idle");
92
93
 
93
94
  // Decide next action based on verdict
@@ -117,11 +118,13 @@ async function main(): Promise<void> {
117
118
  );
118
119
  console.log(`[${AGENT_ID}] CHANGES — nextAction: code ${nextWrite}`);
119
120
  } else {
120
- blackboard.setNextAction({
121
- taskId: "report",
122
- agentType: "review",
123
- iteration: 0,
124
- } as unknown as ReturnType<typeof encodeNextAction>);
121
+ blackboard.setNextAction(
122
+ encodeNextAction({
123
+ taskId: "report",
124
+ agentType: "review",
125
+ iteration: 0,
126
+ }),
127
+ );
125
128
  console.log(`[${AGENT_ID}] CHANGES — nextAction: report`);
126
129
  }
127
130
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pi-harness-runtime",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "description": "[BETA] Codex-style /usage status + autonomous coding harness for pi. Not production ready — expect breaking changes.",
5
5
  "type": "module",
6
6
  "scripts": {
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pi/agent-policy",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "description": "Agent policy runtime for pi-harness - enforces mandatory rule delivery and mutation gating",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pi-harness/auth",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "description": "pi-harness-runtime — auth",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pi/autonomous-runtime",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "description": "Autonomous Operations Runtime — task inbox, lease management, and worker lifecycle (RFC-0101)",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pi/checkpoint",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "description": "Enhanced checkpoint system with incremental snapshots, diff-based storage, and recovery strategies",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pi/clipboard",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "type": "module",
5
5
  "main": "src/index.ts",
6
6
  "exports": {
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pi-harness/codex-watcher",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "description": "Watches Codex CLI sessions and emits visible messages for PING-PONG monitoring",
5
5
  "type": "module",
6
6
  "main": "./dist/src/index.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@moocoding/config-capture",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "description": "Auto-capture API-fetched configuration values to AGENTS.md",
5
5
  "type": "module",
6
6
  "main": "src/index.ts",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pi-harness/contracts",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "type": "module",
5
5
  "description": "RPC schema definitions for pi-harness runtime",
6
6
  "main": "./dist/index.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pi-harness/cookie-sanitizer",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "description": "pi-harness-runtime — cookie sanitizer (provider-quota cookie file normaliser)",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pi-harness/evaluation-engine",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "description": "Evaluation engine for pi-harness runtime (RFC-0057)",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pi/event-bus",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "type": "module",
5
5
  "main": "src/index.ts",
6
6
  "exports": {
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pi/event-store",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "type": "module",
5
5
  "main": "src/index.ts",
6
6
  "exports": {
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pi-harness/experience-replay",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "description": "Experience replay for debugging and reproducibility (RFC-0059)",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@moocoding/file-copy-helper",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "description": "Injects cp/sudo cp rule when user asks to mimic/copy files",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pi/intent-analyzer",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "type": "module",
5
5
  "main": "src/index.ts",
6
6
  "exports": {
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pi-harness/jev-judge",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "description": "Jev Judge - Structured decision model for agent routing, E2E testing, and automated decisions",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pi-harness/knowledge-retrieval",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "description": "Knowledge retrieval via TencentDB-Agent-Memory MCP (RFC-0105)",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pi-harness/learning-engine",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "description": "Learning engine for extracting lessons from runtime execution (RFC-0058)",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pi-harness/logging",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "type": "module",
5
5
  "description": "Centralized structured application logging with buffered Cloudflare R2 and webhook transports",
6
6
  "main": "./dist/index.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pi-harness/memory-engine",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "description": "Memory engine with OKF integration for durable knowledge management (RFC-0060)",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pi-harness/notification",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "description": "pi-harness-runtime — notification",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pi-harness/paperclip-integration",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "description": "Paperclip API integration: poll agent inbox, route tasks to pi.dev, Telegram alerts",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pi-harness/performance-optimizer",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "description": "Performance optimization analyzer for pi-harness runtime (RFC-0056)",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pi/privilege-broker",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "description": "Privilege Broker — capability registry and command executor for autonomous runtime (RFC-0101 §7)",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pi/prompt-compiler",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "description": "Deterministic prompt compiler for pi-harness-runtime",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pi-harness/providers",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "description": "pi-harness-runtime — providers",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pi-harness/qdrant-skills",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "description": "Qdrant vector search integration for Hermes-style skill system",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pi-harness/quota-manager",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "description": "pi-harness-runtime — quota-manager",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pi-harness/relay",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "type": "module",
5
5
  "description": "Cloud relay for remote access - T3 Connect style for pi-harness",
6
6
  "main": "./dist/index.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pi/skill-mcp-client",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "description": "MCP client for Skills SaaS backend",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pi-harness/skills",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "description": "File-based skill system with pi.dev compatibility and Hermes self-improvement",
5
5
  "type": "module",
6
6
  "main": "src/index.ts",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@moocoding/todo-bd-sync",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "description": "Two-way sync between rpiv-todo overlay and bd issue tracker",
5
5
  "type": "module",
6
6
  "main": "src/index.ts",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pi-harness/token-estimation",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "description": "pi-harness-runtime — token-estimation",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pi-harness/tooling-preference",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "description": "pi-harness-runtime — JS/TS tooling preference (Biome vs ESLint/Prettier) proposal",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pi-harness/trajectory",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "description": "Trajectory capture for the write-review loop — persists cycle records for learning",
5
5
  "type": "module",
6
6
  "main": "./dist/src/index.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pi-harness/tui",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "description": "pi-harness-runtime — tui",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pi-harness/two-phase-review",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "description": "pi-harness-runtime — two-phase implementation and review workflow (queue review signals, gate the phase, scope the diff)",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pi-harness/types",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "description": "Shared TypeScript types for pi-harness-runtime packages",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pi-harness/webmcp-tester",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "description": "WebMCP-powered E2E testing for pi-harness - natural language test scenarios",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pi-harness/wiki",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "description": "LLM Wiki integration for pi-harness-runtime",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@moocoding/write-review",
3
- "version": "1.1.446",
3
+ "version": "1.1.447",
4
4
  "description": "Two-agent write-review loop with blackboard coordination",
5
5
  "type": "module",
6
6
  "main": "src/index.ts",
@@ -11,7 +11,7 @@
11
11
 
12
12
  import { mkdirSync, existsSync, readdirSync, cpSync } from "node:fs";
13
13
  import { join, dirname } from "node:path";
14
- import { fileURLToPath } from "node:url";
14
+ import { fileURLToPath, pathToFileURL } from "node:url";
15
15
 
16
16
  const __filename = fileURLToPath(import.meta.url);
17
17
  const __dirname = dirname(__filename);
@@ -57,4 +57,14 @@ function main() {
57
57
  console.log("[copy-plugins] Done!");
58
58
  }
59
59
 
60
- main();
60
+ /**
61
+ * The program runs only when the file is the entry point.
62
+ *
63
+ * The script is published in the npm package and is the postinstall hook,
64
+ * so a consumer may import it. An import must not copy files into the
65
+ * home directory of the machine that imported it.
66
+ */
67
+ const entry = process.argv[1];
68
+ if (entry && pathToFileURL(entry).href === import.meta.url) {
69
+ main();
70
+ }
@@ -11,8 +11,9 @@
11
11
  */
12
12
 
13
13
  import { existsSync, mkdirSync, readdirSync, statSync, copyFileSync, rmSync } from "node:fs";
14
- import { join, basename, dirname } from "node:path";
14
+ import { join, basename } from "node:path";
15
15
  import { homedir } from "node:os";
16
+ import { pathToFileURL } from "node:url";
16
17
 
17
18
  // Default paths
18
19
  const DEFAULT_TARGET = join(homedir(), ".pi-harness-runtime", "skills");
@@ -270,6 +271,20 @@ function syncSkills(options: SyncOptions): void {
270
271
  console.log(` 3. List skills: /skill list`);
271
272
  }
272
273
 
273
- // Main
274
- const options = parseArgs();
275
- syncSkills(options);
274
+ /**
275
+ * The program runs only when the file is the entry point.
276
+ *
277
+ * The script is published in the npm package, so a consumer may import it.
278
+ * An import must not sync skills, and it must not end the importing
279
+ * process - the same rule the harness programs and the command modules
280
+ * follow.
281
+ */
282
+ function main(): void {
283
+ const options = parseArgs();
284
+ syncSkills(options);
285
+ }
286
+
287
+ const entry = process.argv[1];
288
+ if (entry && pathToFileURL(entry).href === import.meta.url) {
289
+ main();
290
+ }
@@ -13,6 +13,7 @@
13
13
 
14
14
  import { existsSync, readdirSync, readFileSync, statSync } from "node:fs";
15
15
  import { join } from "node:path";
16
+ import { pathToFileURL } from "node:url";
16
17
  import { QdrantClient } from "@qdrant/js-client-rest";
17
18
  // The runtime and this script must write into the SAME collection with the
18
19
  // SAME vectors: a collection holds vectors of exactly one size, and a vector
@@ -343,10 +344,19 @@ async function search(query: string): Promise<void> {
343
344
  // Main
344
345
  // =============================================================================
345
346
 
346
- const args = process.argv.slice(2);
347
+ /**
348
+ * The program runs only when the file is the entry point.
349
+ *
350
+ * The script is published in the npm package, so a consumer may import it.
351
+ * An import must not talk to Qdrant, and it must not end the importing
352
+ * process - the same rule the harness programs and the command modules
353
+ * follow.
354
+ */
355
+ async function main(): Promise<void> {
356
+ const args = process.argv.slice(2);
347
357
 
348
- if (args.includes("--help")) {
349
- console.log(`
358
+ if (args.includes("--help")) {
359
+ console.log(`
350
360
  Sync Skills to Qdrant (Sanitized)
351
361
  ──────────────────────────────────
352
362
  Upload skills to Qdrant for team sharing.
@@ -373,28 +383,34 @@ Environment:
373
383
  Or create file:
374
384
  ~/.pi-harness-runtime/keys/qdrant-api-key.txt
375
385
  `);
376
- process.exit(0);
377
- }
386
+ process.exit(0);
387
+ }
378
388
 
379
- if (args.includes("--list")) {
380
- await listSkills();
381
- process.exit(0);
382
- }
389
+ if (args.includes("--list")) {
390
+ await listSkills();
391
+ process.exit(0);
392
+ }
383
393
 
384
- const searchIdx = args.indexOf("--search");
385
- if (searchIdx !== -1 && args[searchIdx + 1]) {
386
- await search(args[searchIdx + 1]);
387
- process.exit(0);
388
- }
394
+ const searchIdx = args.indexOf("--search");
395
+ if (searchIdx !== -1 && args[searchIdx + 1]) {
396
+ await search(args[searchIdx + 1]);
397
+ process.exit(0);
398
+ }
389
399
 
390
- const fromIdx = args.indexOf("--from");
391
- if (fromIdx === -1 || !args[fromIdx + 1]) {
392
- console.error("Error: --from <directory> is required");
393
- console.error("Use --help for usage information.");
394
- process.exit(1);
395
- }
400
+ const fromIdx = args.indexOf("--from");
401
+ if (fromIdx === -1 || !args[fromIdx + 1]) {
402
+ console.error("Error: --from <directory> is required");
403
+ console.error("Use --help for usage information.");
404
+ process.exit(1);
405
+ }
396
406
 
397
- const sourceDir = args[fromIdx + 1];
398
- const clear = args.includes("--clear");
407
+ const sourceDir = args[fromIdx + 1];
408
+ const clear = args.includes("--clear");
399
409
 
400
- await syncToQdrant(sourceDir, clear);
410
+ await syncToQdrant(sourceDir, clear);
411
+ }
412
+
413
+ const entry = process.argv[1];
414
+ if (entry && pathToFileURL(entry).href === import.meta.url) {
415
+ await main();
416
+ }