@arbidocs/sdk 0.3.19 → 0.3.20

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.
@@ -1,5 +1,4 @@
1
- import * as _arbidocs_client from '@arbidocs/client';
2
- import { ArbiClient, LoginResult, components, WebSocketServerMessage, WsTaskUpdateMessage } from '@arbidocs/client';
1
+ import { ArbiClient, LoginResult, components, WebSocketServerMessage, WsTaskUpdateMessage, KeyPair } from '@arbidocs/client';
3
2
 
4
3
  /**
5
4
  * Core error types and throwing error utilities.
@@ -49,7 +48,6 @@ declare function getErrorCode(err: unknown): string | undefined;
49
48
  interface AuthHeaders {
50
49
  baseUrl: string;
51
50
  accessToken: string;
52
- workspaceKeyHeader: string;
53
51
  }
54
52
  interface AuthFetchOptions extends AuthHeaders {
55
53
  /** URL path relative to baseUrl (e.g. '/v1/document/upload'). */
@@ -61,7 +59,8 @@ interface AuthFetchOptions extends AuthHeaders {
61
59
  }
62
60
  /**
63
61
  * Make an authenticated fetch request with standard error handling.
64
- * Automatically sets Authorization + workspace-key headers.
62
+ * Automatically sets Authorization header. Workspace keys are stored
63
+ * server-side on the session — no client-side header needed.
65
64
  * Throws on non-ok responses with a human-readable message including server error details.
66
65
  */
67
66
  declare function authenticatedFetch(options: AuthFetchOptions): Promise<Response>;
@@ -79,21 +78,25 @@ interface CliConfig {
79
78
  notifications?: boolean;
80
79
  verbose?: boolean;
81
80
  watch?: boolean;
81
+ /** Default orchestrator for `arbi agent connect` (e.g. "claude") */
82
+ orchestrator?: string;
82
83
  }
83
84
  interface CliCredentials {
84
85
  email: string;
85
86
  signingPrivateKeyBase64: string;
86
87
  serverSessionKeyBase64: string;
87
- /** Cached workspace-scoped JWT from last successful resolveWorkspace() */
88
+ /** Cached access token from last successful resolveWorkspace() */
88
89
  accessToken?: string;
89
- /** Cached workspace key header from last successful resolveWorkspace() */
90
- workspaceKeyHeader?: string;
90
+ /** Cached session-sealed workspace key from last successful resolveWorkspace() */
91
+ sealedWorkspaceKey?: string;
91
92
  /** Workspace ID the cached token was issued for */
92
93
  workspaceId?: string;
93
94
  /** ISO timestamp when the token was cached */
94
95
  tokenTimestamp?: string;
95
96
  /** Auth0 SSO token — needed for session recovery of SSO users */
96
97
  ssoToken?: string;
98
+ /** Parent user ext_id — set for persistent agent accounts */
99
+ parentExtId?: string;
97
100
  }
