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
Copy file name to clipboardExpand all lines: apps/docs/content/docs/en/integrations/managed_agent.mdx
+196Lines changed: 196 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -64,4 +64,200 @@ Open a Claude Platform Managed Agent session and return the assistant response a
64
64
|`inputTokens`| number | Cumulative input tokens for the session. |
65
65
|`outputTokens`| number | Cumulative output tokens for the session. |
66
66
67
+
### `managed_agent_create_session`
68
+
69
+
Create a Claude Platform Managed Agent session and return its id without waiting for a reply.
70
+
71
+
#### Input
72
+
73
+
| Parameter | Type | Required | Description |
74
+
| --------- | ---- | -------- | ----------- |
75
+
|`agent`| string | Yes | Managed-agent id inside the linked Claude workspace. |
76
+
|`environment`| string | Yes | Environment id inside the linked Claude workspace. |
77
+
|`environmentType`| string | No | Environment execution model hint \('cloud' \| 'self_hosted'\). |
78
+
|`userMessage`| string | No | Optional first message; seeds initial_events and starts the agent immediately. |
79
+
|`vaults`| array | No | Zero or more vault ids for MCP tool auth. |
80
+
|`vaultsAck`| boolean | No | Acknowledgement that the author may use the attached vaults. |
81
+
|`memoryStoreId`| string | No | Optional Agent Memory Store id. |
82
+
|`memoryAccess`| string | No | Memory store access mode: 'read_write' \(default\) or 'read_only'. |
83
+
|`memoryInstructions`| string | No | Per-attachment guidance for how the agent should use the memory store. |
84
+
|`files`| array | No | File attachments \(cloud envs only\), as \[\{fileId, mountPath?\}\]. |
85
+
|`sessionParameters`| object | No | Key/value session metadata forwarded to the session. |
86
+
87
+
#### Output
88
+
89
+
| Parameter | Type | Description |
90
+
| --------- | ---- | ----------- |
91
+
|`sessionId`| string | Anthropic session id \(sesn_...\). |
92
+
|`started`| boolean | True when a first message was seeded, so the agent is already running. |
93
+
94
+
### `managed_agent_send_message`
95
+
96
+
Send a user message to an existing Claude Platform Managed Agent session.
97
+
98
+
#### Input
99
+
100
+
| Parameter | Type | Required | Description |
101
+
| --------- | ---- | -------- | ----------- |
102
+
|`userMessage`| string | Yes | The user message to send to the session. |
103
+
104
+
#### Output
105
+
106
+
| Parameter | Type | Description |
107
+
| --------- | ---- | ----------- |
108
+
|`sessionId`| string | The session the message was sent to. |
109
+
|`sent`| boolean | True when the event was accepted by the API. |
110
+
111
+
### `managed_agent_get_session`
112
+
113
+
Read a Managed Agent session: status, stop reason, token usage, metadata, and any tool calls awaiting approval.
114
+
115
+
#### Input
116
+
117
+
| Parameter | Type | Required | Description |
118
+
| --------- | ---- | -------- | ----------- |
119
+
120
+
#### Output
121
+
122
+
| Parameter | Type | Description |
123
+
| --------- | ---- | ----------- |
124
+
|`sessionId`| string | The session that was read. |
125
+
|`status`| string | Session status — 'idle', 'running', 'rescheduling', or 'terminated'. |
126
+
|`stopReason`| string | Why the session last stopped, e.g. 'end_turn' or 'requires_action'. |
127
+
|`requiresAction`| boolean | True when the session is waiting on a tool confirmation or custom tool result. If this is true while pendingTools is empty, the session is blocked but the API named no blocking events — surface it rather than treating the session as done. |
128
+
|`pendingTools`| json | Blocking tool calls — \[\{id, eventType, kind, name, input\}\]. Route by kind: 'confirmation' ids go to Respond To Tool Confirmation, 'custom_tool_result' ids go to Respond To Custom Tool. |
129
+
|`metadata`| json | Session metadata. |
130
+
|`title`| string | Session title. |
131
+
|`inputTokens`| number | Cumulative input tokens. |
132
+
|`outputTokens`| number | Cumulative output tokens. |
133
+
134
+
### `managed_agent_list_events`
135
+
136
+
Read a Managed Agent session's event history and the agent's reply text.
137
+
138
+
#### Input
139
+
140
+
| Parameter | Type | Required | Description |
141
+
| --------- | ---- | -------- | ----------- |
142
+
|`eventTypes`| array | No | Optional event-type filter, e.g. \['agent.message'\]. Omit to return every event. |
143
+
|`limit`| number | No | Maximum events to return, keeping the most recent \(default 500\). |
144
+
145
+
#### Output
146
+
147
+
| Parameter | Type | Description |
148
+
| --------- | ---- | ----------- |
149
+
|`sessionId`| string | The session that was read. |
150
+
|`events`| json | Session events, oldest first. |
151
+
|`count`| number | Number of events returned. |
152
+
|`assistantText`| string | Concatenated text of every persisted agent.message, in order. |
153
+
|`truncated`| boolean | True when the limit was hit and older events were dropped. |
154
+
155
+
### `managed_agent_update_session`
156
+
157
+
Update a Managed Agent session's title or metadata.
158
+
159
+
#### Input
160
+
161
+
| Parameter | Type | Required | Description |
162
+
| --------- | ---- | -------- | ----------- |
163
+
|`title`| string | No | New session title. |
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. |
166
+
167
+
#### Output
168
+
169
+
| Parameter | Type | Description |
170
+
| --------- | ---- | ----------- |
171
+
|`sessionId`| string | The session that was updated. |
172
+
|`updated`| boolean | True when the update was accepted. |
173
+
|`metadata`| json | Metadata after the update. |
174
+
|`title`| string | Title after the update. |
175
+
176
+
### `managed_agent_interrupt_session`
177
+
178
+
Stop a running Managed Agent session; it stays usable afterwards.
179
+
180
+
#### Input
181
+
182
+
| Parameter | Type | Required | Description |
183
+
| --------- | ---- | -------- | ----------- |
184
+
185
+
#### Output
186
+
187
+
| Parameter | Type | Description |
188
+
| --------- | ---- | ----------- |
189
+
|`sessionId`| string | The session that was interrupted. |
190
+
|`interrupted`| boolean | True when the interrupt was accepted. |
191
+
192
+
### `managed_agent_respond_tool_confirmation`
193
+
194
+
Allow or deny the tool calls a Managed Agent session is waiting on before it can continue.
195
+
196
+
#### Input
197
+
198
+
| Parameter | Type | Required | Description |
199
+
| --------- | ---- | -------- | ----------- |
200
+
|`toolUseIds`| array | Yes | Blocking tool-use EVENT ids, from Get Session pendingTools\[\].id where kind is 'confirmation' \(not toolu_ ids\). |
201
+
|`decision`| string | Yes | 'allow' to let the tools run, or 'deny' to reject them. |
202
+
|`denyMessage`| string | No | Reason surfaced to the agent. Only sent when the decision is deny. |
203
+
204
+
#### Output
205
+
206
+
| Parameter | Type | Description |
207
+
| --------- | ---- | ----------- |
208
+
|`sessionId`| string | The session that was answered. |
209
+
|`decision`| string | The decision applied — 'allow' or 'deny'. |
210
+
|`confirmedToolUseIds`| json | The tool-use event ids that were answered. |
211
+
212
+
### `managed_agent_respond_custom_tool`
213
+
214
+
Return the result of a custom tool a Managed Agent session is waiting on so it can continue.
215
+
216
+
#### Input
217
+
218
+
| Parameter | Type | Required | Description |
219
+
| --------- | ---- | -------- | ----------- |
220
+
|`customToolUseId`| string | Yes | The custom tool-use EVENT id being answered, from Get Session pendingTools\[\].id where kind is 'custom_tool_result'. |
221
+
|`result`| string | Yes | The tool's output, returned to the agent as text. |
222
+
|`isError`| boolean | No | Mark the result as a failure so the agent can adjust its approach. |
223
+
224
+
#### Output
225
+
226
+
| Parameter | Type | Description |
227
+
| --------- | ---- | ----------- |
228
+
|`sessionId`| string | The session that was answered. |
229
+
|`answeredToolUseId`| string | The custom tool-use event id that was answered. |
230
+
231
+
### `managed_agent_archive_session`
232
+
233
+
Archive a Managed Agent session, preserving its history. Not reversible.
234
+
235
+
#### Input
236
+
237
+
| Parameter | Type | Required | Description |
238
+
| --------- | ---- | -------- | ----------- |
239
+
240
+
#### Output
241
+
242
+
| Parameter | Type | Description |
243
+
| --------- | ---- | ----------- |
244
+
|`sessionId`| string | The session that was archived. |
245
+
|`archived`| boolean | True when the archive was accepted. |
246
+
247
+
### `managed_agent_delete_session`
248
+
249
+
Permanently delete a Managed Agent session, its events, and its sandbox. Not reversible.
250
+
251
+
#### Input
252
+
253
+
| Parameter | Type | Required | Description |
254
+
| --------- | ---- | -------- | ----------- |
255
+
256
+
#### Output
257
+
258
+
| Parameter | Type | Description |
259
+
| --------- | ---- | ----------- |
260
+
|`sessionId`| string | The session that was deleted. |
261
+
|`deleted`| boolean | True when the delete was accepted. |
Copy file name to clipboardExpand all lines: apps/docs/content/docs/en/knowledgebase/using-in-workflows.mdx
+14Lines changed: 14 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -37,6 +37,19 @@ In our example, adding `Department equals "Billing"` makes the search consider o
37
37
38
38
Filters run before the vector comparison, so they make a search both more precise and cheaper. See [Tags and filtering](/knowledgebase/tags) for the full operator list by tag type.
39
39
40
+
## Retrieval Mode
41
+
42
+
**Retrieval Mode** is an advanced setting that chooses how matches are found.
43
+
44
+
| Mode | What it does |
45
+
| --- | --- |
46
+
| Vector only | The default. Ranks purely on meaning, as described above. |
47
+
| Hybrid | Also runs a keyword search over the same chunks and blends the two rankings. |
48
+
49
+
Semantic search is strong on paraphrase and weak on literal strings: an error code, a ticket key like `PROJ-1234`, a SKU, or a rare product name carries little meaning for the model, so the chunk containing it may not rank near the top. Hybrid adds a keyword pass that matches those tokens exactly, then merges the two lists so a chunk found by either signal can surface.
50
+
51
+
Turn it on when your documents are full of identifiers, codes, or names people search for verbatim. Leave it off for prose-heavy bases where questions are asked in natural language. Hybrid costs no extra API calls — the keyword pass runs entirely in the database.
52
+
40
53
## Rerank Results
41
54
42
55
**Rerank Results** is an optional second pass. Vector search ranks by raw similarity; reranking re-scores the top matches with a dedicated relevance model (Cohere's rerank models) and reorders them, which sharpens the ordering when the best answer isn't the literal closest vector.
@@ -95,6 +108,7 @@ When the agent's answer is off, the cause is usually in retrieval, not the agent
95
108
-**No results, or wrong documents.** A tag filter may be excluding what you want, or the documents may not be indexed yet. A document is only searchable once its processing status is `completed`; while it is `pending`, `processing`, or `failed`, its chunks won't appear.
96
109
-**Low similarity scores across the board.** The query is too vague, or the information simply isn't in the base. Rewrite the query to match how the documents phrase things.
97
110
-**Right documents, wrong order.** Turn on Rerank Results, or raise Number of Results so the relevant chunk is included.
111
+
-**An exact code, ID, or name isn't found.** Switch Retrieval Mode to Hybrid so a keyword pass runs alongside the semantic one.
98
112
99
113
See [debugging retrieval](/knowledgebase/debugging-retrieval) for the full diagnostic path, and [chunking strategies](/knowledgebase/chunking-strategies) for how chunk boundaries shape what a search can return.
|`COPILOT_API_KEY`| API key for copilot features |
67
+
|`COPILOT_API_KEY`| API key for Chat. Without it the Sim Chat block, scheduled prompt jobs, and Inbox cannot run |
68
+
|`NEXT_PUBLIC_CHAT_DISABLED`| Set to `true` to hide the Chat module: the workspace lands on your first workflow, with no chats list, scheduled tasks, or editor Chat panel. Chat is shown when unset; `bun run setup` sets it for you if you skip the chat key |
68
69
|`ADMIN_API_KEY`| Admin API key for GitOps operations |
69
70
|`ALLOWED_LOGIN_DOMAINS`| Restrict signups to domains (comma-separated) |
70
71
|`ALLOWED_LOGIN_EMAILS`| Restrict signups to specific emails (comma-separated) |
Copy file name to clipboardExpand all lines: apps/docs/content/docs/en/workflows/blocks/pi.mdx
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -211,7 +211,7 @@ The one case neither layer can rescue is a *first* prompt that already exceeds t
211
211
212
212
### Create PR [#setup-cloud-pr]
213
213
214
-
Create PR runs in a sandbox image with the Pi CLIand git baked in.
214
+
Create PR runs in a sandbox image with the Pi CLI, Git, Node.js, and Bun baked in. Repository dependencies are not preinstalled; Pi can run `bun install` when a repository needs them.
215
215
216
216
1.**Enable sandbox execution.** On self-hosted Sim, set `E2B_ENABLED=true`, `E2B_API_KEY`, `E2B_PI_TEMPLATE_ID` (the Pi template id), and `NEXT_PUBLIC_E2B_ENABLED=true` (this reveals Create PR, Update PR, and Review Code in the UI). Build the template with `bun run apps/sim/scripts/build-pi-e2b-template.ts`. These modes stay hidden until `NEXT_PUBLIC_E2B_ENABLED` is set.
Copy file name to clipboardExpand all lines: apps/docs/openapi.json
+9-2Lines changed: 9 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -6040,7 +6040,7 @@
6040
6040
"post": {
6041
6041
"operationId": "searchKnowledgeBase",
6042
6042
"summary": "Search Knowledge Base",
6043
-
"description": "Perform vector similarity search across one or more knowledge bases. Supports semantic search via query text, tag-based filtering, or a combination of both.",
6043
+
"description": "Search across one or more knowledge bases. Supports semantic search via query text, tag-based filtering, or a combination of both. Set `searchMode` to `hybrid` to additionally run a full-text keyword leg and fuse it with the semantic results.",
6044
6044
"tags": ["Knowledge Bases"],
6045
6045
"x-codeSamples": [
6046
6046
{
@@ -6095,14 +6095,21 @@
6095
6095
"items": {
6096
6096
"$ref": "#/components/schemas/TagFilter"
6097
6097
}
6098
+
},
6099
+
"searchMode": {
6100
+
"type": "string",
6101
+
"enum": ["vector", "hybrid"],
6102
+
"default": "vector",
6103
+
"description": "Retrieval strategy. `vector` ranks purely on embedding similarity. `hybrid` also runs a full-text keyword search and fuses the two rankings by reciprocal rank, which retrieves exact tokens — error codes, ticket keys, identifiers, rare product names — that embeddings alone rank poorly. Ignored when only tagFilters are provided."
0 commit comments