llama-stack-client 0.3.5 → 0.4.0-rc2
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/CHANGELOG.md +153 -0
- package/README.md +48 -39
- package/error.d.ts.map +1 -1
- package/error.js +1 -0
- package/error.js.map +1 -1
- package/error.mjs.map +1 -1
- package/index.d.mts +33 -54
- package/index.d.ts +33 -54
- package/index.d.ts.map +1 -1
- package/index.js +20 -29
- package/index.js.map +1 -1
- package/index.mjs +18 -28
- package/index.mjs.map +1 -1
- package/lib/response-helpers.d.ts +23 -0
- package/lib/response-helpers.d.ts.map +1 -0
- package/lib/response-helpers.js +53 -0
- package/lib/response-helpers.js.map +1 -0
- package/lib/response-helpers.mjs +49 -0
- package/lib/response-helpers.mjs.map +1 -0
- package/package.json +7 -1
- package/pagination.d.ts.map +1 -1
- package/pagination.js +2 -4
- package/pagination.js.map +1 -1
- package/pagination.mjs +1 -4
- package/pagination.mjs.map +1 -1
- package/resource.d.ts.map +1 -1
- package/resource.js.map +1 -1
- package/resource.mjs.map +1 -1
- package/resources/alpha/admin.d.ts +41 -0
- package/resources/alpha/admin.d.ts.map +1 -0
- package/resources/alpha/admin.js +46 -0
- package/resources/alpha/admin.js.map +1 -0
- package/resources/alpha/admin.mjs +42 -0
- package/resources/alpha/admin.mjs.map +1 -0
- package/resources/alpha/alpha.d.ts +26 -0
- package/resources/alpha/alpha.d.ts.map +1 -0
- package/resources/alpha/alpha.js +61 -0
- package/resources/alpha/alpha.js.map +1 -0
- package/resources/alpha/alpha.mjs +34 -0
- package/resources/alpha/alpha.mjs.map +1 -0
- package/resources/{benchmarks.d.ts → alpha/benchmarks.d.ts} +41 -15
- package/resources/alpha/benchmarks.d.ts.map +1 -0
- package/resources/{benchmarks.js → alpha/benchmarks.js} +18 -4
- package/resources/alpha/benchmarks.js.map +1 -0
- package/resources/alpha/benchmarks.mjs +44 -0
- package/resources/alpha/benchmarks.mjs.map +1 -0
- package/resources/alpha/eval/eval.d.ts +160 -0
- package/resources/alpha/eval/eval.d.ts.map +1 -0
- package/resources/{eval → alpha/eval}/eval.js +7 -6
- package/resources/alpha/eval/eval.js.map +1 -0
- package/resources/{eval → alpha/eval}/eval.mjs +7 -5
- package/resources/alpha/eval/eval.mjs.map +1 -0
- package/resources/alpha/eval/index.d.ts +3 -0
- package/resources/alpha/eval/index.d.ts.map +1 -0
- package/resources/{eval → alpha/eval}/index.js +2 -1
- package/resources/alpha/eval/index.js.map +1 -0
- package/resources/{eval → alpha/eval}/index.mjs +2 -0
- package/resources/alpha/eval/index.mjs.map +1 -0
- package/resources/{eval → alpha/eval}/jobs.d.ts +2 -2
- package/resources/alpha/eval/jobs.d.ts.map +1 -0
- package/resources/{eval → alpha/eval}/jobs.js +6 -5
- package/resources/alpha/eval/jobs.js.map +1 -0
- package/resources/{eval → alpha/eval}/jobs.mjs +6 -4
- package/resources/alpha/eval/jobs.mjs.map +1 -0
- package/resources/alpha/eval.d.ts.map +1 -0
- package/resources/{eval.js → alpha/eval.js} +1 -0
- package/resources/alpha/eval.js.map +1 -0
- package/resources/alpha/eval.mjs.map +1 -0
- package/resources/alpha/index.d.ts +7 -0
- package/resources/alpha/index.d.ts.map +1 -0
- package/resources/alpha/index.js +23 -0
- package/resources/alpha/index.js.map +1 -0
- package/resources/alpha/index.mjs +14 -0
- package/resources/alpha/index.mjs.map +1 -0
- package/resources/alpha/inference.d.ts +85 -0
- package/resources/alpha/inference.d.ts.map +1 -0
- package/resources/{agents/steps.js → alpha/inference.js} +9 -8
- package/resources/alpha/inference.js.map +1 -0
- package/resources/alpha/inference.mjs +17 -0
- package/resources/alpha/inference.mjs.map +1 -0
- package/resources/alpha/post-training/index.d.ts.map +1 -0
- package/resources/{post-training → alpha/post-training}/index.js +2 -1
- package/resources/alpha/post-training/index.js.map +1 -0
- package/resources/{post-training → alpha/post-training}/index.mjs +2 -0
- package/resources/alpha/post-training/index.mjs.map +1 -0
- package/resources/alpha/post-training/job.d.ts +113 -0
- package/resources/alpha/post-training/job.d.ts.map +1 -0
- package/resources/{post-training → alpha/post-training}/job.js +7 -6
- package/resources/alpha/post-training/job.js.map +1 -0
- package/resources/{post-training → alpha/post-training}/job.mjs +7 -5
- package/resources/alpha/post-training/job.mjs.map +1 -0
- package/resources/alpha/post-training/post-training.d.ts +245 -0
- package/resources/alpha/post-training/post-training.d.ts.map +1 -0
- package/resources/{post-training → alpha/post-training}/post-training.js +5 -4
- package/resources/alpha/post-training/post-training.js.map +1 -0
- package/resources/{post-training → alpha/post-training}/post-training.mjs +5 -3
- package/resources/alpha/post-training/post-training.mjs.map +1 -0
- package/resources/alpha/post-training.d.ts.map +1 -0
- package/resources/{post-training.js → alpha/post-training.js} +2 -1
- package/resources/alpha/post-training.js.map +1 -0
- package/resources/{post-training.mjs → alpha/post-training.mjs} +2 -0
- package/resources/alpha/post-training.mjs.map +1 -0
- package/resources/alpha.d.ts +2 -0
- package/resources/alpha.d.ts.map +1 -0
- package/resources/alpha.js +25 -0
- package/resources/alpha.js.map +1 -0
- package/resources/alpha.mjs +9 -0
- package/resources/alpha.mjs.map +1 -0
- package/resources/batches.d.ts +322 -0
- package/resources/batches.d.ts.map +1 -0
- package/resources/batches.js +45 -0
- package/resources/batches.js.map +1 -0
- package/resources/batches.mjs +40 -0
- package/resources/batches.mjs.map +1 -0
- package/resources/beta/beta.d.ts +10 -0
- package/resources/beta/beta.d.ts.map +1 -0
- package/resources/{tool-runtime/tool-runtime.js → beta/beta.js} +10 -22
- package/resources/beta/beta.js.map +1 -0
- package/resources/beta/beta.mjs +18 -0
- package/resources/beta/beta.mjs.map +1 -0
- package/resources/{datasets.d.ts → beta/datasets.d.ts} +117 -99
- package/resources/beta/datasets.d.ts.map +1 -0
- package/resources/{datasets.js → beta/datasets.js} +14 -9
- package/resources/beta/datasets.js.map +1 -0
- package/resources/{datasets.mjs → beta/datasets.mjs} +14 -8
- package/resources/beta/datasets.mjs.map +1 -0
- package/resources/beta/index.d.ts +3 -0
- package/resources/beta/index.d.ts.map +1 -0
- package/resources/beta/index.js +15 -0
- package/resources/beta/index.js.map +1 -0
- package/resources/beta/index.mjs +10 -0
- package/resources/beta/index.mjs.map +1 -0
- package/resources/beta.d.ts +2 -0
- package/resources/beta.d.ts.map +1 -0
- package/resources/{agents.js → beta.js} +4 -3
- package/resources/beta.js.map +1 -0
- package/resources/beta.mjs +9 -0
- package/resources/beta.mjs.map +1 -0
- package/resources/chat/chat.d.ts +75 -80
- package/resources/chat/chat.d.ts.map +1 -1
- package/resources/chat/chat.js +2 -2
- package/resources/chat/chat.js.map +1 -1
- package/resources/chat/chat.mjs +3 -2
- package/resources/chat/chat.mjs.map +1 -1
- package/resources/chat/completions.d.ts +760 -1406
- package/resources/chat/completions.d.ts.map +1 -1
- package/resources/chat/completions.js +8 -14
- package/resources/chat/completions.js.map +1 -1
- package/resources/chat/completions.mjs +7 -11
- package/resources/chat/completions.mjs.map +1 -1
- package/resources/chat/index.d.ts +1 -1
- package/resources/chat/index.d.ts.map +1 -1
- package/resources/chat/index.js +3 -3
- package/resources/chat/index.js.map +1 -1
- package/resources/chat/index.mjs +3 -1
- package/resources/chat/index.mjs.map +1 -1
- package/resources/chat.js +2 -1
- package/resources/chat.js.map +1 -1
- package/resources/chat.mjs +2 -0
- package/resources/chat.mjs.map +1 -1
- package/resources/completions.d.ts +54 -97
- package/resources/completions.d.ts.map +1 -1
- package/resources/completions.js +3 -6
- package/resources/completions.js.map +1 -1
- package/resources/completions.mjs +3 -5
- package/resources/completions.mjs.map +1 -1
- package/resources/conversations/conversations.d.ts +320 -0
- package/resources/conversations/conversations.d.ts.map +1 -0
- package/resources/conversations/conversations.js +78 -0
- package/resources/conversations/conversations.js.map +1 -0
- package/resources/conversations/conversations.mjs +51 -0
- package/resources/conversations/conversations.mjs.map +1 -0
- package/resources/conversations/index.d.ts +3 -0
- package/resources/conversations/index.d.ts.map +1 -0
- package/resources/conversations/index.js +16 -0
- package/resources/conversations/index.js.map +1 -0
- package/resources/conversations/index.mjs +10 -0
- package/resources/conversations/index.mjs.map +1 -0
- package/resources/conversations/items.d.ts +874 -0
- package/resources/conversations/items.d.ts.map +1 -0
- package/resources/conversations/items.js +51 -0
- package/resources/conversations/items.js.map +1 -0
- package/resources/conversations/items.mjs +46 -0
- package/resources/conversations/items.mjs.map +1 -0
- package/resources/conversations.d.ts +2 -0
- package/resources/conversations.d.ts.map +1 -0
- package/resources/conversations.js +25 -0
- package/resources/conversations.js.map +1 -0
- package/resources/conversations.mjs +9 -0
- package/resources/conversations.mjs.map +1 -0
- package/resources/embeddings.d.ts +10 -52
- package/resources/embeddings.d.ts.map +1 -1
- package/resources/embeddings.js +5 -2
- package/resources/embeddings.js.map +1 -1
- package/resources/embeddings.mjs +5 -1
- package/resources/embeddings.mjs.map +1 -1
- package/resources/files.d.ts +44 -54
- package/resources/files.d.ts.map +1 -1
- package/resources/files.js +18 -9
- package/resources/files.js.map +1 -1
- package/resources/files.mjs +18 -8
- package/resources/files.mjs.map +1 -1
- package/resources/index.d.ts +11 -15
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js +15 -21
- package/resources/index.js.map +1 -1
- package/resources/index.mjs +9 -11
- package/resources/index.mjs.map +1 -1
- package/resources/inspect.d.ts +3 -71
- package/resources/inspect.d.ts.map +1 -1
- package/resources/inspect.js +2 -1
- package/resources/inspect.js.map +1 -1
- package/resources/inspect.mjs +2 -0
- package/resources/inspect.mjs.map +1 -1
- package/resources/models/index.d.ts +2 -2
- package/resources/models/index.d.ts.map +1 -1
- package/resources/models/index.js +2 -1
- package/resources/models/index.js.map +1 -1
- package/resources/models/index.mjs +2 -0
- package/resources/models/index.mjs.map +1 -1
- package/resources/models/models.d.ts +71 -31
- package/resources/models/models.d.ts.map +1 -1
- package/resources/models/models.js +13 -2
- package/resources/models/models.js.map +1 -1
- package/resources/models/models.mjs +13 -1
- package/resources/models/models.mjs.map +1 -1
- package/resources/models/openai.d.ts +2 -16
- package/resources/models/openai.d.ts.map +1 -1
- package/resources/models/openai.js +3 -2
- package/resources/models/openai.js.map +1 -1
- package/resources/models/openai.mjs +3 -1
- package/resources/models/openai.mjs.map +1 -1
- package/resources/models.js +2 -1
- package/resources/models.js.map +1 -1
- package/resources/models.mjs +2 -0
- package/resources/models.mjs.map +1 -1
- package/resources/moderations.d.ts +9 -35
- package/resources/moderations.d.ts.map +1 -1
- package/resources/moderations.js +5 -2
- package/resources/moderations.js.map +1 -1
- package/resources/moderations.mjs +5 -1
- package/resources/moderations.mjs.map +1 -1
- package/resources/prompts/index.d.ts +3 -0
- package/resources/prompts/index.d.ts.map +1 -0
- package/resources/prompts/index.js +15 -0
- package/resources/prompts/index.js.map +1 -0
- package/resources/prompts/index.mjs +10 -0
- package/resources/prompts/index.mjs.map +1 -0
- package/resources/prompts/prompts.d.ts +96 -0
- package/resources/prompts/prompts.d.ts.map +1 -0
- package/resources/{agents/agents.js → prompts/prompts.js} +43 -30
- package/resources/prompts/prompts.js.map +1 -0
- package/resources/prompts/prompts.mjs +66 -0
- package/resources/prompts/prompts.mjs.map +1 -0
- package/resources/prompts/versions.d.ts +12 -0
- package/resources/prompts/versions.d.ts.map +1 -0
- package/resources/prompts/versions.js +23 -0
- package/resources/prompts/versions.js.map +1 -0
- package/resources/prompts/versions.mjs +19 -0
- package/resources/prompts/versions.mjs.map +1 -0
- package/resources/prompts.d.ts +2 -0
- package/resources/prompts.d.ts.map +1 -0
- package/resources/prompts.js +25 -0
- package/resources/prompts.js.map +1 -0
- package/resources/prompts.mjs +9 -0
- package/resources/prompts.mjs.map +1 -0
- package/resources/providers.d.ts +4 -13
- package/resources/providers.d.ts.map +1 -1
- package/resources/providers.js +2 -1
- package/resources/providers.js.map +1 -1
- package/resources/providers.mjs +2 -0
- package/resources/providers.mjs.map +1 -1
- package/resources/responses/index.js +2 -1
- package/resources/responses/index.js.map +1 -1
- package/resources/responses/index.mjs +2 -0
- package/resources/responses/index.mjs.map +1 -1
- package/resources/responses/input-items.d.ts +246 -151
- package/resources/responses/input-items.d.ts.map +1 -1
- package/resources/responses/input-items.js +3 -2
- package/resources/responses/input-items.js.map +1 -1
- package/resources/responses/input-items.mjs +3 -1
- package/resources/responses/input-items.mjs.map +1 -1
- package/resources/responses/responses.d.ts +1841 -1455
- package/resources/responses/responses.d.ts.map +1 -1
- package/resources/responses/responses.js +8 -11
- package/resources/responses/responses.js.map +1 -1
- package/resources/responses/responses.mjs +8 -10
- package/resources/responses/responses.mjs.map +1 -1
- package/resources/responses.js +2 -1
- package/resources/responses.js.map +1 -1
- package/resources/responses.mjs +2 -0
- package/resources/responses.mjs.map +1 -1
- package/resources/routes.d.ts +11 -10
- package/resources/routes.d.ts.map +1 -1
- package/resources/routes.js +8 -6
- package/resources/routes.js.map +1 -1
- package/resources/routes.mjs +8 -5
- package/resources/routes.mjs.map +1 -1
- package/resources/safety.d.ts +144 -10
- package/resources/safety.d.ts.map +1 -1
- package/resources/safety.js +4 -1
- package/resources/safety.js.map +1 -1
- package/resources/safety.mjs +4 -0
- package/resources/safety.mjs.map +1 -1
- package/resources/scoring-functions.d.ts +120 -50
- package/resources/scoring-functions.d.ts.map +1 -1
- package/resources/scoring-functions.js +15 -1
- package/resources/scoring-functions.js.map +1 -1
- package/resources/scoring-functions.mjs +15 -0
- package/resources/scoring-functions.mjs.map +1 -1
- package/resources/scoring.d.ts +85 -26
- package/resources/scoring.d.ts.map +1 -1
- package/resources/scoring.js +2 -1
- package/resources/scoring.js.map +1 -1
- package/resources/scoring.mjs +2 -0
- package/resources/scoring.mjs.map +1 -1
- package/resources/shared.d.ts +173 -591
- package/resources/shared.d.ts.map +1 -1
- package/resources/shared.js +2 -0
- package/resources/shared.js.map +1 -1
- package/resources/shared.mjs +2 -0
- package/resources/shared.mjs.map +1 -1
- package/resources/shields.d.ts +19 -24
- package/resources/shields.d.ts.map +1 -1
- package/resources/shields.js +6 -1
- package/resources/shields.js.map +1 -1
- package/resources/shields.mjs +6 -0
- package/resources/shields.mjs.map +1 -1
- package/resources/tool-runtime.d.ts +151 -1
- package/resources/tool-runtime.d.ts.map +1 -1
- package/resources/tool-runtime.js +22 -16
- package/resources/tool-runtime.js.map +1 -1
- package/resources/tool-runtime.mjs +20 -1
- package/resources/tool-runtime.mjs.map +1 -1
- package/resources/toolgroups.d.ts +27 -37
- package/resources/toolgroups.d.ts.map +1 -1
- package/resources/toolgroups.js +10 -1
- package/resources/toolgroups.js.map +1 -1
- package/resources/toolgroups.mjs +10 -0
- package/resources/toolgroups.mjs.map +1 -1
- package/resources/tools.d.ts +9 -76
- package/resources/tools.d.ts.map +1 -1
- package/resources/tools.js +4 -1
- package/resources/tools.js.map +1 -1
- package/resources/tools.mjs +4 -0
- package/resources/tools.mjs.map +1 -1
- package/resources/vector-io.d.ts +272 -148
- package/resources/vector-io.d.ts.map +1 -1
- package/resources/vector-io.js +2 -1
- package/resources/vector-io.js.map +1 -1
- package/resources/vector-io.mjs +2 -0
- package/resources/vector-io.mjs.map +1 -1
- package/resources/vector-stores/file-batches.d.ts +111 -0
- package/resources/vector-stores/file-batches.d.ts.map +1 -0
- package/resources/vector-stores/file-batches.js +45 -0
- package/resources/vector-stores/file-batches.js.map +1 -0
- package/resources/vector-stores/file-batches.mjs +41 -0
- package/resources/vector-stores/file-batches.mjs.map +1 -0
- package/resources/vector-stores/files.d.ts +83 -135
- package/resources/vector-stores/files.d.ts.map +1 -1
- package/resources/vector-stores/files.js +15 -14
- package/resources/vector-stores/files.js.map +1 -1
- package/resources/vector-stores/files.mjs +15 -13
- package/resources/vector-stores/files.mjs.map +1 -1
- package/resources/vector-stores/index.d.ts +2 -1
- package/resources/vector-stores/index.d.ts.map +1 -1
- package/resources/vector-stores/index.js +5 -2
- package/resources/vector-stores/index.js.map +1 -1
- package/resources/vector-stores/index.mjs +3 -0
- package/resources/vector-stores/index.mjs.map +1 -1
- package/resources/vector-stores/vector-stores.d.ts +118 -217
- package/resources/vector-stores/vector-stores.d.ts.map +1 -1
- package/resources/vector-stores/vector-stores.js +18 -12
- package/resources/vector-stores/vector-stores.js.map +1 -1
- package/resources/vector-stores/vector-stores.mjs +18 -11
- package/resources/vector-stores/vector-stores.mjs.map +1 -1
- package/resources/vector-stores.js +2 -1
- package/resources/vector-stores.js.map +1 -1
- package/resources/vector-stores.mjs +2 -0
- package/resources/vector-stores.mjs.map +1 -1
- package/src/error.ts +1 -0
- package/src/index.ts +92 -267
- package/src/lib/response-helpers.ts +60 -0
- package/src/pagination.ts +2 -5
- package/src/resource.ts +1 -0
- package/src/resources/alpha/admin.ts +84 -0
- package/src/resources/alpha/alpha.ts +93 -0
- package/src/resources/{benchmarks.ts → alpha/benchmarks.ts} +51 -16
- package/src/resources/{eval → alpha/eval}/eval.ts +83 -65
- package/src/resources/{eval → alpha/eval}/index.ts +1 -2
- package/src/resources/{eval → alpha/eval}/jobs.ts +6 -6
- package/src/resources/{eval.ts → alpha/eval.ts} +1 -0
- package/src/resources/alpha/index.ts +36 -0
- package/src/resources/alpha/inference.ts +132 -0
- package/src/resources/{post-training → alpha/post-training}/index.ts +1 -1
- package/src/resources/alpha/post-training/job.ts +177 -0
- package/src/resources/alpha/post-training/post-training.ts +372 -0
- package/src/resources/{post-training.ts → alpha/post-training.ts} +1 -1
- package/src/resources/alpha.ts +9 -0
- package/src/resources/batches.ts +572 -0
- package/src/resources/beta/beta.ts +41 -0
- package/src/resources/{datasets.ts → beta/datasets.ts} +128 -110
- package/src/resources/beta/index.ts +20 -0
- package/src/resources/{agents.ts → beta.ts} +2 -2
- package/src/resources/chat/chat.ts +84 -83
- package/src/resources/chat/completions.ts +876 -1486
- package/src/resources/chat/index.ts +1 -2
- package/src/resources/chat.ts +1 -1
- package/src/resources/completions.ts +59 -103
- package/src/resources/conversations/conversations.ts +491 -0
- package/src/resources/conversations/index.ts +25 -0
- package/src/resources/conversations/items.ts +1365 -0
- package/src/resources/conversations.ts +9 -0
- package/src/resources/embeddings.ts +14 -55
- package/src/resources/files.ts +54 -61
- package/src/resources/index.ts +35 -111
- package/src/resources/inspect.ts +4 -84
- package/src/resources/models/index.ts +4 -2
- package/src/resources/models/models.ts +79 -30
- package/src/resources/models/openai.ts +4 -24
- package/src/resources/models.ts +1 -1
- package/src/resources/moderations.ts +10 -36
- package/src/resources/prompts/index.ts +19 -0
- package/src/resources/prompts/prompts.ts +171 -0
- package/src/resources/prompts/versions.ts +26 -0
- package/src/resources/prompts.ts +9 -0
- package/src/resources/providers.ts +5 -18
- package/src/resources/responses/index.ts +1 -1
- package/src/resources/responses/input-items.ts +365 -161
- package/src/resources/responses/responses.ts +2959 -1870
- package/src/resources/responses.ts +1 -1
- package/src/resources/routes.ts +25 -14
- package/src/resources/safety.ts +199 -9
- package/src/resources/scoring-functions.ts +168 -52
- package/src/resources/scoring.ts +125 -22
- package/src/resources/shared.ts +187 -665
- package/src/resources/shields.ts +18 -23
- package/src/resources/tool-runtime.ts +210 -2
- package/src/resources/toolgroups.ts +26 -36
- package/src/resources/tools.ts +10 -94
- package/src/resources/vector-io.ts +323 -145
- package/src/resources/vector-stores/file-batches.ts +201 -0
- package/src/resources/vector-stores/files.ts +123 -143
- package/src/resources/vector-stores/index.ts +9 -1
- package/src/resources/vector-stores/vector-stores.ts +150 -216
- package/src/resources/vector-stores.ts +1 -1
- package/src/version.ts +1 -1
- package/version.d.ts +1 -1
- package/version.d.ts.map +1 -1
- package/version.js +1 -1
- package/version.js.map +1 -1
- package/version.mjs +1 -1
- package/version.mjs.map +1 -1
- package/resources/agents/agents.d.ts +0 -246
- package/resources/agents/agents.d.ts.map +0 -1
- package/resources/agents/agents.js.map +0 -1
- package/resources/agents/agents.mjs +0 -52
- package/resources/agents/agents.mjs.map +0 -1
- package/resources/agents/index.d.ts +0 -5
- package/resources/agents/index.d.ts.map +0 -1
- package/resources/agents/index.js +0 -18
- package/resources/agents/index.js.map +0 -1
- package/resources/agents/index.mjs +0 -10
- package/resources/agents/index.mjs.map +0 -1
- package/resources/agents/session.d.ts +0 -98
- package/resources/agents/session.d.ts.map +0 -1
- package/resources/agents/session.js +0 -42
- package/resources/agents/session.js.map +0 -1
- package/resources/agents/session.mjs +0 -37
- package/resources/agents/session.mjs.map +0 -1
- package/resources/agents/steps.d.ts +0 -22
- package/resources/agents/steps.d.ts.map +0 -1
- package/resources/agents/steps.js.map +0 -1
- package/resources/agents/steps.mjs +0 -15
- package/resources/agents/steps.mjs.map +0 -1
- package/resources/agents/turn.d.ts +0 -461
- package/resources/agents/turn.d.ts.map +0 -1
- package/resources/agents/turn.js +0 -34
- package/resources/agents/turn.js.map +0 -1
- package/resources/agents/turn.mjs +0 -29
- package/resources/agents/turn.mjs.map +0 -1
- package/resources/agents.d.ts +0 -2
- package/resources/agents.d.ts.map +0 -1
- package/resources/agents.js.map +0 -1
- package/resources/agents.mjs +0 -7
- package/resources/agents.mjs.map +0 -1
- package/resources/benchmarks.d.ts.map +0 -1
- package/resources/benchmarks.js.map +0 -1
- package/resources/benchmarks.mjs +0 -31
- package/resources/benchmarks.mjs.map +0 -1
- package/resources/datasets.d.ts.map +0 -1
- package/resources/datasets.js.map +0 -1
- package/resources/datasets.mjs.map +0 -1
- package/resources/eval/eval.d.ts +0 -159
- package/resources/eval/eval.d.ts.map +0 -1
- package/resources/eval/eval.js.map +0 -1
- package/resources/eval/eval.mjs.map +0 -1
- package/resources/eval/index.d.ts +0 -3
- package/resources/eval/index.d.ts.map +0 -1
- package/resources/eval/index.js.map +0 -1
- package/resources/eval/index.mjs.map +0 -1
- package/resources/eval/jobs.d.ts.map +0 -1
- package/resources/eval/jobs.js.map +0 -1
- package/resources/eval/jobs.mjs.map +0 -1
- package/resources/eval.d.ts.map +0 -1
- package/resources/eval.js.map +0 -1
- package/resources/eval.mjs.map +0 -1
- package/resources/inference.d.ts +0 -580
- package/resources/inference.d.ts.map +0 -1
- package/resources/inference.js +0 -54
- package/resources/inference.js.map +0 -1
- package/resources/inference.mjs +0 -49
- package/resources/inference.mjs.map +0 -1
- package/resources/post-training/index.d.ts.map +0 -1
- package/resources/post-training/index.js.map +0 -1
- package/resources/post-training/index.mjs.map +0 -1
- package/resources/post-training/job.d.ts +0 -205
- package/resources/post-training/job.d.ts.map +0 -1
- package/resources/post-training/job.js.map +0 -1
- package/resources/post-training/job.mjs.map +0 -1
- package/resources/post-training/post-training.d.ts +0 -402
- package/resources/post-training/post-training.d.ts.map +0 -1
- package/resources/post-training/post-training.js.map +0 -1
- package/resources/post-training/post-training.mjs.map +0 -1
- package/resources/post-training.d.ts.map +0 -1
- package/resources/post-training.js.map +0 -1
- package/resources/post-training.mjs.map +0 -1
- package/resources/synthetic-data-generation.d.ts +0 -47
- package/resources/synthetic-data-generation.d.ts.map +0 -1
- package/resources/synthetic-data-generation.js +0 -20
- package/resources/synthetic-data-generation.js.map +0 -1
- package/resources/synthetic-data-generation.mjs +0 -15
- package/resources/synthetic-data-generation.mjs.map +0 -1
- package/resources/telemetry.d.ts +0 -519
- package/resources/telemetry.d.ts.map +0 -1
- package/resources/telemetry.js +0 -70
- package/resources/telemetry.js.map +0 -1
- package/resources/telemetry.mjs +0 -65
- package/resources/telemetry.mjs.map +0 -1
- package/resources/tool-runtime/index.d.ts +0 -3
- package/resources/tool-runtime/index.d.ts.map +0 -1
- package/resources/tool-runtime/index.js +0 -14
- package/resources/tool-runtime/index.js.map +0 -1
- package/resources/tool-runtime/index.mjs +0 -8
- package/resources/tool-runtime/index.mjs.map +0 -1
- package/resources/tool-runtime/rag-tool.d.ts +0 -45
- package/resources/tool-runtime/rag-tool.d.ts.map +0 -1
- package/resources/tool-runtime/rag-tool.js +0 -30
- package/resources/tool-runtime/rag-tool.js.map +0 -1
- package/resources/tool-runtime/rag-tool.mjs +0 -25
- package/resources/tool-runtime/rag-tool.mjs.map +0 -1
- package/resources/tool-runtime/tool-runtime.d.ts +0 -132
- package/resources/tool-runtime/tool-runtime.d.ts.map +0 -1
- package/resources/tool-runtime/tool-runtime.js.map +0 -1
- package/resources/tool-runtime/tool-runtime.mjs +0 -29
- package/resources/tool-runtime/tool-runtime.mjs.map +0 -1
- package/resources/vector-dbs.d.ts +0 -128
- package/resources/vector-dbs.d.ts.map +0 -1
- package/resources/vector-dbs.js +0 -41
- package/resources/vector-dbs.js.map +0 -1
- package/resources/vector-dbs.mjs +0 -36
- package/resources/vector-dbs.mjs.map +0 -1
- package/src/resources/agents/agents.ts +0 -372
- package/src/resources/agents/index.ts +0 -44
- package/src/resources/agents/session.ts +0 -169
- package/src/resources/agents/steps.ts +0 -47
- package/src/resources/agents/turn.ts +0 -638
- package/src/resources/inference.ts +0 -768
- package/src/resources/post-training/job.ts +0 -274
- package/src/resources/post-training/post-training.ts +0 -516
- package/src/resources/synthetic-data-generation.ts +0 -65
- package/src/resources/telemetry.ts +0 -692
- package/src/resources/tool-runtime/index.ts +0 -17
- package/src/resources/tool-runtime/rag-tool.ts +0 -69
- package/src/resources/tool-runtime/tool-runtime.ts +0 -191
- package/src/resources/vector-dbs.ts +0 -191
- /package/resources/{eval.d.ts → alpha/eval.d.ts} +0 -0
- /package/resources/{eval.mjs → alpha/eval.mjs} +0 -0
- /package/resources/{post-training → alpha/post-training}/index.d.ts +0 -0
- /package/resources/{post-training.d.ts → alpha/post-training.d.ts} +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/resources/vector-stores/index.ts"],"names":[],"mappings":";AAAA,qDAAqD;AACrD,uBAAuB;AACvB,EAAE;AACF,gFAAgF;AAChF,0CAA0C
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/resources/vector-stores/index.ts"],"names":[],"mappings":";AAAA,qDAAqD;AACrD,uBAAuB;AACvB,EAAE;AACF,gFAAgF;AAChF,0CAA0C;AAC1C,EAAE;AACF,sFAAsF;;;AAEtF,kDAMwB;AALtB,2GAAA,WAAW,OAAA;AAMb,oCAUiB;AATf,yHAAA,gCAAgC,OAAA;AAChC,8FAAA,KAAK,OAAA;AASP,oDAWyB;AAVvB,6HAAA,4BAA4B,OAAA;AAC5B,6GAAA,YAAY,OAAA"}
|
|
@@ -3,6 +3,9 @@
|
|
|
3
3
|
//
|
|
4
4
|
// This source code is licensed under the terms described in the LICENSE file in
|
|
5
5
|
// the root directory of this source tree.
|
|
6
|
+
//
|
|
7
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
8
|
+
export { FileBatches, } from "./file-batches.mjs";
|
|
6
9
|
export { VectorStoreFilesOpenAICursorPage, Files, } from "./files.mjs";
|
|
7
10
|
export { VectorStoresOpenAICursorPage, VectorStores, } from "./vector-stores.mjs";
|
|
8
11
|
//# sourceMappingURL=index.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs","sourceRoot":"","sources":["../../src/resources/vector-stores/index.ts"],"names":[],"mappings":"AAAA,qDAAqD;AACrD,uBAAuB;AACvB,EAAE;AACF,gFAAgF;AAChF,0CAA0C;
|
|
1
|
+
{"version":3,"file":"index.mjs","sourceRoot":"","sources":["../../src/resources/vector-stores/index.ts"],"names":[],"mappings":"AAAA,qDAAqD;AACrD,uBAAuB;AACvB,EAAE;AACF,gFAAgF;AAChF,0CAA0C;AAC1C,EAAE;AACF,sFAAsF;OAE/E,EACL,WAAW,GAKZ;OACM,EACL,gCAAgC,EAChC,KAAK,GAQN;OACM,EACL,4BAA4B,EAC5B,YAAY,GASb"}
|
|
@@ -1,12 +1,17 @@
|
|
|
1
1
|
import { APIResource } from "../../resource.js";
|
|
2
2
|
import * as Core from "../../core.js";
|
|
3
|
+
import * as FileBatchesAPI from "./file-batches.js";
|
|
4
|
+
import { FileBatchCreateParams, FileBatchListFilesParams, FileBatches, ListVectorStoreFilesInBatchResponse, VectorStoreFileBatches } from "./file-batches.js";
|
|
3
5
|
import * as FilesAPI from "./files.js";
|
|
4
|
-
import { FileContentResponse, FileCreateParams, FileDeleteResponse, FileListParams, FileUpdateParams, Files, VectorStoreFile, VectorStoreFilesOpenAICursorPage } from "./files.js";
|
|
6
|
+
import { FileContentParams, FileContentResponse, FileCreateParams, FileDeleteResponse, FileListParams, FileUpdateParams, Files, VectorStoreFile, VectorStoreFilesOpenAICursorPage } from "./files.js";
|
|
5
7
|
import { OpenAICursorPage, type OpenAICursorPageParams } from "../../pagination.js";
|
|
6
8
|
export declare class VectorStores extends APIResource {
|
|
7
9
|
files: FilesAPI.Files;
|
|
10
|
+
fileBatches: FileBatchesAPI.FileBatches;
|
|
8
11
|
/**
|
|
9
12
|
* Creates a vector store.
|
|
13
|
+
*
|
|
14
|
+
* Generate an OpenAI-compatible vector store with the given parameters.
|
|
10
15
|
*/
|
|
11
16
|
create(body: VectorStoreCreateParams, options?: Core.RequestOptions): Core.APIPromise<VectorStore>;
|
|
12
17
|
/**
|
|
@@ -27,8 +32,10 @@ export declare class VectorStores extends APIResource {
|
|
|
27
32
|
*/
|
|
28
33
|
delete(vectorStoreId: string, options?: Core.RequestOptions): Core.APIPromise<VectorStoreDeleteResponse>;
|
|
29
34
|
/**
|
|
30
|
-
* Search for chunks in a vector store.
|
|
31
|
-
*
|
|
35
|
+
* Search for chunks in a vector store.
|
|
36
|
+
*
|
|
37
|
+
* Searches a vector store for relevant chunks based on a query and optional file
|
|
38
|
+
* attribute filters.
|
|
32
39
|
*/
|
|
33
40
|
search(vectorStoreId: string, body: VectorStoreSearchParams, options?: Core.RequestOptions): Core.APIPromise<VectorStoreSearchResponse>;
|
|
34
41
|
}
|
|
@@ -38,104 +45,44 @@ export declare class VectorStoresOpenAICursorPage extends OpenAICursorPage<Vecto
|
|
|
38
45
|
* Response from listing vector stores.
|
|
39
46
|
*/
|
|
40
47
|
export interface ListVectorStoresResponse {
|
|
41
|
-
/**
|
|
42
|
-
* List of vector store objects
|
|
43
|
-
*/
|
|
44
48
|
data: Array<VectorStore>;
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
/**
|
|
50
|
-
* Object type identifier, always "list"
|
|
51
|
-
*/
|
|
52
|
-
object: string;
|
|
53
|
-
/**
|
|
54
|
-
* (Optional) ID of the first vector store in the list for pagination
|
|
55
|
-
*/
|
|
56
|
-
first_id?: string;
|
|
57
|
-
/**
|
|
58
|
-
* (Optional) ID of the last vector store in the list for pagination
|
|
59
|
-
*/
|
|
60
|
-
last_id?: string;
|
|
49
|
+
first_id?: string | null;
|
|
50
|
+
has_more?: boolean;
|
|
51
|
+
last_id?: string | null;
|
|
52
|
+
object?: string;
|
|
61
53
|
}
|
|
62
54
|
/**
|
|
63
55
|
* OpenAI Vector Store object.
|
|
64
56
|
*/
|
|
65
57
|
export interface VectorStore {
|
|
66
|
-
/**
|
|
67
|
-
* Unique identifier for the vector store
|
|
68
|
-
*/
|
|
69
58
|
id: string;
|
|
70
|
-
/**
|
|
71
|
-
* Timestamp when the vector store was created
|
|
72
|
-
*/
|
|
73
59
|
created_at: number;
|
|
74
60
|
/**
|
|
75
|
-
* File processing status counts for
|
|
61
|
+
* File processing status counts for a vector store.
|
|
76
62
|
*/
|
|
77
63
|
file_counts: VectorStore.FileCounts;
|
|
78
|
-
/**
|
|
79
|
-
* Set of key-value pairs that can be attached to the vector store
|
|
80
|
-
*/
|
|
81
|
-
metadata: {
|
|
82
|
-
[key: string]: boolean | number | string | Array<unknown> | unknown | null;
|
|
83
|
-
};
|
|
84
|
-
/**
|
|
85
|
-
* Object type identifier, always "vector_store"
|
|
86
|
-
*/
|
|
87
|
-
object: string;
|
|
88
|
-
/**
|
|
89
|
-
* Current status of the vector store
|
|
90
|
-
*/
|
|
91
|
-
status: string;
|
|
92
|
-
/**
|
|
93
|
-
* Storage space used by the vector store in bytes
|
|
94
|
-
*/
|
|
95
|
-
usage_bytes: number;
|
|
96
|
-
/**
|
|
97
|
-
* (Optional) Expiration policy for the vector store
|
|
98
|
-
*/
|
|
99
64
|
expires_after?: {
|
|
100
|
-
[key: string]:
|
|
65
|
+
[key: string]: unknown;
|
|
66
|
+
} | null;
|
|
67
|
+
expires_at?: number | null;
|
|
68
|
+
last_active_at?: number | null;
|
|
69
|
+
metadata?: {
|
|
70
|
+
[key: string]: unknown;
|
|
101
71
|
};
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
/**
|
|
107
|
-
* (Optional) Timestamp of last activity on the vector store
|
|
108
|
-
*/
|
|
109
|
-
last_active_at?: number;
|
|
110
|
-
/**
|
|
111
|
-
* (Optional) Name of the vector store
|
|
112
|
-
*/
|
|
113
|
-
name?: string;
|
|
72
|
+
name?: string | null;
|
|
73
|
+
object?: string;
|
|
74
|
+
status?: string;
|
|
75
|
+
usage_bytes?: number;
|
|
114
76
|
}
|
|
115
77
|
export declare namespace VectorStore {
|
|
116
78
|
/**
|
|
117
|
-
* File processing status counts for
|
|
79
|
+
* File processing status counts for a vector store.
|
|
118
80
|
*/
|
|
119
81
|
interface FileCounts {
|
|
120
|
-
/**
|
|
121
|
-
* Number of files that had their processing cancelled
|
|
122
|
-
*/
|
|
123
82
|
cancelled: number;
|
|
124
|
-
/**
|
|
125
|
-
* Number of files that have been successfully processed
|
|
126
|
-
*/
|
|
127
83
|
completed: number;
|
|
128
|
-
/**
|
|
129
|
-
* Number of files that failed to process
|
|
130
|
-
*/
|
|
131
84
|
failed: number;
|
|
132
|
-
/**
|
|
133
|
-
* Number of files currently being processed
|
|
134
|
-
*/
|
|
135
85
|
in_progress: number;
|
|
136
|
-
/**
|
|
137
|
-
* Total number of files in the vector store
|
|
138
|
-
*/
|
|
139
86
|
total: number;
|
|
140
87
|
}
|
|
141
88
|
}
|
|
@@ -143,205 +90,159 @@ export declare namespace VectorStore {
|
|
|
143
90
|
* Response from deleting a vector store.
|
|
144
91
|
*/
|
|
145
92
|
export interface VectorStoreDeleteResponse {
|
|
146
|
-
/**
|
|
147
|
-
* Unique identifier of the deleted vector store
|
|
148
|
-
*/
|
|
149
93
|
id: string;
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
*/
|
|
153
|
-
deleted: boolean;
|
|
154
|
-
/**
|
|
155
|
-
* Object type identifier for the deletion response
|
|
156
|
-
*/
|
|
157
|
-
object: string;
|
|
94
|
+
deleted?: boolean;
|
|
95
|
+
object?: string;
|
|
158
96
|
}
|
|
159
97
|
/**
|
|
160
98
|
* Paginated response from searching a vector store.
|
|
161
99
|
*/
|
|
162
100
|
export interface VectorStoreSearchResponse {
|
|
163
|
-
/**
|
|
164
|
-
* List of search result objects
|
|
165
|
-
*/
|
|
166
101
|
data: Array<VectorStoreSearchResponse.Data>;
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
/**
|
|
172
|
-
* Object type identifier for the search results page
|
|
173
|
-
*/
|
|
174
|
-
object: string;
|
|
175
|
-
/**
|
|
176
|
-
* The original search query that was executed
|
|
177
|
-
*/
|
|
178
|
-
search_query: string;
|
|
179
|
-
/**
|
|
180
|
-
* (Optional) Token for retrieving the next page of results
|
|
181
|
-
*/
|
|
182
|
-
next_page?: string;
|
|
102
|
+
search_query: Array<string>;
|
|
103
|
+
has_more?: boolean;
|
|
104
|
+
next_page?: string | null;
|
|
105
|
+
object?: string;
|
|
183
106
|
}
|
|
184
107
|
export declare namespace VectorStoreSearchResponse {
|
|
185
108
|
/**
|
|
186
109
|
* Response from searching a vector store.
|
|
187
110
|
*/
|
|
188
111
|
interface Data {
|
|
189
|
-
/**
|
|
190
|
-
* List of content items matching the search query
|
|
191
|
-
*/
|
|
192
112
|
content: Array<Data.Content>;
|
|
193
|
-
/**
|
|
194
|
-
* Unique identifier of the file containing the result
|
|
195
|
-
*/
|
|
196
113
|
file_id: string;
|
|
197
|
-
/**
|
|
198
|
-
* Name of the file containing the result
|
|
199
|
-
*/
|
|
200
114
|
filename: string;
|
|
201
|
-
/**
|
|
202
|
-
* Relevance score for this search result
|
|
203
|
-
*/
|
|
204
115
|
score: number;
|
|
205
|
-
/**
|
|
206
|
-
* (Optional) Key-value attributes associated with the file
|
|
207
|
-
*/
|
|
208
116
|
attributes?: {
|
|
209
117
|
[key: string]: string | number | boolean;
|
|
210
|
-
};
|
|
118
|
+
} | null;
|
|
211
119
|
}
|
|
212
120
|
namespace Data {
|
|
213
121
|
/**
|
|
214
122
|
* Content item from a vector store file or search result.
|
|
215
123
|
*/
|
|
216
124
|
interface Content {
|
|
125
|
+
text: string;
|
|
126
|
+
type: 'text';
|
|
217
127
|
/**
|
|
218
|
-
*
|
|
128
|
+
* `ChunkMetadata` is backend metadata for a `Chunk` that is used to store
|
|
129
|
+
* additional information about the chunk that will not be used in the context
|
|
130
|
+
* during inference, but is required for backend functionality. The `ChunkMetadata`
|
|
131
|
+
* is set during chunk creation in `MemoryToolRuntimeImpl().insert()`and is not
|
|
132
|
+
* expected to change after. Use `Chunk.metadata` for metadata that will be used in
|
|
133
|
+
* the context during inference.
|
|
219
134
|
*/
|
|
220
|
-
|
|
135
|
+
chunk_metadata?: Content.ChunkMetadata | null;
|
|
136
|
+
embedding?: Array<number> | null;
|
|
137
|
+
metadata?: {
|
|
138
|
+
[key: string]: unknown;
|
|
139
|
+
} | null;
|
|
140
|
+
}
|
|
141
|
+
namespace Content {
|
|
221
142
|
/**
|
|
222
|
-
*
|
|
143
|
+
* `ChunkMetadata` is backend metadata for a `Chunk` that is used to store
|
|
144
|
+
* additional information about the chunk that will not be used in the context
|
|
145
|
+
* during inference, but is required for backend functionality. The `ChunkMetadata`
|
|
146
|
+
* is set during chunk creation in `MemoryToolRuntimeImpl().insert()`and is not
|
|
147
|
+
* expected to change after. Use `Chunk.metadata` for metadata that will be used in
|
|
148
|
+
* the context during inference.
|
|
223
149
|
*/
|
|
224
|
-
|
|
150
|
+
interface ChunkMetadata {
|
|
151
|
+
chunk_embedding_dimension?: number | null;
|
|
152
|
+
chunk_embedding_model?: string | null;
|
|
153
|
+
chunk_id?: string | null;
|
|
154
|
+
chunk_tokenizer?: string | null;
|
|
155
|
+
chunk_window?: string | null;
|
|
156
|
+
content_token_count?: number | null;
|
|
157
|
+
created_timestamp?: number | null;
|
|
158
|
+
document_id?: string | null;
|
|
159
|
+
metadata_token_count?: number | null;
|
|
160
|
+
source?: string | null;
|
|
161
|
+
updated_timestamp?: number | null;
|
|
162
|
+
}
|
|
225
163
|
}
|
|
226
164
|
}
|
|
227
165
|
}
|
|
228
166
|
export interface VectorStoreCreateParams {
|
|
229
167
|
/**
|
|
230
|
-
*
|
|
231
|
-
* strategy.
|
|
232
|
-
*/
|
|
233
|
-
chunking_strategy?: {
|
|
234
|
-
[key: string]: boolean | number | string | Array<unknown> | unknown | null;
|
|
235
|
-
};
|
|
236
|
-
/**
|
|
237
|
-
* The dimension of the embedding vectors (default: 384).
|
|
238
|
-
*/
|
|
239
|
-
embedding_dimension?: number;
|
|
240
|
-
/**
|
|
241
|
-
* The embedding model to use for this vector store.
|
|
242
|
-
*/
|
|
243
|
-
embedding_model?: string;
|
|
244
|
-
/**
|
|
245
|
-
* The expiration policy for a vector store.
|
|
168
|
+
* Automatic chunking strategy for vector store files.
|
|
246
169
|
*/
|
|
170
|
+
chunking_strategy?: VectorStoreCreateParams.VectorStoreChunkingStrategyAuto | VectorStoreCreateParams.VectorStoreChunkingStrategyStatic | null;
|
|
247
171
|
expires_after?: {
|
|
248
|
-
[key: string]:
|
|
249
|
-
};
|
|
250
|
-
|
|
251
|
-
* A list of File IDs that the vector store should use. Useful for tools like
|
|
252
|
-
* `file_search` that can access files.
|
|
253
|
-
*/
|
|
254
|
-
file_ids?: Array<string>;
|
|
255
|
-
/**
|
|
256
|
-
* Set of 16 key-value pairs that can be attached to an object.
|
|
257
|
-
*/
|
|
172
|
+
[key: string]: unknown;
|
|
173
|
+
} | null;
|
|
174
|
+
file_ids?: Array<string> | null;
|
|
258
175
|
metadata?: {
|
|
259
|
-
[key: string]:
|
|
260
|
-
};
|
|
176
|
+
[key: string]: unknown;
|
|
177
|
+
} | null;
|
|
178
|
+
name?: string | null;
|
|
179
|
+
[k: string]: unknown;
|
|
180
|
+
}
|
|
181
|
+
export declare namespace VectorStoreCreateParams {
|
|
261
182
|
/**
|
|
262
|
-
*
|
|
183
|
+
* Automatic chunking strategy for vector store files.
|
|
263
184
|
*/
|
|
264
|
-
|
|
185
|
+
interface VectorStoreChunkingStrategyAuto {
|
|
186
|
+
type?: 'auto';
|
|
187
|
+
}
|
|
265
188
|
/**
|
|
266
|
-
*
|
|
189
|
+
* Static chunking strategy with configurable parameters.
|
|
267
190
|
*/
|
|
268
|
-
|
|
191
|
+
interface VectorStoreChunkingStrategyStatic {
|
|
192
|
+
/**
|
|
193
|
+
* Configuration for static chunking strategy.
|
|
194
|
+
*/
|
|
195
|
+
static: VectorStoreChunkingStrategyStatic.Static;
|
|
196
|
+
type?: 'static';
|
|
197
|
+
}
|
|
198
|
+
namespace VectorStoreChunkingStrategyStatic {
|
|
199
|
+
/**
|
|
200
|
+
* Configuration for static chunking strategy.
|
|
201
|
+
*/
|
|
202
|
+
interface Static {
|
|
203
|
+
chunk_overlap_tokens?: number;
|
|
204
|
+
max_chunk_size_tokens?: number;
|
|
205
|
+
}
|
|
206
|
+
}
|
|
269
207
|
}
|
|
270
208
|
export interface VectorStoreUpdateParams {
|
|
271
|
-
/**
|
|
272
|
-
* The expiration policy for a vector store.
|
|
273
|
-
*/
|
|
274
209
|
expires_after?: {
|
|
275
|
-
[key: string]:
|
|
276
|
-
};
|
|
277
|
-
/**
|
|
278
|
-
* Set of 16 key-value pairs that can be attached to an object.
|
|
279
|
-
*/
|
|
210
|
+
[key: string]: unknown;
|
|
211
|
+
} | null;
|
|
280
212
|
metadata?: {
|
|
281
|
-
[key: string]:
|
|
282
|
-
};
|
|
283
|
-
|
|
284
|
-
* The name of the vector store.
|
|
285
|
-
*/
|
|
286
|
-
name?: string;
|
|
213
|
+
[key: string]: unknown;
|
|
214
|
+
} | null;
|
|
215
|
+
name?: string | null;
|
|
287
216
|
}
|
|
288
217
|
export interface VectorStoreListParams extends OpenAICursorPageParams {
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
* in the list.
|
|
292
|
-
*/
|
|
293
|
-
before?: string;
|
|
294
|
-
/**
|
|
295
|
-
* Sort order by the `created_at` timestamp of the objects. `asc` for ascending
|
|
296
|
-
* order and `desc` for descending order.
|
|
297
|
-
*/
|
|
298
|
-
order?: string;
|
|
218
|
+
before?: string | null;
|
|
219
|
+
order?: string | null;
|
|
299
220
|
}
|
|
300
221
|
export interface VectorStoreSearchParams {
|
|
301
|
-
/**
|
|
302
|
-
* The query string or array for performing the search.
|
|
303
|
-
*/
|
|
304
222
|
query: string | Array<string>;
|
|
305
|
-
/**
|
|
306
|
-
* Filters based on file attributes to narrow the search results.
|
|
307
|
-
*/
|
|
308
223
|
filters?: {
|
|
309
|
-
[key: string]:
|
|
310
|
-
};
|
|
311
|
-
|
|
312
|
-
* Maximum number of results to return (1 to 50 inclusive, default 10).
|
|
313
|
-
*/
|
|
314
|
-
max_num_results?: number;
|
|
224
|
+
[key: string]: unknown;
|
|
225
|
+
} | null;
|
|
226
|
+
max_num_results?: number | null;
|
|
315
227
|
/**
|
|
316
|
-
*
|
|
228
|
+
* Options for ranking and filtering search results.
|
|
317
229
|
*/
|
|
318
|
-
ranking_options?: VectorStoreSearchParams.RankingOptions;
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
*/
|
|
322
|
-
rewrite_query?: boolean;
|
|
323
|
-
/**
|
|
324
|
-
* The search mode to use - "keyword", "vector", or "hybrid" (default "vector")
|
|
325
|
-
*/
|
|
326
|
-
search_mode?: string;
|
|
230
|
+
ranking_options?: VectorStoreSearchParams.RankingOptions | null;
|
|
231
|
+
rewrite_query?: boolean | null;
|
|
232
|
+
search_mode?: string | null;
|
|
327
233
|
}
|
|
328
234
|
export declare namespace VectorStoreSearchParams {
|
|
329
235
|
/**
|
|
330
|
-
*
|
|
236
|
+
* Options for ranking and filtering search results.
|
|
331
237
|
*/
|
|
332
238
|
interface RankingOptions {
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
*/
|
|
336
|
-
ranker?: string;
|
|
337
|
-
/**
|
|
338
|
-
* (Optional) Minimum relevance score threshold for results
|
|
339
|
-
*/
|
|
340
|
-
score_threshold?: number;
|
|
239
|
+
ranker?: string | null;
|
|
240
|
+
score_threshold?: number | null;
|
|
341
241
|
}
|
|
342
242
|
}
|
|
343
243
|
export declare namespace VectorStores {
|
|
344
244
|
export { type ListVectorStoresResponse as ListVectorStoresResponse, type VectorStore as VectorStore, type VectorStoreDeleteResponse as VectorStoreDeleteResponse, type VectorStoreSearchResponse as VectorStoreSearchResponse, VectorStoresOpenAICursorPage as VectorStoresOpenAICursorPage, type VectorStoreCreateParams as VectorStoreCreateParams, type VectorStoreUpdateParams as VectorStoreUpdateParams, type VectorStoreListParams as VectorStoreListParams, type VectorStoreSearchParams as VectorStoreSearchParams, };
|
|
345
|
-
export { Files as Files, type VectorStoreFile as VectorStoreFile, type FileDeleteResponse as FileDeleteResponse, type FileContentResponse as FileContentResponse, VectorStoreFilesOpenAICursorPage as VectorStoreFilesOpenAICursorPage, type FileCreateParams as FileCreateParams, type FileUpdateParams as FileUpdateParams, type FileListParams as FileListParams, };
|
|
245
|
+
export { Files as Files, type VectorStoreFile as VectorStoreFile, type FileDeleteResponse as FileDeleteResponse, type FileContentResponse as FileContentResponse, VectorStoreFilesOpenAICursorPage as VectorStoreFilesOpenAICursorPage, type FileCreateParams as FileCreateParams, type FileUpdateParams as FileUpdateParams, type FileListParams as FileListParams, type FileContentParams as FileContentParams, };
|
|
246
|
+
export { FileBatches as FileBatches, type ListVectorStoreFilesInBatchResponse as ListVectorStoreFilesInBatchResponse, type VectorStoreFileBatches as VectorStoreFileBatches, type FileBatchCreateParams as FileBatchCreateParams, type FileBatchListFilesParams as FileBatchListFilesParams, };
|
|
346
247
|
}
|
|
347
248
|
//# sourceMappingURL=vector-stores.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"vector-stores.d.ts","sourceRoot":"","sources":["../../src/resources/vector-stores/vector-stores.ts"],"names":[],"mappings":"AAQA,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAE7C,OAAO,KAAK,IAAI,MAAM,YAAY,CAAC;AACnC,OAAO,KAAK,QAAQ,MAAM,SAAS,CAAC;AACpC,OAAO,EACL,mBAAmB,EACnB,gBAAgB,EAChB,kBAAkB,EAClB,cAAc,EACd,gBAAgB,EAChB,KAAK,EACL,eAAe,EACf,gCAAgC,EACjC,MAAM,SAAS,CAAC;AACjB,OAAO,EAAE,gBAAgB,EAAE,KAAK,sBAAsB,EAAE,MAAM,kBAAkB,CAAC;AAEjF,qBAAa,YAAa,SAAQ,WAAW;IAC3C,KAAK,EAAE,QAAQ,CAAC,KAAK,CAAoC;
|
|
1
|
+
{"version":3,"file":"vector-stores.d.ts","sourceRoot":"","sources":["../../src/resources/vector-stores/vector-stores.ts"],"names":[],"mappings":"AAQA,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAE7C,OAAO,KAAK,IAAI,MAAM,YAAY,CAAC;AACnC,OAAO,KAAK,cAAc,MAAM,gBAAgB,CAAC;AACjD,OAAO,EACL,qBAAqB,EACrB,wBAAwB,EACxB,WAAW,EACX,mCAAmC,EACnC,sBAAsB,EACvB,MAAM,gBAAgB,CAAC;AACxB,OAAO,KAAK,QAAQ,MAAM,SAAS,CAAC;AACpC,OAAO,EACL,iBAAiB,EACjB,mBAAmB,EACnB,gBAAgB,EAChB,kBAAkB,EAClB,cAAc,EACd,gBAAgB,EAChB,KAAK,EACL,eAAe,EACf,gCAAgC,EACjC,MAAM,SAAS,CAAC;AACjB,OAAO,EAAE,gBAAgB,EAAE,KAAK,sBAAsB,EAAE,MAAM,kBAAkB,CAAC;AAEjF,qBAAa,YAAa,SAAQ,WAAW;IAC3C,KAAK,EAAE,QAAQ,CAAC,KAAK,CAAoC;IACzD,WAAW,EAAE,cAAc,CAAC,WAAW,CAAgD;IAEvF;;;;OAIG;IACH,MAAM,CAAC,IAAI,EAAE,uBAAuB,EAAE,OAAO,CAAC,EAAE,IAAI,CAAC,cAAc,GAAG,IAAI,CAAC,UAAU,CAAC,WAAW,CAAC;IAIlG;;OAEG;IACH,QAA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AAmB,IAAI,mBAAmB,EAC/C,gCAAgC,IAAI,gCAAgC,EACpE,KAAK,gBAAgB,IAAI,gBAAgB,EACzC,KAAK,gBAAgB,IAAI,gBAAgB,EACzC,KAAK,cAAc,IAAI,cAAc,EACrC,KAAK,iBAAiB,IAAI,iBAAiB,GAC5C,CAAC;IAEF,OAAO,EACL,WAAW,IAAI,WAAW,EAC1B,KAAK,mCAAmC,IAAI,mCAAmC,EAC/E,KAAK,sBAAsB,IAAI,sBAAsB,EACrD,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,wBAAwB,IAAI,wBAAwB,GAC1D,CAAC;CACH"}
|
|
@@ -4,6 +4,8 @@
|
|
|
4
4
|
//
|
|
5
5
|
// This source code is licensed under the terms described in the LICENSE file in
|
|
6
6
|
// the root directory of this source tree.
|
|
7
|
+
//
|
|
8
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
7
9
|
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
8
10
|
if (k2 === undefined) k2 = k;
|
|
9
11
|
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
@@ -29,9 +31,10 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
29
31
|
};
|
|
30
32
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
31
33
|
exports.VectorStoresOpenAICursorPage = exports.VectorStores = void 0;
|
|
32
|
-
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
33
34
|
const resource_1 = require("../../resource.js");
|
|
34
35
|
const core_1 = require("../../core.js");
|
|
36
|
+
const FileBatchesAPI = __importStar(require("./file-batches.js"));
|
|
37
|
+
const file_batches_1 = require("./file-batches.js");
|
|
35
38
|
const FilesAPI = __importStar(require("./files.js"));
|
|
36
39
|
const files_1 = require("./files.js");
|
|
37
40
|
const pagination_1 = require("../../pagination.js");
|
|
@@ -39,46 +42,48 @@ class VectorStores extends resource_1.APIResource {
|
|
|
39
42
|
constructor() {
|
|
40
43
|
super(...arguments);
|
|
41
44
|
this.files = new FilesAPI.Files(this._client);
|
|
45
|
+
this.fileBatches = new FileBatchesAPI.FileBatches(this._client);
|
|
42
46
|
}
|
|
43
47
|
/**
|
|
44
48
|
* Creates a vector store.
|
|
49
|
+
*
|
|
50
|
+
* Generate an OpenAI-compatible vector store with the given parameters.
|
|
45
51
|
*/
|
|
46
52
|
create(body, options) {
|
|
47
|
-
return this._client.post('/v1/
|
|
53
|
+
return this._client.post('/v1/vector_stores', { body, ...options });
|
|
48
54
|
}
|
|
49
55
|
/**
|
|
50
56
|
* Retrieves a vector store.
|
|
51
57
|
*/
|
|
52
58
|
retrieve(vectorStoreId, options) {
|
|
53
|
-
return this._client.get(`/v1/
|
|
59
|
+
return this._client.get(`/v1/vector_stores/${vectorStoreId}`, options);
|
|
54
60
|
}
|
|
55
61
|
/**
|
|
56
62
|
* Updates a vector store.
|
|
57
63
|
*/
|
|
58
64
|
update(vectorStoreId, body, options) {
|
|
59
|
-
return this._client.post(`/v1/
|
|
65
|
+
return this._client.post(`/v1/vector_stores/${vectorStoreId}`, { body, ...options });
|
|
60
66
|
}
|
|
61
67
|
list(query = {}, options) {
|
|
62
68
|
if ((0, core_1.isRequestOptions)(query)) {
|
|
63
69
|
return this.list({}, query);
|
|
64
70
|
}
|
|
65
|
-
return this._client.getAPIList('/v1/
|
|
66
|
-
query,
|
|
67
|
-
...options,
|
|
68
|
-
});
|
|
71
|
+
return this._client.getAPIList('/v1/vector_stores', VectorStoresOpenAICursorPage, { query, ...options });
|
|
69
72
|
}
|
|
70
73
|
/**
|
|
71
74
|
* Delete a vector store.
|
|
72
75
|
*/
|
|
73
76
|
delete(vectorStoreId, options) {
|
|
74
|
-
return this._client.delete(`/v1/
|
|
77
|
+
return this._client.delete(`/v1/vector_stores/${vectorStoreId}`, options);
|
|
75
78
|
}
|
|
76
79
|
/**
|
|
77
|
-
* Search for chunks in a vector store.
|
|
78
|
-
*
|
|
80
|
+
* Search for chunks in a vector store.
|
|
81
|
+
*
|
|
82
|
+
* Searches a vector store for relevant chunks based on a query and optional file
|
|
83
|
+
* attribute filters.
|
|
79
84
|
*/
|
|
80
85
|
search(vectorStoreId, body, options) {
|
|
81
|
-
return this._client.post(`/v1/
|
|
86
|
+
return this._client.post(`/v1/vector_stores/${vectorStoreId}/search`, { body, ...options });
|
|
82
87
|
}
|
|
83
88
|
}
|
|
84
89
|
exports.VectorStores = VectorStores;
|
|
@@ -88,4 +93,5 @@ exports.VectorStoresOpenAICursorPage = VectorStoresOpenAICursorPage;
|
|
|
88
93
|
VectorStores.VectorStoresOpenAICursorPage = VectorStoresOpenAICursorPage;
|
|
89
94
|
VectorStores.Files = files_1.Files;
|
|
90
95
|
VectorStores.VectorStoreFilesOpenAICursorPage = files_1.VectorStoreFilesOpenAICursorPage;
|
|
96
|
+
VectorStores.FileBatches = file_batches_1.FileBatches;
|
|
91
97
|
//# sourceMappingURL=vector-stores.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"vector-stores.js","sourceRoot":"","sources":["../../src/resources/vector-stores/vector-stores.ts"],"names":[],"mappings":";AAAA,qDAAqD;AACrD,uBAAuB;AACvB,EAAE;AACF,gFAAgF;AAChF,0CAA0C
|
|
1
|
+
{"version":3,"file":"vector-stores.js","sourceRoot":"","sources":["../../src/resources/vector-stores/vector-stores.ts"],"names":[],"mappings":";AAAA,qDAAqD;AACrD,uBAAuB;AACvB,EAAE;AACF,gFAAgF;AAChF,0CAA0C;AAC1C,EAAE;AACF,sFAAsF;;;;;;;;;;;;;;;;;;;;;;;;;;AAEtF,gDAA6C;AAC7C,wCAA8C;AAE9C,kEAAiD;AACjD,oDAMwB;AACxB,qDAAoC;AACpC,sCAUiB;AACjB,oDAAiF;AAEjF,MAAa,YAAa,SAAQ,sBAAW;IAA7C;;QACE,UAAK,GAAmB,IAAI,QAAQ,CAAC,KAAK,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;QACzD,gBAAW,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