@mastra/memory 1.9.0-alpha.1 → 1.9.0-alpha.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.
Files changed (51) hide show
  1. package/CHANGELOG.md +20 -0
  2. package/dist/{chunk-5SMKVGJP.js → chunk-JJBSFPC5.js} +315 -25
  3. package/dist/chunk-JJBSFPC5.js.map +1 -0
  4. package/dist/{chunk-AR52LM55.cjs → chunk-LVV2RT42.cjs} +327 -24
  5. package/dist/chunk-LVV2RT42.cjs.map +1 -0
  6. package/dist/docs/SKILL.md +5 -7
  7. package/dist/docs/assets/SOURCE_MAP.json +77 -27
  8. package/dist/docs/references/docs-agents-agent-approval.md +114 -193
  9. package/dist/docs/references/docs-agents-networks.md +88 -205
  10. package/dist/docs/references/docs-agents-supervisor-agents.md +24 -18
  11. package/dist/docs/references/docs-memory-observational-memory.md +30 -2
  12. package/dist/docs/references/docs-memory-overview.md +219 -24
  13. package/dist/docs/references/docs-memory-semantic-recall.md +1 -1
  14. package/dist/docs/references/docs-memory-storage.md +4 -4
  15. package/dist/docs/references/docs-memory-working-memory.md +1 -1
  16. package/dist/docs/references/reference-core-getMemory.md +1 -2
  17. package/dist/docs/references/reference-core-listMemory.md +1 -2
  18. package/dist/docs/references/reference-memory-cloneThread.md +1 -1
  19. package/dist/docs/references/reference-memory-observational-memory.md +39 -1
  20. package/dist/index.cjs +432 -11
  21. package/dist/index.cjs.map +1 -1
  22. package/dist/index.d.ts.map +1 -1
  23. package/dist/index.js +432 -10
  24. package/dist/index.js.map +1 -1
  25. package/dist/observational-memory-3XFCO6MX.js +3 -0
  26. package/dist/{observational-memory-5NFPG6M3.js.map → observational-memory-3XFCO6MX.js.map} +1 -1
  27. package/dist/observational-memory-MJJFU26W.cjs +108 -0
  28. package/dist/{observational-memory-NH7VDTXM.cjs.map → observational-memory-MJJFU26W.cjs.map} +1 -1
  29. package/dist/processors/index.cjs +56 -16
  30. package/dist/processors/index.js +1 -1
  31. package/dist/processors/observational-memory/anchor-ids.d.ts +4 -0
  32. package/dist/processors/observational-memory/anchor-ids.d.ts.map +1 -0
  33. package/dist/processors/observational-memory/index.d.ts +2 -0
  34. package/dist/processors/observational-memory/index.d.ts.map +1 -1
  35. package/dist/processors/observational-memory/observation-groups.d.ts +15 -0
  36. package/dist/processors/observational-memory/observation-groups.d.ts.map +1 -0
  37. package/dist/processors/observational-memory/observational-memory.d.ts +14 -0
  38. package/dist/processors/observational-memory/observational-memory.d.ts.map +1 -1
  39. package/dist/processors/observational-memory/observer-agent.d.ts.map +1 -1
  40. package/dist/processors/observational-memory/reflector-agent.d.ts +1 -1
  41. package/dist/processors/observational-memory/reflector-agent.d.ts.map +1 -1
  42. package/dist/processors/observational-memory/tool-result-helpers.d.ts.map +1 -1
  43. package/dist/tools/om-tools.d.ts +77 -0
  44. package/dist/tools/om-tools.d.ts.map +1 -0
  45. package/package.json +3 -3
  46. package/dist/chunk-5SMKVGJP.js.map +0 -1
  47. package/dist/chunk-AR52LM55.cjs.map +0 -1
  48. package/dist/docs/references/docs-agents-agent-memory.md +0 -209
  49. package/dist/docs/references/docs-agents-network-approval.md +0 -278
  50. package/dist/observational-memory-5NFPG6M3.js +0 -3
  51. package/dist/observational-memory-NH7VDTXM.cjs +0 -68
