llama-stack-client 0.0.35 → 0.1.2
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/LICENSE +22 -201
- package/README.md +60 -26
- package/core.d.ts +7 -7
- package/core.d.ts.map +1 -1
- package/core.js +44 -19
- package/core.js.map +1 -1
- package/core.mjs +41 -17
- package/core.mjs.map +1 -1
- package/error.d.ts +18 -24
- package/error.d.ts.map +1 -1
- package/error.js +1 -31
- package/error.js.map +1 -1
- package/error.mjs +1 -31
- package/error.mjs.map +1 -1
- package/index.d.mts +106 -120
- package/index.d.ts +106 -120
- package/index.d.ts.map +1 -1
- package/index.js +100 -45
- package/index.js.map +1 -1
- package/index.mjs +84 -44
- package/index.mjs.map +1 -1
- package/internal/decoders/jsonl.d.ts +12 -0
- package/internal/decoders/jsonl.d.ts.map +1 -0
- package/internal/decoders/jsonl.js +35 -0
- package/internal/decoders/jsonl.js.map +1 -0
- package/internal/decoders/jsonl.mjs +31 -0
- package/internal/decoders/jsonl.mjs.map +1 -0
- package/internal/decoders/line.d.ts +20 -0
- package/internal/decoders/line.d.ts.map +1 -0
- package/internal/decoders/line.js +88 -0
- package/internal/decoders/line.js.map +1 -0
- package/internal/decoders/line.mjs +84 -0
- package/internal/decoders/line.mjs.map +1 -0
- package/internal/qs/formats.d.ts +6 -0
- package/internal/qs/formats.d.ts.map +1 -0
- package/internal/qs/formats.js +11 -0
- package/internal/qs/formats.js.map +1 -0
- package/internal/qs/formats.mjs +8 -0
- package/internal/qs/formats.mjs.map +1 -0
- package/internal/qs/index.d.ts +10 -0
- package/internal/qs/index.d.ts.map +1 -0
- package/internal/qs/index.js +14 -0
- package/internal/qs/index.js.map +1 -0
- package/internal/qs/index.mjs +10 -0
- package/internal/qs/index.mjs.map +1 -0
- package/internal/qs/stringify.d.ts +3 -0
- package/internal/qs/stringify.d.ts.map +1 -0
- package/internal/qs/stringify.js +280 -0
- package/internal/qs/stringify.js.map +1 -0
- package/internal/qs/stringify.mjs +276 -0
- package/internal/qs/stringify.mjs.map +1 -0
- package/internal/qs/types.d.ts +57 -0
- package/internal/qs/types.d.ts.map +1 -0
- package/internal/qs/types.js +3 -0
- package/internal/qs/types.js.map +1 -0
- package/internal/qs/types.mjs +2 -0
- package/internal/qs/types.mjs.map +1 -0
- package/internal/qs/utils.d.ts +14 -0
- package/internal/qs/utils.d.ts.map +1 -0
- package/internal/qs/utils.js +229 -0
- package/internal/qs/utils.js.map +1 -0
- package/internal/qs/utils.mjs +217 -0
- package/internal/qs/utils.mjs.map +1 -0
- package/internal/stream-utils.d.ts +8 -0
- package/internal/stream-utils.d.ts.map +1 -0
- package/internal/stream-utils.js +39 -0
- package/internal/stream-utils.js.map +1 -0
- package/internal/stream-utils.mjs +35 -0
- package/internal/stream-utils.mjs.map +1 -0
- package/package.json +8 -6
- package/resources/agents/agents.d.ts +31 -187
- package/resources/agents/agents.d.ts.map +1 -1
- package/resources/agents/agents.js +15 -32
- package/resources/agents/agents.js.map +1 -1
- package/resources/agents/agents.mjs +15 -32
- package/resources/agents/agents.mjs.map +1 -1
- package/resources/agents/index.d.ts +4 -4
- package/resources/agents/index.d.ts.map +1 -1
- package/resources/agents/index.js +7 -7
- package/resources/agents/index.js.map +1 -1
- package/resources/agents/index.mjs +3 -3
- package/resources/agents/index.mjs.map +1 -1
- package/resources/agents/session.d.ts +31 -0
- package/resources/agents/session.d.ts.map +1 -0
- package/resources/agents/session.js +25 -0
- package/resources/agents/session.js.map +1 -0
- package/resources/agents/session.mjs +21 -0
- package/resources/agents/session.mjs.map +1 -0
- package/resources/agents/steps.d.ts +3 -24
- package/resources/agents/steps.d.ts.map +1 -1
- package/resources/agents/steps.js +2 -14
- package/resources/agents/steps.js.map +1 -1
- package/resources/agents/steps.mjs +2 -14
- package/resources/agents/steps.mjs.map +1 -1
- package/resources/agents/turn.d.ts +199 -0
- package/resources/agents/turn.d.ts.map +1 -0
- package/resources/agents/turn.js +19 -0
- package/resources/agents/turn.js.map +1 -0
- package/resources/agents/turn.mjs +15 -0
- package/resources/agents/turn.mjs.map +1 -0
- package/resources/batch-inference.d.ts +23 -56
- package/resources/batch-inference.d.ts.map +1 -1
- package/resources/batch-inference.js +4 -26
- package/resources/batch-inference.js.map +1 -1
- package/resources/batch-inference.mjs +4 -26
- package/resources/batch-inference.mjs.map +1 -1
- package/resources/datasetio.d.ts +25 -0
- package/resources/datasetio.d.ts.map +1 -0
- package/resources/datasetio.js +19 -0
- package/resources/datasetio.js.map +1 -0
- package/resources/datasetio.mjs +15 -0
- package/resources/datasetio.mjs.map +1 -0
- package/resources/datasets.d.ts +34 -46
- package/resources/datasets.d.ts.map +1 -1
- package/resources/datasets.js +11 -35
- package/resources/datasets.js.map +1 -1
- package/resources/datasets.mjs +11 -35
- package/resources/datasets.mjs.map +1 -1
- package/resources/eval/eval.d.ts +62 -0
- package/resources/eval/eval.d.ts.map +1 -0
- package/resources/{inference/embeddings.js → eval/eval.js} +16 -20
- package/resources/eval/eval.js.map +1 -0
- package/resources/eval/eval.mjs +18 -0
- package/resources/eval/eval.mjs.map +1 -0
- package/resources/eval/index.d.ts +3 -0
- package/resources/eval/index.d.ts.map +1 -0
- package/resources/eval/index.js +9 -0
- package/resources/eval/index.js.map +1 -0
- package/resources/eval/index.mjs +4 -0
- package/resources/eval/index.mjs.map +1 -0
- package/resources/eval/jobs.d.ts +13 -0
- package/resources/eval/jobs.d.ts.map +1 -0
- package/resources/eval/jobs.js +21 -0
- package/resources/eval/jobs.js.map +1 -0
- package/resources/eval/jobs.mjs +17 -0
- package/resources/eval/jobs.mjs.map +1 -0
- package/resources/eval-tasks.d.ts +32 -0
- package/resources/eval-tasks.d.ts.map +1 -0
- package/resources/eval-tasks.js +22 -0
- package/resources/eval-tasks.js.map +1 -0
- package/resources/eval-tasks.mjs +18 -0
- package/resources/eval-tasks.mjs.map +1 -0
- package/resources/index.d.ts +23 -15
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js +33 -17
- package/resources/index.js.map +1 -1
- package/resources/index.mjs +19 -11
- package/resources/index.mjs.map +1 -1
- package/resources/inference.d.ts +286 -0
- package/resources/inference.d.ts.map +1 -0
- package/resources/inference.js +29 -0
- package/resources/inference.js.map +1 -0
- package/resources/inference.mjs +25 -0
- package/resources/inference.mjs.map +1 -0
- package/resources/inspect.d.ts +26 -0
- package/resources/inspect.d.ts.map +1 -0
- package/resources/inspect.js +15 -0
- package/resources/inspect.js.map +1 -0
- package/resources/inspect.mjs +11 -0
- package/resources/inspect.mjs.map +1 -0
- package/resources/models.d.ts +21 -36
- package/resources/models.d.ts.map +1 -1
- package/resources/models.js +11 -27
- package/resources/models.js.map +1 -1
- package/resources/models.mjs +11 -27
- package/resources/models.mjs.map +1 -1
- package/resources/post-training/index.d.ts +2 -2
- package/resources/post-training/index.d.ts.map +1 -1
- package/resources/post-training/index.js +3 -3
- package/resources/post-training/index.js.map +1 -1
- package/resources/post-training/index.mjs +1 -1
- package/resources/post-training/index.mjs.map +1 -1
- package/resources/post-training/job.d.ts +47 -0
- package/resources/post-training/job.d.ts.map +1 -0
- package/resources/post-training/job.js +25 -0
- package/resources/post-training/job.js.map +1 -0
- package/resources/post-training/job.mjs +21 -0
- package/resources/post-training/job.mjs.map +1 -0
- package/resources/post-training/post-training.d.ts +95 -142
- package/resources/post-training/post-training.d.ts.map +1 -1
- package/resources/post-training/post-training.js +8 -29
- package/resources/post-training/post-training.js.map +1 -1
- package/resources/post-training/post-training.mjs +8 -29
- package/resources/post-training/post-training.mjs.map +1 -1
- package/resources/providers.d.ts +14 -0
- package/resources/providers.d.ts.map +1 -0
- package/resources/providers.js +12 -0
- package/resources/providers.js.map +1 -0
- package/resources/providers.mjs +8 -0
- package/resources/providers.mjs.map +1 -0
- package/resources/routes.d.ts +14 -0
- package/resources/routes.d.ts.map +1 -0
- package/resources/routes.js +12 -0
- package/resources/routes.js.map +1 -0
- package/resources/routes.mjs +8 -0
- package/resources/routes.mjs.map +1 -0
- package/resources/safety.d.ts +6 -29
- package/resources/safety.d.ts.map +1 -1
- package/resources/safety.js +2 -14
- package/resources/safety.js.map +1 -1
- package/resources/safety.mjs +2 -14
- package/resources/safety.mjs.map +1 -1
- package/resources/scoring-functions.d.ts +53 -0
- package/resources/scoring-functions.d.ts.map +1 -0
- package/resources/scoring-functions.js +22 -0
- package/resources/scoring-functions.js.map +1 -0
- package/resources/scoring-functions.mjs +18 -0
- package/resources/scoring-functions.mjs.map +1 -0
- package/resources/scoring.d.ts +28 -0
- package/resources/scoring.d.ts.map +1 -0
- package/resources/scoring.js +15 -0
- package/resources/scoring.js.map +1 -0
- package/resources/scoring.mjs +11 -0
- package/resources/scoring.mjs.map +1 -0
- package/resources/shared.d.ts +406 -14
- package/resources/shared.d.ts.map +1 -1
- package/resources/shields.d.ts +21 -32
- package/resources/shields.d.ts.map +1 -1
- package/resources/shields.js +7 -29
- package/resources/shields.js.map +1 -1
- package/resources/shields.mjs +7 -29
- package/resources/shields.mjs.map +1 -1
- package/resources/synthetic-data-generation.d.ts +12 -22
- package/resources/synthetic-data-generation.d.ts.map +1 -1
- package/resources/synthetic-data-generation.js +5 -17
- package/resources/synthetic-data-generation.js.map +1 -1
- package/resources/synthetic-data-generation.mjs +3 -15
- package/resources/synthetic-data-generation.mjs.map +1 -1
- package/resources/telemetry.d.ts +84 -35
- package/resources/telemetry.d.ts.map +1 -1
- package/resources/telemetry.js +29 -22
- package/resources/telemetry.js.map +1 -1
- package/resources/telemetry.mjs +29 -22
- package/resources/telemetry.mjs.map +1 -1
- package/resources/tool-runtime/index.d.ts +3 -0
- package/resources/tool-runtime/index.d.ts.map +1 -0
- package/resources/tool-runtime/index.js +9 -0
- package/resources/tool-runtime/index.js.map +1 -0
- package/resources/tool-runtime/index.mjs +4 -0
- package/resources/tool-runtime/index.mjs.map +1 -0
- package/resources/tool-runtime/rag-tool.d.ts +30 -0
- package/resources/tool-runtime/rag-tool.d.ts.map +1 -0
- package/resources/tool-runtime/rag-tool.js +25 -0
- package/resources/tool-runtime/rag-tool.js.map +1 -0
- package/resources/tool-runtime/rag-tool.mjs +21 -0
- package/resources/tool-runtime/rag-tool.mjs.map +1 -0
- package/resources/tool-runtime/tool-runtime.d.ts +51 -0
- package/resources/tool-runtime/tool-runtime.d.ts.map +1 -0
- package/resources/{evaluate/evaluate.js → tool-runtime/tool-runtime.js} +29 -18
- package/resources/tool-runtime/tool-runtime.js.map +1 -0
- package/resources/tool-runtime/tool-runtime.mjs +33 -0
- package/resources/tool-runtime/tool-runtime.mjs.map +1 -0
- package/resources/toolgroups.d.ts +40 -0
- package/resources/toolgroups.d.ts.map +1 -0
- package/resources/toolgroups.js +37 -0
- package/resources/toolgroups.js.map +1 -0
- package/resources/toolgroups.mjs +33 -0
- package/resources/toolgroups.mjs.map +1 -0
- package/resources/tools.d.ts +41 -0
- package/resources/tools.d.ts.map +1 -0
- package/resources/tools.js +19 -0
- package/resources/tools.js.map +1 -0
- package/resources/tools.mjs +15 -0
- package/resources/tools.mjs.map +1 -0
- package/resources/vector-dbs.d.ts +49 -0
- package/resources/vector-dbs.d.ts.map +1 -0
- package/resources/vector-dbs.js +24 -0
- package/resources/vector-dbs.js.map +1 -0
- package/resources/vector-dbs.mjs +20 -0
- package/resources/vector-dbs.mjs.map +1 -0
- package/resources/vector-io.d.ts +46 -0
- package/resources/vector-io.d.ts.map +1 -0
- package/resources/vector-io.js +19 -0
- package/resources/vector-io.js.map +1 -0
- package/resources/vector-io.mjs +15 -0
- package/resources/vector-io.mjs.map +1 -0
- package/src/core.ts +57 -27
- package/src/error.ts +25 -41
- package/src/index.ts +457 -153
- package/src/internal/decoders/jsonl.ts +41 -0
- package/src/internal/decoders/line.ts +114 -0
- package/src/internal/qs/LICENSE.md +13 -0
- package/src/internal/qs/README.md +3 -0
- package/src/internal/qs/formats.ts +9 -0
- package/src/internal/qs/index.ts +13 -0
- package/src/internal/qs/stringify.ts +388 -0
- package/src/internal/qs/types.ts +71 -0
- package/src/internal/qs/utils.ts +265 -0
- package/src/internal/stream-utils.ts +32 -0
- package/src/resources/agents/agents.ts +81 -299
- package/src/resources/agents/index.ts +24 -27
- package/src/resources/agents/session.ts +76 -0
- package/src/resources/agents/steps.ts +14 -40
- package/src/resources/agents/turn.ts +322 -0
- package/src/resources/batch-inference.ts +33 -84
- package/src/resources/datasetio.ts +53 -0
- package/src/resources/datasets.ts +70 -82
- package/src/resources/eval/eval.ts +107 -0
- package/src/resources/eval/index.ts +12 -0
- package/src/resources/eval/jobs.ts +36 -0
- package/src/resources/eval-tasks.ts +69 -0
- package/src/resources/index.ts +141 -65
- package/src/resources/inference.ts +395 -0
- package/src/resources/inspect.ts +47 -0
- package/src/resources/models.ts +46 -66
- package/src/resources/post-training/index.ts +14 -14
- package/src/resources/post-training/job.ts +96 -0
- package/src/resources/post-training/post-training.ts +151 -182
- package/src/resources/providers.ts +26 -0
- package/src/resources/routes.ts +23 -0
- package/src/resources/safety.ts +8 -47
- package/src/resources/scoring-functions.ts +108 -0
- package/src/resources/scoring.ts +52 -0
- package/src/resources/shared.ts +530 -14
- package/src/resources/shields.ts +40 -64
- package/src/resources/synthetic-data-generation.ts +17 -37
- package/src/resources/telemetry.ts +211 -65
- package/src/resources/tool-runtime/index.ts +10 -0
- package/src/resources/tool-runtime/rag-tool.ts +48 -0
- package/src/resources/tool-runtime/tool-runtime.ts +109 -0
- package/src/resources/toolgroups.ts +80 -0
- package/src/resources/tools.ts +81 -0
- package/src/resources/vector-dbs.ts +105 -0
- package/src/resources/vector-io.ts +74 -0
- package/src/streaming.ts +6 -148
- package/src/version.ts +1 -1
- package/streaming.d.ts +0 -7
- package/streaming.d.ts.map +1 -1
- package/streaming.js +8 -123
- package/streaming.js.map +1 -1
- package/streaming.mjs +4 -118
- package/streaming.mjs.map +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/sessions.d.ts +0 -76
- package/resources/agents/sessions.d.ts.map +0 -1
- package/resources/agents/sessions.js +0 -52
- package/resources/agents/sessions.js.map +0 -1
- package/resources/agents/sessions.mjs +0 -48
- package/resources/agents/sessions.mjs.map +0 -1
- package/resources/agents/turns.d.ts +0 -133
- package/resources/agents/turns.d.ts.map +0 -1
- package/resources/agents/turns.js +0 -38
- package/resources/agents/turns.js.map +0 -1
- package/resources/agents/turns.mjs +0 -34
- package/resources/agents/turns.mjs.map +0 -1
- package/resources/evaluate/evaluate.d.ts +0 -29
- package/resources/evaluate/evaluate.d.ts.map +0 -1
- package/resources/evaluate/evaluate.js.map +0 -1
- package/resources/evaluate/evaluate.mjs +0 -22
- package/resources/evaluate/evaluate.mjs.map +0 -1
- package/resources/evaluate/index.d.ts +0 -6
- package/resources/evaluate/index.d.ts.map +0 -1
- package/resources/evaluate/index.js +0 -15
- package/resources/evaluate/index.js.map +0 -1
- package/resources/evaluate/index.mjs +0 -7
- package/resources/evaluate/index.mjs.map +0 -1
- package/resources/evaluate/jobs/artifacts.d.ts +0 -22
- package/resources/evaluate/jobs/artifacts.d.ts.map +0 -1
- package/resources/evaluate/jobs/artifacts.js +0 -24
- package/resources/evaluate/jobs/artifacts.js.map +0 -1
- package/resources/evaluate/jobs/artifacts.mjs +0 -20
- package/resources/evaluate/jobs/artifacts.mjs.map +0 -1
- package/resources/evaluate/jobs/index.d.ts +0 -5
- package/resources/evaluate/jobs/index.d.ts.map +0 -1
- package/resources/evaluate/jobs/index.js +0 -13
- package/resources/evaluate/jobs/index.js.map +0 -1
- package/resources/evaluate/jobs/index.mjs +0 -6
- package/resources/evaluate/jobs/index.mjs.map +0 -1
- package/resources/evaluate/jobs/jobs.d.ts +0 -56
- package/resources/evaluate/jobs/jobs.d.ts.map +0 -1
- package/resources/evaluate/jobs/jobs.js +0 -76
- package/resources/evaluate/jobs/jobs.js.map +0 -1
- package/resources/evaluate/jobs/jobs.mjs +0 -49
- package/resources/evaluate/jobs/jobs.mjs.map +0 -1
- package/resources/evaluate/jobs/logs.d.ts +0 -22
- package/resources/evaluate/jobs/logs.d.ts.map +0 -1
- package/resources/evaluate/jobs/logs.js +0 -24
- package/resources/evaluate/jobs/logs.js.map +0 -1
- package/resources/evaluate/jobs/logs.mjs +0 -20
- package/resources/evaluate/jobs/logs.mjs.map +0 -1
- package/resources/evaluate/jobs/status.d.ts +0 -22
- package/resources/evaluate/jobs/status.d.ts.map +0 -1
- package/resources/evaluate/jobs/status.js +0 -24
- package/resources/evaluate/jobs/status.js.map +0 -1
- package/resources/evaluate/jobs/status.mjs +0 -20
- package/resources/evaluate/jobs/status.mjs.map +0 -1
- package/resources/evaluate/question-answering.d.ts +0 -22
- package/resources/evaluate/question-answering.d.ts.map +0 -1
- package/resources/evaluate/question-answering.js +0 -24
- package/resources/evaluate/question-answering.js.map +0 -1
- package/resources/evaluate/question-answering.mjs +0 -20
- package/resources/evaluate/question-answering.mjs.map +0 -1
- package/resources/evaluate/summarization.d.ts +0 -4
- package/resources/evaluate/summarization.d.ts.map +0 -1
- package/resources/evaluate/summarization.js +0 -9
- package/resources/evaluate/summarization.js.map +0 -1
- package/resources/evaluate/summarization.mjs +0 -5
- package/resources/evaluate/summarization.mjs.map +0 -1
- package/resources/evaluate/text-generation.d.ts +0 -4
- package/resources/evaluate/text-generation.d.ts.map +0 -1
- package/resources/evaluate/text-generation.js +0 -9
- package/resources/evaluate/text-generation.js.map +0 -1
- package/resources/evaluate/text-generation.mjs +0 -5
- package/resources/evaluate/text-generation.mjs.map +0 -1
- package/resources/evaluations.d.ts +0 -35
- package/resources/evaluations.d.ts.map +0 -1
- package/resources/evaluations.js +0 -37
- package/resources/evaluations.js.map +0 -1
- package/resources/evaluations.mjs +0 -33
- package/resources/evaluations.mjs.map +0 -1
- package/resources/inference/embeddings.d.ts +0 -29
- package/resources/inference/embeddings.d.ts.map +0 -1
- package/resources/inference/embeddings.js.map +0 -1
- package/resources/inference/embeddings.mjs +0 -22
- package/resources/inference/embeddings.mjs.map +0 -1
- package/resources/inference/index.d.ts +0 -3
- package/resources/inference/index.d.ts.map +0 -1
- package/resources/inference/index.js +0 -9
- package/resources/inference/index.js.map +0 -1
- package/resources/inference/index.mjs +0 -4
- package/resources/inference/index.mjs.map +0 -1
- package/resources/inference/inference.d.ts +0 -172
- package/resources/inference/inference.d.ts.map +0 -1
- package/resources/inference/inference.js +0 -67
- package/resources/inference/inference.js.map +0 -1
- package/resources/inference/inference.mjs +0 -40
- package/resources/inference/inference.mjs.map +0 -1
- package/resources/memory/documents.d.ts +0 -49
- package/resources/memory/documents.d.ts.map +0 -1
- package/resources/memory/documents.js +0 -39
- package/resources/memory/documents.js.map +0 -1
- package/resources/memory/documents.mjs +0 -35
- package/resources/memory/documents.mjs.map +0 -1
- package/resources/memory/index.d.ts +0 -3
- package/resources/memory/index.d.ts.map +0 -1
- package/resources/memory/index.js +0 -9
- package/resources/memory/index.js.map +0 -1
- package/resources/memory/index.mjs +0 -4
- package/resources/memory/index.mjs.map +0 -1
- package/resources/memory/memory.d.ts +0 -158
- package/resources/memory/memory.d.ts.map +0 -1
- package/resources/memory/memory.js +0 -137
- package/resources/memory/memory.js.map +0 -1
- package/resources/memory/memory.mjs +0 -110
- package/resources/memory/memory.mjs.map +0 -1
- package/resources/memory-banks.d.ts +0 -42
- package/resources/memory-banks.d.ts.map +0 -1
- package/resources/memory-banks.js +0 -40
- package/resources/memory-banks.js.map +0 -1
- package/resources/memory-banks.mjs +0 -36
- package/resources/memory-banks.mjs.map +0 -1
- package/resources/post-training/jobs.d.ts +0 -91
- package/resources/post-training/jobs.d.ts.map +0 -1
- package/resources/post-training/jobs.js +0 -80
- package/resources/post-training/jobs.js.map +0 -1
- package/resources/post-training/jobs.mjs +0 -76
- package/resources/post-training/jobs.mjs.map +0 -1
- package/resources/reward-scoring.d.ts +0 -47
- package/resources/reward-scoring.d.ts.map +0 -1
- package/resources/reward-scoring.js +0 -24
- package/resources/reward-scoring.js.map +0 -1
- package/resources/reward-scoring.mjs +0 -20
- package/resources/reward-scoring.mjs.map +0 -1
- package/src/resources/agents/sessions.ts +0 -135
- package/src/resources/agents/turns.ts +0 -231
- package/src/resources/evaluate/evaluate.ts +0 -35
- package/src/resources/evaluate/index.ts +0 -14
- package/src/resources/evaluate/jobs/artifacts.ts +0 -42
- package/src/resources/evaluate/jobs/index.ts +0 -13
- package/src/resources/evaluate/jobs/jobs.ts +0 -99
- package/src/resources/evaluate/jobs/logs.ts +0 -42
- package/src/resources/evaluate/jobs/status.ts +0 -42
- package/src/resources/evaluate/question-answering.ts +0 -42
- package/src/resources/evaluate/summarization.ts +0 -5
- package/src/resources/evaluate/text-generation.ts +0 -5
- package/src/resources/evaluations.ts +0 -73
- package/src/resources/inference/embeddings.ts +0 -48
- package/src/resources/inference/index.ts +0 -15
- package/src/resources/inference/inference.ts +0 -268
- package/src/resources/memory/documents.ts +0 -92
- package/src/resources/memory/index.ts +0 -23
- package/src/resources/memory/memory.ts +0 -297
- package/src/resources/memory-banks.ts +0 -84
- package/src/resources/post-training/jobs.ts +0 -192
- package/src/resources/reward-scoring.ts +0 -82
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
export { RagTool, type RagToolInsertParams, type RagToolQueryParams } from "./rag-tool.js";
|
|
2
|
+
export { ToolRuntime, type ToolDef, type ToolInvocationResult, type ToolRuntimeInvokeToolParams, type ToolRuntimeListToolsParams, } from "./tool-runtime.js";
|
|
3
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/resources/tool-runtime/index.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,OAAO,EAAE,KAAK,mBAAmB,EAAE,KAAK,kBAAkB,EAAE,MAAM,YAAY,CAAC;AACxF,OAAO,EACL,WAAW,EACX,KAAK,OAAO,EACZ,KAAK,oBAAoB,EACzB,KAAK,2BAA2B,EAChC,KAAK,0BAA0B,GAChC,MAAM,gBAAgB,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.ToolRuntime = exports.RagTool = void 0;
|
|
5
|
+
var rag_tool_1 = require("./rag-tool.js");
|
|
6
|
+
Object.defineProperty(exports, "RagTool", { enumerable: true, get: function () { return rag_tool_1.RagTool; } });
|
|
7
|
+
var tool_runtime_1 = require("./tool-runtime.js");
|
|
8
|
+
Object.defineProperty(exports, "ToolRuntime", { enumerable: true, get: function () { return tool_runtime_1.ToolRuntime; } });
|
|
9
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/resources/tool-runtime/index.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,0CAAwF;AAA/E,mGAAA,OAAO,OAAA;AAChB,kDAMwB;AALtB,2GAAA,WAAW,OAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.mjs","sourceRoot":"","sources":["../../src/resources/tool-runtime/index.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,OAAO,EAAqD;OAC9D,EACL,WAAW,GAKZ"}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { APIResource } from "../../resource.js";
|
|
2
|
+
import * as Core from "../../core.js";
|
|
3
|
+
import * as Shared from "../shared.js";
|
|
4
|
+
export declare class RagTool extends APIResource {
|
|
5
|
+
/**
|
|
6
|
+
* Index documents so they can be used by the RAG system
|
|
7
|
+
*/
|
|
8
|
+
insert(body: RagToolInsertParams, options?: Core.RequestOptions): Core.APIPromise<void>;
|
|
9
|
+
/**
|
|
10
|
+
* Query the RAG system for context; typically invoked by the agent
|
|
11
|
+
*/
|
|
12
|
+
query(body: RagToolQueryParams, options?: Core.RequestOptions): Core.APIPromise<Shared.QueryResult>;
|
|
13
|
+
}
|
|
14
|
+
export interface RagToolInsertParams {
|
|
15
|
+
chunk_size_in_tokens: number;
|
|
16
|
+
documents: Array<Shared.Document>;
|
|
17
|
+
vector_db_id: string;
|
|
18
|
+
}
|
|
19
|
+
export interface RagToolQueryParams {
|
|
20
|
+
/**
|
|
21
|
+
* A image content item
|
|
22
|
+
*/
|
|
23
|
+
content: Shared.InterleavedContent;
|
|
24
|
+
vector_db_ids: Array<string>;
|
|
25
|
+
query_config?: Shared.QueryConfig;
|
|
26
|
+
}
|
|
27
|
+
export declare namespace RagTool {
|
|
28
|
+
export { type RagToolInsertParams as RagToolInsertParams, type RagToolQueryParams as RagToolQueryParams };
|
|
29
|
+
}
|
|
30
|
+
//# sourceMappingURL=rag-tool.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"rag-tool.d.ts","sourceRoot":"","sources":["../../src/resources/tool-runtime/rag-tool.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAC7C,OAAO,KAAK,IAAI,MAAM,YAAY,CAAC;AACnC,OAAO,KAAK,MAAM,MAAM,WAAW,CAAC;AAEpC,qBAAa,OAAQ,SAAQ,WAAW;IACtC;;OAEG;IACH,MAAM,CAAC,IAAI,EAAE,mBAAmB,EAAE,OAAO,CAAC,EAAE,IAAI,CAAC,cAAc,GAAG,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC;IAQvF;;OAEG;IACH,KAAK,CAAC,IAAI,EAAE,kBAAkB,EAAE,OAAO,CAAC,EAAE,IAAI,CAAC,cAAc,GAAG,IAAI,CAAC,UAAU,CAAC,MAAM,CAAC,WAAW,CAAC;CAGpG;AAED,MAAM,WAAW,mBAAmB;IAClC,oBAAoB,EAAE,MAAM,CAAC;IAE7B,SAAS,EAAE,KAAK,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC;IAElC,YAAY,EAAE,MAAM,CAAC;CACtB;AAED,MAAM,WAAW,kBAAkB;IACjC;;OAEG;IACH,OAAO,EAAE,MAAM,CAAC,kBAAkB,CAAC;IAEnC,aAAa,EAAE,KAAK,CAAC,MAAM,CAAC,CAAC;IAE7B,YAAY,CAAC,EAAE,MAAM,CAAC,WAAW,CAAC;CACnC;AAED,MAAM,CAAC,OAAO,WAAW,OAAO,CAAC;IAC/B,OAAO,EAAE,KAAK,mBAAmB,IAAI,mBAAmB,EAAE,KAAK,kBAAkB,IAAI,kBAAkB,EAAE,CAAC;CAC3G"}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.RagTool = void 0;
|
|
5
|
+
const resource_1 = require("../../resource.js");
|
|
6
|
+
class RagTool extends resource_1.APIResource {
|
|
7
|
+
/**
|
|
8
|
+
* Index documents so they can be used by the RAG system
|
|
9
|
+
*/
|
|
10
|
+
insert(body, options) {
|
|
11
|
+
return this._client.post('/v1/tool-runtime/rag-tool/insert', {
|
|
12
|
+
body,
|
|
13
|
+
...options,
|
|
14
|
+
headers: { Accept: '*/*', ...options?.headers },
|
|
15
|
+
});
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* Query the RAG system for context; typically invoked by the agent
|
|
19
|
+
*/
|
|
20
|
+
query(body, options) {
|
|
21
|
+
return this._client.post('/v1/tool-runtime/rag-tool/query', { body, ...options });
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
exports.RagTool = RagTool;
|
|
25
|
+
//# sourceMappingURL=rag-tool.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"rag-tool.js","sourceRoot":"","sources":["../../src/resources/tool-runtime/rag-tool.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,gDAA6C;AAI7C,MAAa,OAAQ,SAAQ,sBAAW;IACtC;;OAEG;IACH,MAAM,CAAC,IAAyB,EAAE,OAA6B;QAC7D,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,kCAAkC,EAAE;YAC3D,IAAI;YACJ,GAAG,OAAO;YACV,OAAO,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,OAAO,EAAE;SAChD,CAAC,CAAC;IACL,CAAC;IAED;;OAEG;IACH,KAAK,CAAC,IAAwB,EAAE,OAA6B;QAC3D,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,iCAAiC,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACpF,CAAC;CACF;AAlBD,0BAkBC"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
import { APIResource } from "../../resource.mjs";
|
|
3
|
+
export class RagTool extends APIResource {
|
|
4
|
+
/**
|
|
5
|
+
* Index documents so they can be used by the RAG system
|
|
6
|
+
*/
|
|
7
|
+
insert(body, options) {
|
|
8
|
+
return this._client.post('/v1/tool-runtime/rag-tool/insert', {
|
|
9
|
+
body,
|
|
10
|
+
...options,
|
|
11
|
+
headers: { Accept: '*/*', ...options?.headers },
|
|
12
|
+
});
|
|
13
|
+
}
|
|
14
|
+
/**
|
|
15
|
+
* Query the RAG system for context; typically invoked by the agent
|
|
16
|
+
*/
|
|
17
|
+
query(body, options) {
|
|
18
|
+
return this._client.post('/v1/tool-runtime/rag-tool/query', { body, ...options });
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
//# sourceMappingURL=rag-tool.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"rag-tool.mjs","sourceRoot":"","sources":["../../src/resources/tool-runtime/rag-tool.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;AAItB,MAAM,OAAO,OAAQ,SAAQ,WAAW;IACtC;;OAEG;IACH,MAAM,CAAC,IAAyB,EAAE,OAA6B;QAC7D,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,kCAAkC,EAAE;YAC3D,IAAI;YACJ,GAAG,OAAO;YACV,OAAO,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,OAAO,EAAE;SAChD,CAAC,CAAC;IACL,CAAC;IAED;;OAEG;IACH,KAAK,CAAC,IAAwB,EAAE,OAA6B;QAC3D,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,iCAAiC,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACpF,CAAC;CACF"}
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import { APIResource } from "../../resource.js";
|
|
2
|
+
import * as Core from "../../core.js";
|
|
3
|
+
import * as Shared from "../shared.js";
|
|
4
|
+
import * as RagToolAPI from "./rag-tool.js";
|
|
5
|
+
import { RagTool, RagToolInsertParams, RagToolQueryParams } from "./rag-tool.js";
|
|
6
|
+
import { JSONLDecoder } from "../../internal/decoders/jsonl.js";
|
|
7
|
+
export declare class ToolRuntime extends APIResource {
|
|
8
|
+
ragTool: RagToolAPI.RagTool;
|
|
9
|
+
/**
|
|
10
|
+
* Run a tool with the given arguments
|
|
11
|
+
*/
|
|
12
|
+
invokeTool(body: ToolRuntimeInvokeToolParams, options?: Core.RequestOptions): Core.APIPromise<ToolInvocationResult>;
|
|
13
|
+
listTools(query?: ToolRuntimeListToolsParams, options?: Core.RequestOptions): Core.APIPromise<JSONLDecoder<ToolDef>>;
|
|
14
|
+
listTools(options?: Core.RequestOptions): Core.APIPromise<JSONLDecoder<ToolDef>>;
|
|
15
|
+
}
|
|
16
|
+
export interface ToolDef {
|
|
17
|
+
name: string;
|
|
18
|
+
description?: string;
|
|
19
|
+
metadata?: Record<string, boolean | number | string | Array<unknown> | unknown | null>;
|
|
20
|
+
parameters?: Array<ToolDef.Parameter>;
|
|
21
|
+
}
|
|
22
|
+
export declare namespace ToolDef {
|
|
23
|
+
interface Parameter {
|
|
24
|
+
description: string;
|
|
25
|
+
name: string;
|
|
26
|
+
parameter_type: string;
|
|
27
|
+
required: boolean;
|
|
28
|
+
default?: boolean | number | string | Array<unknown> | unknown | null;
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
export interface ToolInvocationResult {
|
|
32
|
+
/**
|
|
33
|
+
* A image content item
|
|
34
|
+
*/
|
|
35
|
+
content: Shared.InterleavedContent;
|
|
36
|
+
error_code?: number;
|
|
37
|
+
error_message?: string;
|
|
38
|
+
}
|
|
39
|
+
export interface ToolRuntimeInvokeToolParams {
|
|
40
|
+
kwargs: Record<string, boolean | number | string | Array<unknown> | unknown | null>;
|
|
41
|
+
tool_name: string;
|
|
42
|
+
}
|
|
43
|
+
export interface ToolRuntimeListToolsParams {
|
|
44
|
+
mcp_endpoint?: Shared.URL;
|
|
45
|
+
tool_group_id?: string;
|
|
46
|
+
}
|
|
47
|
+
export declare namespace ToolRuntime {
|
|
48
|
+
export { type ToolDef as ToolDef, type ToolInvocationResult as ToolInvocationResult, type ToolRuntimeInvokeToolParams as ToolRuntimeInvokeToolParams, type ToolRuntimeListToolsParams as ToolRuntimeListToolsParams, };
|
|
49
|
+
export { RagTool as RagTool, type RagToolInsertParams as RagToolInsertParams, type RagToolQueryParams as RagToolQueryParams, };
|
|
50
|
+
}
|
|
51
|
+
//# sourceMappingURL=tool-runtime.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tool-runtime.d.ts","sourceRoot":"","sources":["../../src/resources/tool-runtime/tool-runtime.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAE7C,OAAO,KAAK,IAAI,MAAM,YAAY,CAAC;AACnC,OAAO,KAAK,MAAM,MAAM,WAAW,CAAC;AACpC,OAAO,KAAK,UAAU,MAAM,YAAY,CAAC;AACzC,OAAO,EAAE,OAAO,EAAE,mBAAmB,EAAE,kBAAkB,EAAE,MAAM,YAAY,CAAC;AAC9E,OAAO,EAAE,YAAY,EAAE,MAAM,+BAA+B,CAAC;AAE7D,qBAAa,WAAY,SAAQ,WAAW;IAC1C,OAAO,EAAE,UAAU,CAAC,OAAO,CAAwC;IAEnE;;OAEG;IACH,UAAU,CACR,IAAI,EAAE,2BAA2B,EACjC,OAAO,CAAC,EAAE,IAAI,CAAC,cAAc,GAC5B,IAAI,CAAC,UAAU,CAAC,oBAAoB,CAAC;IAIxC,SAAS,CACP,KAAK,CAAC,EAAE,0BAA0B,EAClC,OAAO,CAAC,EAAE,IAAI,CAAC,cAAc,GAC5B,IAAI,CAAC,UAAU,CAAC,YAAY,CAAC,OAAO,CAAC,CAAC;IACzC,SAAS,CAAC,OAAO,CAAC,EAAE,IAAI,CAAC,cAAc,GAAG,IAAI,CAAC,UAAU,CAAC,YAAY,CAAC,OAAO,CAAC,CAAC;CAiBjF;AAED,MAAM,WAAW,OAAO;IACtB,IAAI,EAAE,MAAM,CAAC;IAEb,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB,QAAQ,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,GAAG,MAAM,GAAG,MAAM,GAAG,KAAK,CAAC,OAAO,CAAC,GAAG,OAAO,GAAG,IAAI,CAAC,CAAC;IAEvF,UAAU,CAAC,EAAE,KAAK,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC;CACvC;AAED,yBAAiB,OAAO,CAAC;IACvB,UAAiB,SAAS;QACxB,WAAW,EAAE,MAAM,CAAC;QAEpB,IAAI,EAAE,MAAM,CAAC;QAEb,cAAc,EAAE,MAAM,CAAC;QAEvB,QAAQ,EAAE,OAAO,CAAC;QAElB,OAAO,CAAC,EAAE,OAAO,GAAG,MAAM,GAAG,MAAM,GAAG,KAAK,CAAC,OAAO,CAAC,GAAG,OAAO,GAAG,IAAI,CAAC;KACvE;CACF;AAED,MAAM,WAAW,oBAAoB;IACnC;;OAEG;IACH,OAAO,EAAE,MAAM,CAAC,kBAAkB,CAAC;IAEnC,UAAU,CAAC,EAAE,MAAM,CAAC;IAEpB,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB;AAED,MAAM,WAAW,2BAA2B;IAC1C,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,GAAG,MAAM,GAAG,MAAM,GAAG,KAAK,CAAC,OAAO,CAAC,GAAG,OAAO,GAAG,IAAI,CAAC,CAAC;IAEpF,SAAS,EAAE,MAAM,CAAC;CACnB;AAED,MAAM,WAAW,0BAA0B;IACzC,YAAY,CAAC,EAAE,MAAM,CAAC,GAAG,CAAC;IAE1B,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB;AAID,MAAM,CAAC,OAAO,WAAW,WAAW,CAAC;IACnC,OAAO,EACL,KAAK,OAAO,IAAI,OAAO,EACvB,KAAK,oBAAoB,IAAI,oBAAoB,EACjD,KAAK,2BAA2B,IAAI,2BAA2B,EAC/D,KAAK,0BAA0B,IAAI,0BAA0B,GAC9D,CAAC;IAEF,OAAO,EACL,OAAO,IAAI,OAAO,EAClB,KAAK,mBAAmB,IAAI,mBAAmB,EAC/C,KAAK,kBAAkB,IAAI,kBAAkB,GAC9C,CAAC;CACH"}
|
|
@@ -24,26 +24,37 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
24
24
|
return result;
|
|
25
25
|
};
|
|
26
26
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
27
|
-
exports.
|
|
27
|
+
exports.ToolRuntime = void 0;
|
|
28
28
|
const resource_1 = require("../../resource.js");
|
|
29
|
-
const
|
|
30
|
-
const
|
|
31
|
-
const
|
|
32
|
-
const
|
|
33
|
-
class
|
|
29
|
+
const core_1 = require("../../core.js");
|
|
30
|
+
const RagToolAPI = __importStar(require("./rag-tool.js"));
|
|
31
|
+
const rag_tool_1 = require("./rag-tool.js");
|
|
32
|
+
const jsonl_1 = require("../../internal/decoders/jsonl.js");
|
|
33
|
+
class ToolRuntime extends resource_1.APIResource {
|
|
34
34
|
constructor() {
|
|
35
35
|
super(...arguments);
|
|
36
|
-
this.
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
36
|
+
this.ragTool = new RagToolAPI.RagTool(this._client);
|
|
37
|
+
}
|
|
38
|
+
/**
|
|
39
|
+
* Run a tool with the given arguments
|
|
40
|
+
*/
|
|
41
|
+
invokeTool(body, options) {
|
|
42
|
+
return this._client.post('/v1/tool-runtime/invoke', { body, ...options });
|
|
43
|
+
}
|
|
44
|
+
listTools(query = {}, options) {
|
|
45
|
+
if ((0, core_1.isRequestOptions)(query)) {
|
|
46
|
+
return this.listTools({}, query);
|
|
47
|
+
}
|
|
48
|
+
return this._client
|
|
49
|
+
.get('/v1/tool-runtime/list-tools', {
|
|
50
|
+
query,
|
|
51
|
+
...options,
|
|
52
|
+
headers: { Accept: 'application/jsonl', ...options?.headers },
|
|
53
|
+
__binaryResponse: true,
|
|
54
|
+
})
|
|
55
|
+
._thenUnwrap((_, props) => jsonl_1.JSONLDecoder.fromResponse(props.response, props.controller));
|
|
40
56
|
}
|
|
41
57
|
}
|
|
42
|
-
exports.
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
Evaluate.QuestionAnswering = QuestionAnsweringAPI.QuestionAnswering;
|
|
46
|
-
Evaluate.Summarization = SummarizationAPI.Summarization;
|
|
47
|
-
Evaluate.TextGeneration = TextGenerationAPI.TextGeneration;
|
|
48
|
-
})(Evaluate = exports.Evaluate || (exports.Evaluate = {}));
|
|
49
|
-
//# sourceMappingURL=evaluate.js.map
|
|
58
|
+
exports.ToolRuntime = ToolRuntime;
|
|
59
|
+
ToolRuntime.RagTool = rag_tool_1.RagTool;
|
|
60
|
+
//# sourceMappingURL=tool-runtime.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tool-runtime.js","sourceRoot":"","sources":["../../src/resources/tool-runtime/tool-runtime.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;;;;;;;;;;;;;;;;;;;;;;;;AAEtF,gDAA6C;AAC7C,wCAA8C;AAG9C,0DAAyC;AACzC,4CAA8E;AAC9E,4DAA6D;AAE7D,MAAa,WAAY,SAAQ,sBAAW;IAA5C;;QACE,YAAO,GAAuB,IAAI,UAAU,CAAC,OAAO,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IAiCrE,CAAC;IA/BC;;OAEG;IACH,UAAU,CACR,IAAiC,EACjC,OAA6B;QAE7B,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,yBAAyB,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IAC5E,CAAC;IAOD,SAAS,CACP,QAA0D,EAAE,EAC5D,OAA6B;QAE7B,IAAI,IAAA,uBAAgB,EAAC,KAAK,CAAC,EAAE;YAC3B,OAAO,IAAI,CAAC,SAAS,CAAC,EAAE,EAAE,KAAK,CAAC,CAAC;SAClC;QACD,OAAO,IAAI,CAAC,OAAO;aAChB,GAAG,CAAC,6BAA6B,EAAE;YAClC,KAAK;YACL,GAAG,OAAO;YACV,OAAO,EAAE,EAAE,MAAM,EAAE,mBAAmB,EAAE,GAAG,OAAO,EAAE,OAAO,EAAE;YAC7D,gBAAgB,EAAE,IAAI;SACvB,CAAC;aACD,WAAW,CAAC,CAAC,CAAC,EAAE,KAAK,EAAE,EAAE,CAAC,oBAAY,CAAC,YAAY,CAAC,KAAK,CAAC,QAAQ,EAAE,KAAK,CAAC,UAAU,CAAC,CAAC,CAAC;IAC5F,CAAC;CACF;AAlCD,kCAkCC;AAiDD,WAAW,CAAC,OAAO,GAAG,kBAAO,CAAC"}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
import { APIResource } from "../../resource.mjs";
|
|
3
|
+
import { isRequestOptions } from "../../core.mjs";
|
|
4
|
+
import * as RagToolAPI from "./rag-tool.mjs";
|
|
5
|
+
import { RagTool } from "./rag-tool.mjs";
|
|
6
|
+
import { JSONLDecoder } from "../../internal/decoders/jsonl.mjs";
|
|
7
|
+
export class ToolRuntime extends APIResource {
|
|
8
|
+
constructor() {
|
|
9
|
+
super(...arguments);
|
|
10
|
+
this.ragTool = new RagToolAPI.RagTool(this._client);
|
|
11
|
+
}
|
|
12
|
+
/**
|
|
13
|
+
* Run a tool with the given arguments
|
|
14
|
+
*/
|
|
15
|
+
invokeTool(body, options) {
|
|
16
|
+
return this._client.post('/v1/tool-runtime/invoke', { body, ...options });
|
|
17
|
+
}
|
|
18
|
+
listTools(query = {}, options) {
|
|
19
|
+
if (isRequestOptions(query)) {
|
|
20
|
+
return this.listTools({}, query);
|
|
21
|
+
}
|
|
22
|
+
return this._client
|
|
23
|
+
.get('/v1/tool-runtime/list-tools', {
|
|
24
|
+
query,
|
|
25
|
+
...options,
|
|
26
|
+
headers: { Accept: 'application/jsonl', ...options?.headers },
|
|
27
|
+
__binaryResponse: true,
|
|
28
|
+
})
|
|
29
|
+
._thenUnwrap((_, props) => JSONLDecoder.fromResponse(props.response, props.controller));
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
ToolRuntime.RagTool = RagTool;
|
|
33
|
+
//# sourceMappingURL=tool-runtime.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tool-runtime.mjs","sourceRoot":"","sources":["../../src/resources/tool-runtime/tool-runtime.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;OACf,EAAE,gBAAgB,EAAE;OAGpB,KAAK,UAAU;OACf,EAAE,OAAO,EAA2C;OACpD,EAAE,YAAY,EAAE;AAEvB,MAAM,OAAO,WAAY,SAAQ,WAAW;IAA5C;;QACE,YAAO,GAAuB,IAAI,UAAU,CAAC,OAAO,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IAiCrE,CAAC;IA/BC;;OAEG;IACH,UAAU,CACR,IAAiC,EACjC,OAA6B;QAE7B,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,yBAAyB,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IAC5E,CAAC;IAOD,SAAS,CACP,QAA0D,EAAE,EAC5D,OAA6B;QAE7B,IAAI,gBAAgB,CAAC,KAAK,CAAC,EAAE;YAC3B,OAAO,IAAI,CAAC,SAAS,CAAC,EAAE,EAAE,KAAK,CAAC,CAAC;SAClC;QACD,OAAO,IAAI,CAAC,OAAO;aAChB,GAAG,CAAC,6BAA6B,EAAE;YAClC,KAAK;YACL,GAAG,OAAO;YACV,OAAO,EAAE,EAAE,MAAM,EAAE,mBAAmB,EAAE,GAAG,OAAO,EAAE,OAAO,EAAE;YAC7D,gBAAgB,EAAE,IAAI;SACvB,CAAC;aACD,WAAW,CAAC,CAAC,CAAC,EAAE,KAAK,EAAE,EAAE,CAAC,YAAY,CAAC,YAAY,CAAC,KAAK,CAAC,QAAQ,EAAE,KAAK,CAAC,UAAU,CAAC,CAAC,CAAC;IAC5F,CAAC;CACF;AAiDD,WAAW,CAAC,OAAO,GAAG,OAAO,CAAC"}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import { APIResource } from "../resource.js";
|
|
2
|
+
import * as Core from "../core.js";
|
|
3
|
+
import * as Shared from "./shared.js";
|
|
4
|
+
export declare class Toolgroups extends APIResource {
|
|
5
|
+
/**
|
|
6
|
+
* List tool groups with optional provider
|
|
7
|
+
*/
|
|
8
|
+
list(options?: Core.RequestOptions): Core.APIPromise<ToolgroupListResponse>;
|
|
9
|
+
get(toolgroupId: string, options?: Core.RequestOptions): Core.APIPromise<ToolGroup>;
|
|
10
|
+
/**
|
|
11
|
+
* Register a tool group
|
|
12
|
+
*/
|
|
13
|
+
register(body: ToolgroupRegisterParams, options?: Core.RequestOptions): Core.APIPromise<void>;
|
|
14
|
+
/**
|
|
15
|
+
* Unregister a tool group
|
|
16
|
+
*/
|
|
17
|
+
unregister(toolgroupId: string, options?: Core.RequestOptions): Core.APIPromise<void>;
|
|
18
|
+
}
|
|
19
|
+
export interface ListToolGroupsResponse {
|
|
20
|
+
data: ToolgroupListResponse;
|
|
21
|
+
}
|
|
22
|
+
export interface ToolGroup {
|
|
23
|
+
identifier: string;
|
|
24
|
+
provider_id: string;
|
|
25
|
+
provider_resource_id: string;
|
|
26
|
+
type: 'tool_group';
|
|
27
|
+
args?: Record<string, boolean | number | string | Array<unknown> | unknown | null>;
|
|
28
|
+
mcp_endpoint?: Shared.URL;
|
|
29
|
+
}
|
|
30
|
+
export type ToolgroupListResponse = Array<ToolGroup>;
|
|
31
|
+
export interface ToolgroupRegisterParams {
|
|
32
|
+
provider_id: string;
|
|
33
|
+
toolgroup_id: string;
|
|
34
|
+
args?: Record<string, boolean | number | string | Array<unknown> | unknown | null>;
|
|
35
|
+
mcp_endpoint?: Shared.URL;
|
|
36
|
+
}
|
|
37
|
+
export declare namespace Toolgroups {
|
|
38
|
+
export { type ListToolGroupsResponse as ListToolGroupsResponse, type ToolGroup as ToolGroup, type ToolgroupListResponse as ToolgroupListResponse, type ToolgroupRegisterParams as ToolgroupRegisterParams, };
|
|
39
|
+
}
|
|
40
|
+
//# sourceMappingURL=toolgroups.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"toolgroups.d.ts","sourceRoot":"","sources":["../src/resources/toolgroups.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAC1C,OAAO,KAAK,IAAI,MAAM,SAAS,CAAC;AAChC,OAAO,KAAK,MAAM,MAAM,UAAU,CAAC;AAEnC,qBAAa,UAAW,SAAQ,WAAW;IACzC;;OAEG;IACH,IAAI,CAAC,OAAO,CAAC,EAAE,IAAI,CAAC,cAAc,GAAG,IAAI,CAAC,UAAU,CAAC,qBAAqB,CAAC;IAM3E,GAAG,CAAC,WAAW,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,IAAI,CAAC,cAAc,GAAG,IAAI,CAAC,UAAU,CAAC,SAAS,CAAC;IAInF;;OAEG;IACH,QAAQ,CAAC,IAAI,EAAE,uBAAuB,EAAE,OAAO,CAAC,EAAE,IAAI,CAAC,cAAc,GAAG,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC;IAQ7F;;OAEG;IACH,UAAU,CAAC,WAAW,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,IAAI,CAAC,cAAc,GAAG,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC;CAMtF;AAED,MAAM,WAAW,sBAAsB;IACrC,IAAI,EAAE,qBAAqB,CAAC;CAC7B;AAED,MAAM,WAAW,SAAS;IACxB,UAAU,EAAE,MAAM,CAAC;IAEnB,WAAW,EAAE,MAAM,CAAC;IAEpB,oBAAoB,EAAE,MAAM,CAAC;IAE7B,IAAI,EAAE,YAAY,CAAC;IAEnB,IAAI,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,GAAG,MAAM,GAAG,MAAM,GAAG,KAAK,CAAC,OAAO,CAAC,GAAG,OAAO,GAAG,IAAI,CAAC,CAAC;IAEnF,YAAY,CAAC,EAAE,MAAM,CAAC,GAAG,CAAC;CAC3B;AAED,MAAM,MAAM,qBAAqB,GAAG,KAAK,CAAC,SAAS,CAAC,CAAC;AAErD,MAAM,WAAW,uBAAuB;IACtC,WAAW,EAAE,MAAM,CAAC;IAEpB,YAAY,EAAE,MAAM,CAAC;IAErB,IAAI,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,GAAG,MAAM,GAAG,MAAM,GAAG,KAAK,CAAC,OAAO,CAAC,GAAG,OAAO,GAAG,IAAI,CAAC,CAAC;IAEnF,YAAY,CAAC,EAAE,MAAM,CAAC,GAAG,CAAC;CAC3B;AAED,MAAM,CAAC,OAAO,WAAW,UAAU,CAAC;IAClC,OAAO,EACL,KAAK,sBAAsB,IAAI,sBAAsB,EACrD,KAAK,SAAS,IAAI,SAAS,EAC3B,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,uBAAuB,IAAI,uBAAuB,GACxD,CAAC;CACH"}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.Toolgroups = void 0;
|
|
5
|
+
const resource_1 = require("../resource.js");
|
|
6
|
+
class Toolgroups extends resource_1.APIResource {
|
|
7
|
+
/**
|
|
8
|
+
* List tool groups with optional provider
|
|
9
|
+
*/
|
|
10
|
+
list(options) {
|
|
11
|
+
return this._client.get('/v1/toolgroups', options)._thenUnwrap((obj) => obj.data);
|
|
12
|
+
}
|
|
13
|
+
get(toolgroupId, options) {
|
|
14
|
+
return this._client.get(`/v1/toolgroups/${toolgroupId}`, options);
|
|
15
|
+
}
|
|
16
|
+
/**
|
|
17
|
+
* Register a tool group
|
|
18
|
+
*/
|
|
19
|
+
register(body, options) {
|
|
20
|
+
return this._client.post('/v1/toolgroups', {
|
|
21
|
+
body,
|
|
22
|
+
...options,
|
|
23
|
+
headers: { Accept: '*/*', ...options?.headers },
|
|
24
|
+
});
|
|
25
|
+
}
|
|
26
|
+
/**
|
|
27
|
+
* Unregister a tool group
|
|
28
|
+
*/
|
|
29
|
+
unregister(toolgroupId, options) {
|
|
30
|
+
return this._client.delete(`/v1/toolgroups/${toolgroupId}`, {
|
|
31
|
+
...options,
|
|
32
|
+
headers: { Accept: '*/*', ...options?.headers },
|
|
33
|
+
});
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
exports.Toolgroups = Toolgroups;
|
|
37
|
+
//# sourceMappingURL=toolgroups.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"toolgroups.js","sourceRoot":"","sources":["../src/resources/toolgroups.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,6CAA0C;AAI1C,MAAa,UAAW,SAAQ,sBAAW;IACzC;;OAEG;IACH,IAAI,CAAC,OAA6B;QAChC,OACE,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,gBAAgB,EAAE,OAAO,CAC3C,CAAC,WAAW,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC;IACnC,CAAC;IAED,GAAG,CAAC,WAAmB,EAAE,OAA6B;QACpD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,kBAAkB,WAAW,EAAE,EAAE,OAAO,CAAC,CAAC;IACpE,CAAC;IAED;;OAEG;IACH,QAAQ,CAAC,IAA6B,EAAE,OAA6B;QACnE,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,gBAAgB,EAAE;YACzC,IAAI;YACJ,GAAG,OAAO;YACV,OAAO,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,OAAO,EAAE;SAChD,CAAC,CAAC;IACL,CAAC;IAED;;OAEG;IACH,UAAU,CAAC,WAAmB,EAAE,OAA6B;QAC3D,OAAO,IAAI,CAAC,OAAO,CAAC,MAAM,CAAC,kBAAkB,WAAW,EAAE,EAAE;YAC1D,GAAG,OAAO;YACV,OAAO,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,OAAO,EAAE;SAChD,CAAC,CAAC;IACL,CAAC;CACF;AAlCD,gCAkCC"}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
import { APIResource } from "../resource.mjs";
|
|
3
|
+
export class Toolgroups extends APIResource {
|
|
4
|
+
/**
|
|
5
|
+
* List tool groups with optional provider
|
|
6
|
+
*/
|
|
7
|
+
list(options) {
|
|
8
|
+
return this._client.get('/v1/toolgroups', options)._thenUnwrap((obj) => obj.data);
|
|
9
|
+
}
|
|
10
|
+
get(toolgroupId, options) {
|
|
11
|
+
return this._client.get(`/v1/toolgroups/${toolgroupId}`, options);
|
|
12
|
+
}
|
|
13
|
+
/**
|
|
14
|
+
* Register a tool group
|
|
15
|
+
*/
|
|
16
|
+
register(body, options) {
|
|
17
|
+
return this._client.post('/v1/toolgroups', {
|
|
18
|
+
body,
|
|
19
|
+
...options,
|
|
20
|
+
headers: { Accept: '*/*', ...options?.headers },
|
|
21
|
+
});
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* Unregister a tool group
|
|
25
|
+
*/
|
|
26
|
+
unregister(toolgroupId, options) {
|
|
27
|
+
return this._client.delete(`/v1/toolgroups/${toolgroupId}`, {
|
|
28
|
+
...options,
|
|
29
|
+
headers: { Accept: '*/*', ...options?.headers },
|
|
30
|
+
});
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
//# sourceMappingURL=toolgroups.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"toolgroups.mjs","sourceRoot":"","sources":["../src/resources/toolgroups.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;AAItB,MAAM,OAAO,UAAW,SAAQ,WAAW;IACzC;;OAEG;IACH,IAAI,CAAC,OAA6B;QAChC,OACE,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,gBAAgB,EAAE,OAAO,CAC3C,CAAC,WAAW,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC;IACnC,CAAC;IAED,GAAG,CAAC,WAAmB,EAAE,OAA6B;QACpD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,kBAAkB,WAAW,EAAE,EAAE,OAAO,CAAC,CAAC;IACpE,CAAC;IAED;;OAEG;IACH,QAAQ,CAAC,IAA6B,EAAE,OAA6B;QACnE,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,gBAAgB,EAAE;YACzC,IAAI;YACJ,GAAG,OAAO;YACV,OAAO,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,OAAO,EAAE;SAChD,CAAC,CAAC;IACL,CAAC;IAED;;OAEG;IACH,UAAU,CAAC,WAAmB,EAAE,OAA6B;QAC3D,OAAO,IAAI,CAAC,OAAO,CAAC,MAAM,CAAC,kBAAkB,WAAW,EAAE,EAAE;YAC1D,GAAG,OAAO;YACV,OAAO,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,OAAO,EAAE;SAChD,CAAC,CAAC;IACL,CAAC;CACF"}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import { APIResource } from "../resource.js";
|
|
2
|
+
import * as Core from "../core.js";
|
|
3
|
+
export declare class Tools extends APIResource {
|
|
4
|
+
/**
|
|
5
|
+
* List tools with optional tool group
|
|
6
|
+
*/
|
|
7
|
+
list(query?: ToolListParams, options?: Core.RequestOptions): Core.APIPromise<ToolListResponse>;
|
|
8
|
+
list(options?: Core.RequestOptions): Core.APIPromise<ToolListResponse>;
|
|
9
|
+
get(toolName: string, options?: Core.RequestOptions): Core.APIPromise<Tool>;
|
|
10
|
+
}
|
|
11
|
+
export interface ListToolsResponse {
|
|
12
|
+
data: ToolListResponse;
|
|
13
|
+
}
|
|
14
|
+
export interface Tool {
|
|
15
|
+
description: string;
|
|
16
|
+
identifier: string;
|
|
17
|
+
parameters: Array<Tool.Parameter>;
|
|
18
|
+
provider_id: string;
|
|
19
|
+
provider_resource_id: string;
|
|
20
|
+
tool_host: 'distribution' | 'client' | 'model_context_protocol';
|
|
21
|
+
toolgroup_id: string;
|
|
22
|
+
type: 'tool';
|
|
23
|
+
metadata?: Record<string, boolean | number | string | Array<unknown> | unknown | null>;
|
|
24
|
+
}
|
|
25
|
+
export declare namespace Tool {
|
|
26
|
+
interface Parameter {
|
|
27
|
+
description: string;
|
|
28
|
+
name: string;
|
|
29
|
+
parameter_type: string;
|
|
30
|
+
required: boolean;
|
|
31
|
+
default?: boolean | number | string | Array<unknown> | unknown | null;
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
export type ToolListResponse = Array<Tool>;
|
|
35
|
+
export interface ToolListParams {
|
|
36
|
+
toolgroup_id?: string;
|
|
37
|
+
}
|
|
38
|
+
export declare namespace Tools {
|
|
39
|
+
export { type ListToolsResponse as ListToolsResponse, type Tool as Tool, type ToolListResponse as ToolListResponse, type ToolListParams as ToolListParams, };
|
|
40
|
+
}
|
|
41
|
+
//# sourceMappingURL=tools.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tools.d.ts","sourceRoot":"","sources":["../src/resources/tools.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAE1C,OAAO,KAAK,IAAI,MAAM,SAAS,CAAC;AAEhC,qBAAa,KAAM,SAAQ,WAAW;IACpC;;OAEG;IACH,IAAI,CAAC,KAAK,CAAC,EAAE,cAAc,EAAE,OAAO,CAAC,EAAE,IAAI,CAAC,cAAc,GAAG,IAAI,CAAC,UAAU,CAAC,gBAAgB,CAAC;IAC9F,IAAI,CAAC,OAAO,CAAC,EAAE,IAAI,CAAC,cAAc,GAAG,IAAI,CAAC,UAAU,CAAC,gBAAgB,CAAC;IAatE,GAAG,CAAC,QAAQ,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,IAAI,CAAC,cAAc,GAAG,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC;CAG5E;AAED,MAAM,WAAW,iBAAiB;IAChC,IAAI,EAAE,gBAAgB,CAAC;CACxB;AAED,MAAM,WAAW,IAAI;IACnB,WAAW,EAAE,MAAM,CAAC;IAEpB,UAAU,EAAE,MAAM,CAAC;IAEnB,UAAU,EAAE,KAAK,CAAC,IAAI,CAAC,SAAS,CAAC,CAAC;IAElC,WAAW,EAAE,MAAM,CAAC;IAEpB,oBAAoB,EAAE,MAAM,CAAC;IAE7B,SAAS,EAAE,cAAc,GAAG,QAAQ,GAAG,wBAAwB,CAAC;IAEhE,YAAY,EAAE,MAAM,CAAC;IAErB,IAAI,EAAE,MAAM,CAAC;IAEb,QAAQ,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,GAAG,MAAM,GAAG,MAAM,GAAG,KAAK,CAAC,OAAO,CAAC,GAAG,OAAO,GAAG,IAAI,CAAC,CAAC;CACxF;AAED,yBAAiB,IAAI,CAAC;IACpB,UAAiB,SAAS;QACxB,WAAW,EAAE,MAAM,CAAC;QAEpB,IAAI,EAAE,MAAM,CAAC;QAEb,cAAc,EAAE,MAAM,CAAC;QAEvB,QAAQ,EAAE,OAAO,CAAC;QAElB,OAAO,CAAC,EAAE,OAAO,GAAG,MAAM,GAAG,MAAM,GAAG,KAAK,CAAC,OAAO,CAAC,GAAG,OAAO,GAAG,IAAI,CAAC;KACvE;CACF;AAED,MAAM,MAAM,gBAAgB,GAAG,KAAK,CAAC,IAAI,CAAC,CAAC;AAE3C,MAAM,WAAW,cAAc;IAC7B,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAED,MAAM,CAAC,OAAO,WAAW,KAAK,CAAC;IAC7B,OAAO,EACL,KAAK,iBAAiB,IAAI,iBAAiB,EAC3C,KAAK,IAAI,IAAI,IAAI,EACjB,KAAK,gBAAgB,IAAI,gBAAgB,EACzC,KAAK,cAAc,IAAI,cAAc,GACtC,CAAC;CACH"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.Tools = void 0;
|
|
5
|
+
const resource_1 = require("../resource.js");
|
|
6
|
+
const core_1 = require("../core.js");
|
|
7
|
+
class Tools extends resource_1.APIResource {
|
|
8
|
+
list(query = {}, options) {
|
|
9
|
+
if ((0, core_1.isRequestOptions)(query)) {
|
|
10
|
+
return this.list({}, query);
|
|
11
|
+
}
|
|
12
|
+
return this._client.get('/v1/tools', { query, ...options })._thenUnwrap((obj) => obj.data);
|
|
13
|
+
}
|
|
14
|
+
get(toolName, options) {
|
|
15
|
+
return this._client.get(`/v1/tools/${toolName}`, options);
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
exports.Tools = Tools;
|
|
19
|
+
//# sourceMappingURL=tools.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tools.js","sourceRoot":"","sources":["../src/resources/tools.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,6CAA0C;AAC1C,qCAA2C;AAG3C,MAAa,KAAM,SAAQ,sBAAW;IAMpC,IAAI,CACF,QAA8C,EAAE,EAChD,OAA6B;QAE7B,IAAI,IAAA,uBAAgB,EAAC,KAAK,CAAC,EAAE;YAC3B,OAAO,IAAI,CAAC,IAAI,CAAC,EAAE,EAAE,KAAK,CAAC,CAAC;SAC7B;QACD,OACE,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,WAAW,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CACpD,CAAC,WAAW,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC;IACnC,CAAC;IAED,GAAG,CAAC,QAAgB,EAAE,OAA6B;QACjD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,aAAa,QAAQ,EAAE,EAAE,OAAO,CAAC,CAAC;IAC5D,CAAC;CACF;AArBD,sBAqBC"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
import { APIResource } from "../resource.mjs";
|
|
3
|
+
import { isRequestOptions } from "../core.mjs";
|
|
4
|
+
export class Tools extends APIResource {
|
|
5
|
+
list(query = {}, options) {
|
|
6
|
+
if (isRequestOptions(query)) {
|
|
7
|
+
return this.list({}, query);
|
|
8
|
+
}
|
|
9
|
+
return this._client.get('/v1/tools', { query, ...options })._thenUnwrap((obj) => obj.data);
|
|
10
|
+
}
|
|
11
|
+
get(toolName, options) {
|
|
12
|
+
return this._client.get(`/v1/tools/${toolName}`, options);
|
|
13
|
+
}
|
|
14
|
+
}
|
|
15
|
+
//# sourceMappingURL=tools.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tools.mjs","sourceRoot":"","sources":["../src/resources/tools.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;OACf,EAAE,gBAAgB,EAAE;AAG3B,MAAM,OAAO,KAAM,SAAQ,WAAW;IAMpC,IAAI,CACF,QAA8C,EAAE,EAChD,OAA6B;QAE7B,IAAI,gBAAgB,CAAC,KAAK,CAAC,EAAE;YAC3B,OAAO,IAAI,CAAC,IAAI,CAAC,EAAE,EAAE,KAAK,CAAC,CAAC;SAC7B;QACD,OACE,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,WAAW,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CACpD,CAAC,WAAW,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC;IACnC,CAAC;IAED,GAAG,CAAC,QAAgB,EAAE,OAA6B;QACjD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,aAAa,QAAQ,EAAE,EAAE,OAAO,CAAC,CAAC;IAC5D,CAAC;CACF"}
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import { APIResource } from "../resource.js";
|
|
2
|
+
import * as Core from "../core.js";
|
|
3
|
+
export declare class VectorDBs extends APIResource {
|
|
4
|
+
retrieve(vectorDBId: string, options?: Core.RequestOptions): Core.APIPromise<VectorDBRetrieveResponse | null>;
|
|
5
|
+
list(options?: Core.RequestOptions): Core.APIPromise<VectorDBListResponse>;
|
|
6
|
+
register(body: VectorDBRegisterParams, options?: Core.RequestOptions): Core.APIPromise<VectorDBRegisterResponse>;
|
|
7
|
+
unregister(vectorDBId: string, options?: Core.RequestOptions): Core.APIPromise<void>;
|
|
8
|
+
}
|
|
9
|
+
export interface ListVectorDBsResponse {
|
|
10
|
+
data: VectorDBListResponse;
|
|
11
|
+
}
|
|
12
|
+
export interface VectorDBRetrieveResponse {
|
|
13
|
+
embedding_dimension: number;
|
|
14
|
+
embedding_model: string;
|
|
15
|
+
identifier: string;
|
|
16
|
+
provider_id: string;
|
|
17
|
+
provider_resource_id: string;
|
|
18
|
+
type: 'vector_db';
|
|
19
|
+
}
|
|
20
|
+
export type VectorDBListResponse = Array<VectorDBListResponse.VectorDBListResponseItem>;
|
|
21
|
+
export declare namespace VectorDBListResponse {
|
|
22
|
+
interface VectorDBListResponseItem {
|
|
23
|
+
embedding_dimension: number;
|
|
24
|
+
embedding_model: string;
|
|
25
|
+
identifier: string;
|
|
26
|
+
provider_id: string;
|
|
27
|
+
provider_resource_id: string;
|
|
28
|
+
type: 'vector_db';
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
export interface VectorDBRegisterResponse {
|
|
32
|
+
embedding_dimension: number;
|
|
33
|
+
embedding_model: string;
|
|
34
|
+
identifier: string;
|
|
35
|
+
provider_id: string;
|
|
36
|
+
provider_resource_id: string;
|
|
37
|
+
type: 'vector_db';
|
|
38
|
+
}
|
|
39
|
+
export interface VectorDBRegisterParams {
|
|
40
|
+
embedding_model: string;
|
|
41
|
+
vector_db_id: string;
|
|
42
|
+
embedding_dimension?: number;
|
|
43
|
+
provider_id?: string;
|
|
44
|
+
provider_vector_db_id?: string;
|
|
45
|
+
}
|
|
46
|
+
export declare namespace VectorDBs {
|
|
47
|
+
export { type ListVectorDBsResponse as ListVectorDBsResponse, type VectorDBRetrieveResponse as VectorDBRetrieveResponse, type VectorDBListResponse as VectorDBListResponse, type VectorDBRegisterResponse as VectorDBRegisterResponse, type VectorDBRegisterParams as VectorDBRegisterParams, };
|
|
48
|
+
}
|
|
49
|
+
//# sourceMappingURL=vector-dbs.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"vector-dbs.d.ts","sourceRoot":"","sources":["../src/resources/vector-dbs.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAC1C,OAAO,KAAK,IAAI,MAAM,SAAS,CAAC;AAEhC,qBAAa,SAAU,SAAQ,WAAW;IACxC,QAAQ,CACN,UAAU,EAAE,MAAM,EAClB,OAAO,CAAC,EAAE,IAAI,CAAC,cAAc,GAC5B,IAAI,CAAC,UAAU,CAAC,wBAAwB,GAAG,IAAI,CAAC;IAInD,IAAI,CAAC,OAAO,CAAC,EAAE,IAAI,CAAC,cAAc,GAAG,IAAI,CAAC,UAAU,CAAC,oBAAoB,CAAC;IAM1E,QAAQ,CACN,IAAI,EAAE,sBAAsB,EAC5B,OAAO,CAAC,EAAE,IAAI,CAAC,cAAc,GAC5B,IAAI,CAAC,UAAU,CAAC,wBAAwB,CAAC;IAI5C,UAAU,CAAC,UAAU,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,IAAI,CAAC,cAAc,GAAG,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC;CAMrF;AAED,MAAM,WAAW,qBAAqB;IACpC,IAAI,EAAE,oBAAoB,CAAC;CAC5B;AAED,MAAM,WAAW,wBAAwB;IACvC,mBAAmB,EAAE,MAAM,CAAC;IAE5B,eAAe,EAAE,MAAM,CAAC;IAExB,UAAU,EAAE,MAAM,CAAC;IAEnB,WAAW,EAAE,MAAM,CAAC;IAEpB,oBAAoB,EAAE,MAAM,CAAC;IAE7B,IAAI,EAAE,WAAW,CAAC;CACnB;AAED,MAAM,MAAM,oBAAoB,GAAG,KAAK,CAAC,oBAAoB,CAAC,wBAAwB,CAAC,CAAC;AAExF,yBAAiB,oBAAoB,CAAC;IACpC,UAAiB,wBAAwB;QACvC,mBAAmB,EAAE,MAAM,CAAC;QAE5B,eAAe,EAAE,MAAM,CAAC;QAExB,UAAU,EAAE,MAAM,CAAC;QAEnB,WAAW,EAAE,MAAM,CAAC;QAEpB,oBAAoB,EAAE,MAAM,CAAC;QAE7B,IAAI,EAAE,WAAW,CAAC;KACnB;CACF;AAED,MAAM,WAAW,wBAAwB;IACvC,mBAAmB,EAAE,MAAM,CAAC;IAE5B,eAAe,EAAE,MAAM,CAAC;IAExB,UAAU,EAAE,MAAM,CAAC;IAEnB,WAAW,EAAE,MAAM,CAAC;IAEpB,oBAAoB,EAAE,MAAM,CAAC;IAE7B,IAAI,EAAE,WAAW,CAAC;CACnB;AAED,MAAM,WAAW,sBAAsB;IACrC,eAAe,EAAE,MAAM,CAAC;IAExB,YAAY,EAAE,MAAM,CAAC;IAErB,mBAAmB,CAAC,EAAE,MAAM,CAAC;IAE7B,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB,qBAAqB,CAAC,EAAE,MAAM,CAAC;CAChC;AAED,MAAM,CAAC,OAAO,WAAW,SAAS,CAAC;IACjC,OAAO,EACL,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,wBAAwB,IAAI,wBAAwB,EACzD,KAAK,oBAAoB,IAAI,oBAAoB,EACjD,KAAK,wBAAwB,IAAI,wBAAwB,EACzD,KAAK,sBAAsB,IAAI,sBAAsB,GACtD,CAAC;CACH"}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.VectorDBs = void 0;
|
|
5
|
+
const resource_1 = require("../resource.js");
|
|
6
|
+
class VectorDBs extends resource_1.APIResource {
|
|
7
|
+
retrieve(vectorDBId, options) {
|
|
8
|
+
return this._client.get(`/v1/vector-dbs/${vectorDBId}`, options);
|
|
9
|
+
}
|
|
10
|
+
list(options) {
|
|
11
|
+
return this._client.get('/v1/vector-dbs', options)._thenUnwrap((obj) => obj.data);
|
|
12
|
+
}
|
|
13
|
+
register(body, options) {
|
|
14
|
+
return this._client.post('/v1/vector-dbs', { body, ...options });
|
|
15
|
+
}
|
|
16
|
+
unregister(vectorDBId, options) {
|
|
17
|
+
return this._client.delete(`/v1/vector-dbs/${vectorDBId}`, {
|
|
18
|
+
...options,
|
|
19
|
+
headers: { Accept: '*/*', ...options?.headers },
|
|
20
|
+
});
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
exports.VectorDBs = VectorDBs;
|
|
24
|
+
//# sourceMappingURL=vector-dbs.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"vector-dbs.js","sourceRoot":"","sources":["../src/resources/vector-dbs.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,6CAA0C;AAG1C,MAAa,SAAU,SAAQ,sBAAW;IACxC,QAAQ,CACN,UAAkB,EAClB,OAA6B;QAE7B,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,kBAAkB,UAAU,EAAE,EAAE,OAAO,CAAC,CAAC;IACnE,CAAC;IAED,IAAI,CAAC,OAA6B;QAChC,OACE,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,gBAAgB,EAAE,OAAO,CAC3C,CAAC,WAAW,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC;IACnC,CAAC;IAED,QAAQ,CACN,IAA4B,EAC5B,OAA6B;QAE7B,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,gBAAgB,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACnE,CAAC;IAED,UAAU,CAAC,UAAkB,EAAE,OAA6B;QAC1D,OAAO,IAAI,CAAC,OAAO,CAAC,MAAM,CAAC,kBAAkB,UAAU,EAAE,EAAE;YACzD,GAAG,OAAO;YACV,OAAO,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,OAAO,EAAE;SAChD,CAAC,CAAC;IACL,CAAC;CACF;AA3BD,8BA2BC"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
import { APIResource } from "../resource.mjs";
|
|
3
|
+
export class VectorDBs extends APIResource {
|
|
4
|
+
retrieve(vectorDBId, options) {
|
|
5
|
+
return this._client.get(`/v1/vector-dbs/${vectorDBId}`, options);
|
|
6
|
+
}
|
|
7
|
+
list(options) {
|
|
8
|
+
return this._client.get('/v1/vector-dbs', options)._thenUnwrap((obj) => obj.data);
|
|
9
|
+
}
|
|
10
|
+
register(body, options) {
|
|
11
|
+
return this._client.post('/v1/vector-dbs', { body, ...options });
|
|
12
|
+
}
|
|
13
|
+
unregister(vectorDBId, options) {
|
|
14
|
+
return this._client.delete(`/v1/vector-dbs/${vectorDBId}`, {
|
|
15
|
+
...options,
|
|
16
|
+
headers: { Accept: '*/*', ...options?.headers },
|
|
17
|
+
});
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
//# sourceMappingURL=vector-dbs.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"vector-dbs.mjs","sourceRoot":"","sources":["../src/resources/vector-dbs.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;AAGtB,MAAM,OAAO,SAAU,SAAQ,WAAW;IACxC,QAAQ,CACN,UAAkB,EAClB,OAA6B;QAE7B,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,kBAAkB,UAAU,EAAE,EAAE,OAAO,CAAC,CAAC;IACnE,CAAC;IAED,IAAI,CAAC,OAA6B;QAChC,OACE,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,gBAAgB,EAAE,OAAO,CAC3C,CAAC,WAAW,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC;IACnC,CAAC;IAED,QAAQ,CACN,IAA4B,EAC5B,OAA6B;QAE7B,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,gBAAgB,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACnE,CAAC;IAED,UAAU,CAAC,UAAkB,EAAE,OAA6B;QAC1D,OAAO,IAAI,CAAC,OAAO,CAAC,MAAM,CAAC,kBAAkB,UAAU,EAAE,EAAE;YACzD,GAAG,OAAO;YACV,OAAO,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,OAAO,EAAE;SAChD,CAAC,CAAC;IACL,CAAC;CACF"}
|