@mastra/memory 1.16.0-alpha.2 → 1.16.0-alpha.3

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.
@@ -3,7 +3,7 @@ name: mastra-memory
3
3
  description: Documentation for @mastra/memory. Use when working with @mastra/memory APIs, configuration, or implementation.
4
4
  metadata:
5
5
  package: "@mastra/memory"
6
- version: "1.16.0-alpha.2"
6
+ version: "1.16.0-alpha.3"
7
7
  ---
8
8
 
9
9
  ## When to use
@@ -1,119 +1,119 @@
1
1
  {
2
- "version": "1.16.0-alpha.2",
2
+ "version": "1.16.0-alpha.3",
3
3
  "package": "@mastra/memory",
4
4
  "exports": {
5
5
  "ModelByInputTokens": {
6
6
  "types": "dist/processors/index.d.ts",
7
- "implementation": "dist/chunk-MGHUIRKN.js",
7
+ "implementation": "dist/chunk-25XLVCFF.js",
8
8
  "line": 684
9
9
  },
10
10
  "OBSERVER_SYSTEM_PROMPT": {
11
11
  "types": "dist/processors/index.d.ts",
12
- "implementation": "dist/chunk-MGHUIRKN.js"
12
+ "implementation": "dist/chunk-25XLVCFF.js"
13
13
  },
14
14
  "ObservationalMemory": {
15
15
  "types": "dist/processors/index.d.ts",
16
- "implementation": "dist/chunk-MGHUIRKN.js",
16
+ "implementation": "dist/chunk-25XLVCFF.js",
17
17
  "line": 6432
18
18
  },
19
19
  "ObservationalMemoryProcessor": {
20
20
  "types": "dist/processors/index.d.ts",
21
- "implementation": "dist/chunk-MGHUIRKN.js",
21
+ "implementation": "dist/chunk-25XLVCFF.js",
22
22
  "line": 8868
23
23
  },
24
24
  "TokenCounter": {
25
25
  "types": "dist/processors/index.d.ts",
26
- "implementation": "dist/chunk-MGHUIRKN.js",
26
+ "implementation": "dist/chunk-25XLVCFF.js",
27
27
  "line": 5902
28
28
  },
29
29
  "buildObserverPrompt": {
30
30
  "types": "dist/processors/index.d.ts",
31
- "implementation": "dist/chunk-MGHUIRKN.js",
31
+ "implementation": "dist/chunk-25XLVCFF.js",
32
32
  "line": 3443
33
33
  },
34
34
  "buildObserverSystemPrompt": {
35
35
  "types": "dist/processors/index.d.ts",
36
- "implementation": "dist/chunk-MGHUIRKN.js",
36
+ "implementation": "dist/chunk-25XLVCFF.js",
37
37
  "line": 2842
38
38
  },
39
39
  "combineObservationGroupRanges": {
40
40
  "types": "dist/processors/index.d.ts",
41
- "implementation": "dist/chunk-MGHUIRKN.js",
41
+ "implementation": "dist/chunk-25XLVCFF.js",
42
42
  "line": 776
43
43
  },
44
44
  "deriveObservationGroupProvenance": {
45
45
  "types": "dist/processors/index.d.ts",
46
- "implementation": "dist/chunk-MGHUIRKN.js",
46
+ "implementation": "dist/chunk-25XLVCFF.js",
47
47
  "line": 810
48
48
  },
49
49
  "extractCurrentTask": {
50
50
  "types": "dist/processors/index.d.ts",
51
- "implementation": "dist/chunk-MGHUIRKN.js",
51
+ "implementation": "dist/chunk-25XLVCFF.js",
52
52
  "line": 3557
53
53
  },
54
54
  "formatMessagesForObserver": {
55
55
  "types": "dist/processors/index.d.ts",
56
- "implementation": "dist/chunk-MGHUIRKN.js",
56
+ "implementation": "dist/chunk-25XLVCFF.js",
57
57
  "line": 3169
58
58
  },
59
59
  "getObservationsAsOf": {
60
60
  "types": "dist/processors/index.d.ts",
61
- "implementation": "dist/chunk-MGHUIRKN.js",
61
+ "implementation": "dist/chunk-25XLVCFF.js",
62
62
  "line": 9054
63
63
  },
64
64
  "hasCurrentTaskSection": {
65
65
  "types": "dist/processors/index.d.ts",
66
- "implementation": "dist/chunk-MGHUIRKN.js",
66
+ "implementation": "dist/chunk-25XLVCFF.js",
67
67
  "line": 3545
68
68
  },
69
69
  "injectAnchorIds": {
70
70
  "types": "dist/processors/index.d.ts",
71
- "implementation": "dist/chunk-MGHUIRKN.js",
71
+ "implementation": "dist/chunk-25XLVCFF.js",
72
72
  "line": 2399
73
73
  },
74
74
  "optimizeObservationsForContext": {
75
75
  "types": "dist/processors/index.d.ts",
76
- "implementation": "dist/chunk-MGHUIRKN.js",
76
+ "implementation": "dist/chunk-25XLVCFF.js",
77
77
  "line": 3568
78
78
  },
79
79
  "parseAnchorId": {
80
80
  "types": "dist/processors/index.d.ts",
81
- "implementation": "dist/chunk-MGHUIRKN.js",
81
+ "implementation": "dist/chunk-25XLVCFF.js",
82
82
  "line": 2372
83
83
  },
84
84
  "parseObservationGroups": {
85
85
  "types": "dist/processors/index.d.ts",
86
- "implementation": "dist/chunk-MGHUIRKN.js",
86
+ "implementation": "dist/chunk-25XLVCFF.js",
87
87
  "line": 745
88
88
  },
89
89
  "parseObserverOutput": {
90
90
  "types": "dist/processors/index.d.ts",
91
- "implementation": "dist/chunk-MGHUIRKN.js",
91
+ "implementation": "dist/chunk-25XLVCFF.js",
92
92
  "line": 3453
93
93
  },
94
94
  "reconcileObservationGroupsFromReflection": {
95
95
  "types": "dist/processors/index.d.ts",
96
- "implementation": "dist/chunk-MGHUIRKN.js",
96
+ "implementation": "dist/chunk-25XLVCFF.js",
97
97
  "line": 834
98
98
  },
99
99
  "renderObservationGroupsForReflection": {
100
100
  "types": "dist/processors/index.d.ts",
101
- "implementation": "dist/chunk-MGHUIRKN.js",
101
+ "implementation": "dist/chunk-25XLVCFF.js",
102
102
  "line": 790
103
103
  },
104
104
  "stripEphemeralAnchorIds": {
105
105
  "types": "dist/processors/index.d.ts",
106
- "implementation": "dist/chunk-MGHUIRKN.js",
106
+ "implementation": "dist/chunk-25XLVCFF.js",
107
107
  "line": 2429
108
108
  },
109
109
  "stripObservationGroups": {
110
110
  "types": "dist/processors/index.d.ts",
111
- "implementation": "dist/chunk-MGHUIRKN.js",
111
+ "implementation": "dist/chunk-25XLVCFF.js",
112
112
  "line": 767
113
113
  },
114
114
  "wrapInObservationGroup": {
115
115
  "types": "dist/processors/index.d.ts",
116
- "implementation": "dist/chunk-MGHUIRKN.js",
116
+ "implementation": "dist/chunk-25XLVCFF.js",
117
117
  "line": 738
118
118
  },
119
119
  "OBSERVATIONAL_MEMORY_DEFAULTS": {
@@ -161,7 +161,7 @@
161
161
  "processors": {
162
162
  "index": "dist/processors/index.js",
163
163
  "chunks": [
164
- "chunk-MGHUIRKN.js",
164
+ "chunk-25XLVCFF.js",
165
165
  "chunk-LSJJAJAF.js"
166
166
  ]
167
167
  }
@@ -300,8 +300,26 @@ Success criteria:
300
300
  })
301
301
  ```
302
302
 
303
+ ## Sub-agent versioning
304
+
305
+ When using the [editor](https://mastra.ai/docs/editor/overview), you can control which stored version of each sub-agent the supervisor uses at runtime. Set version overrides on the Mastra instance or per invocation:
306
+
307
+ ```typescript
308
+ const result = await supervisor.generate('Research and write about AI safety', {
309
+ versions: {
310
+ agents: {
311
+ 'research-agent': { status: 'published' },
312
+ 'writing-agent': { versionId: 'draft-456' },
313
+ },
314
+ },
315
+ })
316
+ ```
317
+
318
+ Version overrides propagate automatically through delegation. See [Sub-agent versioning](https://mastra.ai/docs/editor/overview) for details on resolution order and server API usage.
319
+
303
320
  ## Related
304
321
 
322
+ - [Sub-agent versioning](https://mastra.ai/docs/editor/overview)
305
323
  - [Guide: Research coordinator](https://mastra.ai/guides/guide/research-coordinator)
306
324
  - [Agent.stream() reference](https://mastra.ai/reference/streaming/agents/stream)
307
325
  - [Agent.generate() reference](https://mastra.ai/reference/agents/generate)
package/dist/index.cjs CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  var chunkCK4U3AYR_cjs = require('./chunk-CK4U3AYR.cjs');
4
4
  var chunkIDRQZVB4_cjs = require('./chunk-IDRQZVB4.cjs');
5
- var chunkEOHXGI4J_cjs = require('./chunk-EOHXGI4J.cjs');
5
+ var chunk3MHY4GB4_cjs = require('./chunk-3MHY4GB4.cjs');
6
6
  var v3 = require('zod/v3');
7
7
  var zod = require('zod');
8
8
  var z4 = require('zod/v4');
@@ -15709,7 +15709,7 @@ function formatTimestamp(date) {
15709
15709
  }
15710
15710
  function truncateByTokens(text4, maxTokens, hint) {
15711
15711
  if (tokenx.estimateTokenCount(text4) <= maxTokens) return { text: text4, wasTruncated: false };
15712
- const truncated = chunkEOHXGI4J_cjs.truncateStringByTokens(text4, maxTokens);
15712
+ const truncated = chunk3MHY4GB4_cjs.truncateStringByTokens(text4, maxTokens);
15713
15713
  const suffix = hint ? ` [${hint} for more]` : "";
15714
15714
  return { text: truncated + suffix, wasTruncated: true };
15715
15715
  }
@@ -15761,11 +15761,11 @@ ${JSON.stringify(inv.args, null, 2)}`;
15761
15761
  });