@@ -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.9.0-alpha.1"
6
+ version: "1.9.0-alpha.2"
7
7
  ---
8
8
 
9
9
  ## When to use
@@ -17,13 +17,11 @@ Read the individual reference documents for detailed explanations and code examp
17
17
  ### Docs
18
18
 
19
19
  - [Agent approval](references/docs-agents-agent-approval.md) - Learn how to require approvals, suspend tool execution, and automatically resume suspended tools while keeping humans in control of agent workflows.
20
- - [Agent memory](references/docs-agents-agent-memory.md) - Learn how to add memory to agents to store message history and maintain context across interactions.
21
- - [Network approval](references/docs-agents-network-approval.md) - Learn how to require approvals, suspend execution, and resume suspended networks while keeping humans in control of agent network workflows.
22
- - [Agent networks](references/docs-agents-networks.md) - Learn how to coordinate multiple agents, workflows, and tools using agent networks for complex, non-deterministic task execution.
23
- - [Supervisor agents](references/docs-agents-supervisor-agents.md) - Learn how to coordinate multiple agents using the supervisor pattern with delegation hooks, iteration monitoring, message filtering, and task completion scoring.
20
+ - [Agent networks](references/docs-agents-networks.md) - Coordinate multiple agents, workflows, and tools using agent networks for complex, non-deterministic task execution.
21
+ - [Supervisor agents](references/docs-agents-supervisor-agents.md) - Learn how to coordinate multiple agents with delegation hooks, iteration monitoring, message filtering, and task completion scoring.
24
22
  - [Memory processors](references/docs-memory-memory-processors.md) - Learn how to use memory processors in Mastra to filter, trim, and transform messages before they're sent to the language model to manage context window limits.
25
23
  - [Message history](references/docs-memory-message-history.md) - Learn how to configure message history in Mastra to store recent messages from the current conversation.
26
- - [Observational memory](references/docs-memory-observational-memory.md) - Learn how Observational Memory keeps your agent's context window small while preserving long-term memory across conversations.
24
+ - [Observational Memory](references/docs-memory-observational-memory.md) - Learn how Observational Memory keeps your agent's context window small while preserving long-term memory across conversations.
27
25
  - [Memory overview](references/docs-memory-overview.md) - Learn how Mastra's memory system works with working memory, message history, semantic recall, and observational memory.
28
26
  - [Semantic recall](references/docs-memory-semantic-recall.md) - Learn how to use semantic recall in Mastra to retrieve relevant messages from past conversations using vector search and embeddings.
29
27
  - [Storage](references/docs-memory-storage.md) - Configure storage for Mastra to persist conversations and other runtime state.
@@ -39,7 +37,7 @@ Read the individual reference documents for detailed explanations and code examp
39
37
  - [Reference: Memory.getThreadById()](references/reference-memory-getThreadById.md) - Documentation for the `Memory.getThreadById()` method in Mastra, which retrieves a specific thread by its ID.
40
38
  - [Reference: Memory.listThreads()](references/reference-memory-listThreads.md) - Documentation for the `Memory.listThreads()` method in Mastra, which retrieves threads with optional filtering by resourceId and/or metadata.
41
39
  - [Reference: Memory class](references/reference-memory-memory-class.md) - Documentation for the `Memory` class in Mastra, which provides a robust system for managing conversation history and thread-based message storage.
42
- - [Reference: Observational memory](references/reference-memory-observational-memory.md) - API reference for Observational Memory in Mastra — a three-tier memory system that uses Observer and Reflector agents to maintain long-term memory across conversations.
40
+ - [Reference: Observational Memory](references/reference-memory-observational-memory.md) - API reference for Observational Memory in Mastra — a three-tier memory system that uses Observer and Reflector agents to maintain long-term memory across conversations.
43
41
  - [Reference: TokenLimiterProcessor](references/reference-processors-token-limiter-processor.md) - Documentation for the TokenLimiterProcessor in Mastra, which limits the number of tokens in messages.