98
101
  interface ChatSession {
99
102
  /** Last assistant message ID — used as previous_response_id for follow-ups */
@@ -141,7 +144,7 @@ interface AuthContext {
141
144
  interface WorkspaceContext extends AuthContext {
142
145
  workspaceId: string;
143
146
  accessToken: string;
144
- workspaceKeyHeader: string;
147
+ sealedWorkspaceKey: string;
145
148
  }
146
149
  /** Minimal workspace shape required by formatWorkspaceChoices. */
147
150
  interface WorkspaceForChoice {
@@ -187,15 +190,21 @@ declare function performSsoDeviceFlowLogin(config: CliConfig, email: string, pas
187
190
  onPoll?: (elapsedMs: number) => void;
188
191
  }): Promise<AuthContext>;
189
192
  /**
190
- * Decrypt wrapped workspace key and set it as the active workspace header.
193
+ * Decrypt wrapped workspace key and generate the encrypted workspace key header.
194
+ * Returns the encrypted key string for use with /open.
191
195
  */
192
- declare function selectWorkspace(arbi: ArbiClient, workspaceId: string, wrappedKey: string, serverSessionKey: Uint8Array, signingPrivateKeyBase64: string): Promise<void>;
196
+ declare function selectWorkspace(arbi: ArbiClient, workspaceId: string, wrappedKey: string, serverSessionKey: Uint8Array, signingPrivateKeyBase64: string): Promise<string>;
193
197
  /**
194
198
  * Generate an encrypted workspace key for the given workspace.
195
199
  * Used for operations that need a key for a workspace other than the current one
196
200
  * (e.g., copy documents to a target workspace).
197
201
  */
198
202
  declare function generateEncryptedWorkspaceKey(arbi: ArbiClient, wrappedKey: string, serverSessionKey: Uint8Array, signingPrivateKeyBase64: string): Promise<string>;
203
+ /**
204
+ * Generate a random workspace key encrypted with the session public key.
205
+ * Used when creating new workspaces.
206
+ */
207
+ declare function generateNewWorkspaceKey(arbi: ArbiClient, serverSessionKey: Uint8Array): Promise<string>;
199
208
  /**
200
209
  * Find a workspace by ID in the user's workspace list, select it, and return workspace info.
201
210
  */
@@ -836,9 +845,10 @@ declare function listContacts(arbi: ArbiClient): Promise<{
836
845
  email: string;
837
846
  user?: {
838
847
  external_id: string;
848
+ parent_ext_id?: string | null | undefined;
839
849
  email: string;
840
850
  given_name: string;
841
- family_name: string;
851
+ family_name?: string | null | undefined;
842
852
  picture?: string | null | undefined;
843
853
  encryption_public_key: string;
844
854
  } | null | undefined;
@@ -850,9 +860,10 @@ declare function addContacts(arbi: ArbiClient, emails: string[]): Promise<{
850
860
  email: string;
851
861
  user?: {
852
862
  external_id: string;
863
+ parent_ext_id?: string | null | undefined;
853
864
  email: string;
854
865
  given_name: string;
855
- family_name: string;
866
+ family_name?: string | null | undefined;
856
867
  picture?: string | null | undefined;
857
868
  encryption_public_key: string;
858
869
  } | null | undefined;
@@ -1075,9 +1086,10 @@ declare class Arbi {
1075
1086
  users: {
1076
1087
  user: {
1077
1088
  external_id: string;
1089
+ parent_ext_id?: string | null | undefined;
1078
1090
  email: string;
1079
1091
  given_name: string;
1080
- family_name: string;
1092
+ family_name?: string | null | undefined;
1081
1093
  picture?: string | null | undefined;
1082
1094
  encryption_public_key: string;
1083
1095
  };
@@ -1085,6 +1097,7 @@ declare class Arbi {
1085
1097
  joined_at: string;
1086
1098
  conversation_count: number;
1087
1099
  document_count: number;
1100
+ agent_ext_id?: string | null | undefined;
1088
1101
  }[];
1089
1102
  }[]>;
1090
1103
  create: (name: string, description?: string | null, isPublic?: boolean) => Promise<{
@@ -1105,9 +1118,10 @@ declare class Arbi {
1105
1118
  users: {
1106
1119
  user: {
1107
1120
  external_id: string;
1121
+ parent_ext_id?: string | null | undefined;
1108
1122
  email: string;
1109
1123
  given_name: string;
1110
- family_name: string;
1124
+ family_name?: string | null | undefined;
1111
1125
  picture?: string | null | undefined;
1112
1126
  encryption_public_key: string;
1113
1127
  };
@@ -1115,6 +1129,7 @@ declare class Arbi {
1115
1129
  joined_at: string;
1116
1130
  conversation_count: number;
1117
1131
  document_count: number;
1132
+ agent_ext_id?: string | null | undefined;
1118
1133
  }[];
1119
1134
  }>;
1120
1135
  delete: (workspaceIds: string[]) => Promise<void>;
@@ -1136,9 +1151,10 @@ declare class Arbi {
1136
1151
  users: {
1137
1152
  user: {
1138
1153
  external_id: string;
1154
+ parent_ext_id?: string | null | undefined;
1139
1155
  email: string;
1140
1156
  given_name: string;
1141
- family_name: string;
1157
+ family_name?: string | null | undefined;
1142
1158
  picture?: string | null | undefined;
1143
1159
  encryption_public_key: string;
1144
1160
  };
@@ -1146,14 +1162,16 @@ declare class Arbi {
1146
1162
  joined_at: string;
1147
1163
  conversation_count: number;
1148
1164
  document_count: number;
1165
+ agent_ext_id?: string | null | undefined;
1149
1166
  }[];
1150
1167
  }>;
1151
1168
  listUsers: () => Promise<{
1152
1169
  user: {
1153
1170
  external_id: string;
1171
+ parent_ext_id?: string | null | undefined;
1154
1172
  email: string;
1155
1173
  given_name: string;
1156
- family_name: string;
1174
+ family_name?: string | null | undefined;
1157
1175
  picture?: string | null | undefined;
1158
1176
  encryption_public_key: string;
1159
1177
  };
@@ -1161,13 +1179,15 @@ declare class Arbi {
1161
1179
  joined_at: string;
1162
1180
  conversation_count: number;
1163
1181
  document_count: number;
1182
+ agent_ext_id?: string | null | undefined;
1164
1183
  }[]>;
1165
1184
  addUsers: (emails: string[], role?: "owner" | "collaborator" | "guest") => Promise<{
1166
1185
  user: {
1167
1186
  external_id: string;
1187
+ parent_ext_id?: string | null | undefined;
1168
1188
  email: string;
1169
1189
  given_name: string;
1170
- family_name: string;
1190
+ family_name?: string | null | undefined;
1171
1191
  picture?: string | null | undefined;
1172
1192
  encryption_public_key: string;
1173
1193
  };
@@ -1175,14 +1195,16 @@ declare class Arbi {
1175
1195
  joined_at: string;
1176
1196
  conversation_count: number;
1177
1197
  document_count: number;
1198
+ agent_ext_id?: string | null | undefined;
1178
1199
  }[]>;
1179
1200
  removeUsers: (userIds: string[]) => Promise<void>;
1180
1201
  setUserRole: (userIds: string[], role: "owner" | "collaborator" | "guest") => Promise<{
1181
1202
  user: {
1182
1203
  external_id: string;
1204
+ parent_ext_id?: string | null | undefined;
1183
1205
  email: string;
1184
1206
  given_name: string;
1185
- family_name: string;
1207
+ family_name?: string | null | undefined;
1186
1208
  picture?: string | null | undefined;
1187
1209
  encryption_public_key: string;
1188
1210
  };
@@ -1190,6 +1212,7 @@ declare class Arbi {
1190
1212
  joined_at: string;
1191
1213
  conversation_count: number;
1192
1214
  document_count: number;
1215
+ agent_ext_id?: string | null | undefined;
1193
1216
  }[]>;
1194
1217
  copyDocuments: (targetWorkspaceId: string, docIds: string[], targetWorkspaceKey: string) => Promise<{
1195
1218
  detail: string;
@@ -1793,9 +1816,10 @@ declare class Arbi {
1793
1816
  email: string;
1794
1817
  user?: {
1795
1818
  external_id: string;
1819
+ parent_ext_id?: string | null | undefined;
1796
1820
  email: string;
1797
1821
  given_name: string;
1798
- family_name: string;
1822
+ family_name?: string | null | undefined;
1799
1823
  picture?: string | null | undefined;
1800
1824
  encryption_public_key: string;
1801
1825
  } | null | undefined;
@@ -1807,9 +1831,10 @@ declare class Arbi {
1807
1831
  email: string;
1808
1832
  user?: {
1809
1833
  external_id: string;
1834
+ parent_ext_id?: string | null | undefined;
1810
1835
  email: string;
1811
1836
  given_name: string;
1812
- family_name: string;
1837
+ family_name?: string | null | undefined;
1813
1838
  picture?: string | null | undefined;
1814
1839
  encryption_public_key: string;
1815
1840
  } | null | undefined;
@@ -1825,17 +1850,19 @@ declare class Arbi {
1825
1850
  external_id: string;
1826
1851
  sender: {
1827
1852
  external_id: string;
1853
+ parent_ext_id?: string | null | undefined;
1828
1854
  email: string;
1829
1855
  given_name: string;
1830
- family_name: string;
1856
+ family_name?: string | null | undefined;
1831
1857
  picture?: string | null | undefined;
1832
1858
  encryption_public_key: string;
1833
1859
  };
1834
1860
  recipient: {
1835
1861
  external_id: string;
1862
+ parent_ext_id?: string | null | undefined;
1836
1863
  email: string;
1837
1864
  given_name: string;
1838
- family_name: string;
1865
+ family_name?: string | null | undefined;
1839
1866
  picture?: string | null | undefined;
1840
1867
  encryption_public_key: string;
1841
1868
  };
@@ -1853,17 +1880,19 @@ declare class Arbi {
1853
1880
  external_id: string;
1854
1881
  sender: {
1855
1882
  external_id: string;
1883
+ parent_ext_id?: string | null | undefined;
1856
1884
  email: string;
1857
1885
  given_name: string;
1858
- family_name: string;
1886
+ family_name?: string | null | undefined;
1859
1887
  picture?: string | null | undefined;
1860
1888
  encryption_public_key: string;
1861
1889
  };
1862
1890
  recipient: {
1863
1891
  external_id: string;
1892
+ parent_ext_id?: string | null | undefined;
1864
1893
  email: string;
1865
1894
  given_name: string;
1866
- family_name: string;
1895
+ family_name?: string | null | undefined;
1867
1896
  picture?: string | null | undefined;
1868
1897
  encryption_public_key: string;
1869
1898
  };
@@ -1878,17 +1907,19 @@ declare class Arbi {
1878
1907
  external_id: string;
1879
1908
  sender: {
1880
1909
  external_id: string;
1910
+ parent_ext_id?: string | null | undefined;
1881
1911
  email: string;
1882
1912
  given_name: string;
1883
- family_name: string;
1913
+ family_name?: string | null | undefined;
1884
1914
  picture?: string | null | undefined;
1885
1915
  encryption_public_key: string;
1886
1916
  };
1887
1917
  recipient: {
1888
1918
  external_id: string;
1919
+ parent_ext_id?: string | null | undefined;
1889
1920
  email: string;
1890
1921
  given_name: string;
1891
- family_name: string;
1922
+ family_name?: string | null | undefined;
1892
1923
  picture?: string | null | undefined;
1893
1924
  encryption_public_key: string;
1894
1925
  };
@@ -1924,6 +1955,7 @@ declare class Arbi {
1924
1955
  show_help_page: boolean;
1925
1956
  show_templates: boolean;
1926
1957
  show_pa_mode: boolean;
1958
+ show_agent_sessions: boolean;
1927
1959
  hide_online_status: boolean;
1928
1960
  muted_users: string[];
1929
1961
  }>;
@@ -1957,8 +1989,6 @@ declare class Arbi {
1957
1989
  SUGGESTED_QUERIES: boolean;
1958
1990
  ARTIFACTS_ENABLED: boolean;
1959
1991
  VISION_ENABLED: boolean;
1960
- DOC_INDEX_COMPACT_THRESHOLD: number;
1961
- DOC_INDEX_SKIP_THRESHOLD: number;
1962
1992
  PERSONAL_AGENT: boolean;
1963
1993
  MEMORY_ENABLED: boolean;
1964
1994
  SKILLS_ENABLED: boolean;
@@ -1969,13 +1999,15 @@ declare class Arbi {
1969
1999
  AGENT_API_TYPE: "local" | "remote";
1970
2000
  LLM_AGENT_TEMPERATURE: number;
1971
2001
  AGENT_MAX_TOKENS: number;
2002
+ ENABLE_THINKING: boolean;
1972
2003
  AGENT_MAX_ITERATIONS: number;
1973
- MAX_PASSAGE_PAGES: number;
2004
+ AGENT_MAX_PARALLEL_TOOL_CALLS: number;
1974
2005
  AGENT_HISTORY_CHAR_THRESHOLD: number;
1975
2006
  AGENT_SYSTEM_PROMPT: string;
1976
2007
  };
1977
2008
  QueryLLM: {
1978
2009
  API_TYPE: "local" | "remote";
2010
+ ENABLE_THINKING: boolean;
1979
2011
  MODEL_NAME: string;
1980
2012
  SYSTEM_INSTRUCTION: string;
1981
2013
  MAX_CHAR_SIZE_TO_ANSWER: number;
@@ -1984,6 +2016,7 @@ declare class Arbi {
1984
2016
  };
1985
2017
  ReviewLLM: {
1986
2018
  API_TYPE: "local" | "remote";
2019
+ ENABLE_THINKING: boolean;
1987
2020
  MODEL_NAME: string;
1988
2021
  SYSTEM_INSTRUCTION: string;
1989
2022
  TEMPERATURE: number;
@@ -1992,6 +2025,7 @@ declare class Arbi {
1992
2025
  };
1993
2026
  EvaluatorLLM: {
1994
2027
  API_TYPE: "local" | "remote";
2028
+ ENABLE_THINKING: boolean;
1995
2029
  MODEL_NAME: string;
1996
2030
  SYSTEM_INSTRUCTION: string;
1997
2031
  TEMPERATURE: number;
@@ -2000,6 +2034,7 @@ declare class Arbi {
2000
2034
  };
2001
2035
  TitleLLM: {
2002
2036
  API_TYPE: "local" | "remote";
2037
+ ENABLE_THINKING: boolean;
2003
2038
  MODEL_NAME: string;
2004
2039
  SYSTEM_INSTRUCTION: string;
2005
2040
  MAX_CHAR_SIZE_TO_ANSWER: number;
@@ -2008,6 +2043,7 @@ declare class Arbi {
2008
2043
  };
2009
2044
  SummariseLLM: {
2010
2045
  API_TYPE: "local" | "remote";
2046
+ ENABLE_THINKING: boolean;
2011
2047
  MODEL_NAME: string;
2012
2048
  SYSTEM_INSTRUCTION: string;
2013
2049
  TEMPERATURE: number;
@@ -2018,6 +2054,7 @@ declare class Arbi {
2018
2054
  };
2019
2055
  DoctagLLM: {
2020
2056
  API_TYPE: "local" | "remote";
2057
+ ENABLE_THINKING: boolean;
2021
2058
  MODEL_NAME: string;
2022
2059
  SYSTEM_INSTRUCTION: string;
2023
2060
  MAX_CHAR_CONTEXT_TO_ANSWER: number;
@@ -2035,6 +2072,7 @@ declare class Arbi {
2035
2072
  };
2036
2073
  MemoryLLM: {
2037
2074
  API_TYPE: "local" | "remote";
2075
+ ENABLE_THINKING: boolean;
2038
2076
  MODEL_NAME: string;
2039
2077
  SYSTEM_INSTRUCTION: string;
2040
2078
  TEMPERATURE: number;
@@ -2044,6 +2082,7 @@ declare class Arbi {
2044
2082
  };
2045
2083
  PlanningLLM: {
2046
2084
  API_TYPE: "local" | "remote";
2085
+ ENABLE_THINKING: boolean;
2047
2086
  MODEL_NAME: string;
2048
2087
  SYSTEM_INSTRUCTION: string;
2049
2088
  TEMPERATURE: number;
@@ -2051,8 +2090,17 @@ declare class Arbi {
2051
2090
  MAX_CHAR_SIZE_TO_ANSWER: number;
2052
2091
  APPROVAL_TIMEOUT: number;
2053
2092
  };
2093
+ FilterPlanLLM: {
2094
+ API_TYPE: "local" | "remote";
2095
+ ENABLE_THINKING: boolean;
2096
+ MODEL_NAME: string;
2097
+ SYSTEM_INSTRUCTION: string;
2098
+ TEMPERATURE: number;
2099
+ MAX_TOKENS: number;
2100
+ };
2054
2101
  VisionLLM: {
2055
2102
  API_TYPE: "local" | "remote";
2103
+ ENABLE_THINKING: boolean;
2056
2104
  MODEL_NAME: string;
2057
2105
  TEMPERATURE: number;
2058
2106
  MAX_TOKENS: number;
@@ -2061,6 +2109,7 @@ declare class Arbi {
2061
2109
  };
2062
2110
  CodeAgent: {
2063
2111
  API_TYPE: "local" | "remote";
2112
+ ENABLE_THINKING: boolean;
2064
2113
  MODEL_NAME: string;
2065
2114
  SYSTEM_INSTRUCTION: string;
2066
2115
  TEMPERATURE: number;
@@ -2071,6 +2120,7 @@ declare class Arbi {
2071
2120
  SIM_THREASHOLD: number;
2072
2121
  MIN_CHAR_SIZE_TO_ANSWER: number;
2073
2122
  MAX_NUMB_CITATIONS: number;
2123
+ CITATION_INSTRUCTION: string;
2074
2124
  };
2075
2125
  Retriever: {
2076
2126
  MIN_RETRIEVAL_SIM_SCORE: number;
@@ -2078,9 +2128,9 @@ declare class Arbi {
2078
2128
  MAX_TOTAL_CHUNKS_TO_RETRIEVE: number;
2079
2129
  GROUP_SIZE: number;
2080
2130
  SEARCH_MODE: components["schemas"]["SearchMode"];
2131
+ HYBRID_PREFETCH_LIMIT: number;
2081
2132
  HYBRID_DENSE_WEIGHT: number;
2082
2133
  HYBRID_SPARSE_WEIGHT: number;
2083
- HYBRID_RERANKER_WEIGHT: number;
2084
2134
  };
2085
2135
  Reranker: {
2086
2136
  MIN_SCORE: number;
@@ -2088,6 +2138,7 @@ declare class Arbi {
2088
2138
  MAX_CONCURRENT_REQUESTS: number;
2089
2139
  MODEL_NAME: string;
2090
2140
  API_TYPE: "local" | "remote";
2141
+ RETRIEVAL_INSTRUCTION: string;
2091
2142
  };
2092
2143
  Parser: {
2093
2144
  SKIP_DUPLICATES: boolean;
@@ -2247,6 +2298,48 @@ declare class Arbi {
2247
2298
  }>;
2248
2299
  getContent: (fileId: string) => Promise<Response>;
2249
2300
  };
2301
+ readonly agents: {
2302
+ list: () => Promise<{
2303
+ external_id: string;
2304
+ parent_ext_id?: string | null;
2305
+ email: string;
2306
+ given_name: string;
2307
+ family_name?: string | null;
2308
+ picture?: string | null;
2309
+ encryption_public_key: string;
2310
+ }[]>;
2311
+ delete: (agentExtIds: string[]) => Promise<{
2312
+ [x: string]: unknown;
2313
+ }>;
2314
+ };
2315
+ readonly sessions: {
2316
+ list: () => Promise<{
2317
+ session_id: string;
2318
+ external_id?: string | null;
2319
+ name?: string | null;
2320
+ ip_address?: string | null;
2321
+ active_workspace?: string | null;
2322
+ workspaces: string[];
2323
+ status: string;
2324
+ ttl: number;
2325
+ }[]>;
2326
+ authorize: (workspaces: Record<string, string>, options?: {
2327
+ activeWorkspace?: string;
2328
+ ttl?: number;
2329
+ persistIdentity?: boolean;
2330
+ name?: string;
2331
+ }) => Promise<{
2332
+ claim_code: string;
2333
+ }>;
2334
+ claim: (claimCode: string, signingKey?: string) => Promise<{
2335
+ access_token: string;
2336
+ session_key: string;
2337
+ user: components["schemas"]["UserResponse"];
2338
+ workspaces: {
2339
+ [key: string]: unknown;
2340
+ }[];
2341
+ }>;
2342
+ };
2250
2343
  private requireClient;
2251
2344
  private requireLogin;
2252
2345
  private requireWorkspace;
@@ -2275,9 +2368,10 @@ declare function listWorkspaces(arbi: ArbiClient): Promise<{
2275
2368
  users: {
2276
2369
  user: {
2277
2370
  external_id: string;
2371
+ parent_ext_id?: string | null | undefined;
2278
2372
  email: string;
2279
2373
  given_name: string;
2280
- family_name: string;
2374
+ family_name?: string | null | undefined;
2281
2375
  picture?: string | null | undefined;
2282
2376
  encryption_public_key: string;
2283
2377
  };
@@ -2285,9 +2379,17 @@ declare function listWorkspaces(arbi: ArbiClient): Promise<{
2285
2379
  joined_at: string;
2286
2380
  conversation_count: number;
2287
2381
  document_count: number;
2382
+ agent_ext_id?: string | null | undefined;
2288
2383
  }[];
2289
2384
  }[]>;
2290
- declare function createWorkspace(arbi: ArbiClient, name: string, description?: string | null, isPublic?: boolean): Promise<{
2385
+ /**
2386
+ * Create a workspace with a pre-encrypted workspace key.
2387
+ *
2388
+ * The caller must generate a random 32-byte key, encrypt it with the session
2389
+ * public key (SealedBox via `sealKeyForSession`), and pass it here.
2390
+ * Use `Arbi.workspaces.create()` for automatic key generation.
2391
+ */
2392
+ declare function createWorkspace(arbi: ArbiClient, name: string, encryptedWorkspaceKey: string, description?: string | null, isPublic?: boolean): Promise<{
2291
2393
  external_id: string;
2292
2394
  name: string;
2293
2395
  description: string | null;
@@ -2305,9 +2407,10 @@ declare function createWorkspace(arbi: ArbiClient, name: string, description?: s
2305
2407
  users: {
2306
2408
  user: {
2307
2409
  external_id: string;
2410
+ parent_ext_id?: string | null | undefined;
2308
2411
  email: string;
2309
2412
  given_name: string;
2310
- family_name: string;
2413
+ family_name?: string | null | undefined;
2311
2414
  picture?: string | null | undefined;
2312
2415
  encryption_public_key: string;
2313
2416
  };
@@ -2315,6 +2418,7 @@ declare function createWorkspace(arbi: ArbiClient, name: string, description?: s
2315
2418
  joined_at: string;
2316
2419
  conversation_count: number;
2317
2420
  document_count: number;
2421
+ agent_ext_id?: string | null | undefined;
2318
2422
  }[];
2319
2423
  }>;
2320
2424
  declare function deleteWorkspaces(arbi: ArbiClient, workspaceIds: string[]): Promise<void>;
@@ -2336,9 +2440,10 @@ declare function updateWorkspace(arbi: ArbiClient, body: WorkspaceUpdateRequest)
2336
2440
  users: {
2337
2441
  user: {
2338
2442
  external_id: string;
2443
+ parent_ext_id?: string | null | undefined;
2339
2444
  email: string;
2340
2445
  given_name: string;
2341
- family_name: string;
2446
+ family_name?: string | null | undefined;
2342
2447
  picture?: string | null | undefined;
2343
2448
  encryption_public_key: string;
2344
2449
  };
@@ -2346,14 +2451,16 @@ declare function updateWorkspace(arbi: ArbiClient, body: WorkspaceUpdateRequest)
2346
2451
  joined_at: string;
2347
2452
  conversation_count: number;
2348
2453
  document_count: number;
2454
+ agent_ext_id?: string | null | undefined;
2349
2455
  }[];
2350
2456
  }>;
2351
2457
  declare function listWorkspaceUsers(arbi: ArbiClient): Promise<{
2352
2458
  user: {
2353
2459
  external_id: string;
2460
+ parent_ext_id?: string | null | undefined;
2354
2461
  email: string;
2355
2462
  given_name: string;
2356
- family_name: string;
2463
+ family_name?: string | null | undefined;
2357
2464
  picture?: string | null | undefined;
2358
2465
  encryption_public_key: string;
2359
2466
  };
@@ -2361,13 +2468,15 @@ declare function listWorkspaceUsers(arbi: ArbiClient): Promise<{
2361
2468
  joined_at: string;
2362
2469
  conversation_count: number;
2363
2470
  document_count: number;
2471
+ agent_ext_id?: string | null | undefined;
2364
2472
  }[]>;
2365
2473
  declare function addWorkspaceUsers(arbi: ArbiClient, emails: string[], role?: 'owner' | 'collaborator' | 'guest'): Promise<{
2366
2474
  user: {
2367
2475
  external_id: string;
2476
+ parent_ext_id?: string | null | undefined;
2368
2477
  email: string;
2369
2478
  given_name: string;
2370
- family_name: string;
2479
+ family_name?: string | null | undefined;
2371
2480
  picture?: string | null | undefined;
2372
2481
  encryption_public_key: string;
2373
2482
  };
@@ -2375,14 +2484,16 @@ declare function addWorkspaceUsers(arbi: ArbiClient, emails: string[], role?: 'o
2375
2484
  joined_at: string;
2376
2485
  conversation_count: number;
2377
2486
  document_count: number;
2487
+ agent_ext_id?: string | null | undefined;
2378
2488
  }[]>;
2379
2489
  declare function removeWorkspaceUsers(arbi: ArbiClient, userIds: string[]): Promise<void>;
2380
2490
  declare function setUserRole(arbi: ArbiClient, userIds: string[], role: 'owner' | 'collaborator' | 'guest'): Promise<{
2381
2491
  user: {
2382
2492
  external_id: string;
2493
+ parent_ext_id?: string | null | undefined;
2383
2494
  email: string;
2384
2495
  given_name: string;
2385
- family_name: string;
2496
+ family_name?: string | null | undefined;
2386
2497
  picture?: string | null | undefined;
2387
2498
  encryption_public_key: string;
2388
2499
  };
@@ -2390,6 +2501,7 @@ declare function setUserRole(arbi: ArbiClient, userIds: string[], role: 'owner'
2390
2501
  joined_at: string;
2391
2502
  conversation_count: number;
2392
2503
  document_count: number;
2504
+ agent_ext_id?: string | null | undefined;
2393
2505
  }[]>;
2394
2506
  declare function copyDocuments(arbi: ArbiClient, targetWorkspaceId: string, docIds: string[], targetWorkspaceKey: string): Promise<{
2395
2507
  detail: string;
@@ -2858,22 +2970,83 @@ declare namespace doctags {
2858
2970
  export { doctags_assignDocTags as assignDocTags, doctags_generateDocTags as generateDocTags, doctags_removeDocTags as removeDocTags, doctags_updateDocTag as updateDocTag };
2859
2971
  }
2860
2972
 
2973
+ /**
2974
+ * Direct message / notification operations — list, send, mark read, delete.
2975
+ *
2976
+ * All message content is E2E encrypted using ECDH (X25519 + XSalsa20-Poly1305).
2977
+ * Encryption keys are derived from the user's Ed25519 signing keypair.
2978
+ */
2979
+
2980
+ type NotificationResponse = components['schemas']['NotificationResponse'];
2981
+ /**
2982
+ * Everything needed to encrypt/decrypt DMs.
2983
+ * Derive once per session, pass to all DM operations.
2984
+ */
2985
+ interface DmCryptoContext {
2986
+ /** User's X25519 encryption keypair (derived from Ed25519 signing key) */
2987
+ encryptionKeypair: KeyPair;
2988
+ /** User's own external_id (to determine send vs receive direction) */
2989
+ userExtId: string;
2990
+ }
2991
+ /**
2992
+ * Create a DM crypto context from a signing private key.
2993
+ *
2994
+ * @param arbi - ArbiClient instance (provides crypto utilities)
2995
+ * @param signingPrivateKeyBytes - Ed25519 signing private key (64 bytes)
2996
+ * @param userExtId - Current user's external_id
2997
+ */
2998
+ declare function createDmCryptoContext(arbi: ArbiClient, signingPrivateKeyBytes: Uint8Array, userExtId: string): DmCryptoContext;
2999
+ /**
3000
+ * Encrypt a plaintext message for a recipient.
3001
+ *
3002
+ * @param arbi - ArbiClient instance
3003
+ * @param plaintext - Message content to encrypt
3004
+ * @param recipientEncryptionPubKeyBase64 - Recipient's X25519 public key (base64)
3005
+ * @param senderEncryptionSecretKey - Sender's X25519 secret key (Uint8Array)
3006
+ * @returns Base64-encoded ciphertext (nonce prepended)
3007
+ */
3008
+ declare function encryptDmContent(arbi: ArbiClient, plaintext: string, recipientEncryptionPubKeyBase64: string, senderEncryptionSecretKey: Uint8Array): Promise<string>;
3009
+ /**
3010
+ * Decrypt an encrypted notification message.
3011
+ *
3012
+ * Uses the sender/recipient public keys embedded in NotificationResponse
3013
+ * to determine the "other party" for ECDH decryption.
3014
+ *
3015
+ * @param arbi - ArbiClient instance
3016
+ * @param notification - The notification with encrypted content
3017
+ * @param crypto - DM crypto context for the current user
3018
+ * @returns Decrypted plaintext, or null if content is empty
3019
+ * @throws Error if decryption fails (wrong keys or tampered message)
3020
+ */
3021
+ declare function decryptDmContent(arbi: ArbiClient, notification: NotificationResponse, crypto: DmCryptoContext): Promise<string | null>;
3022
+ /**
3023
+ * Decrypt a batch of notifications, replacing content in-place.
3024
+ * Failed decryptions get content set to '[Decryption failed]'.
3025
+ *
3026
+ * @returns New array with decrypted content
3027
+ */
3028
+ declare function decryptDmBatch(arbi: ArbiClient, notifications: NotificationResponse[], crypto: DmCryptoContext): Promise<NotificationResponse[]>;
3029
+ /**
3030
+ * List DMs (raw — content is encrypted ciphertext).
3031
+ */
2861
3032
  declare function listDMs(arbi: ArbiClient): Promise<{
2862
- type: _arbidocs_client.components["schemas"]["NotificationType"];
3033
+ type: components["schemas"]["NotificationType"];
2863
3034
  external_id: string;
2864
3035
  sender: {
2865
3036
  external_id: string;
3037
+ parent_ext_id?: string | null | undefined;
2866
3038
  email: string;
2867
3039
  given_name: string;
2868
- family_name: string;
3040
+ family_name?: string | null | undefined;
2869
3041
  picture?: string | null | undefined;
2870
3042
  encryption_public_key: string;
2871
3043
  };
2872
3044
  recipient: {
2873
3045
  external_id: string;
3046
+ parent_ext_id?: string | null | undefined;
2874
3047
  email: string;
2875
3048
  given_name: string;
2876
- family_name: string;
3049
+ family_name?: string | null | undefined;
2877
3050
  picture?: string | null | undefined;
2878
3051
  encryption_public_key: string;
2879
3052
  };
@@ -2883,25 +3056,86 @@ declare function listDMs(arbi: ArbiClient): Promise<{
2883
3056
  created_at: string;
2884
3057
  updated_at: string;
2885
3058
  }[]>;
3059
+ /**
3060
+ * List and decrypt DMs in one call.
3061
+ */
3062
+ declare function listDecryptedDMs(arbi: ArbiClient, crypto: DmCryptoContext): Promise<{
3063
+ type: components["schemas"]["NotificationType"];
3064
+ external_id: string;
3065
+ sender: components["schemas"]["UserResponse"];
3066
+ recipient: components["schemas"]["UserResponse"];
3067
+ workspace_ext_id?: string | null;
3068
+ content?: string | null;
3069
+ read: boolean;
3070
+ created_at: string;
3071
+ updated_at: string;
3072
+ }[]>;
3073
+ /**
3074
+ * Send an E2E encrypted DM.
3075
+ *
3076
+ * Encrypts plaintext content for each recipient using their public key.
3077
+ * Requires recipient public keys — fetch via contacts or user lookup first.
3078
+ *
3079
+ * @param arbi - ArbiClient instance
3080
+ * @param messages - Array of { recipient_ext_id, content (plaintext), recipient_encryption_public_key }
3081
+ * @param crypto - DM crypto context for the sender
3082
+ */
3083
+ declare function sendEncryptedDM(arbi: ArbiClient, messages: Array<{
3084
+ recipient_ext_id: string;
3085
+ content: string;
3086
+ recipient_encryption_public_key: string;
3087
+ }>, crypto: DmCryptoContext): Promise<{
3088
+ type: components["schemas"]["NotificationType"];
3089
+ external_id: string;
3090
+ sender: {
3091
+ external_id: string;
3092
+ parent_ext_id?: string | null | undefined;
3093
+ email: string;
3094
+ given_name: string;
3095
+ family_name?: string | null | undefined;
3096
+ picture?: string | null | undefined;
3097
+ encryption_public_key: string;
3098
+ };
3099
+ recipient: {
3100
+ external_id: string;
3101
+ parent_ext_id?: string | null | undefined;
3102
+ email: string;
3103
+ given_name: string;
3104
+ family_name?: string | null | undefined;
3105
+ picture?: string | null | undefined;
3106
+ encryption_public_key: string;
3107
+ };
3108
+ workspace_ext_id?: string | null | undefined;
3109
+ content?: string | null | undefined;
3110
+ read: boolean;
3111
+ created_at: string;
3112
+ updated_at: string;
3113
+ }[]>;
3114
+ /**
3115
+ * Send a plaintext DM (no encryption).
3116
+ * @deprecated Use sendEncryptedDM instead.
3117
+ */
2886
3118
  declare function sendDM(arbi: ArbiClient, messages: Array<{
2887
3119
  recipient_ext_id: string;
2888
3120
  content: string;
2889
3121
  }>): Promise<{
2890
- type: _arbidocs_client.components["schemas"]["NotificationType"];
3122
+ type: components["schemas"]["NotificationType"];
2891
3123
  external_id: string;
2892
3124
  sender: {
2893
3125
  external_id: string;
3126
+ parent_ext_id?: string | null | undefined;
2894
3127
  email: string;
2895
3128
  given_name: string;
2896
- family_name: string;
3129
+ family_name?: string | null | undefined;
2897
3130
  picture?: string | null | undefined;
2898
3131
  encryption_public_key: string;
2899
3132
  };
2900
3133
  recipient: {
2901
3134
  external_id: string;
3135
+ parent_ext_id?: string | null | undefined;
2902
3136
  email: string;
2903
3137
  given_name: string;
2904
- family_name: string;
3138
+ family_name?: string | null | undefined;
2905
3139
  picture?: string | null | undefined;
2906
3140
  encryption_public_key: string;
2907
3141
  };
@@ -2912,21 +3146,23 @@ declare function sendDM(arbi: ArbiClient, messages: Array<{
2912
3146
  updated_at: string;
2913
3147
  }[]>;
2914
3148
  declare function markRead(arbi: ArbiClient, messageIds: string[]): Promise<{
2915
- type: _arbidocs_client.components["schemas"]["NotificationType"];
3149
+ type: components["schemas"]["NotificationType"];
2916
3150
  external_id: string;
2917
3151
  sender: {
2918
3152
  external_id: string;
3153
+ parent_ext_id?: string | null | undefined;
2919
3154
  email: string;
2920
3155
  given_name: string;
2921
- family_name: string;
3156
+ family_name?: string | null | undefined;
2922
3157
  picture?: string | null | undefined;
2923
3158
  encryption_public_key: string;
2924
3159
  };
2925
3160
  recipient: {
2926
3161
  external_id: string;
3162
+ parent_ext_id?: string | null | undefined;
2927
3163
  email: string;
2928
3164
  given_name: string;
2929
- family_name: string;
3165
+ family_name?: string | null | undefined;
2930
3166
  picture?: string | null | undefined;
2931
3167
  encryption_public_key: string;
2932
3168
  };
@@ -2938,12 +3174,19 @@ declare function markRead(arbi: ArbiClient, messageIds: string[]): Promise<{
2938
3174
  }[]>;
2939
3175
  declare function deleteDMs(arbi: ArbiClient, messageIds: string[]): Promise<void>;
2940
3176
 
3177
+ type dm_DmCryptoContext = DmCryptoContext;
3178
+ declare const dm_createDmCryptoContext: typeof createDmCryptoContext;
3179
+ declare const dm_decryptDmBatch: typeof decryptDmBatch;
3180
+ declare const dm_decryptDmContent: typeof decryptDmContent;
2941
3181
  declare const dm_deleteDMs: typeof deleteDMs;
3182
+ declare const dm_encryptDmContent: typeof encryptDmContent;
2942
3183
  declare const dm_listDMs: typeof listDMs;
3184
+ declare const dm_listDecryptedDMs: typeof listDecryptedDMs;
2943
3185
  declare const dm_markRead: typeof markRead;
2944
3186
  declare const dm_sendDM: typeof sendDM;
3187
+ declare const dm_sendEncryptedDM: typeof sendEncryptedDM;
2945
3188
  declare namespace dm {
2946
- export { dm_deleteDMs as deleteDMs, dm_listDMs as listDMs, dm_markRead as markRead, dm_sendDM as sendDM };
3189
+ export { type dm_DmCryptoContext as DmCryptoContext, dm_createDmCryptoContext as createDmCryptoContext, dm_decryptDmBatch as decryptDmBatch, dm_decryptDmContent as decryptDmContent, dm_deleteDMs as deleteDMs, dm_encryptDmContent as encryptDmContent, dm_listDMs as listDMs, dm_listDecryptedDMs as listDecryptedDMs, dm_markRead as markRead, dm_sendDM as sendDM, dm_sendEncryptedDM as sendEncryptedDM };
2947
3190
  }
2948
3191
 
2949
3192
  /**
@@ -2974,6 +3217,7 @@ declare function getSettings(arbi: ArbiClient): Promise<{
2974
3217
  show_help_page: boolean;
2975
3218
  show_templates: boolean;
2976
3219
  show_pa_mode: boolean;
3220
+ show_agent_sessions: boolean;
2977
3221
  hide_online_status: boolean;
2978
3222
  muted_users: string[];
2979
3223
  }>;
@@ -3017,8 +3261,6 @@ declare function getConfig(arbi: ArbiClient, configId: string): Promise<{
3017
3261
  SUGGESTED_QUERIES: boolean;
3018
3262
  ARTIFACTS_ENABLED: boolean;
3019
3263
  VISION_ENABLED: boolean;
3020
- DOC_INDEX_COMPACT_THRESHOLD: number;
3021
- DOC_INDEX_SKIP_THRESHOLD: number;
3022
3264
  PERSONAL_AGENT: boolean;
3023
3265
  MEMORY_ENABLED: boolean;
3024
3266
  SKILLS_ENABLED: boolean;
@@ -3029,13 +3271,15 @@ declare function getConfig(arbi: ArbiClient, configId: string): Promise<{
3029
3271
  AGENT_API_TYPE: "local" | "remote";
3030
3272
  LLM_AGENT_TEMPERATURE: number;
3031
3273
  AGENT_MAX_TOKENS: number;
3274
+ ENABLE_THINKING: boolean;
3032
3275
  AGENT_MAX_ITERATIONS: number;
3033
- MAX_PASSAGE_PAGES: number;
3276
+ AGENT_MAX_PARALLEL_TOOL_CALLS: number;
3034
3277
  AGENT_HISTORY_CHAR_THRESHOLD: number;
3035
3278
  AGENT_SYSTEM_PROMPT: string;
3036
3279
  };
3037
3280
  QueryLLM: {
3038
3281
  API_TYPE: "local" | "remote";
3282
+ ENABLE_THINKING: boolean;
3039
3283
  MODEL_NAME: string;
3040
3284
  SYSTEM_INSTRUCTION: string;
3041
3285
  MAX_CHAR_SIZE_TO_ANSWER: number;
@@ -3044,6 +3288,7 @@ declare function getConfig(arbi: ArbiClient, configId: string): Promise<{
3044
3288
  };
3045
3289
  ReviewLLM: {
3046
3290
  API_TYPE: "local" | "remote";
3291
+ ENABLE_THINKING: boolean;
3047
3292
  MODEL_NAME: string;
3048
3293
  SYSTEM_INSTRUCTION: string;
3049
3294
  TEMPERATURE: number;
@@ -3052,6 +3297,7 @@ declare function getConfig(arbi: ArbiClient, configId: string): Promise<{
3052
3297
  };
3053
3298
  EvaluatorLLM: {
3054
3299
  API_TYPE: "local" | "remote";
3300
+ ENABLE_THINKING: boolean;
3055
3301
  MODEL_NAME: string;
3056
3302
  SYSTEM_INSTRUCTION: string;
3057
3303
  TEMPERATURE: number;
@@ -3060,6 +3306,7 @@ declare function getConfig(arbi: ArbiClient, configId: string): Promise<{
3060
3306
  };
3061
3307
  TitleLLM: {
3062
3308
  API_TYPE: "local" | "remote";
3309
+ ENABLE_THINKING: boolean;
3063
3310
  MODEL_NAME: string;
3064
3311
  SYSTEM_INSTRUCTION: string;
3065
3312
  MAX_CHAR_SIZE_TO_ANSWER: number;
@@ -3068,6 +3315,7 @@ declare function getConfig(arbi: ArbiClient, configId: string): Promise<{
3068
3315
  };
3069
3316
  SummariseLLM: {
3070
3317
  API_TYPE: "local" | "remote";
3318
+ ENABLE_THINKING: boolean;
3071
3319
  MODEL_NAME: string;
3072
3320
  SYSTEM_INSTRUCTION: string;
3073
3321
  TEMPERATURE: number;
@@ -3078,6 +3326,7 @@ declare function getConfig(arbi: ArbiClient, configId: string): Promise<{
3078
3326
  };
3079
3327
  DoctagLLM: {
3080
3328
  API_TYPE: "local" | "remote";
3329
+ ENABLE_THINKING: boolean;
3081
3330
  MODEL_NAME: string;
3082
3331
  SYSTEM_INSTRUCTION: string;
3083
3332
  MAX_CHAR_CONTEXT_TO_ANSWER: number;
@@ -3095,6 +3344,7 @@ declare function getConfig(arbi: ArbiClient, configId: string): Promise<{
3095
3344
  };
3096
3345
  MemoryLLM: {
3097
3346
  API_TYPE: "local" | "remote";
3347
+ ENABLE_THINKING: boolean;
3098
3348
  MODEL_NAME: string;
3099
3349
  SYSTEM_INSTRUCTION: string;
3100
3350
  TEMPERATURE: number;
@@ -3104,6 +3354,7 @@ declare function getConfig(arbi: ArbiClient, configId: string): Promise<{
3104
3354
  };
3105
3355
  PlanningLLM: {
3106
3356
  API_TYPE: "local" | "remote";
3357
+ ENABLE_THINKING: boolean;
3107
3358
  MODEL_NAME: string;
3108
3359
  SYSTEM_INSTRUCTION: string;
3109
3360
  TEMPERATURE: number;
@@ -3111,8 +3362,17 @@ declare function getConfig(arbi: ArbiClient, configId: string): Promise<{
3111
3362
  MAX_CHAR_SIZE_TO_ANSWER: number;
3112
3363
  APPROVAL_TIMEOUT: number;
3113
3364
  };
3365
+ FilterPlanLLM: {
3366
+ API_TYPE: "local" | "remote";
3367
+ ENABLE_THINKING: boolean;
3368
+ MODEL_NAME: string;
3369
+ SYSTEM_INSTRUCTION: string;
3370
+ TEMPERATURE: number;
3371
+ MAX_TOKENS: number;
3372
+ };
3114
3373
  VisionLLM: {
3115
3374
  API_TYPE: "local" | "remote";
3375
+ ENABLE_THINKING: boolean;
3116
3376
  MODEL_NAME: string;
3117
3377
  TEMPERATURE: number;
3118
3378
  MAX_TOKENS: number;
@@ -3121,6 +3381,7 @@ declare function getConfig(arbi: ArbiClient, configId: string): Promise<{
3121
3381
  };
3122
3382
  CodeAgent: {
3123
3383
  API_TYPE: "local" | "remote";
3384
+ ENABLE_THINKING: boolean;
3124
3385
  MODEL_NAME: string;
3125
3386
  SYSTEM_INSTRUCTION: string;
3126
3387
  TEMPERATURE: number;
@@ -3131,6 +3392,7 @@ declare function getConfig(arbi: ArbiClient, configId: string): Promise<{
3131
3392
  SIM_THREASHOLD: number;
3132
3393
  MIN_CHAR_SIZE_TO_ANSWER: number;
3133
3394
  MAX_NUMB_CITATIONS: number;
3395
+ CITATION_INSTRUCTION: string;
3134
3396
  };
3135
3397
  Retriever: {
3136
3398
  MIN_RETRIEVAL_SIM_SCORE: number;
@@ -3138,9 +3400,9 @@ declare function getConfig(arbi: ArbiClient, configId: string): Promise<{
3138
3400
  MAX_TOTAL_CHUNKS_TO_RETRIEVE: number;
3139
3401
  GROUP_SIZE: number;
3140
3402
  SEARCH_MODE: components["schemas"]["SearchMode"];
3403
+ HYBRID_PREFETCH_LIMIT: number;
3141
3404
  HYBRID_DENSE_WEIGHT: number;
3142
3405
  HYBRID_SPARSE_WEIGHT: number;
3143
- HYBRID_RERANKER_WEIGHT: number;
3144
3406
  };
3145
3407
  Reranker: {
3146
3408
  MIN_SCORE: number;
@@ -3148,6 +3410,7 @@ declare function getConfig(arbi: ArbiClient, configId: string): Promise<{
3148
3410
  MAX_CONCURRENT_REQUESTS: number;
3149
3411
  MODEL_NAME: string;
3150
3412
  API_TYPE: "local" | "remote";
3413
+ RETRIEVAL_INSTRUCTION: string;
3151
3414
  };
3152
3415
  Parser: {
3153
3416
  SKIP_DUPLICATES: boolean;
@@ -3321,4 +3584,4 @@ declare namespace responses {
3321
3584
  export { type responses_SubmitBackgroundQueryOptions as SubmitBackgroundQueryOptions, responses_extractResponseText as extractResponseText, responses_getResponse as getResponse, responses_submitBackgroundQuery as submitBackgroundQuery };
3322
3585
  }
3323
3586
 
3324
- export { connectWebSocket as $, type AuthHeaders as A, type ResponseOutputTextDeltaEvent as B, type ConfigStore as C, type DocumentWaiter as D, type ResponseOutputTextDoneEvent as E, type FormattedWsMessage as F, type ResponseUsage as G, type SSEStreamCallbacks as H, type SSEStreamResult as I, type SSEStreamStartData as J, type UserInfo as K, type UserInputRequestEvent as L, type MessageLevel as M, type UserMessageEvent as N, type OutputTokensDetails as O, type WsConnection as P, type QueryOptions as Q, type ReconnectOptions as R, type SSEEvent as S, agentconfig as T, type UploadBatchResult as U, assistant as V, type WorkspaceContext as W, authenticatedFetch as X, buildRetrievalChunkTool as Y, buildRetrievalFullContextTool as Z, buildRetrievalTocTool as _, type CliConfig as a, connectWithReconnect as a0, consumeSSEStream as a1, contacts as a2, conversations as a3, countCitations as a4, createAuthenticatedClient as a5, createDocumentWaiter as a6, dm as a7, doctags as a8, documents as a9, tags as aA, workspaces as aB, files as aa, formatAgentStepLabel as ab, formatFileSize as ac, formatStreamSummary as ad, formatUserName as ae, formatWorkspaceChoices as af, formatWsMessage as ag, generateEncryptedWorkspaceKey as ah, getErrorCode as ai, getErrorMessage as aj, health as ak, parseSSEEvents as al, performPasswordLogin as am, performSsoDeviceFlowLogin as an, requireData as ao, requireOk as ap, resolveAuth as aq, resolveCitations as ar, resolveWorkspace as as, responses as at, selectWorkspace as au, selectWorkspaceById as av, settings as aw, streamSSE as ax, stripCitationMarkdown as ay, summarizeCitations as az, type CliCredentials as b, type ChatSession as c, type UploadOptions as d, type UploadResult as e, type AgentStepEvent as f, Arbi as g, ArbiApiError as h, ArbiError as i, type ArbiOptions as j, type ArtifactEvent as k, type AuthContext as l, type AuthenticatedClient as m, type CitationSummary as n, type ConnectOptions as o, type DocumentWaiterOptions as p, type MessageMetadataPayload$1 as q, type MessageQueuedEvent as r, type ReconnectableWsConnection as s, type ResolvedCitation as t, type ResponseCompletedEvent as u, type ResponseContentPartAddedEvent as v, type ResponseCreatedEvent as w, type ResponseFailedEvent as x, type ResponseOutputItemAddedEvent as y, type ResponseOutputItemDoneEvent as z };
3587
+ export { buildRetrievalTocTool as $, type AuthHeaders as A, type ResponseOutputItemDoneEvent as B, type ConfigStore as C, type DmCryptoContext as D, type ResponseOutputTextDeltaEvent as E, type FormattedWsMessage as F, type ResponseOutputTextDoneEvent as G, type ResponseUsage as H, type SSEStreamCallbacks as I, type SSEStreamResult as J, type SSEStreamStartData as K, type UserInfo as L, type MessageLevel as M, type UserInputRequestEvent as N, type OutputTokensDetails as O, type UserMessageEvent as P, type QueryOptions as Q, type ReconnectOptions as R, type SSEEvent as S, type WsConnection as T, type UploadBatchResult as U, agentconfig as V, type WorkspaceContext as W, assistant as X, authenticatedFetch as Y, buildRetrievalChunkTool as Z, buildRetrievalFullContextTool as _, type CliConfig as a, connectWebSocket as a0, connectWithReconnect as a1, consumeSSEStream as a2, contacts as a3, conversations as a4, countCitations as a5, createAuthenticatedClient as a6, createDocumentWaiter as a7, dm as a8, doctags as a9, stripCitationMarkdown as aA, summarizeCitations as aB, tags as aC, workspaces as aD, documents as aa, files as ab, formatAgentStepLabel as ac, formatFileSize as ad, formatStreamSummary as ae, formatUserName as af, formatWorkspaceChoices as ag, formatWsMessage as ah, generateEncryptedWorkspaceKey as ai, generateNewWorkspaceKey as aj, getErrorCode as ak, getErrorMessage as al, health as am, parseSSEEvents as an, performPasswordLogin as ao, performSsoDeviceFlowLogin as ap, requireData as aq, requireOk as ar, resolveAuth as as, resolveCitations as at, resolveWorkspace as au, responses as av, selectWorkspace as aw, selectWorkspaceById as ax, settings as ay, streamSSE as az, type CliCredentials as b, type ChatSession as c, type UploadOptions as d, type UploadResult as e, type AgentStepEvent as f, Arbi as g, ArbiApiError as h, ArbiError as i, type ArbiOptions as j, type ArtifactEvent as k, type AuthContext as l, type AuthenticatedClient as m, type CitationSummary as n, type ConnectOptions as o, type DocumentWaiter as p, type DocumentWaiterOptions as q, type MessageMetadataPayload$1 as r, type MessageQueuedEvent as s, type ReconnectableWsConnection as t, type ResolvedCitation as u, type ResponseCompletedEvent as v, type ResponseContentPartAddedEvent as w, type ResponseCreatedEvent as x, type ResponseFailedEvent as y, type ResponseOutputItemAddedEvent as z };