15762
15762
  }
15763
15763
  if (inv.state === "result") {
15764
- const { value: resultValue } = chunkEOHXGI4J_cjs.resolveToolResultValue(
15764
+ const { value: resultValue } = chunk3MHY4GB4_cjs.resolveToolResultValue(
15765
15765
  part,
15766
15766
  inv.result
15767
15767
  );
15768
- const resultStr = chunkEOHXGI4J_cjs.formatToolResultForObserver(resultValue, { maxTokens: HIGH_DETAIL_TOOL_RESULT_TOKENS });
15768
+ const resultStr = chunk3MHY4GB4_cjs.formatToolResultForObserver(resultValue, { maxTokens: HIGH_DETAIL_TOOL_RESULT_TOKENS });
15769
15769
  const fullText = `[Tool Result: ${inv.toolName}]
15770
15770
  ${resultStr}`;
15771
15771
  parts.push(makePart(msg, i, "tool-result", fullText, detail, inv.toolName));
@@ -15792,7 +15792,7 @@ ${typeof rawArgs === "string" ? rawArgs : JSON.stringify(rawArgs, null, 2)}`;
15792
15792
  const toolName = part.toolName;
15793
15793
  if (toolName) {
15794
15794
  const rawResult = part.output ?? part.result;
15795
- const resultStr = chunkEOHXGI4J_cjs.formatToolResultForObserver(rawResult, { maxTokens: HIGH_DETAIL_TOOL_RESULT_TOKENS });
15795
+ const resultStr = chunk3MHY4GB4_cjs.formatToolResultForObserver(rawResult, { maxTokens: HIGH_DETAIL_TOOL_RESULT_TOKENS });
15796
15796
  const fullText = `[Tool Result: ${toolName}]
15797
15797
  ${resultStr}`;
15798
15798
  parts.push(makePart(msg, i, "tool-result", fullText, detail, toolName));
@@ -15871,7 +15871,7 @@ function renderFormattedParts(parts, timestamps, options) {
15871
15871
  const text4 = buildRenderedText(parts, timestamps);
15872
15872
  let totalTokens = tokenx.estimateTokenCount(text4);
15873
15873
  if (totalTokens > options.maxTokens) {
15874
- const truncated = chunkEOHXGI4J_cjs.truncateStringByTokens(text4, options.maxTokens);
15874
+ const truncated = chunk3MHY4GB4_cjs.truncateStringByTokens(text4, options.maxTokens);
15875
15875
  return { text: truncated, truncated: true, tokenOffset: totalTokens - options.maxTokens };
15876
15876
  }
15877
15877
  const truncatedIndices = parts.map((p, i) => ({ part: p, index: i })).filter(({ part }) => part.text !== part.fullText).sort((a, b) => expandPriority(a.part) - expandPriority(b.part));
@@ -15904,7 +15904,7 @@ function renderFormattedParts(parts, timestamps, options) {
15904
15904
  if (expandedTokens <= options.maxTokens) {
15905
15905
  return { text: expanded, truncated: false, tokenOffset: 0 };
15906
15906
  }
15907
- const hardTruncated = chunkEOHXGI4J_cjs.truncateStringByTokens(expanded, options.maxTokens);
15907
+ const hardTruncated = chunk3MHY4GB4_cjs.truncateStringByTokens(expanded, options.maxTokens);
15908
15908
  return { text: hardTruncated, truncated: true, tokenOffset: expandedTokens - options.maxTokens };
15909
15909
  }
15910
15910
  async function recallPart({
@@ -15955,7 +15955,7 @@ async function recallPart({
15955
15955
 
15956
15956
  `;
15957
15957
  const fallbackText = `${fallbackNote}${firstNextPart.text}`;
15958
- const truncatedText2 = chunkEOHXGI4J_cjs.truncateStringByTokens(fallbackText, maxTokens);
15958
+ const truncatedText2 = chunk3MHY4GB4_cjs.truncateStringByTokens(fallbackText, maxTokens);
15959
15959
  const wasTruncated2 = truncatedText2 !== fallbackText;
15960
15960
  return {
15961
15961
  text: truncatedText2,
@@ -15970,7 +15970,7 @@ async function recallPart({
15970
15970
  }
15971
15971
  throw new Error(`Part index ${partIndex} not found in message ${cursor}. Available indices: ${availableIndices}`);
15972
15972
  }
15973
- const truncatedText = chunkEOHXGI4J_cjs.truncateStringByTokens(target.text, maxTokens);
15973
+ const truncatedText = chunk3MHY4GB4_cjs.truncateStringByTokens(target.text, maxTokens);
15974
15974
  const wasTruncated = truncatedText !== target.text;
15975
15975
  return {
15976
15976
  text: truncatedText,
@@ -17601,7 +17601,7 @@ ${workingMemory}`;
17601
17601
  "Observational memory requires @mastra/core support for request-response-id-rotation. Please bump @mastra/core to a newer version."
17602
17602
  );
17603
17603
  }
17604
- const { ObservationalMemory: OMClass } = await import('./observational-memory-FCDIQ3SX.cjs');
17604
+ const { ObservationalMemory: OMClass } = await import('./observational-memory-FPGLTCDV.cjs');
17605
17605
  const onIndexObservations = this.hasRetrievalSearch(omConfig.retrieval) ? async (observation) => {
17606
17606
  await this.indexObservation(observation);
17607
17607
  } : void 0;
@@ -18526,18 +18526,18 @@ Notes:
18526
18526
  if (!effectiveConfig) return null;
18527
18527
  const engine = await this.omEngine;
18528
18528
  if (!engine) return null;
18529
- const { ObservationalMemoryProcessor } = await import('./observational-memory-FCDIQ3SX.cjs');
18529
+ const { ObservationalMemoryProcessor } = await import('./observational-memory-FPGLTCDV.cjs');
18530
18530
  return new ObservationalMemoryProcessor(engine, this);
18531
18531
  }
18532
18532
  };
18533
18533
 
18534
18534
  Object.defineProperty(exports, "ModelByInputTokens", {
18535
18535
  enumerable: true,
18536
- get: function () { return chunkEOHXGI4J_cjs.ModelByInputTokens; }
18536
+ get: function () { return chunk3MHY4GB4_cjs.ModelByInputTokens; }
18537
18537
  });
18538
18538
  Object.defineProperty(exports, "getObservationsAsOf", {
18539
18539
  enumerable: true,
18540
- get: function () { return chunkEOHXGI4J_cjs.getObservationsAsOf; }
18540
+ get: function () { return chunk3MHY4GB4_cjs.getObservationsAsOf; }
18541
18541
  });
18542
18542
  Object.defineProperty(exports, "extractWorkingMemoryContent", {
18543
18543
  enumerable: true,
package/dist/index.js CHANGED
@@ -1,7 +1,7 @@
1
1
  import { __commonJS, require_token_error, __toESM } from './chunk-SVPZMV27.js';
2
2
  import { __commonJS as __commonJS$1, require_token_error as require_token_error$1, __toESM as __toESM$1 } from './chunk-RC6RZVYE.js';
3
- import { truncateStringByTokens, resolveToolResultValue, formatToolResultForObserver } from './chunk-MGHUIRKN.js';
4
- export { ModelByInputTokens, getObservationsAsOf } from './chunk-MGHUIRKN.js';
3
+ import { truncateStringByTokens, resolveToolResultValue, formatToolResultForObserver } from './chunk-25XLVCFF.js';
4
+ export { ModelByInputTokens, getObservationsAsOf } from './chunk-25XLVCFF.js';
5
5
  import { ZodFirstPartyTypeKind } from 'zod/v3';
6
6
  import { z } from 'zod';
7
7
  import * as z4 from 'zod/v4';
@@ -17579,7 +17579,7 @@ ${workingMemory}`;
17579
17579
  "Observational memory requires @mastra/core support for request-response-id-rotation. Please bump @mastra/core to a newer version."
17580
17580
  );
17581
17581
  }
17582
- const { ObservationalMemory: OMClass } = await import('./observational-memory-WJ4BDRUP.js');
17582
+ const { ObservationalMemory: OMClass } = await import('./observational-memory-IL63MWVI.js');
17583
17583
  const onIndexObservations = this.hasRetrievalSearch(omConfig.retrieval) ? async (observation) => {
17584
17584
  await this.indexObservation(observation);
17585
17585
  } : void 0;
@@ -18504,7 +18504,7 @@ Notes:
18504
18504
  if (!effectiveConfig) return null;
18505
18505
  const engine = await this.omEngine;
18506
18506
  if (!engine) return null;
18507
- const { ObservationalMemoryProcessor } = await import('./observational-memory-WJ4BDRUP.js');
18507
+ const { ObservationalMemoryProcessor } = await import('./observational-memory-IL63MWVI.js');
18508
18508
  return new ObservationalMemoryProcessor(engine, this);
18509
18509
  }
18510
18510
  };
