@arbidocs/client 0.3.139 → 0.3.140
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 +39 -8
- package/dist/index.d.ts +39 -8
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -3376,6 +3376,11 @@ interface components {
|
|
|
3376
3376
|
* @description Per-step token cost (input + output + reasoning) for the LLM call that produced this step.
|
|
3377
3377
|
*/
|
|
3378
3378
|
step_tokens?: number | null;
|
|
3379
|
+
/**
|
|
3380
|
+
* Step Credits
|
|
3381
|
+
* @description This step's own AI-credit cost, priced from cached model pricing — an estimate, not the authoritative LiteLLM cost (which is captured once per call into the turn-level ledger total, not correlated back to a specific step).
|
|
3382
|
+
*/
|
|
3383
|
+
step_credits?: number | null;
|
|
3379
3384
|
/** @description Token budget context snapshot. Present when retrieval counts change. */
|
|
3380
3385
|
context?: components['schemas']['TokenBudgetContext'] | null;
|
|
3381
3386
|
/**
|
|
@@ -3601,6 +3606,12 @@ interface components {
|
|
|
3601
3606
|
* @default 20
|
|
3602
3607
|
*/
|
|
3603
3608
|
AGENT_MAX_ITERATIONS: number;
|
|
3609
|
+
/**
|
|
3610
|
+
* Agent Turn Credit Budget
|
|
3611
|
+
* @description Maximum AI credits (1 credit = $0.01) a turn may spend, shared across the main agent and every deep_research/run_code/sub_agent child it spawns — priced per call using each call's own model, since different stages run different models. Agents get a heads-up in their own scratchpad at 50% and 90% so they can wrap up before being forced to answer with what they have. Default is half FREE_AI_CREDITS (100) — a free account's entire grant, so one turn can't consume it all. 0 = uncapped.
|
|
3612
|
+
* @default 50
|
|
3613
|
+
*/
|
|
3614
|
+
AGENT_TURN_CREDIT_BUDGET: number;
|
|
3604
3615
|
/**
|
|
3605
3616
|
* Agent Max Parallel Tool Calls
|
|
3606
3617
|
* @description Maximum number of tool calls the agent can make in a single iteration. Extra calls beyond this limit are silently dropped.
|
|
@@ -3801,6 +3812,12 @@ interface components {
|
|
|
3801
3812
|
* @default 20
|
|
3802
3813
|
*/
|
|
3803
3814
|
AGENT_MAX_ITERATIONS: number;
|
|
3815
|
+
/**
|
|
3816
|
+
* Agent Turn Credit Budget
|
|
3817
|
+
* @description Maximum AI credits (1 credit = $0.01) a turn may spend, shared across the main agent and every deep_research/run_code/sub_agent child it spawns — priced per call using each call's own model, since different stages run different models. Agents get a heads-up in their own scratchpad at 50% and 90% so they can wrap up before being forced to answer with what they have. Default is half FREE_AI_CREDITS (100) — a free account's entire grant, so one turn can't consume it all. 0 = uncapped.
|
|
3818
|
+
* @default 50
|
|
3819
|
+
*/
|
|
3820
|
+
AGENT_TURN_CREDIT_BUDGET: number;
|
|
3804
3821
|
};
|
|
3805
3822
|
/** AllConfigs */
|
|
3806
3823
|
AllConfigs: {
|
|
@@ -3836,6 +3853,7 @@ interface components {
|
|
|
3836
3853
|
* "ENABLE_THINKING": false,
|
|
3837
3854
|
* "AGENT_STRICT_TOOL_CALLS": true,
|
|
3838
3855
|
* "AGENT_MAX_ITERATIONS": 20,
|
|
3856
|
+
* "AGENT_TURN_CREDIT_BUDGET": 50,
|
|
3839
3857
|
* "AGENT_MAX_PARALLEL_TOOL_CALLS": 10,
|
|
3840
3858
|
* "AGENT_HISTORY_CHAR_THRESHOLD": 8000,
|
|
3841
3859
|
* "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."
|
|
@@ -4032,8 +4050,7 @@ interface components {
|
|
|
4032
4050
|
* "MODEL_NAME": "Premium",
|
|
4033
4051
|
* "SYSTEM_INSTRUCTION": "You are a code execution agent. You write and run code to accomplish tasks.\n\nYou have access to an execute_code tool that runs code in a sandboxed Docker container.\n\nThe sandbox has:\n- Python 3.12 with numpy, pandas, matplotlib, requests, beautifulsoup4,\n httpx, pillow, sympy, pyyaml (plus uv for installing more)\n- Node.js 22 with TypeScript (ts-node) and npm\n- Bash with git, curl, wget, jq, sqlite3, build-essential\n- Network access (can pip/npm install additional packages)\n\nInstructions:\n1. Write clean, correct code to accomplish the user's task\n2. Always call execute_code to run your code — never guess the output\n3. If execution errors, analyze the traceback, fix the code, and retry\n4. Once you have the correct output, respond with ONLY the final result\n\nKeep code simple and direct. Prefer Python unless the task specifically requires another language.",
|
|
4034
4052
|
* "TEMPERATURE": 0.2,
|
|
4035
|
-
* "MAX_TOKENS": 0
|
|
4036
|
-
* "MAX_ITERATIONS": 3
|
|
4053
|
+
* "MAX_TOKENS": 0
|
|
4037
4054
|
* }
|
|
4038
4055
|
*/
|
|
4039
4056
|
CodeAgent: components['schemas']['CodeAgentConfig'];
|
|
@@ -4241,6 +4258,11 @@ interface components {
|
|
|
4241
4258
|
* @description The agent's own words for what this item is doing.
|
|
4242
4259
|
*/
|
|
4243
4260
|
focus?: string | null;
|
|
4261
|
+
/**
|
|
4262
|
+
* Content
|
|
4263
|
+
* @description Extended text a one-line focus can't carry — e.g. a sub-agent spawn marker's own task description, or a planning step's checklist.
|
|
4264
|
+
*/
|
|
4265
|
+
content?: string | null;
|
|
4244
4266
|
/**
|
|
4245
4267
|
* Detail
|
|
4246
4268
|
* @description Enriched tool-call display shape (resolved summary, page ranges, digest flags) — richer than the raw `arguments` JSON, for the trace UI. One entry per call on a function_call item.
|
|
@@ -4260,6 +4282,11 @@ interface components {
|
|
|
4260
4282
|
* @description Per-item token cost.
|
|
4261
4283
|
*/
|
|
4262
4284
|
step_tokens?: number | null;
|
|
4285
|
+
/**
|
|
4286
|
+
* Step Credits
|
|
4287
|
+
* @description This item's own AI-credit cost, priced from cached model pricing for its usage — not the authoritative LiteLLM cost (that's captured once per call into the turn-level ledger, not correlated back to a specific step). An estimate for relative step-to-step cost while streaming.
|
|
4288
|
+
*/
|
|
4289
|
+
step_credits?: number | null;
|
|
4263
4290
|
/**
|
|
4264
4291
|
* Total Tokens
|
|
4265
4292
|
* @description Cumulative tokens across the response so far.
|
|
@@ -4773,12 +4800,6 @@ interface components {
|
|
|
4773
4800
|
* @default 0
|
|
4774
4801
|
*/
|
|
4775
4802
|
MAX_TOKENS: number;
|
|
4776
|
-
/**
|
|
4777
|
-
* Max Iterations
|
|
4778
|
-
* @description Maximum code-execute-fix retry cycles.
|
|
4779
|
-
* @default 3
|
|
4780
|
-
*/
|
|
4781
|
-
MAX_ITERATIONS: number;
|
|
4782
4803
|
};
|
|
4783
4804
|
/**
|
|
4784
4805
|
* CommandDescriptorResponse
|
|
@@ -10366,6 +10387,16 @@ interface components {
|
|
|
10366
10387
|
* @description Total cost: input_cost + output_cost (USD)
|
|
10367
10388
|
*/
|
|
10368
10389
|
total_cost?: number | null;
|
|
10390
|
+
/**
|
|
10391
|
+
* Credits Spent
|
|
10392
|
+
* @description AI credits spent so far this turn (1 credit = $0.01), priced per LLM call using each call's own model — unlike total_cost above (single-rate, main query LLM only), this is correct across a turn that mixes models (agent LLM, deep_research/run_code child LLMs, evaluator, judge). Updates live as the turn progresses, not just a final total.
|
|
10393
|
+
*/
|
|
10394
|
+
credits_spent?: number | null;
|
|
10395
|
+
/**
|
|
10396
|
+
* Credit Budget
|
|
10397
|
+
* @description This turn's shared credit budget (AGENT_TURN_CREDIT_BUDGET) — same value across the parent and every child it spawns. Absent when uncapped (budget=0).
|
|
10398
|
+
*/
|
|
10399
|
+
credit_budget?: number | null;
|
|
10369
10400
|
/**
|
|
10370
10401
|
* Elapsed Seconds
|
|
10371
10402
|
* @description Wall-clock time for the LLM call(s)
|
package/dist/index.d.ts
CHANGED
|
@@ -3376,6 +3376,11 @@ interface components {
|
|
|
3376
3376
|
* @description Per-step token cost (input + output + reasoning) for the LLM call that produced this step.
|
|
3377
3377
|
*/
|
|
3378
3378
|
step_tokens?: number | null;
|
|
3379
|
+
/**
|
|
3380
|
+
* Step Credits
|
|
3381
|
+
* @description This step's own AI-credit cost, priced from cached model pricing — an estimate, not the authoritative LiteLLM cost (which is captured once per call into the turn-level ledger total, not correlated back to a specific step).
|
|
3382
|
+
*/
|
|
3383
|
+
step_credits?: number | null;
|
|
3379
3384
|
/** @description Token budget context snapshot. Present when retrieval counts change. */
|
|
3380
3385
|
context?: components['schemas']['TokenBudgetContext'] | null;
|
|
3381
3386
|
/**
|
|
@@ -3601,6 +3606,12 @@ interface components {
|
|
|
3601
3606
|
* @default 20
|
|
3602
3607
|
*/
|
|
3603
3608
|
AGENT_MAX_ITERATIONS: number;
|
|
3609
|
+
/**
|
|
3610
|
+
* Agent Turn Credit Budget
|
|
3611
|
+
* @description Maximum AI credits (1 credit = $0.01) a turn may spend, shared across the main agent and every deep_research/run_code/sub_agent child it spawns — priced per call using each call's own model, since different stages run different models. Agents get a heads-up in their own scratchpad at 50% and 90% so they can wrap up before being forced to answer with what they have. Default is half FREE_AI_CREDITS (100) — a free account's entire grant, so one turn can't consume it all. 0 = uncapped.
|
|
3612
|
+
* @default 50
|
|
3613
|
+
*/
|
|
3614
|
+
AGENT_TURN_CREDIT_BUDGET: number;
|
|
3604
3615
|
/**
|
|
3605
3616
|
* Agent Max Parallel Tool Calls
|
|
3606
3617
|
* @description Maximum number of tool calls the agent can make in a single iteration. Extra calls beyond this limit are silently dropped.
|
|
@@ -3801,6 +3812,12 @@ interface components {
|
|
|
3801
3812
|
* @default 20
|
|
3802
3813
|
*/
|
|
3803
3814
|
AGENT_MAX_ITERATIONS: number;
|
|
3815
|
+
/**
|
|
3816
|
+
* Agent Turn Credit Budget
|
|
3817
|
+
* @description Maximum AI credits (1 credit = $0.01) a turn may spend, shared across the main agent and every deep_research/run_code/sub_agent child it spawns — priced per call using each call's own model, since different stages run different models. Agents get a heads-up in their own scratchpad at 50% and 90% so they can wrap up before being forced to answer with what they have. Default is half FREE_AI_CREDITS (100) — a free account's entire grant, so one turn can't consume it all. 0 = uncapped.
|
|
3818
|
+
* @default 50
|
|
3819
|
+
*/
|
|
3820
|
+
AGENT_TURN_CREDIT_BUDGET: number;
|
|
3804
3821
|
};
|
|
3805
3822
|
/** AllConfigs */
|
|
3806
3823
|
AllConfigs: {
|
|
@@ -3836,6 +3853,7 @@ interface components {
|
|
|
3836
3853
|
* "ENABLE_THINKING": false,
|
|
3837
3854
|
* "AGENT_STRICT_TOOL_CALLS": true,
|
|
3838
3855
|
* "AGENT_MAX_ITERATIONS": 20,
|
|
3856
|
+
* "AGENT_TURN_CREDIT_BUDGET": 50,
|
|
3839
3857
|
* "AGENT_MAX_PARALLEL_TOOL_CALLS": 10,
|
|
3840
3858
|
* "AGENT_HISTORY_CHAR_THRESHOLD": 8000,
|
|
3841
3859
|
* "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."
|
|
@@ -4032,8 +4050,7 @@ interface components {
|
|
|
4032
4050
|
* "MODEL_NAME": "Premium",
|
|
4033
4051
|
* "SYSTEM_INSTRUCTION": "You are a code execution agent. You write and run code to accomplish tasks.\n\nYou have access to an execute_code tool that runs code in a sandboxed Docker container.\n\nThe sandbox has:\n- Python 3.12 with numpy, pandas, matplotlib, requests, beautifulsoup4,\n httpx, pillow, sympy, pyyaml (plus uv for installing more)\n- Node.js 22 with TypeScript (ts-node) and npm\n- Bash with git, curl, wget, jq, sqlite3, build-essential\n- Network access (can pip/npm install additional packages)\n\nInstructions:\n1. Write clean, correct code to accomplish the user's task\n2. Always call execute_code to run your code — never guess the output\n3. If execution errors, analyze the traceback, fix the code, and retry\n4. Once you have the correct output, respond with ONLY the final result\n\nKeep code simple and direct. Prefer Python unless the task specifically requires another language.",
|
|
4034
4052
|
* "TEMPERATURE": 0.2,
|
|
4035
|
-
* "MAX_TOKENS": 0
|
|
4036
|
-
* "MAX_ITERATIONS": 3
|
|
4053
|
+
* "MAX_TOKENS": 0
|
|
4037
4054
|
* }
|
|
4038
4055
|
*/
|
|
4039
4056
|
CodeAgent: components['schemas']['CodeAgentConfig'];
|
|
@@ -4241,6 +4258,11 @@ interface components {
|
|
|
4241
4258
|
* @description The agent's own words for what this item is doing.
|
|
4242
4259
|
*/
|
|
4243
4260
|
focus?: string | null;
|
|
4261
|
+
/**
|
|
4262
|
+
* Content
|
|
4263
|
+
* @description Extended text a one-line focus can't carry — e.g. a sub-agent spawn marker's own task description, or a planning step's checklist.
|
|
4264
|
+
*/
|
|
4265
|
+
content?: string | null;
|
|
4244
4266
|
/**
|
|
4245
4267
|
* Detail
|
|
4246
4268
|
* @description Enriched tool-call display shape (resolved summary, page ranges, digest flags) — richer than the raw `arguments` JSON, for the trace UI. One entry per call on a function_call item.
|
|
@@ -4260,6 +4282,11 @@ interface components {
|
|
|
4260
4282
|
* @description Per-item token cost.
|
|
4261
4283
|
*/
|
|
4262
4284
|
step_tokens?: number | null;
|
|
4285
|
+
/**
|
|
4286
|
+
* Step Credits
|
|
4287
|
+
* @description This item's own AI-credit cost, priced from cached model pricing for its usage — not the authoritative LiteLLM cost (that's captured once per call into the turn-level ledger, not correlated back to a specific step). An estimate for relative step-to-step cost while streaming.
|
|
4288
|
+
*/
|
|
4289
|
+
step_credits?: number | null;
|
|
4263
4290
|
/**
|
|
4264
4291
|
* Total Tokens
|
|
4265
4292
|
* @description Cumulative tokens across the response so far.
|
|
@@ -4773,12 +4800,6 @@ interface components {
|
|
|
4773
4800
|
* @default 0
|
|
4774
4801
|
*/
|
|
4775
4802
|
MAX_TOKENS: number;
|
|
4776
|
-
/**
|
|
4777
|
-
* Max Iterations
|
|
4778
|
-
* @description Maximum code-execute-fix retry cycles.
|
|
4779
|
-
* @default 3
|
|
4780
|
-
*/
|
|
4781
|
-
MAX_ITERATIONS: number;
|
|
4782
4803
|
};
|
|
4783
4804
|
/**
|
|
4784
4805
|
* CommandDescriptorResponse
|
|
@@ -10366,6 +10387,16 @@ interface components {
|
|
|
10366
10387
|
* @description Total cost: input_cost + output_cost (USD)
|
|
10367
10388
|
*/
|
|
10368
10389
|
total_cost?: number | null;
|
|
10390
|
+
/**
|
|
10391
|
+
* Credits Spent
|
|
10392
|
+
* @description AI credits spent so far this turn (1 credit = $0.01), priced per LLM call using each call's own model — unlike total_cost above (single-rate, main query LLM only), this is correct across a turn that mixes models (agent LLM, deep_research/run_code child LLMs, evaluator, judge). Updates live as the turn progresses, not just a final total.
|
|
10393
|
+
*/
|
|
10394
|
+
credits_spent?: number | null;
|
|
10395
|
+
/**
|
|
10396
|
+
* Credit Budget
|
|
10397
|
+
* @description This turn's shared credit budget (AGENT_TURN_CREDIT_BUDGET) — same value across the parent and every child it spawns. Absent when uncapped (budget=0).
|
|
10398
|
+
*/
|
|
10399
|
+
credit_budget?: number | null;
|
|
10369
10400
|
/**
|
|
10370
10401
|
* Elapsed Seconds
|
|
10371
10402
|
* @description Wall-clock time for the LLM call(s)
|
package/package.json
CHANGED