You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix(managed-agent): floor event cap and make metadata clearing explicit
- A `maxItems` between 0 and 1 slipped past the zero guard and became
`slice(-0)` — the whole history — because slice truncates its index toward
zero. The cap is now floored at the library boundary, so no caller can hit
it whatever they pass.
- Update Session documented full metadata replacement but could not express
a clear: an empty map normalizes to "absent". Inferring the clear from
emptiness would be worse, since an untouched table is also empty and would
wipe metadata on every title-only update. Adds an explicit `clearMetadata`
instead, and corrects the parameter's documentation.
Copy file name to clipboardExpand all lines: apps/docs/content/docs/en/integrations/managed_agent.mdx
+2-1Lines changed: 2 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -161,7 +161,8 @@ Update a Managed Agent session's title or metadata.
161
161
| Parameter | Type | Required | Description |
162
162
| --------- | ---- | -------- | ----------- |
163
163
|`title`| string | No | New session title. |
164
-
|`sessionParameters`| object | No | Replacement metadata map \(replaces all stored metadata, not merged\). |
164
+
|`sessionParameters`| object | No | Replacement metadata map \(replaces all stored metadata, not merged\). Leaving it empty leaves the stored metadata unchanged — use clearMetadata to remove it. |
165
+
|`clearMetadata`| boolean | No | Removes all of the session's stored metadata. Overrides any map supplied above. |
description: 'Replacement metadata map (replaces all stored metadata, not merged).',
53
+
description:
54
+
'Replacement metadata map (replaces all stored metadata, not merged). Leaving it empty leaves the stored metadata unchanged — use clearMetadata to remove it.',
55
+
},
56
+
clearMetadata: {
57
+
type: 'boolean',
58
+
required: false,
59
+
visibility: 'user-or-llm',
60
+
description:
61
+
"Removes all of the session's stored metadata. Overrides any map supplied above.",
0 commit comments