@@ -1,101 +1,101 @@
1
1
  'use strict';
2
2
 
3
- var chunkEOHXGI4J_cjs = require('./chunk-EOHXGI4J.cjs');
3
+ var chunk3MHY4GB4_cjs = require('./chunk-3MHY4GB4.cjs');
4
4
  var chunkD4J4XPGM_cjs = require('./chunk-D4J4XPGM.cjs');
5
5
 
6
6
 
7
7
 
8
8
  Object.defineProperty(exports, "ModelByInputTokens", {
9
9
  enumerable: true,
10
- get: function () { return chunkEOHXGI4J_cjs.ModelByInputTokens; }
10
+ get: function () { return chunk3MHY4GB4_cjs.ModelByInputTokens; }
11
11
  });
12
12
  Object.defineProperty(exports, "OBSERVER_SYSTEM_PROMPT", {
13
13
  enumerable: true,
14
- get: function () { return chunkEOHXGI4J_cjs.OBSERVER_SYSTEM_PROMPT; }
14
+ get: function () { return chunk3MHY4GB4_cjs.OBSERVER_SYSTEM_PROMPT; }
15
15
  });
16
16
  Object.defineProperty(exports, "ObservationalMemory", {
17
17
  enumerable: true,
18
- get: function () { return chunkEOHXGI4J_cjs.ObservationalMemory; }
18
+ get: function () { return chunk3MHY4GB4_cjs.ObservationalMemory; }
19
19
  });
