@oh-my-pi/pi-ai 15.12.0 → 15.12.2

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/CHANGELOG.md CHANGED
@@ -2,6 +2,12 @@
2
2
 
3
3
  ## [Unreleased]
4
4
 
5
+ ## [15.12.1] - 2026-06-12
6
+
7
+ ### Added
8
+
9
+ - Added the optional `ToolResultMessage.useless` flag: tools can declare a finished result contextually useless (zero matches, elapsed wait) so compaction passes may elide it once consumed. Never serialized to provider wire formats and never set together with `isError`.
10
+
5
11
  ## [15.12.0] - 2026-06-12
6
12
 
7
13
  ### Fixed
@@ -429,6 +429,12 @@ export interface ToolResultMessage<TDetails = any> {
429
429
  attribution?: MessageAttribution;
430
430
  /** Timestamp when output was pruned (ms since epoch). Undefined if unpruned. */
431
431
  prunedAt?: number;
432
+ /**
433
+ * Tool-declared: this result carried no information worth retaining once
434
+ * consumed (zero matches, elapsed wait). Compaction passes may elide it.
435
+ * Never set together with isError.
436
+ */
437
+ useless?: boolean;
432
438
  timestamp: number;
433
439
  }
434
440
  export type Message = UserMessage | DeveloperMessage | AssistantMessage | ToolResultMessage;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "type": "module",
3
3
  "name": "@oh-my-pi/pi-ai",
4
- "version": "15.12.0",
4
+ "version": "15.12.2",
5
5
  "description": "Unified LLM API with automatic model discovery and provider configuration",
6
6
  "homepage": "https://omp.sh",
7
7
  "author": "Can Boluk",
@@ -38,8 +38,8 @@
38
38
  },
39
39
  "dependencies": {
40
40
  "@bufbuild/protobuf": "^2.12.0",
41
- "@oh-my-pi/pi-catalog": "15.12.0",
42
- "@oh-my-pi/pi-utils": "15.12.0",
41
+ "@oh-my-pi/pi-catalog": "15.12.2",
42
+ "@oh-my-pi/pi-utils": "15.12.2",
43
43
  "openai": "^6.39.0",
44
44
  "partial-json": "^0.1.7",
45
45
  "zod": "4.4.3"
package/src/types.ts CHANGED
@@ -518,6 +518,12 @@ export interface ToolResultMessage<TDetails = any> {
518
518
  attribution?: MessageAttribution;
519
519
  /** Timestamp when output was pruned (ms since epoch). Undefined if unpruned. */
520
520
  prunedAt?: number;
521
+ /**
522
+ * Tool-declared: this result carried no information worth retaining once
523
+ * consumed (zero matches, elapsed wait). Compaction passes may elide it.
524
+ * Never set together with isError.
525
+ */
526
+ useless?: boolean;
521
527
  timestamp: number; // Unix timestamp in milliseconds
522
528
  }
523
529