@arbidocs/client 0.3.83 → 0.3.85
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/dist/index.d.cts +211 -8
- package/dist/index.d.ts +211 -8
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -1448,6 +1448,34 @@ interface paths {
|
|
|
1448
1448
|
patch?: never;
|
|
1449
1449
|
trace?: never;
|
|
1450
1450
|
};
|
|
1451
|
+
'/v1/conversation/search': {
|
|
1452
|
+
parameters: {
|
|
1453
|
+
query?: never;
|
|
1454
|
+
header?: never;
|
|
1455
|
+
path?: never;
|
|
1456
|
+
cookie?: never;
|
|
1457
|
+
};
|
|
1458
|
+
get?: never;
|
|
1459
|
+
put?: never;
|
|
1460
|
+
/**
|
|
1461
|
+
* Search Conversations
|
|
1462
|
+
* @description Search conversation messages in the current workspace.
|
|
1463
|
+
*
|
|
1464
|
+
* First-class semantic/keyword/hybrid search over the dedicated messages
|
|
1465
|
+
* vector collection. Results are grouped by conversation, with decrypted
|
|
1466
|
+
* snippets of the matching messages.
|
|
1467
|
+
*
|
|
1468
|
+
* Gated by the per-user ``show_conversation_search`` experimental flag — this
|
|
1469
|
+
* is the user-facing feature switch, independent of the agent's
|
|
1470
|
+
* ``search_conversations`` tool (gated by AgentsConfig).
|
|
1471
|
+
*/
|
|
1472
|
+
post: operations['search_conversations'];
|
|
1473
|
+
delete?: never;
|
|
1474
|
+
options?: never;
|
|
1475
|
+
head?: never;
|
|
1476
|
+
patch?: never;
|
|
1477
|
+
trace?: never;
|
|
1478
|
+
};
|
|
1451
1479
|
'/v1/conversation/{conversation_ext_id}': {
|
|
1452
1480
|
parameters: {
|
|
1453
1481
|
query?: never;
|
|
@@ -2509,6 +2537,12 @@ interface components {
|
|
|
2509
2537
|
* @default false
|
|
2510
2538
|
*/
|
|
2511
2539
|
VISION_ENABLED: boolean;
|
|
2540
|
+
/**
|
|
2541
|
+
* Conversation Search Enabled
|
|
2542
|
+
* @description Enable the search_conversations tool so the agent can semantically search past conversation messages in the workspace. Independent of the user-facing conversation search feature flag (show_conversation_search).
|
|
2543
|
+
* @default false
|
|
2544
|
+
*/
|
|
2545
|
+
CONVERSATION_SEARCH_ENABLED: boolean;
|
|
2512
2546
|
/**
|
|
2513
2547
|
* Personal Agent
|
|
2514
2548
|
* @description Enable the personal_agent tool for delegating tasks to an external agent via OpenClaw.
|
|
@@ -2611,12 +2645,12 @@ interface components {
|
|
|
2611
2645
|
* @description System prompt for the agent. Dynamic context is appended automatically.
|
|
2612
2646
|
* @default Answer any question the user asks. You have access to workspace documents — use them when relevant. When no documents are relevant, answer from your own knowledge. Always provide a helpful answer.
|
|
2613
2647
|
*
|
|
2614
|
-
* IMPORTANT: Never say "I don't have information in the available documents" or refuse to answer. If documents are not relevant, just answer the question directly from your own knowledge. If the user
|
|
2648
|
+
* IMPORTANT: Never say "I don't have information in the available documents" or refuse to answer. If documents are not relevant, just answer the question directly from your own knowledge. If the user asks about a specific workspace document, call read_document or get_table_of_contents — never answer from memory.
|
|
2615
2649
|
*
|
|
2616
2650
|
* When using documents, retrieve actual document content — do not rely on metadata or headings alone. Cross-check information across sources. Not all assertions in sources are factual — some are arguments by a party. Attribute claims to their source where parties disagree.
|
|
2617
2651
|
*
|
|
2618
2652
|
* DOCUMENT INDEX:
|
|
2619
|
-
* The "Workspace Documents" table in your system prompt
|
|
2653
|
+
* The "Workspace Documents" table in your system prompt lists every document with its Id, Title, Date, and Pages. The Subject field is a brief navigation label only — it does not contain enough information to answer questions about a document's content. Use this table directly when the user asks to list, catalogue, or tabulate documents — do NOT call any tools for that. Only use tools when you need to read or search document content.
|
|
2620
2654
|
*
|
|
2621
2655
|
* DOCUMENT STRATEGY:
|
|
2622
2656
|
* - For listing/cataloguing documents: use the document index already in your prompt — no tool calls needed.
|
|
@@ -2624,6 +2658,7 @@ interface components {
|
|
|
2624
2658
|
* - For specific questions: use search_inside_documents to find relevant sections, then read those sections with read_document.
|
|
2625
2659
|
* - For translation, deep analysis, or detailed summaries of a single document: use read_document with no ranges to load the complete text.
|
|
2626
2660
|
* - For extracting structured findings from passages: use read_document with digest=true or search_inside_documents with digest=true.
|
|
2661
|
+
* - For open-ended investigative queries ("find interesting things", "what's notable", "what stands out", "explore X", "what should I know about", "any findings", "anything unusual", "key insights"): ALWAYS call search_inside_documents with multiple diverse queries covering different aspects of the documents before answering. The document index is never sufficient for investigative answers — you must retrieve actual content.
|
|
2627
2662
|
* - Never search for meta-queries like "summary", "overview", or "all documents" — search for the actual subject matter.
|
|
2628
2663
|
*
|
|
2629
2664
|
* FORMATTING:
|
|
@@ -2636,8 +2671,8 @@ interface components {
|
|
|
2636
2671
|
*
|
|
2637
2672
|
* TOOL CALLING:
|
|
2638
2673
|
* - Your job is to gather context by calling tools, then answer only once every reasonable tool call has been made. Do not give a final answer while there is still relevant context you could retrieve.
|
|
2639
|
-
* - Always invoke tools using the tool-calling mechanism.
|
|
2640
|
-
* - If you intend to search or read, issue the tool call
|
|
2674
|
+
* - Always invoke tools using the tool-calling mechanism. NEVER write text that describes or simulates a tool call (e.g. never write "Searching for X...", "Reading document Y...", "Calling search_inside_documents" as prose — actually call the tool).
|
|
2675
|
+
* - If you intend to search or read, issue the tool call immediately. Do not narrate your intent first.
|
|
2641
2676
|
*
|
|
2642
2677
|
* EFFICIENCY:
|
|
2643
2678
|
* 1. Before each step, review the results of prior steps. Adapt your approach based on what you learned — if a call was rejected or returned poor results, adjust your strategy.
|
|
@@ -2698,6 +2733,7 @@ interface components {
|
|
|
2698
2733
|
* "SUGGESTED_QUERIES": false,
|
|
2699
2734
|
* "ARTIFACTS_ENABLED": false,
|
|
2700
2735
|
* "VISION_ENABLED": false,
|
|
2736
|
+
* "CONVERSATION_SEARCH_ENABLED": false,
|
|
2701
2737
|
* "PERSONAL_AGENT": false,
|
|
2702
2738
|
* "MEMORY_ENABLED": false,
|
|
2703
2739
|
* "SKILLS_ENABLED": true,
|
|
@@ -2714,7 +2750,7 @@ interface components {
|
|
|
2714
2750
|
* "AGENT_MAX_ITERATIONS": 20,
|
|
2715
2751
|
* "AGENT_MAX_PARALLEL_TOOL_CALLS": 10,
|
|
2716
2752
|
* "AGENT_HISTORY_CHAR_THRESHOLD": 8000,
|
|
2717
|
-
* "AGENT_SYSTEM_PROMPT": "Answer any question the user asks. You have access to workspace documents — use them when relevant. When no documents are relevant, answer from your own knowledge. Always provide a helpful answer.\n\nIMPORTANT: Never say \"I don't have information in the available documents\" or refuse to answer. If documents are not relevant, just answer the question directly from your own knowledge. If the user
|
|
2753
|
+
* "AGENT_SYSTEM_PROMPT": "Answer any question the user asks. You have access to workspace documents — use them when relevant. When no documents are relevant, answer from your own knowledge. Always provide a helpful answer.\n\nIMPORTANT: Never say \"I don't have information in the available documents\" or refuse to answer. If documents are not relevant, just answer the question directly from your own knowledge. If the user asks about a specific workspace document, call read_document or get_table_of_contents — never answer from memory.\n\nWhen using documents, retrieve actual document content — do not rely on metadata or headings alone. Cross-check information across sources. Not all assertions in sources are factual — some are arguments by a party. Attribute claims to their source where parties disagree.\n\nDOCUMENT INDEX:\nThe \"Workspace Documents\" table in your system prompt lists every document with its Id, Title, Date, and Pages. The Subject field is a brief navigation label only — it does not contain enough information to answer questions about a document's content. Use this table directly when the user asks to list, catalogue, or tabulate documents — do NOT call any tools for that. Only use tools when you need to read or search document content.\n\nDOCUMENT STRATEGY:\n- For listing/cataloguing documents: use the document index already in your prompt — no tool calls needed.\n- For overview/summary requests: use get_table_of_contents first, then read key sections with read_document.\n- For specific questions: use search_inside_documents to find relevant sections, then read those sections with read_document.\n- For translation, deep analysis, or detailed summaries of a single document: use read_document with no ranges to load the complete text.\n- For extracting structured findings from passages: use read_document with digest=true or search_inside_documents with digest=true.\n- For open-ended investigative queries (\"find interesting things\", \"what's notable\", \"what stands out\", \"explore X\", \"what should I know about\", \"any findings\", \"anything unusual\", \"key insights\"): ALWAYS call search_inside_documents with multiple diverse queries covering different aspects of the documents before answering. The document index is never sufficient for investigative answers — you must retrieve actual content.\n- Never search for meta-queries like \"summary\", \"overview\", or \"all documents\" — search for the actual subject matter.\n\nFORMATTING:\n- Start your answer directly with the content — never open with a description of what you searched for or read (e.g. never write \"Searching for X\", \"Reading Y\", \"I found Z documents\" as the first lines of an answer).\n- Use markdown: headings, bold, bullet points, numbered lists\n- Main conclusion first, followed by supporting points\n- Bullet points for lists of discrete items\n- Numbering for sequential steps or prioritized items\n- Bold text for critical conclusions or decision points\n\nTOOL CALLING:\n- Your job is to gather context by calling tools, then answer only once every reasonable tool call has been made. Do not give a final answer while there is still relevant context you could retrieve.\n- Always invoke tools using the tool-calling mechanism. NEVER write text that describes or simulates a tool call (e.g. never write \"Searching for X...\", \"Reading document Y...\", \"Calling search_inside_documents\" as prose — actually call the tool).\n- If you intend to search or read, issue the tool call immediately. Do not narrate your intent first.\n\nEFFICIENCY:\n1. Before each step, review the results of prior steps. Adapt your approach based on what you learned — if a call was rejected or returned poor results, adjust your strategy.\n2. Call multiple tools in parallel when a query has several aspects.\n3. NEVER repeat a tool call with the same arguments.\n4. Use targeted queries and narrow page ranges per retrieval call.\n5. Stop when you have sufficient evidence — do not over-research."
|
|
2718
2754
|
* }
|
|
2719
2755
|
*/
|
|
2720
2756
|
Agents: components['schemas']['AgentsConfig'];
|
|
@@ -3465,6 +3501,48 @@ interface components {
|
|
|
3465
3501
|
*/
|
|
3466
3502
|
MAX_ITERATIONS: number;
|
|
3467
3503
|
};
|
|
3504
|
+
/**
|
|
3505
|
+
* CompactionEvent
|
|
3506
|
+
* @description Emitted when the thread was compacted this turn.
|
|
3507
|
+
*
|
|
3508
|
+
* Message-anchored compaction summarises all messages above an anchor message
|
|
3509
|
+
* and stores the summary on that anchor (in place, same thread). The frontend
|
|
3510
|
+
* can surface a "summarised earlier messages" marker at the anchor.
|
|
3511
|
+
*
|
|
3512
|
+
* Example:
|
|
3513
|
+
* {"type": "arbi.compaction",
|
|
3514
|
+
* "anchor_message_ext_id": "msg-1a2b3c4d",
|
|
3515
|
+
* "messages_summarized": 12,
|
|
3516
|
+
* "tokens_saved": 41000}
|
|
3517
|
+
*/
|
|
3518
|
+
CompactionEvent: {
|
|
3519
|
+
/**
|
|
3520
|
+
* T
|
|
3521
|
+
* @description Seconds elapsed since stream start.
|
|
3522
|
+
*/
|
|
3523
|
+
t?: number | null;
|
|
3524
|
+
/**
|
|
3525
|
+
* Type
|
|
3526
|
+
* @default arbi.compaction
|
|
3527
|
+
* @constant
|
|
3528
|
+
*/
|
|
3529
|
+
type: 'arbi.compaction';
|
|
3530
|
+
/**
|
|
3531
|
+
* Anchor Message Ext Id
|
|
3532
|
+
* @description External id of the message carrying the summary
|
|
3533
|
+
*/
|
|
3534
|
+
anchor_message_ext_id: string;
|
|
3535
|
+
/**
|
|
3536
|
+
* Messages Summarized
|
|
3537
|
+
* @description Number of ancestor messages folded into the summary
|
|
3538
|
+
*/
|
|
3539
|
+
messages_summarized: number;
|
|
3540
|
+
/**
|
|
3541
|
+
* Tokens Saved
|
|
3542
|
+
* @description Approximate tokens removed from context (above − summary)
|
|
3543
|
+
*/
|
|
3544
|
+
tokens_saved: number;
|
|
3545
|
+
};
|
|
3468
3546
|
/** CompactionTool */
|
|
3469
3547
|
CompactionTool: {
|
|
3470
3548
|
/**
|
|
@@ -3477,6 +3555,7 @@ interface components {
|
|
|
3477
3555
|
* @default conversation compaction
|
|
3478
3556
|
*/
|
|
3479
3557
|
description: string;
|
|
3558
|
+
/** @default {} */
|
|
3480
3559
|
tool_args: components['schemas']['CompactionToolArgs'];
|
|
3481
3560
|
/**
|
|
3482
3561
|
* Tool Responses
|
|
@@ -3488,13 +3567,29 @@ interface components {
|
|
|
3488
3567
|
};
|
|
3489
3568
|
/**
|
|
3490
3569
|
* CompactionToolArgs
|
|
3491
|
-
* @description
|
|
3570
|
+
* @description Compaction lineage and anchored-compaction metadata.
|
|
3571
|
+
*
|
|
3572
|
+
* Two flavours share this shape:
|
|
3573
|
+
* - Legacy new-conversation compaction set ``source_*`` refs pointing at the
|
|
3574
|
+
* original (now-separate) conversation. These are kept for read-compat.
|
|
3575
|
+
* - Message-anchored compaction (current design) summarises the thread's own
|
|
3576
|
+
* ancestors in place, so it has no source conversation. It records non-
|
|
3577
|
+
* sensitive counts instead. The summary itself lives in
|
|
3578
|
+
* ``CompactionTool.tool_responses["summary"]`` (encrypted).
|
|
3492
3579
|
*/
|
|
3493
3580
|
CompactionToolArgs: {
|
|
3494
3581
|
/** Source Conversation Ext Id */
|
|
3495
|
-
source_conversation_ext_id
|
|
3582
|
+
source_conversation_ext_id?: string | null;
|
|
3496
3583
|
/** Source Leaf Message Ext Id */
|
|
3497
|
-
source_leaf_message_ext_id
|
|
3584
|
+
source_leaf_message_ext_id?: string | null;
|
|
3585
|
+
/** Messages Summarized */
|
|
3586
|
+
messages_summarized?: number | null;
|
|
3587
|
+
/** Tokens Above */
|
|
3588
|
+
tokens_above?: number | null;
|
|
3589
|
+
/** Tokens Summary */
|
|
3590
|
+
tokens_summary?: number | null;
|
|
3591
|
+
/** Model Used */
|
|
3592
|
+
model_used?: string | null;
|
|
3498
3593
|
};
|
|
3499
3594
|
/** ConfigDeleteResponse */
|
|
3500
3595
|
ConfigDeleteResponse: {
|
|
@@ -3732,6 +3827,56 @@ interface components {
|
|
|
3732
3827
|
/** Last Message Status */
|
|
3733
3828
|
last_message_status?: string | null;
|
|
3734
3829
|
};
|
|
3830
|
+
/**
|
|
3831
|
+
* ConversationSearchGroup
|
|
3832
|
+
* @description Matching messages grouped under their conversation.
|
|
3833
|
+
*/
|
|
3834
|
+
ConversationSearchGroup: {
|
|
3835
|
+
/** Conversation Ext Id */
|
|
3836
|
+
conversation_ext_id: string;
|
|
3837
|
+
/** Title */
|
|
3838
|
+
title?: string | null;
|
|
3839
|
+
/** Score */
|
|
3840
|
+
score: number;
|
|
3841
|
+
/** Messages */
|
|
3842
|
+
messages: components['schemas']['MessageSearchHit'][];
|
|
3843
|
+
};
|
|
3844
|
+
/**
|
|
3845
|
+
* ConversationSearchRequest
|
|
3846
|
+
* @description Request body for conversation message search.
|
|
3847
|
+
*/
|
|
3848
|
+
ConversationSearchRequest: {
|
|
3849
|
+
/**
|
|
3850
|
+
* Query
|
|
3851
|
+
* @description Search query text
|
|
3852
|
+
*/
|
|
3853
|
+
query: string;
|
|
3854
|
+
/**
|
|
3855
|
+
* Search Mode
|
|
3856
|
+
* @description Search mode: dense-only, sparse-only (BM25), or RRF fusion
|
|
3857
|
+
* @default hybrid
|
|
3858
|
+
* @enum {string}
|
|
3859
|
+
*/
|
|
3860
|
+
search_mode: 'semantic' | 'keyword' | 'hybrid';
|
|
3861
|
+
/**
|
|
3862
|
+
* Limit
|
|
3863
|
+
* @description Maximum number of conversations to return
|
|
3864
|
+
* @default 10
|
|
3865
|
+
*/
|
|
3866
|
+
limit: number;
|
|
3867
|
+
};
|
|
3868
|
+
/**
|
|
3869
|
+
* ConversationSearchResponse
|
|
3870
|
+
* @description Response for conversation message search, grouped by conversation.
|
|
3871
|
+
*/
|
|
3872
|
+
ConversationSearchResponse: {
|
|
3873
|
+
/** Query */
|
|
3874
|
+
query: string;
|
|
3875
|
+
/** Search Mode */
|
|
3876
|
+
search_mode: string;
|
|
3877
|
+
/** Results */
|
|
3878
|
+
results: components['schemas']['ConversationSearchGroup'][];
|
|
3879
|
+
};
|
|
3735
3880
|
/** ConversationTitleUpdateRequest */
|
|
3736
3881
|
ConversationTitleUpdateRequest: {
|
|
3737
3882
|
/**
|
|
@@ -5150,6 +5295,23 @@ interface components {
|
|
|
5150
5295
|
/** Parent Message Ext Id */
|
|
5151
5296
|
parent_message_ext_id?: string | null;
|
|
5152
5297
|
};
|
|
5298
|
+
/**
|
|
5299
|
+
* MessageSearchHit
|
|
5300
|
+
* @description A single matching message within a conversation search result.
|
|
5301
|
+
*/
|
|
5302
|
+
MessageSearchHit: {
|
|
5303
|
+
/** Message Ext Id */
|
|
5304
|
+
message_ext_id: string;
|
|
5305
|
+
/**
|
|
5306
|
+
* Role
|
|
5307
|
+
* @enum {string}
|
|
5308
|
+
*/
|
|
5309
|
+
role: 'user' | 'assistant' | 'system';
|
|
5310
|
+
/** Snippet */
|
|
5311
|
+
snippet: string;
|
|
5312
|
+
/** Score */
|
|
5313
|
+
score: number;
|
|
5314
|
+
};
|
|
5153
5315
|
/** ModelCitationConfig */
|
|
5154
5316
|
ModelCitationConfig: {
|
|
5155
5317
|
/**
|
|
@@ -6981,6 +7143,7 @@ interface components {
|
|
|
6981
7143
|
response_completed?: components['schemas']['ResponseCompletedEvent'] | null;
|
|
6982
7144
|
response_failed?: components['schemas']['ResponseFailedEvent'] | null;
|
|
6983
7145
|
artifact?: components['schemas']['ArtifactEvent'] | null;
|
|
7146
|
+
compaction?: components['schemas']['CompactionEvent'] | null;
|
|
6984
7147
|
token_budget_context?: components['schemas']['TokenBudgetContext'] | null;
|
|
6985
7148
|
response_usage?: components['schemas']['ResponseUsage'] | null;
|
|
6986
7149
|
output_tokens_details?: components['schemas']['OutputTokensDetails'] | null;
|
|
@@ -8192,6 +8355,11 @@ interface components {
|
|
|
8192
8355
|
* @default false
|
|
8193
8356
|
*/
|
|
8194
8357
|
show_pa_mode: boolean;
|
|
8358
|
+
/**
|
|
8359
|
+
* Show Conversation Search
|
|
8360
|
+
* @default false
|
|
8361
|
+
*/
|
|
8362
|
+
show_conversation_search: boolean;
|
|
8195
8363
|
/**
|
|
8196
8364
|
* Show Agent Sessions
|
|
8197
8365
|
* @default false
|
|
@@ -8267,6 +8435,8 @@ interface components {
|
|
|
8267
8435
|
show_chronology?: boolean | null;
|
|
8268
8436
|
/** Show Pa Mode */
|
|
8269
8437
|
show_pa_mode?: boolean | null;
|
|
8438
|
+
/** Show Conversation Search */
|
|
8439
|
+
show_conversation_search?: boolean | null;
|
|
8270
8440
|
/** Show Agent Sessions */
|
|
8271
8441
|
show_agent_sessions?: boolean | null;
|
|
8272
8442
|
/** Show Mcp Connectors */
|
|
@@ -10839,6 +11009,39 @@ interface operations {
|
|
|
10839
11009
|
};
|
|
10840
11010
|
};
|
|
10841
11011
|
};
|
|
11012
|
+
search_conversations: {
|
|
11013
|
+
parameters: {
|
|
11014
|
+
query?: never;
|
|
11015
|
+
header?: never;
|
|
11016
|
+
path?: never;
|
|
11017
|
+
cookie?: never;
|
|
11018
|
+
};
|
|
11019
|
+
requestBody: {
|
|
11020
|
+
content: {
|
|
11021
|
+
'application/json': components['schemas']['ConversationSearchRequest'];
|
|
11022
|
+
};
|
|
11023
|
+
};
|
|
11024
|
+
responses: {
|
|
11025
|
+
/** @description Successful Response */
|
|
11026
|
+
200: {
|
|
11027
|
+
headers: {
|
|
11028
|
+
[name: string]: unknown;
|
|
11029
|
+
};
|
|
11030
|
+
content: {
|
|
11031
|
+
'application/json': components['schemas']['ConversationSearchResponse'];
|
|
11032
|
+
};
|
|
11033
|
+
};
|
|
11034
|
+
/** @description Validation Error */
|
|
11035
|
+
422: {
|
|
11036
|
+
headers: {
|
|
11037
|
+
[name: string]: unknown;
|
|
11038
|
+
};
|
|
11039
|
+
content: {
|
|
11040
|
+
'application/json': components['schemas']['HTTPValidationError'];
|
|
11041
|
+
};
|
|
11042
|
+
};
|
|
11043
|
+
};
|
|
11044
|
+
};
|
|
10842
11045
|
delete_conversation: {
|
|
10843
11046
|
parameters: {
|
|
10844
11047
|
query?: never;
|
package/dist/index.d.ts
CHANGED
|
@@ -1448,6 +1448,34 @@ interface paths {
|
|
|
1448
1448
|
patch?: never;
|
|
1449
1449
|
trace?: never;
|
|
1450
1450
|
};
|
|
1451
|
+
'/v1/conversation/search': {
|
|
1452
|
+
parameters: {
|
|
1453
|
+
query?: never;
|
|
1454
|
+
header?: never;
|
|
1455
|
+
path?: never;
|
|
1456
|
+
cookie?: never;
|
|
1457
|
+
};
|
|
1458
|
+
get?: never;
|
|
1459
|
+
put?: never;
|
|
1460
|
+
/**
|
|
1461
|
+
* Search Conversations
|
|
1462
|
+
* @description Search conversation messages in the current workspace.
|
|
1463
|
+
*
|
|
1464
|
+
* First-class semantic/keyword/hybrid search over the dedicated messages
|
|
1465
|
+
* vector collection. Results are grouped by conversation, with decrypted
|
|
1466
|
+
* snippets of the matching messages.
|
|
1467
|
+
*
|
|
1468
|
+
* Gated by the per-user ``show_conversation_search`` experimental flag — this
|
|
1469
|
+
* is the user-facing feature switch, independent of the agent's
|
|
1470
|
+
* ``search_conversations`` tool (gated by AgentsConfig).
|
|
1471
|
+
*/
|
|
1472
|
+
post: operations['search_conversations'];
|
|
1473
|
+
delete?: never;
|
|
1474
|
+
options?: never;
|
|
1475
|
+
head?: never;
|
|
1476
|
+
patch?: never;
|
|
1477
|
+
trace?: never;
|
|
1478
|
+
};
|
|
1451
1479
|
'/v1/conversation/{conversation_ext_id}': {
|
|
1452
1480
|
parameters: {
|
|
1453
1481
|
query?: never;
|
|
@@ -2509,6 +2537,12 @@ interface components {
|
|
|
2509
2537
|
* @default false
|
|
2510
2538
|
*/
|
|
2511
2539
|
VISION_ENABLED: boolean;
|
|
2540
|
+
/**
|
|
2541
|
+
* Conversation Search Enabled
|
|
2542
|
+
* @description Enable the search_conversations tool so the agent can semantically search past conversation messages in the workspace. Independent of the user-facing conversation search feature flag (show_conversation_search).
|
|
2543
|
+
* @default false
|
|
2544
|
+
*/
|
|
2545
|
+
CONVERSATION_SEARCH_ENABLED: boolean;
|
|
2512
2546
|
/**
|
|
2513
2547
|
* Personal Agent
|
|
2514
2548
|
* @description Enable the personal_agent tool for delegating tasks to an external agent via OpenClaw.
|
|
@@ -2611,12 +2645,12 @@ interface components {
|
|
|
2611
2645
|
* @description System prompt for the agent. Dynamic context is appended automatically.
|
|
2612
2646
|
* @default Answer any question the user asks. You have access to workspace documents — use them when relevant. When no documents are relevant, answer from your own knowledge. Always provide a helpful answer.
|
|
2613
2647
|
*
|
|
2614
|
-
* IMPORTANT: Never say "I don't have information in the available documents" or refuse to answer. If documents are not relevant, just answer the question directly from your own knowledge. If the user
|
|
2648
|
+
* IMPORTANT: Never say "I don't have information in the available documents" or refuse to answer. If documents are not relevant, just answer the question directly from your own knowledge. If the user asks about a specific workspace document, call read_document or get_table_of_contents — never answer from memory.
|
|
2615
2649
|
*
|
|
2616
2650
|
* When using documents, retrieve actual document content — do not rely on metadata or headings alone. Cross-check information across sources. Not all assertions in sources are factual — some are arguments by a party. Attribute claims to their source where parties disagree.
|
|
2617
2651
|
*
|
|
2618
2652
|
* DOCUMENT INDEX:
|
|
2619
|
-
* The "Workspace Documents" table in your system prompt
|
|
2653
|
+
* The "Workspace Documents" table in your system prompt lists every document with its Id, Title, Date, and Pages. The Subject field is a brief navigation label only — it does not contain enough information to answer questions about a document's content. Use this table directly when the user asks to list, catalogue, or tabulate documents — do NOT call any tools for that. Only use tools when you need to read or search document content.
|
|
2620
2654
|
*
|
|
2621
2655
|
* DOCUMENT STRATEGY:
|
|
2622
2656
|
* - For listing/cataloguing documents: use the document index already in your prompt — no tool calls needed.
|
|
@@ -2624,6 +2658,7 @@ interface components {
|
|
|
2624
2658
|
* - For specific questions: use search_inside_documents to find relevant sections, then read those sections with read_document.
|
|
2625
2659
|
* - For translation, deep analysis, or detailed summaries of a single document: use read_document with no ranges to load the complete text.
|
|
2626
2660
|
* - For extracting structured findings from passages: use read_document with digest=true or search_inside_documents with digest=true.
|
|
2661
|
+
* - For open-ended investigative queries ("find interesting things", "what's notable", "what stands out", "explore X", "what should I know about", "any findings", "anything unusual", "key insights"): ALWAYS call search_inside_documents with multiple diverse queries covering different aspects of the documents before answering. The document index is never sufficient for investigative answers — you must retrieve actual content.
|
|
2627
2662
|
* - Never search for meta-queries like "summary", "overview", or "all documents" — search for the actual subject matter.
|
|
2628
2663
|
*
|
|
2629
2664
|
* FORMATTING:
|
|
@@ -2636,8 +2671,8 @@ interface components {
|
|
|
2636
2671
|
*
|
|
2637
2672
|
* TOOL CALLING:
|
|
2638
2673
|
* - Your job is to gather context by calling tools, then answer only once every reasonable tool call has been made. Do not give a final answer while there is still relevant context you could retrieve.
|
|
2639
|
-
* - Always invoke tools using the tool-calling mechanism.
|
|
2640
|
-
* - If you intend to search or read, issue the tool call
|
|
2674
|
+
* - Always invoke tools using the tool-calling mechanism. NEVER write text that describes or simulates a tool call (e.g. never write "Searching for X...", "Reading document Y...", "Calling search_inside_documents" as prose — actually call the tool).
|
|
2675
|
+
* - If you intend to search or read, issue the tool call immediately. Do not narrate your intent first.
|
|
2641
2676
|
*
|
|
2642
2677
|
* EFFICIENCY:
|
|
2643
2678
|
* 1. Before each step, review the results of prior steps. Adapt your approach based on what you learned — if a call was rejected or returned poor results, adjust your strategy.
|
|
@@ -2698,6 +2733,7 @@ interface components {
|
|
|
2698
2733
|
* "SUGGESTED_QUERIES": false,
|
|
2699
2734
|
* "ARTIFACTS_ENABLED": false,
|
|
2700
2735
|
* "VISION_ENABLED": false,
|
|
2736
|
+
* "CONVERSATION_SEARCH_ENABLED": false,
|
|
2701
2737
|
* "PERSONAL_AGENT": false,
|
|
2702
2738
|
* "MEMORY_ENABLED": false,
|
|
2703
2739
|
* "SKILLS_ENABLED": true,
|
|
@@ -2714,7 +2750,7 @@ interface components {
|
|
|
2714
2750
|
* "AGENT_MAX_ITERATIONS": 20,
|
|
2715
2751
|
* "AGENT_MAX_PARALLEL_TOOL_CALLS": 10,
|
|
2716
2752
|
* "AGENT_HISTORY_CHAR_THRESHOLD": 8000,
|
|
2717
|
-
* "AGENT_SYSTEM_PROMPT": "Answer any question the user asks. You have access to workspace documents — use them when relevant. When no documents are relevant, answer from your own knowledge. Always provide a helpful answer.\n\nIMPORTANT: Never say \"I don't have information in the available documents\" or refuse to answer. If documents are not relevant, just answer the question directly from your own knowledge. If the user
|
|
2753
|
+
* "AGENT_SYSTEM_PROMPT": "Answer any question the user asks. You have access to workspace documents — use them when relevant. When no documents are relevant, answer from your own knowledge. Always provide a helpful answer.\n\nIMPORTANT: Never say \"I don't have information in the available documents\" or refuse to answer. If documents are not relevant, just answer the question directly from your own knowledge. If the user asks about a specific workspace document, call read_document or get_table_of_contents — never answer from memory.\n\nWhen using documents, retrieve actual document content — do not rely on metadata or headings alone. Cross-check information across sources. Not all assertions in sources are factual — some are arguments by a party. Attribute claims to their source where parties disagree.\n\nDOCUMENT INDEX:\nThe \"Workspace Documents\" table in your system prompt lists every document with its Id, Title, Date, and Pages. The Subject field is a brief navigation label only — it does not contain enough information to answer questions about a document's content. Use this table directly when the user asks to list, catalogue, or tabulate documents — do NOT call any tools for that. Only use tools when you need to read or search document content.\n\nDOCUMENT STRATEGY:\n- For listing/cataloguing documents: use the document index already in your prompt — no tool calls needed.\n- For overview/summary requests: use get_table_of_contents first, then read key sections with read_document.\n- For specific questions: use search_inside_documents to find relevant sections, then read those sections with read_document.\n- For translation, deep analysis, or detailed summaries of a single document: use read_document with no ranges to load the complete text.\n- For extracting structured findings from passages: use read_document with digest=true or search_inside_documents with digest=true.\n- For open-ended investigative queries (\"find interesting things\", \"what's notable\", \"what stands out\", \"explore X\", \"what should I know about\", \"any findings\", \"anything unusual\", \"key insights\"): ALWAYS call search_inside_documents with multiple diverse queries covering different aspects of the documents before answering. The document index is never sufficient for investigative answers — you must retrieve actual content.\n- Never search for meta-queries like \"summary\", \"overview\", or \"all documents\" — search for the actual subject matter.\n\nFORMATTING:\n- Start your answer directly with the content — never open with a description of what you searched for or read (e.g. never write \"Searching for X\", \"Reading Y\", \"I found Z documents\" as the first lines of an answer).\n- Use markdown: headings, bold, bullet points, numbered lists\n- Main conclusion first, followed by supporting points\n- Bullet points for lists of discrete items\n- Numbering for sequential steps or prioritized items\n- Bold text for critical conclusions or decision points\n\nTOOL CALLING:\n- Your job is to gather context by calling tools, then answer only once every reasonable tool call has been made. Do not give a final answer while there is still relevant context you could retrieve.\n- Always invoke tools using the tool-calling mechanism. NEVER write text that describes or simulates a tool call (e.g. never write \"Searching for X...\", \"Reading document Y...\", \"Calling search_inside_documents\" as prose — actually call the tool).\n- If you intend to search or read, issue the tool call immediately. Do not narrate your intent first.\n\nEFFICIENCY:\n1. Before each step, review the results of prior steps. Adapt your approach based on what you learned — if a call was rejected or returned poor results, adjust your strategy.\n2. Call multiple tools in parallel when a query has several aspects.\n3. NEVER repeat a tool call with the same arguments.\n4. Use targeted queries and narrow page ranges per retrieval call.\n5. Stop when you have sufficient evidence — do not over-research."
|
|
2718
2754
|
* }
|
|
2719
2755
|
*/
|
|
2720
2756
|
Agents: components['schemas']['AgentsConfig'];
|
|
@@ -3465,6 +3501,48 @@ interface components {
|
|
|
3465
3501
|
*/
|
|
3466
3502
|
MAX_ITERATIONS: number;
|
|
3467
3503
|
};
|
|
3504
|
+
/**
|
|
3505
|
+
* CompactionEvent
|
|
3506
|
+
* @description Emitted when the thread was compacted this turn.
|
|
3507
|
+
*
|
|
3508
|
+
* Message-anchored compaction summarises all messages above an anchor message
|
|
3509
|
+
* and stores the summary on that anchor (in place, same thread). The frontend
|
|
3510
|
+
* can surface a "summarised earlier messages" marker at the anchor.
|
|
3511
|
+
*
|
|
3512
|
+
* Example:
|
|
3513
|
+
* {"type": "arbi.compaction",
|
|
3514
|
+
* "anchor_message_ext_id": "msg-1a2b3c4d",
|
|
3515
|
+
* "messages_summarized": 12,
|
|
3516
|
+
* "tokens_saved": 41000}
|
|
3517
|
+
*/
|
|
3518
|
+
CompactionEvent: {
|
|
3519
|
+
/**
|
|
3520
|
+
* T
|
|
3521
|
+
* @description Seconds elapsed since stream start.
|
|
3522
|
+
*/
|
|
3523
|
+
t?: number | null;
|
|
3524
|
+
/**
|
|
3525
|
+
* Type
|
|
3526
|
+
* @default arbi.compaction
|
|
3527
|
+
* @constant
|
|
3528
|
+
*/
|
|
3529
|
+
type: 'arbi.compaction';
|
|
3530
|
+
/**
|
|
3531
|
+
* Anchor Message Ext Id
|
|
3532
|
+
* @description External id of the message carrying the summary
|
|
3533
|
+
*/
|
|
3534
|
+
anchor_message_ext_id: string;
|
|
3535
|
+
/**
|
|
3536
|
+
* Messages Summarized
|
|
3537
|
+
* @description Number of ancestor messages folded into the summary
|
|
3538
|
+
*/
|
|
3539
|
+
messages_summarized: number;
|
|
3540
|
+
/**
|
|
3541
|
+
* Tokens Saved
|
|
3542
|
+
* @description Approximate tokens removed from context (above − summary)
|
|
3543
|
+
*/
|
|
3544
|
+
tokens_saved: number;
|
|
3545
|
+
};
|
|
3468
3546
|
/** CompactionTool */
|
|
3469
3547
|
CompactionTool: {
|
|
3470
3548
|
/**
|
|
@@ -3477,6 +3555,7 @@ interface components {
|
|
|
3477
3555
|
* @default conversation compaction
|
|
3478
3556
|
*/
|
|
3479
3557
|
description: string;
|
|
3558
|
+
/** @default {} */
|
|
3480
3559
|
tool_args: components['schemas']['CompactionToolArgs'];
|
|
3481
3560
|
/**
|
|
3482
3561
|
* Tool Responses
|
|
@@ -3488,13 +3567,29 @@ interface components {
|
|
|
3488
3567
|
};
|
|
3489
3568
|
/**
|
|
3490
3569
|
* CompactionToolArgs
|
|
3491
|
-
* @description
|
|
3570
|
+
* @description Compaction lineage and anchored-compaction metadata.
|
|
3571
|
+
*
|
|
3572
|
+
* Two flavours share this shape:
|
|
3573
|
+
* - Legacy new-conversation compaction set ``source_*`` refs pointing at the
|
|
3574
|
+
* original (now-separate) conversation. These are kept for read-compat.
|
|
3575
|
+
* - Message-anchored compaction (current design) summarises the thread's own
|
|
3576
|
+
* ancestors in place, so it has no source conversation. It records non-
|
|
3577
|
+
* sensitive counts instead. The summary itself lives in
|
|
3578
|
+
* ``CompactionTool.tool_responses["summary"]`` (encrypted).
|
|
3492
3579
|
*/
|
|
3493
3580
|
CompactionToolArgs: {
|
|
3494
3581
|
/** Source Conversation Ext Id */
|
|
3495
|
-
source_conversation_ext_id
|
|
3582
|
+
source_conversation_ext_id?: string | null;
|
|
3496
3583
|
/** Source Leaf Message Ext Id */
|
|
3497
|
-
source_leaf_message_ext_id
|
|
3584
|
+
source_leaf_message_ext_id?: string | null;
|
|
3585
|
+
/** Messages Summarized */
|
|
3586
|
+
messages_summarized?: number | null;
|
|
3587
|
+
/** Tokens Above */
|
|
3588
|
+
tokens_above?: number | null;
|
|
3589
|
+
/** Tokens Summary */
|
|
3590
|
+
tokens_summary?: number | null;
|
|
3591
|
+
/** Model Used */
|
|
3592
|
+
model_used?: string | null;
|
|
3498
3593
|
};
|
|
3499
3594
|
/** ConfigDeleteResponse */
|
|
3500
3595
|
ConfigDeleteResponse: {
|
|
@@ -3732,6 +3827,56 @@ interface components {
|
|
|
3732
3827
|
/** Last Message Status */
|
|
3733
3828
|
last_message_status?: string | null;
|
|
3734
3829
|
};
|
|
3830
|
+
/**
|
|
3831
|
+
* ConversationSearchGroup
|
|
3832
|
+
* @description Matching messages grouped under their conversation.
|
|
3833
|
+
*/
|
|
3834
|
+
ConversationSearchGroup: {
|
|
3835
|
+
/** Conversation Ext Id */
|
|
3836
|
+
conversation_ext_id: string;
|
|
3837
|
+
/** Title */
|
|
3838
|
+
title?: string | null;
|
|
3839
|
+
/** Score */
|
|
3840
|
+
score: number;
|
|
3841
|
+
/** Messages */
|
|
3842
|
+
messages: components['schemas']['MessageSearchHit'][];
|
|
3843
|
+
};
|
|
3844
|
+
/**
|
|
3845
|
+
* ConversationSearchRequest
|
|
3846
|
+
* @description Request body for conversation message search.
|
|
3847
|
+
*/
|
|
3848
|
+
ConversationSearchRequest: {
|
|
3849
|
+
/**
|
|
3850
|
+
* Query
|
|
3851
|
+
* @description Search query text
|
|
3852
|
+
*/
|
|
3853
|
+
query: string;
|
|
3854
|
+
/**
|
|
3855
|
+
* Search Mode
|
|
3856
|
+
* @description Search mode: dense-only, sparse-only (BM25), or RRF fusion
|
|
3857
|
+
* @default hybrid
|
|
3858
|
+
* @enum {string}
|
|
3859
|
+
*/
|
|
3860
|
+
search_mode: 'semantic' | 'keyword' | 'hybrid';
|
|
3861
|
+
/**
|
|
3862
|
+
* Limit
|
|
3863
|
+
* @description Maximum number of conversations to return
|
|
3864
|
+
* @default 10
|
|
3865
|
+
*/
|
|
3866
|
+
limit: number;
|
|
3867
|
+
};
|
|
3868
|
+
/**
|
|
3869
|
+
* ConversationSearchResponse
|
|
3870
|
+
* @description Response for conversation message search, grouped by conversation.
|
|
3871
|
+
*/
|
|
3872
|
+
ConversationSearchResponse: {
|
|
3873
|
+
/** Query */
|
|
3874
|
+
query: string;
|
|
3875
|
+
/** Search Mode */
|
|
3876
|
+
search_mode: string;
|
|
3877
|
+
/** Results */
|
|
3878
|
+
results: components['schemas']['ConversationSearchGroup'][];
|
|
3879
|
+
};
|
|
3735
3880
|
/** ConversationTitleUpdateRequest */
|
|
3736
3881
|
ConversationTitleUpdateRequest: {
|
|
3737
3882
|
/**
|
|
@@ -5150,6 +5295,23 @@ interface components {
|
|
|
5150
5295
|
/** Parent Message Ext Id */
|
|
5151
5296
|
parent_message_ext_id?: string | null;
|
|
5152
5297
|
};
|
|
5298
|
+
/**
|
|
5299
|
+
* MessageSearchHit
|
|
5300
|
+
* @description A single matching message within a conversation search result.
|
|
5301
|
+
*/
|
|
5302
|
+
MessageSearchHit: {
|
|
5303
|
+
/** Message Ext Id */
|
|
5304
|
+
message_ext_id: string;
|
|
5305
|
+
/**
|
|
5306
|
+
* Role
|
|
5307
|
+
* @enum {string}
|
|
5308
|
+
*/
|
|
5309
|
+
role: 'user' | 'assistant' | 'system';
|
|
5310
|
+
/** Snippet */
|
|
5311
|
+
snippet: string;
|
|
5312
|
+
/** Score */
|
|
5313
|
+
score: number;
|
|
5314
|
+
};
|
|
5153
5315
|
/** ModelCitationConfig */
|
|
5154
5316
|
ModelCitationConfig: {
|
|
5155
5317
|
/**
|
|
@@ -6981,6 +7143,7 @@ interface components {
|
|
|
6981
7143
|
response_completed?: components['schemas']['ResponseCompletedEvent'] | null;
|
|
6982
7144
|
response_failed?: components['schemas']['ResponseFailedEvent'] | null;
|
|
6983
7145
|
artifact?: components['schemas']['ArtifactEvent'] | null;
|
|
7146
|
+
compaction?: components['schemas']['CompactionEvent'] | null;
|
|
6984
7147
|
token_budget_context?: components['schemas']['TokenBudgetContext'] | null;
|
|
6985
7148
|
response_usage?: components['schemas']['ResponseUsage'] | null;
|
|
6986
7149
|
output_tokens_details?: components['schemas']['OutputTokensDetails'] | null;
|
|
@@ -8192,6 +8355,11 @@ interface components {
|
|
|
8192
8355
|
* @default false
|
|
8193
8356
|
*/
|
|
8194
8357
|
show_pa_mode: boolean;
|
|
8358
|
+
/**
|
|
8359
|
+
* Show Conversation Search
|
|
8360
|
+
* @default false
|
|
8361
|
+
*/
|
|
8362
|
+
show_conversation_search: boolean;
|
|
8195
8363
|
/**
|
|
8196
8364
|
* Show Agent Sessions
|
|
8197
8365
|
* @default false
|
|
@@ -8267,6 +8435,8 @@ interface components {
|
|
|
8267
8435
|
show_chronology?: boolean | null;
|
|
8268
8436
|
/** Show Pa Mode */
|
|
8269
8437
|
show_pa_mode?: boolean | null;
|
|
8438
|
+
/** Show Conversation Search */
|
|
8439
|
+
show_conversation_search?: boolean | null;
|
|
8270
8440
|
/** Show Agent Sessions */
|
|
8271
8441
|
show_agent_sessions?: boolean | null;
|
|
8272
8442
|
/** Show Mcp Connectors */
|
|
@@ -10839,6 +11009,39 @@ interface operations {
|
|
|
10839
11009
|
};
|
|
10840
11010
|
};
|
|
10841
11011
|
};
|
|
11012
|
+
search_conversations: {
|
|
11013
|
+
parameters: {
|
|
11014
|
+
query?: never;
|
|
11015
|
+
header?: never;
|
|
11016
|
+
path?: never;
|
|
11017
|
+
cookie?: never;
|
|
11018
|
+
};
|
|
11019
|
+
requestBody: {
|
|
11020
|
+
content: {
|
|
11021
|
+
'application/json': components['schemas']['ConversationSearchRequest'];
|
|
11022
|
+
};
|
|
11023
|
+
};
|
|
11024
|
+
responses: {
|
|
11025
|
+
/** @description Successful Response */
|
|
11026
|
+
200: {
|
|
11027
|
+
headers: {
|
|
11028
|
+
[name: string]: unknown;
|
|
11029
|
+
};
|
|
11030
|
+
content: {
|
|
11031
|
+
'application/json': components['schemas']['ConversationSearchResponse'];
|
|
11032
|
+
};
|
|
11033
|
+
};
|
|
11034
|
+
/** @description Validation Error */
|
|
11035
|
+
422: {
|
|
11036
|
+
headers: {
|
|
11037
|
+
[name: string]: unknown;
|
|
11038
|
+
};
|
|
11039
|
+
content: {
|
|
11040
|
+
'application/json': components['schemas']['HTTPValidationError'];
|
|
11041
|
+
};
|
|
11042
|
+
};
|
|
11043
|
+
};
|
|
11044
|
+
};
|
|
10842
11045
|
delete_conversation: {
|
|
10843
11046
|
parameters: {
|
|
10844
11047
|
query?: never;
|
package/package.json
CHANGED