20
20
  Object.defineProperty(exports, "ObservationalMemoryProcessor", {
21
21
  enumerable: true,
22
- get: function () { return chunkEOHXGI4J_cjs.ObservationalMemoryProcessor; }
22
+ get: function () { return chunk3MHY4GB4_cjs.ObservationalMemoryProcessor; }
23
23
  });
24
24
  Object.defineProperty(exports, "TokenCounter", {
25
25
  enumerable: true,
26
- get: function () { return chunkEOHXGI4J_cjs.TokenCounter; }
26
+ get: function () { return chunk3MHY4GB4_cjs.TokenCounter; }
27
27
  });
28
28
  Object.defineProperty(exports, "buildObserverPrompt", {
29
29
  enumerable: true,
30
- get: function () { return chunkEOHXGI4J_cjs.buildObserverPrompt; }
30
+ get: function () { return chunk3MHY4GB4_cjs.buildObserverPrompt; }
31
31
  });
32
32
  Object.defineProperty(exports, "buildObserverSystemPrompt", {
33
33
  enumerable: true,
34
- get: function () { return chunkEOHXGI4J_cjs.buildObserverSystemPrompt; }
34
+ get: function () { return chunk3MHY4GB4_cjs.buildObserverSystemPrompt; }
35
35
  });
36
36
  Object.defineProperty(exports, "combineObservationGroupRanges", {
37
37
  enumerable: true,
38
- get: function () { return chunkEOHXGI4J_cjs.combineObservationGroupRanges; }
38
+ get: function () { return chunk3MHY4GB4_cjs.combineObservationGroupRanges; }
39
39
  });
40
40
  Object.defineProperty(exports, "deriveObservationGroupProvenance", {
41
41
  enumerable: true,
42
- get: function () { return chunkEOHXGI4J_cjs.deriveObservationGroupProvenance; }
42
+ get: function () { return chunk3MHY4GB4_cjs.deriveObservationGroupProvenance; }
43
43
  });
44
44
  Object.defineProperty(exports, "extractCurrentTask", {
45
45
  enumerable: true,
46
- get: function () { return chunkEOHXGI4J_cjs.extractCurrentTask; }
46
+ get: function () { return chunk3MHY4GB4_cjs.extractCurrentTask; }
47
47
  });
48
48
  Object.defineProperty(exports, "formatMessagesForObserver", {
49
49
  enumerable: true,
50
- get: function () { return chunkEOHXGI4J_cjs.formatMessagesForObserver; }
50
+ get: function () { return chunk3MHY4GB4_cjs.formatMessagesForObserver; }
51
51
  });