44
42
  - [Reference: DynamoDB storage](references/reference-storage-dynamodb.md) - Documentation for the DynamoDB storage implementation in Mastra, using a single-table design with ElectroDB.
45
43
  - [Reference: libSQL storage](references/reference-storage-libsql.md) - Documentation for the libSQL storage implementation in Mastra.
@@ -1,76 +1,126 @@
1
1
  {
2
- "version": "1.9.0-alpha.1",
2
+ "version": "1.9.0-alpha.2",
3
3
  "package": "@mastra/memory",
4
4
  "exports": {
5
5
  "OBSERVATIONAL_MEMORY_DEFAULTS": {
6
6
  "types": "dist/processors/index.d.ts",
7
- "implementation": "dist/chunk-5SMKVGJP.js"
7
+ "implementation": "dist/chunk-JJBSFPC5.js"
8
8
  },
9
9
  "OBSERVATION_CONTEXT_INSTRUCTIONS": {
10
10
  "types": "dist/processors/index.d.ts",
11
- "implementation": "dist/chunk-5SMKVGJP.js"
11
+ "implementation": "dist/chunk-JJBSFPC5.js"
12
12
  },
13
13
  "OBSERVATION_CONTEXT_PROMPT": {
14
14
  "types": "dist/processors/index.d.ts",
15
- "implementation": "dist/chunk-5SMKVGJP.js"
15
+ "implementation": "dist/chunk-JJBSFPC5.js"
16
16
  },
17
17
  "OBSERVATION_CONTINUATION_HINT": {
18
18
  "types": "dist/processors/index.d.ts",
19
- "implementation": "dist/chunk-5SMKVGJP.js"
19
+ "implementation": "dist/chunk-JJBSFPC5.js"
20
20
  },
21
21
  "OBSERVER_SYSTEM_PROMPT": {
22
22
  "types": "dist/processors/index.d.ts",
23
- "implementation": "dist/chunk-5SMKVGJP.js"
23
+ "implementation": "dist/chunk-JJBSFPC5.js"
24
24
  },
25
25
  "ObservationalMemory": {
26
26
  "types": "dist/processors/index.d.ts",
27
- "implementation": "dist/chunk-5SMKVGJP.js",
28
- "line": 3160
27
+ "implementation": "dist/chunk-JJBSFPC5.js",
28
+ "line": 3436
29
29
  },
30
30
  "TokenCounter": {
31
31
  "types": "dist/processors/index.d.ts",
32
- "implementation": "dist/chunk-5SMKVGJP.js",
33
- "line": 2649
32
+ "implementation": "dist/chunk-JJBSFPC5.js",
33
+ "line": 2867
34
34
  },
35
35
  "buildObserverPrompt": {
36
36
  "types": "dist/processors/index.d.ts",
37
- "implementation": "dist/chunk-5SMKVGJP.js",
38
- "line": 1256
37
+ "implementation": "dist/chunk-JJBSFPC5.js",
38
+ "line": 1471
39
39
  },
40
40
  "buildObserverSystemPrompt": {
41
41
  "types": "dist/processors/index.d.ts",
42
- "implementation": "dist/chunk-5SMKVGJP.js",
43
- "line": 723
42
+ "implementation": "dist/chunk-JJBSFPC5.js",
43
+ "line": 938
44
+ },
45
+ "combineObservationGroupRanges": {
46
+ "types": "dist/processors/index.d.ts",
47
+ "implementation": "dist/chunk-JJBSFPC5.js",
48
+ "line": 384
49
+ },
50
+ "deriveObservationGroupProvenance": {
51
+ "types": "dist/processors/index.d.ts",
52
+ "implementation": "dist/chunk-JJBSFPC5.js",
53
+ "line": 411
44
54
  },
45
55
  "extractCurrentTask": {
46
56
  "types": "dist/processors/index.d.ts",
47
- "implementation": "dist/chunk-5SMKVGJP.js",
48
- "line": 1370
57
+ "implementation": "dist/chunk-JJBSFPC5.js",
58
+ "line": 1585
49
59
  },
50
60
  "formatMessagesForObserver": {
51
61
  "types": "dist/processors/index.d.ts",
52
- "implementation": "dist/chunk-5SMKVGJP.js",
53
- "line": 989
62
+ "implementation": "dist/chunk-JJBSFPC5.js",
63
+ "line": 1204
54
64
  },
55
65
  "getObservationsAsOf": {
56
66
  "types": "dist/processors/index.d.ts",
57
- "implementation": "dist/chunk-5SMKVGJP.js",
58
- "line": 7254
67
+ "implementation": "dist/chunk-JJBSFPC5.js",
68
+ "line": 7544
59
69
  },
60
70
  "hasCurrentTaskSection": {
61
71
  "types": "dist/processors/index.d.ts",
62
- "implementation": "dist/chunk-5SMKVGJP.js",
63
- "line": 1358
72
+ "implementation": "dist/chunk-JJBSFPC5.js",
73
+ "line": 1573
74
+ },
75
+ "injectAnchorIds": {
76
+ "types": "dist/processors/index.d.ts",
77
+ "implementation": "dist/chunk-JJBSFPC5.js",
78
+ "line": 495
64
79
  },
65
80
  "optimizeObservationsForContext": {
66
81
  "types": "dist/processors/index.d.ts",
67
- "implementation": "dist/chunk-5SMKVGJP.js",
68
- "line": 1381
82
+ "implementation": "dist/chunk-JJBSFPC5.js",
83
+ "line": 1596
84
+ },
85
+ "parseAnchorId": {
86
+ "types": "dist/processors/index.d.ts",
87
+ "implementation": "dist/chunk-JJBSFPC5.js",
88
+ "line": 468
89
+ },
90
+ "parseObservationGroups": {
91
+ "types": "dist/processors/index.d.ts",
92
+ "implementation": "dist/chunk-JJBSFPC5.js",
93
+ "line": 356
69
94
  },
70
95
  "parseObserverOutput": {
71
96
  "types": "dist/processors/index.d.ts",
72
- "implementation": "dist/chunk-5SMKVGJP.js",
73
- "line": 1266
97
+ "implementation": "dist/chunk-JJBSFPC5.js",
98
+ "line": 1481
99
+ },
100
+ "reconcileObservationGroupsFromReflection": {
101
+ "types": "dist/processors/index.d.ts",
102
+ "implementation": "dist/chunk-JJBSFPC5.js",
103
+ "line": 438
104
+ },
105
+ "renderObservationGroupsForReflection": {
106
+ "types": "dist/processors/index.d.ts",
107
+ "implementation": "dist/chunk-JJBSFPC5.js",
108
+ "line": 391
109
+ },
110
+ "stripEphemeralAnchorIds": {
111
+ "types": "dist/processors/index.d.ts",
112
+ "implementation": "dist/chunk-JJBSFPC5.js",
113
+ "line": 525
114
+ },
115
+ "stripObservationGroups": {
116
+ "types": "dist/processors/index.d.ts",
117
+ "implementation": "dist/chunk-JJBSFPC5.js",
118
+ "line": 378
119
+ },
120
+ "wrapInObservationGroup": {
121
+ "types": "dist/processors/index.d.ts",
122
+ "implementation": "dist/chunk-JJBSFPC5.js",
123
+ "line": 349
74
124
  },
75
125
  "extractWorkingMemoryContent": {
76
126
  "types": "dist/index.d.ts",
@@ -101,7 +151,7 @@
101
151
  "processors": {
102
152
  "index": "dist/processors/index.js",
103
153
  "chunks": [
104
- "chunk-5SMKVGJP.js"
154
+ "chunk-JJBSFPC5.js"
105
155
  ]
106
156
  }
107
157
  }