52
52
  Object.defineProperty(exports, "getObservationsAsOf", {
53
53
  enumerable: true,
54
- get: function () { return chunkEOHXGI4J_cjs.getObservationsAsOf; }
54
+ get: function () { return chunk3MHY4GB4_cjs.getObservationsAsOf; }
55
55
  });
56
56
  Object.defineProperty(exports, "hasCurrentTaskSection", {
57
57
  enumerable: true,
58
- get: function () { return chunkEOHXGI4J_cjs.hasCurrentTaskSection; }
58
+ get: function () { return chunk3MHY4GB4_cjs.hasCurrentTaskSection; }
59
59
  });
60
60
  Object.defineProperty(exports, "injectAnchorIds", {
61
61
  enumerable: true,
62
- get: function () { return chunkEOHXGI4J_cjs.injectAnchorIds; }
62
+ get: function () { return chunk3MHY4GB4_cjs.injectAnchorIds; }
63
63
  });
64
64
  Object.defineProperty(exports, "optimizeObservationsForContext", {
65
65
  enumerable: true,
66
- get: function () { return chunkEOHXGI4J_cjs.optimizeObservationsForContext; }
66
+ get: function () { return chunk3MHY4GB4_cjs.optimizeObservationsForContext; }
67
67
  });
68
68
  Object.defineProperty(exports, "parseAnchorId", {
69
69
  enumerable: true,
70
- get: function () { return chunkEOHXGI4J_cjs.parseAnchorId; }
70
+ get: function () { return chunk3MHY4GB4_cjs.parseAnchorId; }
71
71
  });
72
72
  Object.defineProperty(exports, "parseObservationGroups", {
73
73
  enumerable: true,
74
- get: function () { return chunkEOHXGI4J_cjs.parseObservationGroups; }
74
+ get: function () { return chunk3MHY4GB4_cjs.parseObservationGroups; }
75
75
  });
76
76
  Object.defineProperty(exports, "parseObserverOutput", {
77
77
  enumerable: true,
78
- get: function () { return chunkEOHXGI4J_cjs.parseObserverOutput; }
78
+ get: function () { return chunk3MHY4GB4_cjs.parseObserverOutput; }
79
79
  });
80
80
  Object.defineProperty(exports, "reconcileObservationGroupsFromReflection", {
81
81
  enumerable: true,
82
- get: function () { return chunkEOHXGI4J_cjs.reconcileObservationGroupsFromReflection; }
82
+ get: function () { return chunk3MHY4GB4_cjs.reconcileObservationGroupsFromReflection; }
83
83
  });
84
84
  Object.defineProperty(exports, "renderObservationGroupsForReflection", {
85
85
  enumerable: true,
86
- get: function () { return chunkEOHXGI4J_cjs.renderObservationGroupsForReflection; }
86
+ get: function () { return chunk3MHY4GB4_cjs.renderObservationGroupsForReflection; }
87
87
  });
88
88
  Object.defineProperty(exports, "stripEphemeralAnchorIds", {
89
89
  enumerable: true,
90
- get: function () { return chunkEOHXGI4J_cjs.stripEphemeralAnchorIds; }
90
+ get: function () { return chunk3MHY4GB4_cjs.stripEphemeralAnchorIds; }
91
91
  });
92
92
  Object.defineProperty(exports, "stripObservationGroups", {
93
93
  enumerable: true,
94
- get: function () { return chunkEOHXGI4J_cjs.stripObservationGroups; }
94
+ get: function () { return chunk3MHY4GB4_cjs.stripObservationGroups; }
95
95
  });
96
96
  Object.defineProperty(exports, "wrapInObservationGroup", {
97
97
  enumerable: true,
98
- get: function () { return chunkEOHXGI4J_cjs.wrapInObservationGroup; }
98
+ get: function () { return chunk3MHY4GB4_cjs.wrapInObservationGroup; }
99
99
  });
100
100
  Object.defineProperty(exports, "OBSERVATIONAL_MEMORY_DEFAULTS", {
101
101
  enumerable: true,
@@ -113,5 +113,5 @@ Object.defineProperty(exports, "OBSERVATION_CONTINUATION_HINT", {
113
113
  enumerable: true,
114
114
  get: function () { return chunkD4J4XPGM_cjs.OBSERVATION_CONTINUATION_HINT; }
115
115
  });
116
- //# sourceMappingURL=observational-memory-FCDIQ3SX.cjs.map
117
- //# sourceMappingURL=observational-memory-FCDIQ3SX.cjs.map
116
+ //# sourceMappingURL=observational-memory-FPGLTCDV.cjs.map
117
+ //# sourceMappingURL=observational-memory-FPGLTCDV.cjs.map
@@ -1 +1 @@
1
- {"version":3,"sources":[],"names":[],"mappings":"","file":"observational-memory-FCDIQ3SX.cjs"}
1
+ {"version":3,"sources":[],"names":[],"mappings":"","file":"observational-memory-FPGLTCDV.cjs"}
@@ -1,4 +1,4 @@
1
- export { ModelByInputTokens, OBSERVER_SYSTEM_PROMPT, ObservationalMemory, ObservationalMemoryProcessor, TokenCounter, buildObserverPrompt, buildObserverSystemPrompt, combineObservationGroupRanges, deriveObservationGroupProvenance, extractCurrentTask, formatMessagesForObserver, getObservationsAsOf, hasCurrentTaskSection, injectAnchorIds, optimizeObservationsForContext, parseAnchorId, parseObservationGroups, parseObserverOutput, reconcileObservationGroupsFromReflection, renderObservationGroupsForReflection, stripEphemeralAnchorIds, stripObservationGroups, wrapInObservationGroup } from './chunk-MGHUIRKN.js';
1
+ export { ModelByInputTokens, OBSERVER_SYSTEM_PROMPT, ObservationalMemory, ObservationalMemoryProcessor, TokenCounter, buildObserverPrompt, buildObserverSystemPrompt, combineObservationGroupRanges, deriveObservationGroupProvenance, extractCurrentTask, formatMessagesForObserver, getObservationsAsOf, hasCurrentTaskSection, injectAnchorIds, optimizeObservationsForContext, parseAnchorId, parseObservationGroups, parseObserverOutput, reconcileObservationGroupsFromReflection, renderObservationGroupsForReflection, stripEphemeralAnchorIds, stripObservationGroups, wrapInObservationGroup } from './chunk-25XLVCFF.js';
2
2
  export { OBSERVATIONAL_MEMORY_DEFAULTS, OBSERVATION_CONTEXT_INSTRUCTIONS, OBSERVATION_CONTEXT_PROMPT, OBSERVATION_CONTINUATION_HINT } from './chunk-LSJJAJAF.js';
3
- //# sourceMappingURL=observational-memory-WJ4BDRUP.js.map
4
- //# sourceMappingURL=observational-memory-WJ4BDRUP.js.map
3
+ //# sourceMappingURL=observational-memory-IL63MWVI.js.map
4
+ //# sourceMappingURL=observational-memory-IL63MWVI.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":[],"names":[],"mappings":"","file":"observational-memory-WJ4BDRUP.js"}
1
+ {"version":3,"sources":[],"names":[],"mappings":"","file":"observational-memory-IL63MWVI.js"}
@@ -1,101 +1,101 @@
1
1
  'use strict';
2
2
 
3
- var chunkEOHXGI4J_cjs = require('../chunk-EOHXGI4J.cjs');
3
+ var chunk3MHY4GB4_cjs = require('../chunk-3MHY4GB4.cjs');
4
4
  var chunkD4J4XPGM_cjs = require('../chunk-D4J4XPGM.cjs');
5
5
 
6
6
 
7
7
 
8
8
  Object.defineProperty(exports, "ModelByInputTokens", {
9
9
  enumerable: true,
10
- get: function () { return chunkEOHXGI4J_cjs.ModelByInputTokens; }
10
+ get: function () { return chunk3MHY4GB4_cjs.ModelByInputTokens; }
11
11
  });
12
12
  Object.defineProperty(exports, "OBSERVER_SYSTEM_PROMPT", {
13
13
  enumerable: true,
14
- get: function () { return chunkEOHXGI4J_cjs.OBSERVER_SYSTEM_PROMPT; }
14
+ get: function () { return chunk3MHY4GB4_cjs.OBSERVER_SYSTEM_PROMPT; }
15
15
  });
16
16
  Object.defineProperty(exports, "ObservationalMemory", {
17
17
  enumerable: true,
18
- get: function () { return chunkEOHXGI4J_cjs.ObservationalMemory; }
18
+ get: function () { return chunk3MHY4GB4_cjs.ObservationalMemory; }
19
19
  });
20
20
  Object.defineProperty(exports, "ObservationalMemoryProcessor", {
21
21
  enumerable: true,
22
- get: function () { return chunkEOHXGI4J_cjs.ObservationalMemoryProcessor; }
22
+ get: function () { return chunk3MHY4GB4_cjs.ObservationalMemoryProcessor; }
23
23
  });
24
24
  Object.defineProperty(exports, "TokenCounter", {
25
25
  enumerable: true,
26
- get: function () { return chunkEOHXGI4J_cjs.TokenCounter; }
26
+ get: function () { return chunk3MHY4GB4_cjs.TokenCounter; }
27
27
  });
28
28
  Object.defineProperty(exports, "buildObserverPrompt", {
29
29
  enumerable: true,
30
- get: function () { return chunkEOHXGI4J_cjs.buildObserverPrompt; }
30
+ get: function () { return chunk3MHY4GB4_cjs.buildObserverPrompt; }
31
31
  });
32
32
  Object.defineProperty(exports, "buildObserverSystemPrompt", {
33
33
  enumerable: true,
34
- get: function () { return chunkEOHXGI4J_cjs.buildObserverSystemPrompt; }
34
+ get: function () { return chunk3MHY4GB4_cjs.buildObserverSystemPrompt; }
35
35
  });
36
36
  Object.defineProperty(exports, "combineObservationGroupRanges", {
37
37
  enumerable: true,
38
- get: function () { return chunkEOHXGI4J_cjs.combineObservationGroupRanges; }
38
+ get: function () { return chunk3MHY4GB4_cjs.combineObservationGroupRanges; }
39
39
  });
40
40
  Object.defineProperty(exports, "deriveObservationGroupProvenance", {
41
41
  enumerable: true,
42
- get: function () { return chunkEOHXGI4J_cjs.deriveObservationGroupProvenance; }
42
+ get: function () { return chunk3MHY4GB4_cjs.deriveObservationGroupProvenance; }
43
43
  });
44
44
  Object.defineProperty(exports, "extractCurrentTask", {
45
45
  enumerable: true,
46
- get: function () { return chunkEOHXGI4J_cjs.extractCurrentTask; }
46
+ get: function () { return chunk3MHY4GB4_cjs.extractCurrentTask; }
47
47
  });
48
48
  Object.defineProperty(exports, "formatMessagesForObserver", {
49
49
  enumerable: true,
50
- get: function () { return chunkEOHXGI4J_cjs.formatMessagesForObserver; }
50
+ get: function () { return chunk3MHY4GB4_cjs.formatMessagesForObserver; }
51
51
  });
52
52
  Object.defineProperty(exports, "getObservationsAsOf", {
53
53
  enumerable: true,
54
- get: function () { return chunkEOHXGI4J_cjs.getObservationsAsOf; }
54
+ get: function () { return chunk3MHY4GB4_cjs.getObservationsAsOf; }
55
55
  });
56
56
  Object.defineProperty(exports, "hasCurrentTaskSection", {
57
57
  enumerable: true,
58
- get: function () { return chunkEOHXGI4J_cjs.hasCurrentTaskSection; }
58
+ get: function () { return chunk3MHY4GB4_cjs.hasCurrentTaskSection; }
59
59
  });
60
60
  Object.defineProperty(exports, "injectAnchorIds", {
61
61
  enumerable: true,
62
- get: function () { return chunkEOHXGI4J_cjs.injectAnchorIds; }
62
+ get: function () { return chunk3MHY4GB4_cjs.injectAnchorIds; }
63
63
  });
64
64
  Object.defineProperty(exports, "optimizeObservationsForContext", {
65
65
  enumerable: true,
66
- get: function () { return chunkEOHXGI4J_cjs.optimizeObservationsForContext; }
66
+ get: function () { return chunk3MHY4GB4_cjs.optimizeObservationsForContext; }
67
67
  });
68
68
  Object.defineProperty(exports, "parseAnchorId", {
69
69
  enumerable: true,
70
- get: function () { return chunkEOHXGI4J_cjs.parseAnchorId; }
70
+ get: function () { return chunk3MHY4GB4_cjs.parseAnchorId; }
71
71
  });
72
72
  Object.defineProperty(exports, "parseObservationGroups", {
73
73
  enumerable: true,
74
- get: function () { return chunkEOHXGI4J_cjs.parseObservationGroups; }
74
+ get: function () { return chunk3MHY4GB4_cjs.parseObservationGroups; }
75
75
  });
76
76
  Object.defineProperty(exports, "parseObserverOutput", {
77
77
  enumerable: true,
78
- get: function () { return chunkEOHXGI4J_cjs.parseObserverOutput; }
78
+ get: function () { return chunk3MHY4GB4_cjs.parseObserverOutput; }
79
79
  });
80
80
  Object.defineProperty(exports, "reconcileObservationGroupsFromReflection", {
81
81
  enumerable: true,
82
- get: function () { return chunkEOHXGI4J_cjs.reconcileObservationGroupsFromReflection; }
82
+ get: function () { return chunk3MHY4GB4_cjs.reconcileObservationGroupsFromReflection; }
83
83
  });
84
84
  Object.defineProperty(exports, "renderObservationGroupsForReflection", {
85
85
  enumerable: true,
86
- get: function () { return chunkEOHXGI4J_cjs.renderObservationGroupsForReflection; }
86
+ get: function () { return chunk3MHY4GB4_cjs.renderObservationGroupsForReflection; }
87
87
  });
88
88
  Object.defineProperty(exports, "stripEphemeralAnchorIds", {
89
89
  enumerable: true,
90
- get: function () { return chunkEOHXGI4J_cjs.stripEphemeralAnchorIds; }
90
+ get: function () { return chunk3MHY4GB4_cjs.stripEphemeralAnchorIds; }
91
91
  });
92
92
  Object.defineProperty(exports, "stripObservationGroups", {
93
93
  enumerable: true,
94
- get: function () { return chunkEOHXGI4J_cjs.stripObservationGroups; }
94
+ get: function () { return chunk3MHY4GB4_cjs.stripObservationGroups; }
95
95
  });
96
96
  Object.defineProperty(exports, "wrapInObservationGroup", {
97
97
  enumerable: true,
98
- get: function () { return chunkEOHXGI4J_cjs.wrapInObservationGroup; }
98
+ get: function () { return chunk3MHY4GB4_cjs.wrapInObservationGroup; }
99
99
  });
100
100
  Object.defineProperty(exports, "OBSERVATIONAL_MEMORY_DEFAULTS", {
101
101
  enumerable: true,
@@ -1,4 +1,4 @@
1
- export { ModelByInputTokens, OBSERVER_SYSTEM_PROMPT, ObservationalMemory, ObservationalMemoryProcessor, TokenCounter, buildObserverPrompt, buildObserverSystemPrompt, combineObservationGroupRanges, deriveObservationGroupProvenance, extractCurrentTask, formatMessagesForObserver, getObservationsAsOf, hasCurrentTaskSection, injectAnchorIds, optimizeObservationsForContext, parseAnchorId, parseObservationGroups, parseObserverOutput, reconcileObservationGroupsFromReflection, renderObservationGroupsForReflection, stripEphemeralAnchorIds, stripObservationGroups, wrapInObservationGroup } from '../chunk-MGHUIRKN.js';
1
+ export { ModelByInputTokens, OBSERVER_SYSTEM_PROMPT, ObservationalMemory, ObservationalMemoryProcessor, TokenCounter, buildObserverPrompt, buildObserverSystemPrompt, combineObservationGroupRanges, deriveObservationGroupProvenance, extractCurrentTask, formatMessagesForObserver, getObservationsAsOf, hasCurrentTaskSection, injectAnchorIds, optimizeObservationsForContext, parseAnchorId, parseObservationGroups, parseObserverOutput, reconcileObservationGroupsFromReflection, renderObservationGroupsForReflection, stripEphemeralAnchorIds, stripObservationGroups, wrapInObservationGroup } from '../chunk-25XLVCFF.js';
2
2
  export { OBSERVATIONAL_MEMORY_DEFAULTS, OBSERVATION_CONTEXT_INSTRUCTIONS, OBSERVATION_CONTEXT_PROMPT, OBSERVATION_CONTINUATION_HINT } from '../chunk-LSJJAJAF.js';
3
3
  //# sourceMappingURL=index.js.map
4
4
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"message-utils.d.ts","sourceRoot":"","sources":["../../../src/processors/observational-memory/message-utils.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AACvE,OAAO,KAAK,EAAE,wBAAwB,EAAE,yBAAyB,EAAE,MAAM,sBAAsB,CAAC;AAEhG;;;GAGG;AACH,wBAAgB,oCAAoC,CAAC,OAAO,EAAE,eAAe,GAAG,MAAM,CAYrF;AAED;;;;;GAKG;AACH,wBAAgB,kBAAkB,CAAC,OAAO,EAAE,eAAe,GAAG,eAAe,CAAC,SAAS,CAAC,CAAC,OAAO,CAAC,CAoBhG;AAED;;GAEG;AACH,wBAAgB,kBAAkB,CAAC,OAAO,EAAE,eAAe,GAAG,OAAO,CAEpE;AAED;;;GAGG;AACH,wBAAgB,4BAA4B,CAC1C,QAAQ,EAAE,eAAe,EAAE,GAC1B;IAAE,SAAS,EAAE,MAAM,CAAC;IAAC,EAAE,EAAE,MAAM,CAAA;CAAE,GAAG,SAAS,CAS/C;AAED;;GAEG;AACH,wBAAgB,yBAAyB,CAAC,GAAG,EAAE,eAAe,EAAE,MAAM,EAAE;IAAE,SAAS,EAAE,MAAM,CAAC;IAAC,EAAE,EAAE,MAAM,CAAA;CAAE,GAAG,OAAO,CAMlH;AAED;;;GAGG;AACH;;;;;;GAMG;AACH,wBAAgB,sBAAsB,CAAC,IAAI,EAAE;IAC3C,WAAW,EAAE,WAAW,CAAC;IACzB,MAAM,CAAC,EAAE,yBAAyB,CAAC;IACnC,wBAAwB,CAAC,EAAE,OAAO,CAAC;IACnC,cAAc,CAAC,EAAE;QAAE,SAAS,EAAE,MAAM,CAAC;QAAC,EAAE,EAAE,MAAM,CAAA;KAAE,CAAC;CACpD,GAAG,IAAI,CAuEP;AAED,wBAAgB,iBAAiB,CAAC,MAAM,EAAE,yBAAyB,GAAG,IAAI,GAAG,SAAS,GAAG,wBAAwB,EAAE,CAYlH;AAED;;;GAGG;AACH;;GAEG;AACH,wBAAgB,+BAA+B,CAC7C,kBAAkB,EAAE,MAAM,GAAG,SAAS,EACtC,oBAAoB,EAAE,MAAM,GAAG,SAAS,GACvC,MAAM,GAAG,SAAS,CAKpB;AAED,wBAAgB,0BAA0B,CAAC,gBAAgB,EAAE,GAAG,CAAC,MAAM,EAAE,eAAe,EAAE,CAAC,GAAG,MAAM,EAAE,CAQrG;AAED;;;GAGG;AACH,wBAAgB,eAAe,CAAC,YAAY,EAAE,MAAM,GAAG,MAAM,CAE5D"}
1
+ {"version":3,"file":"message-utils.d.ts","sourceRoot":"","sources":["../../../src/processors/observational-memory/message-utils.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AACvE,OAAO,KAAK,EAAE,wBAAwB,EAAE,yBAAyB,EAAE,MAAM,sBAAsB,CAAC;AAEhG;;;GAGG;AACH,wBAAgB,oCAAoC,CAAC,OAAO,EAAE,eAAe,GAAG,MAAM,CAYrF;AAED;;;;;GAKG;AACH,wBAAgB,kBAAkB,CAAC,OAAO,EAAE,eAAe,GAAG,eAAe,CAAC,SAAS,CAAC,CAAC,OAAO,CAAC,CAoBhG;AAED;;GAEG;AACH,wBAAgB,kBAAkB,CAAC,OAAO,EAAE,eAAe,GAAG,OAAO,CAEpE;AAED;;;GAGG;AACH,wBAAgB,4BAA4B,CAC1C,QAAQ,EAAE,eAAe,EAAE,GAC1B;IAAE,SAAS,EAAE,MAAM,CAAC;IAAC,EAAE,EAAE,MAAM,CAAA;CAAE,GAAG,SAAS,CAS/C;AAED;;GAEG;AACH,wBAAgB,yBAAyB,CAAC,GAAG,EAAE,eAAe,EAAE,MAAM,EAAE;IAAE,SAAS,EAAE,MAAM,CAAC;IAAC,EAAE,EAAE,MAAM,CAAA;CAAE,GAAG,OAAO,CAMlH;AAED;;;GAGG;AACH;;;;;;GAMG;AACH,wBAAgB,sBAAsB,CAAC,IAAI,EAAE;IAC3C,WAAW,EAAE,WAAW,CAAC;IACzB,MAAM,CAAC,EAAE,yBAAyB,CAAC;IACnC,wBAAwB,CAAC,EAAE,OAAO,CAAC;IACnC,cAAc,CAAC,EAAE;QAAE,SAAS,EAAE,MAAM,CAAC;QAAC,EAAE,EAAE,MAAM,CAAA;KAAE,CAAC;CACpD,GAAG,IAAI,CAuEP;AAED,wBAAgB,iBAAiB,CAAC,MAAM,EAAE,yBAAyB,GAAG,IAAI,GAAG,SAAS,GAAG,wBAAwB,EAAE,CAYlH;AAED;;;GAGG;AACH;;GAEG;AACH,wBAAgB,+BAA+B,CAC7C,kBAAkB,EAAE,MAAM,GAAG,SAAS,EACtC,oBAAoB,EAAE,MAAM,GAAG,SAAS,GACvC,MAAM,GAAG,SAAS,CAKpB;AAED,wBAAgB,0BAA0B,CAAC,gBAAgB,EAAE,GAAG,CAAC,MAAM,EAAE,eAAe,EAAE,CAAC,GAAG,MAAM,EAAE,CAQrG;AAED;;;GAGG;AACH,wBAAgB,eAAe,CAAC,YAAY,EAAE,MAAM,GAAG,MAAM,CAM5D"}