@od-oneapp/ai-platform 0.1.0
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/README.md +235 -0
- package/dist/agents-base.d.mts +12 -0
- package/dist/agents-base.d.mts.map +1 -0
- package/dist/agents-base.mjs +20 -0
- package/dist/agents-base.mjs.map +1 -0
- package/dist/agents-control-flow.d.mts +115 -0
- package/dist/agents-control-flow.d.mts.map +1 -0
- package/dist/agents-control-flow.mjs +514 -0
- package/dist/agents-control-flow.mjs.map +1 -0
- package/dist/agents-coordinator.d.mts +11 -0
- package/dist/agents-coordinator.d.mts.map +1 -0
- package/dist/agents-coordinator.mjs +12 -0
- package/dist/agents-coordinator.mjs.map +1 -0
- package/dist/agents-experimental.d.mts +153 -0
- package/dist/agents-experimental.d.mts.map +1 -0
- package/dist/agents-experimental.mjs +580 -0
- package/dist/agents-experimental.mjs.map +1 -0
- package/dist/agents-fallback.d.mts +10 -0
- package/dist/agents-fallback.d.mts.map +1 -0
- package/dist/agents-fallback.mjs +15 -0
- package/dist/agents-fallback.mjs.map +1 -0
- package/dist/agents-multi-swarm.d.mts +9 -0
- package/dist/agents-multi-swarm.d.mts.map +1 -0
- package/dist/agents-multi-swarm.mjs +44 -0
- package/dist/agents-multi-swarm.mjs.map +1 -0
- package/dist/agents-multi.d.mts +10 -0
- package/dist/agents-multi.d.mts.map +1 -0
- package/dist/agents-multi.mjs +44 -0
- package/dist/agents-multi.mjs.map +1 -0
- package/dist/agents-observability.d.mts +161 -0
- package/dist/agents-observability.d.mts.map +1 -0
- package/dist/agents-observability.mjs +550 -0
- package/dist/agents-observability.mjs.map +1 -0
- package/dist/agents-patterns.d.mts +9 -0
- package/dist/agents-patterns.d.mts.map +1 -0
- package/dist/agents-patterns.mjs +18 -0
- package/dist/agents-patterns.mjs.map +1 -0
- package/dist/agents-persistence.d.mts +234 -0
- package/dist/agents-persistence.d.mts.map +1 -0
- package/dist/agents-persistence.mjs +447 -0
- package/dist/agents-persistence.mjs.map +1 -0
- package/dist/agents-triage.d.mts +11 -0
- package/dist/agents-triage.d.mts.map +1 -0
- package/dist/agents-triage.mjs +13 -0
- package/dist/agents-triage.mjs.map +1 -0
- package/dist/agents-workflows.d.mts +9 -0
- package/dist/agents-workflows.d.mts.map +1 -0
- package/dist/agents-workflows.mjs +9 -0
- package/dist/agents-workflows.mjs.map +1 -0
- package/dist/agents.d.mts +30 -0
- package/dist/agents.d.mts.map +1 -0
- package/dist/agents.mjs +50 -0
- package/dist/agents.mjs.map +1 -0
- package/dist/aggregation-8KJF1uzp.d.mts +276 -0
- package/dist/aggregation-8KJF1uzp.d.mts.map +1 -0
- package/dist/aggregation-BDop87kL.mjs +1180 -0
- package/dist/aggregation-BDop87kL.mjs.map +1 -0
- package/dist/ai-runtime-CDzQztTt.mjs +85 -0
- package/dist/ai-runtime-CDzQztTt.mjs.map +1 -0
- package/dist/ai-runtime-DIwOEc6g.d.mts +56 -0
- package/dist/ai-runtime-DIwOEc6g.d.mts.map +1 -0
- package/dist/ai-sdk-error-integration-D0GDqrM0.d.mts +553 -0
- package/dist/ai-sdk-error-integration-D0GDqrM0.d.mts.map +1 -0
- package/dist/approval-queue-BcDDQ4oQ.mjs +104 -0
- package/dist/approval-queue-BcDDQ4oQ.mjs.map +1 -0
- package/dist/approval-queue-CiKiFT9z.d.mts +21 -0
- package/dist/approval-queue-CiKiFT9z.d.mts.map +1 -0
- package/dist/audio-BzvN7r10.d.mts +79 -0
- package/dist/audio-BzvN7r10.d.mts.map +1 -0
- package/dist/audio-vBG_62ME.mjs +226 -0
- package/dist/audio-vBG_62ME.mjs.map +1 -0
- package/dist/audit-logger-Bb2JIcIk.d.mts +12 -0
- package/dist/audit-logger-Bb2JIcIk.d.mts.map +1 -0
- package/dist/audit-logger-CHIP8bRO.mjs +596 -0
- package/dist/audit-logger-CHIP8bRO.mjs.map +1 -0
- package/dist/auto-resume-BpUNbPtp.d.mts +160 -0
- package/dist/auto-resume-BpUNbPtp.d.mts.map +1 -0
- package/dist/auto-resume-BuFRNvAX.mjs +638 -0
- package/dist/auto-resume-BuFRNvAX.mjs.map +1 -0
- package/dist/budget-guard-C83KCH9V.d.mts +52 -0
- package/dist/budget-guard-C83KCH9V.d.mts.map +1 -0
- package/dist/budget-guard-d_b5rq4u.mjs +158 -0
- package/dist/budget-guard-d_b5rq4u.mjs.map +1 -0
- package/dist/budget-guard-gyhJS00s.mjs +234 -0
- package/dist/budget-guard-gyhJS00s.mjs.map +1 -0
- package/dist/buffer-BC8mvXHE.d.mts +98 -0
- package/dist/buffer-BC8mvXHE.d.mts.map +1 -0
- package/dist/buffer-CefJGbRy.mjs +289 -0
- package/dist/buffer-CefJGbRy.mjs.map +1 -0
- package/dist/caching-adapters.d.mts +5 -0
- package/dist/caching-adapters.mjs +3 -0
- package/dist/caching-strategies.d.mts +52 -0
- package/dist/caching-strategies.d.mts.map +1 -0
- package/dist/caching-strategies.mjs +703 -0
- package/dist/caching-strategies.mjs.map +1 -0
- package/dist/caching.d.mts +14 -0
- package/dist/caching.d.mts.map +1 -0
- package/dist/caching.mjs +15 -0
- package/dist/caching.mjs.map +1 -0
- package/dist/catalog.d.mts +19 -0
- package/dist/catalog.d.mts.map +1 -0
- package/dist/catalog.mjs +1114 -0
- package/dist/catalog.mjs.map +1 -0
- package/dist/chunk-CkzbjWQW.mjs +20 -0
- package/dist/circuit-breaker-DoKWPORd.mjs +262 -0
- package/dist/circuit-breaker-DoKWPORd.mjs.map +1 -0
- package/dist/circuit-breaker-Mey3E7tW.d.mts +64 -0
- package/dist/circuit-breaker-Mey3E7tW.d.mts.map +1 -0
- package/dist/citation-generator-C-9RpbHq.mjs +103 -0
- package/dist/citation-generator-C-9RpbHq.mjs.map +1 -0
- package/dist/citation-generator-CDSymDs_.d.mts +18 -0
- package/dist/citation-generator-CDSymDs_.d.mts.map +1 -0
- package/dist/client-CpacYDIE.mjs +882 -0
- package/dist/client-CpacYDIE.mjs.map +1 -0
- package/dist/client.d.mts +103 -0
- package/dist/client.d.mts.map +1 -0
- package/dist/client.mjs +470 -0
- package/dist/client.mjs.map +1 -0
- package/dist/compliance-approval-queue-DQGLojAm.mjs +172 -0
- package/dist/compliance-approval-queue-DQGLojAm.mjs.map +1 -0
- package/dist/compliance-approval-queue-IrMxFfSJ.d.mts +99 -0
- package/dist/compliance-approval-queue-IrMxFfSJ.d.mts.map +1 -0
- package/dist/compliance-wrapper-CrOMHhHN.mjs +528 -0
- package/dist/compliance-wrapper-CrOMHhHN.mjs.map +1 -0
- package/dist/conditions-DmQ6Y1Wt.mjs +179 -0
- package/dist/conditions-DmQ6Y1Wt.mjs.map +1 -0
- package/dist/conditions-zDrKfrc3.d.mts +42 -0
- package/dist/conditions-zDrKfrc3.d.mts.map +1 -0
- package/dist/console-BGMxxPZN.mjs +181 -0
- package/dist/console-BGMxxPZN.mjs.map +1 -0
- package/dist/console-DqEqZd4A.d.mts +76 -0
- package/dist/console-DqEqZd4A.d.mts.map +1 -0
- package/dist/controller-BOy3-xbC.mjs +501 -0
- package/dist/controller-BOy3-xbC.mjs.map +1 -0
- package/dist/controller-Y0NGosbJ.d.mts +104 -0
- package/dist/controller-Y0NGosbJ.d.mts.map +1 -0
- package/dist/coordinator-agent-BglqZLwo.d.mts +54 -0
- package/dist/coordinator-agent-BglqZLwo.d.mts.map +1 -0
- package/dist/coordinator-agent-WFWBRL-G.mjs +236 -0
- package/dist/coordinator-agent-WFWBRL-G.mjs.map +1 -0
- package/dist/crypto-8ABhc3TD.mjs +40 -0
- package/dist/crypto-8ABhc3TD.mjs.map +1 -0
- package/dist/environment-CSoJb0SW.mjs +255 -0
- package/dist/environment-CSoJb0SW.mjs.map +1 -0
- package/dist/error-handling-DNVkm6RY.mjs +1334 -0
- package/dist/error-handling-DNVkm6RY.mjs.map +1 -0
- package/dist/errors-CQ8tF4dP.mjs +985 -0
- package/dist/errors-CQ8tF4dP.mjs.map +1 -0
- package/dist/errors-CfYdVeum.d.mts +212 -0
- package/dist/errors-CfYdVeum.d.mts.map +1 -0
- package/dist/errors-Dtn-UeRi.mjs +61 -0
- package/dist/errors-Dtn-UeRi.mjs.map +1 -0
- package/dist/evaluator-Cs84qkr8.mjs +91 -0
- package/dist/evaluator-Cs84qkr8.mjs.map +1 -0
- package/dist/evaluator-optimizer-De67_mJC.mjs +1086 -0
- package/dist/evaluator-optimizer-De67_mJC.mjs.map +1 -0
- package/dist/evaluator-optimizer-pattern-B5939s2Z.mjs +367 -0
- package/dist/evaluator-optimizer-pattern-B5939s2Z.mjs.map +1 -0
- package/dist/evaluator-optimizer-pattern-D1AJrzBD.d.mts +72 -0
- package/dist/evaluator-optimizer-pattern-D1AJrzBD.d.mts.map +1 -0
- package/dist/factory-DP6VSl8C.mjs +307 -0
- package/dist/factory-DP6VSl8C.mjs.map +1 -0
- package/dist/generative-ui-catalog.d.mts +8 -0
- package/dist/generative-ui-catalog.d.mts.map +1 -0
- package/dist/generative-ui-catalog.mjs +679 -0
- package/dist/generative-ui-catalog.mjs.map +1 -0
- package/dist/generative-ui-registry.d.mts +195 -0
- package/dist/generative-ui-registry.d.mts.map +1 -0
- package/dist/generative-ui-registry.mjs +250 -0
- package/dist/generative-ui-registry.mjs.map +1 -0
- package/dist/generative-ui-stream.d.mts +23 -0
- package/dist/generative-ui-stream.d.mts.map +1 -0
- package/dist/generative-ui-stream.mjs +219 -0
- package/dist/generative-ui-stream.mjs.map +1 -0
- package/dist/generative-ui-types.d.mts +123 -0
- package/dist/generative-ui-types.d.mts.map +1 -0
- package/dist/generative-ui-types.mjs +1 -0
- package/dist/generative-ui.d.mts +13 -0
- package/dist/generative-ui.d.mts.map +1 -0
- package/dist/generative-ui.mjs +21 -0
- package/dist/generative-ui.mjs.map +1 -0
- package/dist/governance-audit.d.mts +3 -0
- package/dist/governance-audit.mjs +3 -0
- package/dist/governance-compliance.d.mts +5 -0
- package/dist/governance-compliance.mjs +4 -0
- package/dist/governance-policies.d.mts +4 -0
- package/dist/governance-policies.mjs +4 -0
- package/dist/governance-tenancy.d.mts +3 -0
- package/dist/governance-tenancy.mjs +3 -0
- package/dist/governance.d.mts +88 -0
- package/dist/governance.d.mts.map +1 -0
- package/dist/governance.mjs +432 -0
- package/dist/governance.mjs.map +1 -0
- package/dist/grounding-attribution.d.mts +63 -0
- package/dist/grounding-attribution.d.mts.map +1 -0
- package/dist/grounding-attribution.mjs +259 -0
- package/dist/grounding-attribution.mjs.map +1 -0
- package/dist/grounding-citation.d.mts +2 -0
- package/dist/grounding-citation.mjs +3 -0
- package/dist/grounding-context.d.mts +9 -0
- package/dist/grounding-context.d.mts.map +1 -0
- package/dist/grounding-context.mjs +19 -0
- package/dist/grounding-context.mjs.map +1 -0
- package/dist/grounding-embed.d.mts +102 -0
- package/dist/grounding-embed.d.mts.map +1 -0
- package/dist/grounding-embed.mjs +417 -0
- package/dist/grounding-embed.mjs.map +1 -0
- package/dist/grounding-hallucination.d.mts +44 -0
- package/dist/grounding-hallucination.d.mts.map +1 -0
- package/dist/grounding-hallucination.mjs +115 -0
- package/dist/grounding-hallucination.mjs.map +1 -0
- package/dist/grounding-proof-map.d.mts +9 -0
- package/dist/grounding-proof-map.d.mts.map +1 -0
- package/dist/grounding-proof-map.mjs +26 -0
- package/dist/grounding-proof-map.mjs.map +1 -0
- package/dist/grounding-rag.d.mts +10 -0
- package/dist/grounding-rag.d.mts.map +1 -0
- package/dist/grounding-rag.mjs +27 -0
- package/dist/grounding-rag.mjs.map +1 -0
- package/dist/grounding-verification.d.mts +48 -0
- package/dist/grounding-verification.d.mts.map +1 -0
- package/dist/grounding-verification.mjs +224 -0
- package/dist/grounding-verification.mjs.map +1 -0
- package/dist/grounding.d.mts +24 -0
- package/dist/grounding.d.mts.map +1 -0
- package/dist/grounding.mjs +77 -0
- package/dist/grounding.mjs.map +1 -0
- package/dist/hitl-active-learning.d.mts +41 -0
- package/dist/hitl-active-learning.d.mts.map +1 -0
- package/dist/hitl-active-learning.mjs +178 -0
- package/dist/hitl-active-learning.mjs.map +1 -0
- package/dist/hitl-annotation.d.mts +74 -0
- package/dist/hitl-annotation.d.mts.map +1 -0
- package/dist/hitl-annotation.mjs +170 -0
- package/dist/hitl-annotation.mjs.map +1 -0
- package/dist/hitl-approval.d.mts +2 -0
- package/dist/hitl-approval.mjs +3 -0
- package/dist/hitl-feedback.d.mts +59 -0
- package/dist/hitl-feedback.d.mts.map +1 -0
- package/dist/hitl-feedback.mjs +137 -0
- package/dist/hitl-feedback.mjs.map +1 -0
- package/dist/hitl-review.d.mts +2 -0
- package/dist/hitl-review.mjs +3 -0
- package/dist/hitl.d.mts +14 -0
- package/dist/hitl.d.mts.map +1 -0
- package/dist/hitl.mjs +22 -0
- package/dist/hitl.mjs.map +1 -0
- package/dist/index-B17HT-VL.d.mts +285 -0
- package/dist/index-B17HT-VL.d.mts.map +1 -0
- package/dist/index-BDwgsK9B.d.mts +101 -0
- package/dist/index-BDwgsK9B.d.mts.map +1 -0
- package/dist/index-BGgMn_Ev.d.mts +2615 -0
- package/dist/index-BGgMn_Ev.d.mts.map +1 -0
- package/dist/index-DOqe5r9G.d.mts +318 -0
- package/dist/index-DOqe5r9G.d.mts.map +1 -0
- package/dist/index-DotINT7o.d.mts +1004 -0
- package/dist/index-DotINT7o.d.mts.map +1 -0
- package/dist/index-URlW7aD1.d.mts +67 -0
- package/dist/index-URlW7aD1.d.mts.map +1 -0
- package/dist/index.d.mts +64 -0
- package/dist/index.d.mts.map +1 -0
- package/dist/index.mjs +46 -0
- package/dist/index.mjs.map +1 -0
- package/dist/integrations-blob-storage.d.mts +25 -0
- package/dist/integrations-blob-storage.d.mts.map +1 -0
- package/dist/integrations-blob-storage.mjs +3 -0
- package/dist/integrations-notifications.d.mts +2 -0
- package/dist/integrations-notifications.mjs +3 -0
- package/dist/integrations-rate-limit.d.mts +27 -0
- package/dist/integrations-rate-limit.d.mts.map +1 -0
- package/dist/integrations-rate-limit.mjs +30 -0
- package/dist/integrations-rate-limit.mjs.map +1 -0
- package/dist/integrations-redis.d.mts +3 -0
- package/dist/integrations-redis.mjs +3 -0
- package/dist/integrations-stream.d.mts +14 -0
- package/dist/integrations-stream.d.mts.map +1 -0
- package/dist/integrations-stream.mjs +3 -0
- package/dist/integrations.d.mts +7 -0
- package/dist/integrations.mjs +7 -0
- package/dist/log-adapter-BLegSZtz.d.mts +16 -0
- package/dist/log-adapter-BLegSZtz.d.mts.map +1 -0
- package/dist/log-adapter-PPe_2Pwv.mjs +28 -0
- package/dist/log-adapter-PPe_2Pwv.mjs.map +1 -0
- package/dist/loop-BOYEtr2g.mjs +520 -0
- package/dist/loop-BOYEtr2g.mjs.map +1 -0
- package/dist/loop-C-tBBOqi.d.mts +219 -0
- package/dist/loop-C-tBBOqi.d.mts.map +1 -0
- package/dist/middleware-5wQ9bANW.mjs +306 -0
- package/dist/middleware-5wQ9bANW.mjs.map +1 -0
- package/dist/middleware-C1apSrj0.mjs +613 -0
- package/dist/middleware-C1apSrj0.mjs.map +1 -0
- package/dist/middleware-C7k0uItW.d.mts +9 -0
- package/dist/middleware-C7k0uItW.d.mts.map +1 -0
- package/dist/middleware-CZQCTHfl.mjs +366 -0
- package/dist/middleware-CZQCTHfl.mjs.map +1 -0
- package/dist/models.d.mts +11 -0
- package/dist/models.d.mts.map +1 -0
- package/dist/models.mjs +32 -0
- package/dist/models.mjs.map +1 -0
- package/dist/observability-analytics.d.mts +107 -0
- package/dist/observability-analytics.d.mts.map +1 -0
- package/dist/observability-analytics.mjs +409 -0
- package/dist/observability-analytics.mjs.map +1 -0
- package/dist/observability-cost.d.mts +10 -0
- package/dist/observability-cost.d.mts.map +1 -0
- package/dist/observability-cost.mjs +15 -0
- package/dist/observability-cost.mjs.map +1 -0
- package/dist/observability-telemetry.d.mts +111 -0
- package/dist/observability-telemetry.d.mts.map +1 -0
- package/dist/observability-telemetry.mjs +343 -0
- package/dist/observability-telemetry.mjs.map +1 -0
- package/dist/observability-tracing.d.mts +10 -0
- package/dist/observability-tracing.d.mts.map +1 -0
- package/dist/observability-tracing.mjs +17 -0
- package/dist/observability-tracing.mjs.map +1 -0
- package/dist/observability.d.mts +15 -0
- package/dist/observability.d.mts.map +1 -0
- package/dist/observability.mjs +17 -0
- package/dist/observability.mjs.map +1 -0
- package/dist/optimizer-DhXXpci6.mjs +97 -0
- package/dist/optimizer-DhXXpci6.mjs.map +1 -0
- package/dist/output-multimodal.d.mts +9 -0
- package/dist/output-multimodal.d.mts.map +1 -0
- package/dist/output-multimodal.mjs +18 -0
- package/dist/output-multimodal.mjs.map +1 -0
- package/dist/output.d.mts +11 -0
- package/dist/output.d.mts.map +1 -0
- package/dist/output.mjs +40 -0
- package/dist/output.mjs.map +1 -0
- package/dist/pii-filter-3AxmYSiu.d.mts +23 -0
- package/dist/pii-filter-3AxmYSiu.d.mts.map +1 -0
- package/dist/pipelines.d.mts +448 -0
- package/dist/pipelines.d.mts.map +1 -0
- package/dist/pipelines.mjs +1534 -0
- package/dist/pipelines.mjs.map +1 -0
- package/dist/prompt-injection-DQXchzsV.d.mts +8 -0
- package/dist/prompt-injection-DQXchzsV.d.mts.map +1 -0
- package/dist/prompt-injection-RpoLPwSa.mjs +52 -0
- package/dist/prompt-injection-RpoLPwSa.mjs.map +1 -0
- package/dist/prompts.d.mts +192 -0
- package/dist/prompts.d.mts.map +1 -0
- package/dist/prompts.mjs +732 -0
- package/dist/prompts.mjs.map +1 -0
- package/dist/protocol-DfBiEsnl.d.mts +112 -0
- package/dist/protocol-DfBiEsnl.d.mts.map +1 -0
- package/dist/quota-manager-0iPMkQWN.d.mts +62 -0
- package/dist/quota-manager-0iPMkQWN.d.mts.map +1 -0
- package/dist/quota-manager-D_N7FuQ2.mjs +180 -0
- package/dist/quota-manager-D_N7FuQ2.mjs.map +1 -0
- package/dist/redaction-utils-DcQwsiNh.mjs +438 -0
- package/dist/redaction-utils-DcQwsiNh.mjs.map +1 -0
- package/dist/redis-CpsSrF8K.mjs +102 -0
- package/dist/redis-CpsSrF8K.mjs.map +1 -0
- package/dist/redis-CwguYFGh.d.mts +33 -0
- package/dist/redis-CwguYFGh.d.mts.map +1 -0
- package/dist/registry-CsD3iTIx.mjs +190 -0
- package/dist/registry-CsD3iTIx.mjs.map +1 -0
- package/dist/registry-DVPWzkXR.d.mts +36 -0
- package/dist/registry-DVPWzkXR.d.mts.map +1 -0
- package/dist/reranking-BpWYhYzl.d.mts +72 -0
- package/dist/reranking-BpWYhYzl.d.mts.map +1 -0
- package/dist/reranking-Ck8aKZW7.mjs +331 -0
- package/dist/reranking-Ck8aKZW7.mjs.map +1 -0
- package/dist/resumable-adapter-CO1HtsgJ.mjs +21 -0
- package/dist/resumable-adapter-CO1HtsgJ.mjs.map +1 -0
- package/dist/review-trigger-DmAsiQlM.d.mts +24 -0
- package/dist/review-trigger-DmAsiQlM.d.mts.map +1 -0
- package/dist/review-trigger-DwXfpww9.mjs +112 -0
- package/dist/review-trigger-DwXfpww9.mjs.map +1 -0
- package/dist/safe-context-BynhkTKR.d.mts +54 -0
- package/dist/safe-context-BynhkTKR.d.mts.map +1 -0
- package/dist/safe-context-C5A3Wv3b.mjs +143 -0
- package/dist/safe-context-C5A3Wv3b.mjs.map +1 -0
- package/dist/schema-Bu2noOZ4.mjs +27 -0
- package/dist/schema-Bu2noOZ4.mjs.map +1 -0
- package/dist/schema-CwFvuCnA.mjs +97 -0
- package/dist/schema-CwFvuCnA.mjs.map +1 -0
- package/dist/schema-Wz-1-ro9.d.mts +37 -0
- package/dist/schema-Wz-1-ro9.d.mts.map +1 -0
- package/dist/schemas-CxQtxIga.mjs +62 -0
- package/dist/schemas-CxQtxIga.mjs.map +1 -0
- package/dist/schemas-DBOhxgW7.d.mts +32 -0
- package/dist/schemas-DBOhxgW7.d.mts.map +1 -0
- package/dist/schemas-Dp_OCqBt.d.mts +63 -0
- package/dist/schemas-Dp_OCqBt.d.mts.map +1 -0
- package/dist/schemas-SwCsnT0z.mjs +83 -0
- package/dist/schemas-SwCsnT0z.mjs.map +1 -0
- package/dist/sdk-errors.d.mts +2 -0
- package/dist/sdk-errors.mjs +3 -0
- package/dist/sdk-experimental.d.mts +59 -0
- package/dist/sdk-experimental.d.mts.map +1 -0
- package/dist/sdk-experimental.mjs +193 -0
- package/dist/sdk-experimental.mjs.map +1 -0
- package/dist/sdk-stop-conditions.d.mts +3 -0
- package/dist/sdk-stop-conditions.mjs +3 -0
- package/dist/sdk.d.mts +15 -0
- package/dist/sdk.d.mts.map +1 -0
- package/dist/sdk.mjs +50 -0
- package/dist/sdk.mjs.map +1 -0
- package/dist/security-guardrails.d.mts +3 -0
- package/dist/security-guardrails.mjs +3 -0
- package/dist/security-injection.d.mts +2 -0
- package/dist/security-injection.mjs +3 -0
- package/dist/security.d.mts +12 -0
- package/dist/security.d.mts.map +1 -0
- package/dist/security.mjs +18 -0
- package/dist/security.mjs.map +1 -0
- package/dist/server.d.mts +420 -0
- package/dist/server.d.mts.map +1 -0
- package/dist/server.mjs +2225 -0
- package/dist/server.mjs.map +1 -0
- package/dist/shared.d.mts +2 -0
- package/dist/shared.mjs +3 -0
- package/dist/streaming-control.d.mts +2 -0
- package/dist/streaming-control.mjs +4 -0
- package/dist/streaming-core.d.mts +4 -0
- package/dist/streaming-core.mjs +3 -0
- package/dist/streaming-infra-resilience.d.mts +120 -0
- package/dist/streaming-infra-resilience.d.mts.map +1 -0
- package/dist/streaming-infra-resilience.mjs +358 -0
- package/dist/streaming-infra-resilience.mjs.map +1 -0
- package/dist/streaming-infra-transport.d.mts +57 -0
- package/dist/streaming-infra-transport.d.mts.map +1 -0
- package/dist/streaming-infra-transport.mjs +488 -0
- package/dist/streaming-infra-transport.mjs.map +1 -0
- package/dist/streaming-infra.d.mts +5 -0
- package/dist/streaming-infra.mjs +5 -0
- package/dist/streaming.d.mts +17 -0
- package/dist/streaming.d.mts.map +1 -0
- package/dist/streaming.mjs +71 -0
- package/dist/streaming.mjs.map +1 -0
- package/dist/telemetry-2eKMojIb.mjs +1046 -0
- package/dist/telemetry-2eKMojIb.mjs.map +1 -0
- package/dist/telemetry-C2t03dwD.d.mts +59 -0
- package/dist/telemetry-C2t03dwD.d.mts.map +1 -0
- package/dist/tool-Btbththq.d.mts +253 -0
- package/dist/tool-Btbththq.d.mts.map +1 -0
- package/dist/tool-JSf8JXZ8.mjs +1150 -0
- package/dist/tool-JSf8JXZ8.mjs.map +1 -0
- package/dist/tool-safety-CZO8a4D4.d.mts +60 -0
- package/dist/tool-safety-CZO8a4D4.d.mts.map +1 -0
- package/dist/tool-safety-DXtYDXod.mjs +319 -0
- package/dist/tool-safety-DXtYDXod.mjs.map +1 -0
- package/dist/tools-BuS2Uv0q.mjs +1708 -0
- package/dist/tools-BuS2Uv0q.mjs.map +1 -0
- package/dist/tools-approval.d.mts +99 -0
- package/dist/tools-approval.d.mts.map +1 -0
- package/dist/tools-approval.mjs +395 -0
- package/dist/tools-approval.mjs.map +1 -0
- package/dist/tools-compliance.d.mts +67 -0
- package/dist/tools-compliance.d.mts.map +1 -0
- package/dist/tools-compliance.mjs +330 -0
- package/dist/tools-compliance.mjs.map +1 -0
- package/dist/tools-computer.d.mts +25 -0
- package/dist/tools-computer.d.mts.map +1 -0
- package/dist/tools-computer.mjs +64 -0
- package/dist/tools-computer.mjs.map +1 -0
- package/dist/tools-core.d.mts +3 -0
- package/dist/tools-core.mjs +3 -0
- package/dist/tools-mcp.d.mts +3 -0
- package/dist/tools-mcp.mjs +5 -0
- package/dist/tools-superpowers.d.mts +2 -0
- package/dist/tools-superpowers.mjs +3 -0
- package/dist/tools.d.mts +401 -0
- package/dist/tools.d.mts.map +1 -0
- package/dist/tools.mjs +1921 -0
- package/dist/tools.mjs.map +1 -0
- package/dist/transport-selector-D-Ib05X1.mjs +1936 -0
- package/dist/transport-selector-D-Ib05X1.mjs.map +1 -0
- package/dist/triage-agent-BEsXg5sw.d.mts +63 -0
- package/dist/triage-agent-BEsXg5sw.d.mts.map +1 -0
- package/dist/triage-agent-CBsfX-HW.mjs +167 -0
- package/dist/triage-agent-CBsfX-HW.mjs.map +1 -0
- package/dist/types-BPnq3GQo.d.mts +23 -0
- package/dist/types-BPnq3GQo.d.mts.map +1 -0
- package/dist/types-BjWgimpY.d.mts +16 -0
- package/dist/types-BjWgimpY.d.mts.map +1 -0
- package/dist/types-BxD-5btB.d.mts +41 -0
- package/dist/types-BxD-5btB.d.mts.map +1 -0
- package/dist/types-By-r93bE.d.mts +36 -0
- package/dist/types-By-r93bE.d.mts.map +1 -0
- package/dist/types-CLBWFRZN.d.mts +69 -0
- package/dist/types-CLBWFRZN.d.mts.map +1 -0
- package/dist/types-CQ0HFd0u.d.mts +62 -0
- package/dist/types-CQ0HFd0u.d.mts.map +1 -0
- package/dist/types-D3zJb59_.d.mts +47 -0
- package/dist/types-D3zJb59_.d.mts.map +1 -0
- package/dist/types-DJnugQX0.d.mts +80 -0
- package/dist/types-DJnugQX0.d.mts.map +1 -0
- package/dist/types-DbUfMCnT.d.mts +70 -0
- package/dist/types-DbUfMCnT.d.mts.map +1 -0
- package/dist/upstash-adapter-D96Caq2O.mjs +22 -0
- package/dist/upstash-adapter-D96Caq2O.mjs.map +1 -0
- package/dist/upstash-adapter-DD4433dx.d.mts +8 -0
- package/dist/upstash-adapter-DD4433dx.d.mts.map +1 -0
- package/dist/utils-BlYhcD6M.mjs +319 -0
- package/dist/utils-BlYhcD6M.mjs.map +1 -0
- package/dist/utils-DpJGOb3y.d.mts +120 -0
- package/dist/utils-DpJGOb3y.d.mts.map +1 -0
- package/dist/vercel-blob-adapter-CkOXLT2D.mjs +25 -0
- package/dist/vercel-blob-adapter-CkOXLT2D.mjs.map +1 -0
- package/dist/xai-CbV_dCnP.mjs +1600 -0
- package/dist/xai-CbV_dCnP.mjs.map +1 -0
- package/package.json +479 -0
- package/src/agents/base/factory.ts +382 -0
- package/src/agents/base/index.ts +8 -0
- package/src/agents/base/schemas.ts +117 -0
- package/src/agents/base/types.ts +192 -0
- package/src/agents/control-flow/index.ts +683 -0
- package/src/agents/coordinator/coordinator-agent.ts +381 -0
- package/src/agents/coordinator/index.ts +6 -0
- package/src/agents/default-agent.ts +211 -0
- package/src/agents/evaluator-optimizer/README.md +612 -0
- package/src/agents/evaluator-optimizer/evaluator-optimizer.example.ts +437 -0
- package/src/agents/evaluator-optimizer/evaluator.ts +282 -0
- package/src/agents/evaluator-optimizer/index.test.ts +416 -0
- package/src/agents/evaluator-optimizer/index.ts +519 -0
- package/src/agents/evaluator-optimizer/optimizer.ts +322 -0
- package/src/agents/evaluator-optimizer/schema.ts +302 -0
- package/src/agents/evaluator-optimizer/utils.ts +42 -0
- package/src/agents/experimental/index.ts +1095 -0
- package/src/agents/experimental/types.ts +212 -0
- package/src/agents/fallback/index.ts +18 -0
- package/src/agents/fallback/recovery/circuit-breaker.ts +166 -0
- package/src/agents/fallback/strategies/model-fallback.ts +192 -0
- package/src/agents/fallback/types.ts +87 -0
- package/src/agents/governance-agent.ts +446 -0
- package/src/agents/index.ts +79 -0
- package/src/agents/multi/coordination/index.ts +6 -0
- package/src/agents/multi/coordination/message-bus.ts +144 -0
- package/src/agents/multi/index.ts +6 -0
- package/src/agents/multi/state/index.ts +162 -0
- package/src/agents/multi/supervisor/index.ts +7 -0
- package/src/agents/multi/supervisor/supervisor.ts +254 -0
- package/src/agents/multi/swarm/aggregation.ts +466 -0
- package/src/agents/multi/swarm/communication.ts +388 -0
- package/src/agents/multi/swarm/coordination.ts +380 -0
- package/src/agents/multi/swarm/index.ts +73 -0
- package/src/agents/multi/swarm/swarm-executor.ts +479 -0
- package/src/agents/multi/types.ts +181 -0
- package/src/agents/observability/index.ts +914 -0
- package/src/agents/orchestrator.ts +218 -0
- package/src/agents/patterns/README.md +512 -0
- package/src/agents/patterns/evaluator-optimizer-pattern.example.ts +455 -0
- package/src/agents/patterns/evaluator-optimizer-pattern.ts +653 -0
- package/src/agents/patterns/index.ts +26 -0
- package/src/agents/persistence/index.ts +726 -0
- package/src/agents/tools/index.ts +291 -0
- package/src/agents/tools/mcp.ts +188 -0
- package/src/agents/triage/index.ts +6 -0
- package/src/agents/triage/triage-agent.ts +280 -0
- package/src/agents/workflows/index.ts +6 -0
- package/src/agents/workflows/interfaces.ts +36 -0
- package/src/agents/workflows/schema.ts +20 -0
- package/src/caching/adapters/index.ts +7 -0
- package/src/caching/adapters/memory.ts +77 -0
- package/src/caching/adapters/redis.ts +60 -0
- package/src/caching/index.ts +17 -0
- package/src/caching/middleware.ts +452 -0
- package/src/caching/strategies/index.ts +1008 -0
- package/src/caching/types.ts +47 -0
- package/src/catalog.ts +921 -0
- package/src/client/chat-usage.ts +53 -0
- package/src/client/hooks.ts +343 -0
- package/src/client/index.ts +36 -0
- package/src/client/message-utils.ts +29 -0
- package/src/client/use-generative-ui.ts +174 -0
- package/src/client/utils.ts +66 -0
- package/src/generative-ui/catalog.ts +653 -0
- package/src/generative-ui/index.ts +82 -0
- package/src/generative-ui/registry.ts +273 -0
- package/src/generative-ui/stream.ts +324 -0
- package/src/generative-ui/types.ts +376 -0
- package/src/governance/audit/audit-logger.ts +239 -0
- package/src/governance/audit/audit-schema.ts +82 -0
- package/src/governance/audit/index.ts +6 -0
- package/src/governance/compliance/abac/policy-engine.ts +175 -0
- package/src/governance/compliance/abac/types.ts +40 -0
- package/src/governance/compliance/approval/compliance-approval-queue.ts +217 -0
- package/src/governance/compliance/index.ts +16 -0
- package/src/governance/compliance/schemas.ts +68 -0
- package/src/governance/compliance/types.ts +143 -0
- package/src/governance/compliance/validators/phi-detector.ts +145 -0
- package/src/governance/compliance/validators/redaction-utils.ts +176 -0
- package/src/governance/compliance/validators/safe-harbor.ts +135 -0
- package/src/governance/entitlements/index.ts +585 -0
- package/src/governance/entitlements/middleware.ts +651 -0
- package/src/governance/entitlements/rate-limiter.ts +711 -0
- package/src/governance/index.ts +32 -0
- package/src/governance/policies/guardrails.ts +1121 -0
- package/src/governance/policies/index.ts +42 -0
- package/src/governance/policies/loop-controls.ts +136 -0
- package/src/governance/policies/telemetry.ts +63 -0
- package/src/governance/tenancy/index.ts +30 -0
- package/src/governance/tenancy/isolation/context.ts +92 -0
- package/src/governance/tenancy/isolation/index.ts +13 -0
- package/src/governance/tenancy/quotas/index.ts +11 -0
- package/src/governance/tenancy/quotas/quota-manager.ts +180 -0
- package/src/governance/tenancy/types.ts +66 -0
- package/src/governance/types.ts +16 -0
- package/src/governance/versioning/index.ts +573 -0
- package/src/grounding/attribution/index.ts +424 -0
- package/src/grounding/citation/citation-generator.ts +174 -0
- package/src/grounding/citation/index.ts +12 -0
- package/src/grounding/context/index.ts +32 -0
- package/src/grounding/context/safe-context.ts +116 -0
- package/src/grounding/context/types.ts +62 -0
- package/src/grounding/context-engineering/error-handling.ts +359 -0
- package/src/grounding/context-engineering/index.ts +23 -0
- package/src/grounding/context-engineering/memory.ts +559 -0
- package/src/grounding/context-engineering/tool-masking.ts +338 -0
- package/src/grounding/embed/index.ts +704 -0
- package/src/grounding/embed/reranking.ts +604 -0
- package/src/grounding/hallucination/index.ts +223 -0
- package/src/grounding/index.ts +82 -0
- package/src/grounding/proof-map/applyPatch.ts +172 -0
- package/src/grounding/proof-map/index.ts +41 -0
- package/src/grounding/proof-map/loop.ts +275 -0
- package/src/grounding/proof-map/schema.ts +217 -0
- package/src/grounding/rag/__tests__/pipeline.test.ts +274 -0
- package/src/grounding/rag/__tests__/tool.test.ts +202 -0
- package/src/grounding/rag/__tests__/trace.test.ts +229 -0
- package/src/grounding/rag/circuit-breaker.ts +152 -0
- package/src/grounding/rag/index.ts +64 -0
- package/src/grounding/rag/pipeline.ts +602 -0
- package/src/grounding/rag/tool.ts +281 -0
- package/src/grounding/rag/trace.ts +503 -0
- package/src/grounding/rag/types.ts +284 -0
- package/src/grounding/retrieval/in-memory-store.ts +107 -0
- package/src/grounding/sources/index.ts +943 -0
- package/src/grounding/tests/applyPatch.test.ts +194 -0
- package/src/grounding/tests/loop.test.ts +141 -0
- package/src/grounding/tests/schema.test.ts +160 -0
- package/src/grounding/types.ts +100 -0
- package/src/grounding/verification/index.ts +419 -0
- package/src/hitl/active-learning/index.ts +332 -0
- package/src/hitl/annotation/index.ts +362 -0
- package/src/hitl/approval/approval-queue.ts +132 -0
- package/src/hitl/approval/index.ts +5 -0
- package/src/hitl/feedback/index.ts +284 -0
- package/src/hitl/index.ts +69 -0
- package/src/hitl/review/index.ts +6 -0
- package/src/hitl/review/review-trigger.ts +162 -0
- package/src/hitl/types.ts +126 -0
- package/src/index.ts +125 -0
- package/src/integrations/blob-storage/index.ts +7 -0
- package/src/integrations/blob-storage/types.ts +28 -0
- package/src/integrations/blob-storage/vercel-blob-adapter.ts +35 -0
- package/src/integrations/index.ts +15 -0
- package/src/integrations/notifications/index.ts +7 -0
- package/src/integrations/notifications/log-adapter.ts +30 -0
- package/src/integrations/notifications/types.ts +27 -0
- package/src/integrations/rate-limit/index.ts +7 -0
- package/src/integrations/rate-limit/types.ts +26 -0
- package/src/integrations/rate-limit/upstash-adapter.ts +45 -0
- package/src/integrations/redis/index.ts +7 -0
- package/src/integrations/redis/types.ts +67 -0
- package/src/integrations/redis/upstash-adapter.ts +18 -0
- package/src/integrations/stream/index.ts +7 -0
- package/src/integrations/stream/resumable-adapter.ts +20 -0
- package/src/integrations/stream/types.ts +21 -0
- package/src/internal/__tests__/hallucination.test.ts +162 -0
- package/src/internal/__tests__/models.test.ts +104 -0
- package/src/internal/__tests__/sdk-errors.test.ts +201 -0
- package/src/internal/__tests__/stop-conditions.test.ts +210 -0
- package/src/internal/shared/ai-types.ts +942 -0
- package/src/internal/testing/evaluators.ts +575 -0
- package/src/internal/testing/index.ts +960 -0
- package/src/internal/ui/data-parts.ts +511 -0
- package/src/internal/ui/type-guards.ts +344 -0
- package/src/internal/ui-factories/__tests__/ui-factories.test.ts +548 -0
- package/src/internal/ui-factories/artifact-factory.ts +667 -0
- package/src/internal/ui-factories/index.ts +82 -0
- package/src/internal/ui-factories/shimmer-manager.ts +220 -0
- package/src/internal/ui-factories/status-helpers.ts +149 -0
- package/src/internal/ui-factories/tool-renderer.ts +167 -0
- package/src/internal/ui-factories/types.ts +235 -0
- package/src/models/capabilities.ts +88 -0
- package/src/models/index.ts +16 -0
- package/src/models/provider-factory.ts +229 -0
- package/src/models/providers/anthropic.ts +539 -0
- package/src/models/providers/google.ts +354 -0
- package/src/models/providers/index.ts +21 -0
- package/src/models/providers/openai.ts +346 -0
- package/src/models/providers/perplexity.ts +276 -0
- package/src/models/providers/shared.ts +90 -0
- package/src/models/providers/xai.ts +269 -0
- package/src/models/registry.ts +208 -0
- package/src/models/routing/index.ts +45 -0
- package/src/models/routing/intent-router.ts +143 -0
- package/src/models/routing/model-router.ts +300 -0
- package/src/models/routing/types.ts +106 -0
- package/src/models/types.ts +23 -0
- package/src/observability/analytics/index.ts +593 -0
- package/src/observability/cost/index.ts +16 -0
- package/src/observability/cost/tracking/budget-guard.ts +110 -0
- package/src/observability/cost/tracking/usage-tracker.ts +120 -0
- package/src/observability/cost/types.ts +85 -0
- package/src/observability/index.ts +17 -0
- package/src/observability/telemetry/index.ts +508 -0
- package/src/observability/tracing/index.ts +30 -0
- package/src/observability/tracing/otel/ai-instrumentation.ts +193 -0
- package/src/observability/tracing/otel/exporters/console.ts +58 -0
- package/src/observability/tracing/otel/exporters/index.ts +6 -0
- package/src/observability/tracing/provenance.ts +769 -0
- package/src/observability/tracing/types.ts +92 -0
- package/src/output/__tests__/output.test.ts +737 -0
- package/src/output/element-stream.ts +678 -0
- package/src/output/errors.ts +108 -0
- package/src/output/factories.ts +392 -0
- package/src/output/index.ts +98 -0
- package/src/output/multimodal/EXPORTS.md +306 -0
- package/src/output/multimodal/IMPLEMENTATION_SUMMARY.md +421 -0
- package/src/output/multimodal/README.md +349 -0
- package/src/output/multimodal/SETUP_GUIDE.md +472 -0
- package/src/output/multimodal/audio.ts +650 -0
- package/src/output/multimodal/image.ts +22 -0
- package/src/output/multimodal/index.ts +32 -0
- package/src/output/multimodal/providers.example.ts +375 -0
- package/src/output/validator.ts +495 -0
- package/src/pipelines/adapters/trace-storage-blob.ts +458 -0
- package/src/pipelines/adapters/trace-storage-memory.ts +319 -0
- package/src/pipelines/defaults.ts +109 -0
- package/src/pipelines/index.ts +24 -0
- package/src/pipelines/message-transforms.ts +107 -0
- package/src/pipelines/multi-step-wrapper.ts +433 -0
- package/src/pipelines/pipeline-presets.ts +339 -0
- package/src/pipelines/step-executor.ts +257 -0
- package/src/pipelines/storage-factory.ts +85 -0
- package/src/pipelines/trace-storage-interface.ts +216 -0
- package/src/pipelines/types.ts +255 -0
- package/src/pipelines/validation.ts +323 -0
- package/src/prompts/index.ts +271 -0
- package/src/prompts/model-variants.ts +410 -0
- package/src/prompts/templates.ts +327 -0
- package/src/sdk/errors/base.ts +296 -0
- package/src/sdk/errors/index.ts +31 -0
- package/src/sdk/errors/utils.ts +148 -0
- package/src/sdk/experimental/index.ts +286 -0
- package/src/sdk/index.ts +25 -0
- package/src/sdk/middleware/ai-middleware.ts +95 -0
- package/src/sdk/middleware/cache.ts +154 -0
- package/src/sdk/middleware/circuit-breaker.ts +388 -0
- package/src/sdk/middleware/compose.ts +81 -0
- package/src/sdk/middleware/deduplication.ts +307 -0
- package/src/sdk/middleware/index.ts +660 -0
- package/src/sdk/middleware/model-middleware.ts +200 -0
- package/src/sdk/stop-conditions/conditions.ts +209 -0
- package/src/sdk/stop-conditions/index.ts +35 -0
- package/src/sdk/stop-conditions/types.ts +59 -0
- package/src/security/guardrails/index.ts +6 -0
- package/src/security/guardrails/middleware.ts +465 -0
- package/src/security/guardrails/pii-filter.ts +396 -0
- package/src/security/index.ts +33 -0
- package/src/security/injection/index.ts +5 -0
- package/src/security/injection/prompt-injection.ts +64 -0
- package/src/security/types.ts +85 -0
- package/src/server/cache/crypto.ts +47 -0
- package/src/server/cache/performance.ts +79 -0
- package/src/server/error-handler.ts +93 -0
- package/src/server/errors.ts +73 -0
- package/src/server/helpers.ts +944 -0
- package/src/server/http.ts +156 -0
- package/src/server/index.ts +12 -0
- package/src/server/messages/__tests__/messages.test.ts +720 -0
- package/src/server/messages/converter.ts +245 -0
- package/src/server/messages/data-parts.ts +338 -0
- package/src/server/messages/extraction.ts +328 -0
- package/src/server/messages/index.ts +126 -0
- package/src/server/messages/types.ts +355 -0
- package/src/server/messages/window.ts +450 -0
- package/src/server/rate-limit/env.ts +8 -0
- package/src/server/rate-limit/rate-limit.ts +165 -0
- package/src/server/routes/HEALTH_CHECK.md +502 -0
- package/src/server/routes/IMPLEMENTATION_SUMMARY.md +432 -0
- package/src/server/routes/QUICK_START.md +327 -0
- package/src/server/routes/README.md +357 -0
- package/src/server/routes/__tests__/routes.test.ts +628 -0
- package/src/server/routes/agent-route.ts +224 -0
- package/src/server/routes/agent-routes.ts +191 -0
- package/src/server/routes/embed-config.ts +181 -0
- package/src/server/routes/health-check.example.ts +507 -0
- package/src/server/routes/health-check.test.ts +533 -0
- package/src/server/routes/health-check.ts +639 -0
- package/src/server/routes/health-check.types.ts +217 -0
- package/src/server/routes/index.ts +32 -0
- package/src/server/routes/types.ts +274 -0
- package/src/shared/__tests__/schemas.test.ts +317 -0
- package/src/shared/ai-runtime.ts +139 -0
- package/src/shared/ai-types.ts +133 -0
- package/src/shared/index.ts +30 -0
- package/src/shared/sdk-runtime.ts +198 -0
- package/src/shared/sdk-types.ts +301 -0
- package/src/streaming/control/__tests__/streaming-control.test.ts +708 -0
- package/src/streaming/control/budget-guard.ts +264 -0
- package/src/streaming/control/controller.ts +255 -0
- package/src/streaming/control/index.ts +105 -0
- package/src/streaming/control/smoothing.ts +201 -0
- package/src/streaming/control/step-limit.ts +215 -0
- package/src/streaming/control/types.ts +234 -0
- package/src/streaming/core/auto-resume.ts +276 -0
- package/src/streaming/core/index.ts +85 -0
- package/src/streaming/core/multi-step.ts +471 -0
- package/src/streaming/core/protocol.ts +194 -0
- package/src/streaming/core/types.ts +182 -0
- package/src/streaming/index.ts +97 -0
- package/src/streaming/infra/backpressure/buffer.ts +210 -0
- package/src/streaming/infra/backpressure/index.ts +6 -0
- package/src/streaming/infra/index.ts +75 -0
- package/src/streaming/infra/multiplexing/index.ts +311 -0
- package/src/streaming/infra/resilience/index.ts +684 -0
- package/src/streaming/infra/transform/index.ts +15 -0
- package/src/streaming/infra/transform/stream-transforms.ts +166 -0
- package/src/streaming/infra/transport/index.ts +774 -0
- package/src/streaming/infra/types.ts +118 -0
- package/src/streaming/infra-extra/types.ts +118 -0
- package/src/tools/advanced/caching.ts +299 -0
- package/src/tools/advanced/generator.ts +267 -0
- package/src/tools/advanced/hitl.ts +251 -0
- package/src/tools/advanced/index.ts +9 -0
- package/src/tools/advanced/llm-tool.ts +208 -0
- package/src/tools/approval/FILES.md +449 -0
- package/src/tools/approval/IMPLEMENTATION_SUMMARY.md +567 -0
- package/src/tools/approval/QUICK_START.md +362 -0
- package/src/tools/approval/README.md +514 -0
- package/src/tools/approval/advanced-approval-queue.ts +7 -0
- package/src/tools/approval/approval.example.ts +571 -0
- package/src/tools/approval/in-memory-queue.ts +405 -0
- package/src/tools/approval/index.ts +737 -0
- package/src/tools/approval/middleware.ts +590 -0
- package/src/tools/approval/queue-factory.ts +162 -0
- package/src/tools/approval/redis-queue.ts +327 -0
- package/src/tools/approval/testing.ts +493 -0
- package/src/tools/approval/types.ts +221 -0
- package/src/tools/approval/with-approval.ts +366 -0
- package/src/tools/artifacts/artifact-tools.ts +273 -0
- package/src/tools/artifacts/index.ts +6 -0
- package/src/tools/compliance/compliance-wrapper.ts +789 -0
- package/src/tools/compliance/create-compliant-stream.ts +226 -0
- package/src/tools/compliance/index.ts +8 -0
- package/src/tools/compliance/phi-redaction.ts +406 -0
- package/src/tools/compliance/tool-wrapper.ts +306 -0
- package/src/tools/computer/index.ts +99 -0
- package/src/tools/computer/types.ts +41 -0
- package/src/tools/core/abort.ts +202 -0
- package/src/tools/core/factory.ts +197 -0
- package/src/tools/core/index.ts +8 -0
- package/src/tools/core/tool-safety.ts +112 -0
- package/src/tools/generic/index.ts +9 -0
- package/src/tools/generic/json-schema-tool.ts +301 -0
- package/src/tools/generic/tiptap-context.ts +619 -0
- package/src/tools/generic/web-search-tool.ts +82 -0
- package/src/tools/generic/web-search.ts +142 -0
- package/src/tools/index.ts +36 -0
- package/src/tools/mcp/ai-sdk-error-integration.ts +401 -0
- package/src/tools/mcp/client.ts +988 -0
- package/src/tools/mcp/connection-manager.ts +380 -0
- package/src/tools/mcp/connection-pool.ts +408 -0
- package/src/tools/mcp/edge-runtime.ts +318 -0
- package/src/tools/mcp/environment.ts +310 -0
- package/src/tools/mcp/index.ts +20 -0
- package/src/tools/mcp/next-pattern.ts +401 -0
- package/src/tools/mcp/stream-lifecycle-integration.ts +617 -0
- package/src/tools/mcp/tool-cache.ts +359 -0
- package/src/tools/mcp/transport-selector.ts +492 -0
- package/src/tools/mcp/transports.ts +99 -0
- package/src/tools/simple-factory.ts +55 -0
- package/src/tools/superpowers/index.ts +122 -0
- package/src/tools/superpowers/prompts/index.ts +533 -0
- package/src/tools/superpowers/schemas/index.ts +701 -0
- package/src/tools/superpowers/tools/index.ts +721 -0
- package/src/tools/validation-wrapper.ts +97 -0
|
@@ -0,0 +1,1004 @@
|
|
|
1
|
+
import { Ct as google, G as createGoogleGenerativeAI, It as openai, J as createOpenAI, N as anthropic, Nr as SDKLanguageModel, _i as SDKSharedV3ProviderMetadata, cn as xai, et as createXai } from "./ai-runtime-DIwOEc6g.mjs";
|
|
2
|
+
import { n as Model, s as ModelTier } from "./registry-DVPWzkXR.mjs";
|
|
3
|
+
import * as ai from "ai";
|
|
4
|
+
import * as _ai_sdk_provider0 from "@ai-sdk/provider";
|
|
5
|
+
|
|
6
|
+
//#region src/models/provider-factory.d.ts
|
|
7
|
+
interface CreateLanguageModelOptions {
|
|
8
|
+
useNative?: boolean;
|
|
9
|
+
}
|
|
10
|
+
declare function createLanguageModel(model: Model, options?: CreateLanguageModelOptions): SDKLanguageModel;
|
|
11
|
+
declare function getModelsByTier(tier: ModelTier): Model[];
|
|
12
|
+
declare function getModelTier(model: Model): ModelTier;
|
|
13
|
+
declare function estimateCost(model: Model, inputTokens: number, outputTokens: number): number;
|
|
14
|
+
declare function getCheapestModel(options: {
|
|
15
|
+
supportsTools?: boolean;
|
|
16
|
+
supportsStreaming?: boolean;
|
|
17
|
+
minContextWindow?: number;
|
|
18
|
+
}): Model;
|
|
19
|
+
//#endregion
|
|
20
|
+
//#region src/models/capabilities.d.ts
|
|
21
|
+
declare function modelSupportsReasoning(modelId: string): boolean;
|
|
22
|
+
declare function modelSupportsTools(modelId: string): boolean;
|
|
23
|
+
declare function modelSupportsStreaming(modelId: string): boolean;
|
|
24
|
+
//#endregion
|
|
25
|
+
//#region src/models/providers/shared.d.ts
|
|
26
|
+
declare const TEMPS: {
|
|
27
|
+
readonly PRECISE: 0;
|
|
28
|
+
readonly VERY_LOW: 0.1;
|
|
29
|
+
readonly FACTUAL: 0.2;
|
|
30
|
+
readonly LOW_CREATIVE: 0.3;
|
|
31
|
+
readonly MODERATE: 0.5;
|
|
32
|
+
readonly BALANCED: 0.7;
|
|
33
|
+
readonly HIGH_CREATIVE: 0.8;
|
|
34
|
+
readonly CREATIVE: 0.9;
|
|
35
|
+
};
|
|
36
|
+
declare const TOKENS: {
|
|
37
|
+
readonly TINY: 256;
|
|
38
|
+
readonly SHORT: 1024;
|
|
39
|
+
readonly MEDIUM: 2048;
|
|
40
|
+
readonly LONG: 4096;
|
|
41
|
+
readonly EXTENDED: 8192;
|
|
42
|
+
readonly MAX: 16384;
|
|
43
|
+
};
|
|
44
|
+
declare const TOP_P: {
|
|
45
|
+
readonly DETERMINISTIC: 1;
|
|
46
|
+
readonly FOCUSED: 0.95;
|
|
47
|
+
readonly BALANCED: 0.98;
|
|
48
|
+
};
|
|
49
|
+
declare const commonModes: {
|
|
50
|
+
precise: () => {
|
|
51
|
+
temperature: 0;
|
|
52
|
+
topP: 1;
|
|
53
|
+
};
|
|
54
|
+
code: () => {
|
|
55
|
+
temperature: 0.2;
|
|
56
|
+
topP: 0.95;
|
|
57
|
+
};
|
|
58
|
+
creative: () => {
|
|
59
|
+
temperature: 0.9;
|
|
60
|
+
topP: 0.98;
|
|
61
|
+
};
|
|
62
|
+
research: () => {
|
|
63
|
+
temperature: 0.2;
|
|
64
|
+
maxOutputTokens: 4096;
|
|
65
|
+
};
|
|
66
|
+
quick: () => {
|
|
67
|
+
temperature: 0.5;
|
|
68
|
+
maxOutputTokens: 1024;
|
|
69
|
+
};
|
|
70
|
+
};
|
|
71
|
+
type TemperaturePreset = keyof typeof TEMPS;
|
|
72
|
+
type TokenPreset = keyof typeof TOKENS;
|
|
73
|
+
type TopPPreset = keyof typeof TOP_P;
|
|
74
|
+
type CommonMode = keyof typeof commonModes;
|
|
75
|
+
declare namespace anthropic_d_exports {
|
|
76
|
+
export { ANTHROPIC_MODEL_CAPABILITIES, ANTHROPIC_MODEL_GROUPS, ANTHROPIC_MODEL_IDS, ANTHROPIC_PRESETS, ANTHROPIC_TOOL_NAMES, AnthropicMetadata, AnthropicModelCapabilities, CacheMetadata, ReasoningDetails, ToolError, anthropic, anthropicTools, extractCacheMetadata, extractProviderMetadata$1 as extractProviderMetadata, extractReasoningDetails, extractToolErrors, getCacheMinTokens, getMaxContextTokens, isMultimodalModel, isReasoningModel$1 as isReasoningModel, supportsCodeExecution, supportsComputerUse, supportsPDF, supportsReasoning, supportsWebSearch$1 as supportsWebSearch, withCacheControl, withExtendedCache, withReasoning, withSendReasoning };
|
|
77
|
+
}
|
|
78
|
+
interface ComputerToolConfig {
|
|
79
|
+
displayWidth: number;
|
|
80
|
+
displayHeight: number;
|
|
81
|
+
screenshotFormat?: 'png' | 'jpeg';
|
|
82
|
+
}
|
|
83
|
+
interface GenerationResult$3 {
|
|
84
|
+
reasoningText?: string;
|
|
85
|
+
content?: Array<{
|
|
86
|
+
type: string;
|
|
87
|
+
text?: string;
|
|
88
|
+
error?: unknown;
|
|
89
|
+
}>;
|
|
90
|
+
providerOptions?: SDKSharedV3ProviderMetadata;
|
|
91
|
+
}
|
|
92
|
+
declare const ANTHROPIC_MODEL_IDS: {
|
|
93
|
+
readonly OPUS_4: "claude-opus-4-20250514";
|
|
94
|
+
readonly SONNET_4: "claude-sonnet-4-20250514";
|
|
95
|
+
readonly SONNET_37: "claude-3-7-sonnet-20250219";
|
|
96
|
+
readonly SONNET_35: "claude-3-5-sonnet-20241022";
|
|
97
|
+
readonly SONNET_35_OLD: "claude-3-5-sonnet-20240620";
|
|
98
|
+
readonly HAIKU_35: "claude-3-5-haiku-20241022";
|
|
99
|
+
readonly OPUS_3: "claude-3-opus-20240229";
|
|
100
|
+
readonly SONNET_3: "claude-3-sonnet-20240229";
|
|
101
|
+
readonly HAIKU_3: "claude-3-haiku-20240307";
|
|
102
|
+
};
|
|
103
|
+
declare const ANTHROPIC_MODEL_GROUPS: {
|
|
104
|
+
readonly REASONING_MODELS: readonly ["claude-opus-4-20250514", "claude-sonnet-4-20250514", "claude-3-7-sonnet-20250219"];
|
|
105
|
+
readonly MULTIMODAL_MODELS: readonly ["claude-opus-4-20250514", "claude-sonnet-4-20250514", "claude-3-7-sonnet-20250219", "claude-3-5-sonnet-20241022", "claude-3-5-sonnet-20240620", "claude-3-5-haiku-20241022", "claude-3-opus-20240229", "claude-3-sonnet-20240229", "claude-3-haiku-20240307"];
|
|
106
|
+
readonly PDF_CAPABLE_MODELS: readonly ["claude-3-5-sonnet-20241022"];
|
|
107
|
+
readonly COMPUTER_USE_MODELS: readonly ["claude-opus-4-20250514", "claude-sonnet-4-20250514", "claude-3-7-sonnet-20250219", "claude-3-5-sonnet-20241022"];
|
|
108
|
+
readonly WEB_SEARCH_MODELS: readonly ["claude-opus-4-20250514", "claude-sonnet-4-20250514", "claude-3-7-sonnet-20250219", "claude-3-5-sonnet-20241022", "claude-3-5-sonnet-20240620", "claude-3-5-haiku-20241022"];
|
|
109
|
+
readonly CODE_EXECUTION_MODELS: readonly ["claude-opus-4-20250514", "claude-sonnet-4-20250514", "claude-3-7-sonnet-20250219", "claude-3-5-sonnet-20241022", "claude-3-5-sonnet-20240620", "claude-3-5-haiku-20241022"];
|
|
110
|
+
};
|
|
111
|
+
declare const ANTHROPIC_MODEL_CAPABILITIES: {
|
|
112
|
+
readonly "claude-opus-4-20250514": {
|
|
113
|
+
readonly imageInput: true;
|
|
114
|
+
readonly objectGeneration: true;
|
|
115
|
+
readonly toolUsage: true;
|
|
116
|
+
readonly computerUse: true;
|
|
117
|
+
readonly webSearch: true;
|
|
118
|
+
readonly codeExecution: true;
|
|
119
|
+
readonly pdfSupport: false;
|
|
120
|
+
readonly reasoningText: true;
|
|
121
|
+
readonly maxContextTokens: 200000;
|
|
122
|
+
readonly cacheMinTokens: 1024;
|
|
123
|
+
readonly specialFeatures: readonly ["reasoning", "computer-use", "web-search", "code-execution"];
|
|
124
|
+
};
|
|
125
|
+
readonly "claude-sonnet-4-20250514": {
|
|
126
|
+
readonly imageInput: true;
|
|
127
|
+
readonly objectGeneration: true;
|
|
128
|
+
readonly toolUsage: true;
|
|
129
|
+
readonly computerUse: true;
|
|
130
|
+
readonly webSearch: true;
|
|
131
|
+
readonly codeExecution: true;
|
|
132
|
+
readonly pdfSupport: false;
|
|
133
|
+
readonly reasoningText: true;
|
|
134
|
+
readonly maxContextTokens: 200000;
|
|
135
|
+
readonly cacheMinTokens: 1024;
|
|
136
|
+
readonly specialFeatures: readonly ["reasoning", "computer-use", "web-search", "code-execution"];
|
|
137
|
+
};
|
|
138
|
+
readonly "claude-3-7-sonnet-20250219": {
|
|
139
|
+
readonly imageInput: true;
|
|
140
|
+
readonly objectGeneration: true;
|
|
141
|
+
readonly toolUsage: true;
|
|
142
|
+
readonly computerUse: true;
|
|
143
|
+
readonly webSearch: true;
|
|
144
|
+
readonly codeExecution: true;
|
|
145
|
+
readonly pdfSupport: false;
|
|
146
|
+
readonly reasoningText: true;
|
|
147
|
+
readonly maxContextTokens: 200000;
|
|
148
|
+
readonly cacheMinTokens: 1024;
|
|
149
|
+
readonly specialFeatures: readonly ["reasoning", "computer-use", "web-search", "code-execution"];
|
|
150
|
+
};
|
|
151
|
+
readonly "claude-3-5-sonnet-20241022": {
|
|
152
|
+
readonly imageInput: true;
|
|
153
|
+
readonly objectGeneration: true;
|
|
154
|
+
readonly toolUsage: true;
|
|
155
|
+
readonly computerUse: true;
|
|
156
|
+
readonly webSearch: true;
|
|
157
|
+
readonly codeExecution: true;
|
|
158
|
+
readonly pdfSupport: true;
|
|
159
|
+
readonly reasoningText: false;
|
|
160
|
+
readonly maxContextTokens: 200000;
|
|
161
|
+
readonly cacheMinTokens: 1024;
|
|
162
|
+
readonly specialFeatures: readonly ["pdf-support", "computer-use", "web-search", "code-execution"];
|
|
163
|
+
};
|
|
164
|
+
readonly "claude-3-5-sonnet-20240620": {
|
|
165
|
+
readonly imageInput: true;
|
|
166
|
+
readonly objectGeneration: true;
|
|
167
|
+
readonly toolUsage: true;
|
|
168
|
+
readonly computerUse: false;
|
|
169
|
+
readonly webSearch: true;
|
|
170
|
+
readonly codeExecution: true;
|
|
171
|
+
readonly pdfSupport: false;
|
|
172
|
+
readonly reasoningText: false;
|
|
173
|
+
readonly maxContextTokens: 200000;
|
|
174
|
+
readonly cacheMinTokens: 1024;
|
|
175
|
+
readonly specialFeatures: readonly ["web-search", "code-execution"];
|
|
176
|
+
};
|
|
177
|
+
readonly "claude-3-5-haiku-20241022": {
|
|
178
|
+
readonly imageInput: true;
|
|
179
|
+
readonly objectGeneration: true;
|
|
180
|
+
readonly toolUsage: true;
|
|
181
|
+
readonly computerUse: false;
|
|
182
|
+
readonly webSearch: true;
|
|
183
|
+
readonly codeExecution: true;
|
|
184
|
+
readonly pdfSupport: false;
|
|
185
|
+
readonly reasoningText: false;
|
|
186
|
+
readonly maxContextTokens: 200000;
|
|
187
|
+
readonly cacheMinTokens: 2048;
|
|
188
|
+
readonly specialFeatures: readonly ["fast", "web-search", "code-execution"];
|
|
189
|
+
};
|
|
190
|
+
readonly "claude-3-opus-20240229": {
|
|
191
|
+
readonly imageInput: true;
|
|
192
|
+
readonly objectGeneration: true;
|
|
193
|
+
readonly toolUsage: true;
|
|
194
|
+
readonly computerUse: false;
|
|
195
|
+
readonly webSearch: false;
|
|
196
|
+
readonly codeExecution: false;
|
|
197
|
+
readonly pdfSupport: false;
|
|
198
|
+
readonly reasoningText: false;
|
|
199
|
+
readonly maxContextTokens: 200000;
|
|
200
|
+
readonly cacheMinTokens: 1024;
|
|
201
|
+
readonly specialFeatures: readonly ["legacy"];
|
|
202
|
+
};
|
|
203
|
+
readonly "claude-3-sonnet-20240229": {
|
|
204
|
+
readonly imageInput: true;
|
|
205
|
+
readonly objectGeneration: true;
|
|
206
|
+
readonly toolUsage: true;
|
|
207
|
+
readonly computerUse: false;
|
|
208
|
+
readonly webSearch: false;
|
|
209
|
+
readonly codeExecution: false;
|
|
210
|
+
readonly pdfSupport: false;
|
|
211
|
+
readonly reasoningText: false;
|
|
212
|
+
readonly maxContextTokens: 200000;
|
|
213
|
+
readonly cacheMinTokens: 1024;
|
|
214
|
+
readonly specialFeatures: readonly ["legacy"];
|
|
215
|
+
};
|
|
216
|
+
readonly "claude-3-haiku-20240307": {
|
|
217
|
+
readonly imageInput: true;
|
|
218
|
+
readonly objectGeneration: true;
|
|
219
|
+
readonly toolUsage: true;
|
|
220
|
+
readonly computerUse: false;
|
|
221
|
+
readonly webSearch: false;
|
|
222
|
+
readonly codeExecution: false;
|
|
223
|
+
readonly pdfSupport: false;
|
|
224
|
+
readonly reasoningText: false;
|
|
225
|
+
readonly maxContextTokens: 200000;
|
|
226
|
+
readonly cacheMinTokens: 2048;
|
|
227
|
+
readonly specialFeatures: readonly ["legacy", "fast"];
|
|
228
|
+
};
|
|
229
|
+
};
|
|
230
|
+
declare const ANTHROPIC_PRESETS: {
|
|
231
|
+
readonly REASONING: {
|
|
232
|
+
readonly temperature: 0;
|
|
233
|
+
readonly maxOutputTokens: 4096;
|
|
234
|
+
readonly topP: 0.95;
|
|
235
|
+
readonly anthropic: {
|
|
236
|
+
readonly sendReasoning: true;
|
|
237
|
+
};
|
|
238
|
+
};
|
|
239
|
+
readonly CREATIVE: {
|
|
240
|
+
readonly temperature: 0.9;
|
|
241
|
+
readonly maxOutputTokens: 2048;
|
|
242
|
+
readonly topP: 0.98;
|
|
243
|
+
};
|
|
244
|
+
readonly CODING: {
|
|
245
|
+
readonly temperature: 0.7;
|
|
246
|
+
readonly maxOutputTokens: 8192;
|
|
247
|
+
readonly topP: 1;
|
|
248
|
+
};
|
|
249
|
+
readonly ANALYSIS: {
|
|
250
|
+
readonly temperature: 0.1;
|
|
251
|
+
readonly maxOutputTokens: 4096;
|
|
252
|
+
readonly topP: 0.95;
|
|
253
|
+
};
|
|
254
|
+
readonly VISION: {
|
|
255
|
+
readonly temperature: 0.7;
|
|
256
|
+
readonly maxOutputTokens: 2048;
|
|
257
|
+
readonly topP: 0.98;
|
|
258
|
+
};
|
|
259
|
+
readonly QUICK: {
|
|
260
|
+
readonly temperature: 0.1;
|
|
261
|
+
readonly maxOutputTokens: 1024;
|
|
262
|
+
readonly topP: 1;
|
|
263
|
+
};
|
|
264
|
+
};
|
|
265
|
+
declare const ANTHROPIC_TOOL_NAMES: {
|
|
266
|
+
readonly WEB_SEARCH: "web_search";
|
|
267
|
+
readonly CODE_EXECUTION: "code_execution";
|
|
268
|
+
readonly COMPUTER: "computer";
|
|
269
|
+
readonly BASH: "bash";
|
|
270
|
+
readonly TEXT_EDITOR: "str_replace_editor";
|
|
271
|
+
readonly TEXT_EDITOR_V2: "str_replace_based_edit_tool";
|
|
272
|
+
};
|
|
273
|
+
declare const anthropicTools: {
|
|
274
|
+
webSearch: (options?: {
|
|
275
|
+
maxUses?: number;
|
|
276
|
+
allowedDomains?: string[];
|
|
277
|
+
blockedDomains?: string[];
|
|
278
|
+
userLocation?: {
|
|
279
|
+
type: "approximate";
|
|
280
|
+
country?: string;
|
|
281
|
+
region?: string;
|
|
282
|
+
city?: string;
|
|
283
|
+
timezone?: string;
|
|
284
|
+
};
|
|
285
|
+
}) => ai.Tool<{
|
|
286
|
+
query: string;
|
|
287
|
+
}, {
|
|
288
|
+
type: "web_search_result";
|
|
289
|
+
url: string;
|
|
290
|
+
title: string | null;
|
|
291
|
+
pageAge: string | null;
|
|
292
|
+
encryptedContent: string;
|
|
293
|
+
}[]>;
|
|
294
|
+
codeExecution: () => ai.Tool<{
|
|
295
|
+
code: string;
|
|
296
|
+
}, {
|
|
297
|
+
type: "code_execution_result";
|
|
298
|
+
stdout: string;
|
|
299
|
+
stderr: string;
|
|
300
|
+
return_code: number;
|
|
301
|
+
content: Array<{
|
|
302
|
+
type: "code_execution_output";
|
|
303
|
+
file_id: string;
|
|
304
|
+
}>;
|
|
305
|
+
}>;
|
|
306
|
+
computer: (config: ComputerToolConfig) => ai.Tool<{
|
|
307
|
+
action: "key" | "type" | "mouse_move" | "left_click" | "left_click_drag" | "right_click" | "middle_click" | "double_click" | "screenshot" | "cursor_position";
|
|
308
|
+
coordinate?: number[];
|
|
309
|
+
text?: string;
|
|
310
|
+
}, unknown>;
|
|
311
|
+
bash: () => ai.Tool<{
|
|
312
|
+
command: string;
|
|
313
|
+
restart?: boolean;
|
|
314
|
+
}, unknown>;
|
|
315
|
+
textEditor: () => ai.Tool<{
|
|
316
|
+
command: "view" | "create" | "str_replace" | "insert" | "undo_edit";
|
|
317
|
+
path: string;
|
|
318
|
+
file_text?: string;
|
|
319
|
+
insert_line?: number;
|
|
320
|
+
new_str?: string;
|
|
321
|
+
insert_text?: string;
|
|
322
|
+
old_str?: string;
|
|
323
|
+
view_range?: number[];
|
|
324
|
+
}, unknown>;
|
|
325
|
+
textEditorV2: () => ai.Tool<{
|
|
326
|
+
command: "view" | "create" | "str_replace" | "insert";
|
|
327
|
+
path: string;
|
|
328
|
+
file_text?: string;
|
|
329
|
+
insert_line?: number;
|
|
330
|
+
new_str?: string;
|
|
331
|
+
insert_text?: string;
|
|
332
|
+
old_str?: string;
|
|
333
|
+
view_range?: number[];
|
|
334
|
+
}, unknown>;
|
|
335
|
+
};
|
|
336
|
+
declare function withReasoning(budgetTokens?: number): {
|
|
337
|
+
providerOptions: {
|
|
338
|
+
anthropic: {
|
|
339
|
+
thinking: {
|
|
340
|
+
type: "enabled";
|
|
341
|
+
budgetTokens: number;
|
|
342
|
+
};
|
|
343
|
+
};
|
|
344
|
+
};
|
|
345
|
+
};
|
|
346
|
+
declare function withCacheControl(ttl?: '5m' | '1h'): {
|
|
347
|
+
providerOptions: {
|
|
348
|
+
anthropic: {
|
|
349
|
+
cacheControl: {
|
|
350
|
+
ttl?: "5m" | "1h" | undefined;
|
|
351
|
+
type: "ephemeral";
|
|
352
|
+
};
|
|
353
|
+
};
|
|
354
|
+
};
|
|
355
|
+
};
|
|
356
|
+
declare function withSendReasoning(send?: boolean): {
|
|
357
|
+
providerOptions: {
|
|
358
|
+
anthropic: {
|
|
359
|
+
sendReasoning: boolean;
|
|
360
|
+
};
|
|
361
|
+
};
|
|
362
|
+
};
|
|
363
|
+
declare function withExtendedCache(): {
|
|
364
|
+
headers: {
|
|
365
|
+
'anthropic-beta': string;
|
|
366
|
+
};
|
|
367
|
+
providerOptions: {
|
|
368
|
+
anthropic: {
|
|
369
|
+
cacheControl: {
|
|
370
|
+
type: "ephemeral";
|
|
371
|
+
ttl: string;
|
|
372
|
+
};
|
|
373
|
+
};
|
|
374
|
+
};
|
|
375
|
+
};
|
|
376
|
+
declare function supportsReasoning(modelId: string): boolean;
|
|
377
|
+
declare function supportsPDF(modelId: string): boolean;
|
|
378
|
+
declare function supportsComputerUse(modelId: string): boolean;
|
|
379
|
+
declare function supportsWebSearch$1(modelId: string): boolean;
|
|
380
|
+
declare function supportsCodeExecution(modelId: string): boolean;
|
|
381
|
+
declare function getCacheMinTokens(modelId: string): number;
|
|
382
|
+
declare function getMaxContextTokens(modelId: string): number;
|
|
383
|
+
declare function isReasoningModel$1(modelId: string): boolean;
|
|
384
|
+
declare function isMultimodalModel(modelId: string): boolean;
|
|
385
|
+
declare function extractReasoningDetails(result: GenerationResult$3): ReasoningDetails | null;
|
|
386
|
+
declare function extractCacheMetadata(result: GenerationResult$3): CacheMetadata | null;
|
|
387
|
+
declare function extractProviderMetadata$1(result: GenerationResult$3): AnthropicMetadata | null;
|
|
388
|
+
declare function extractToolErrors(result: GenerationResult$3): ToolError[];
|
|
389
|
+
interface AnthropicModelCapabilities {
|
|
390
|
+
readonly imageInput: boolean;
|
|
391
|
+
readonly objectGeneration: boolean;
|
|
392
|
+
readonly toolUsage: boolean;
|
|
393
|
+
readonly computerUse: boolean;
|
|
394
|
+
readonly webSearch: boolean;
|
|
395
|
+
readonly codeExecution: boolean;
|
|
396
|
+
readonly pdfSupport: boolean;
|
|
397
|
+
readonly reasoningText: boolean;
|
|
398
|
+
readonly maxContextTokens: number;
|
|
399
|
+
readonly cacheMinTokens: number;
|
|
400
|
+
readonly specialFeatures: readonly string[];
|
|
401
|
+
}
|
|
402
|
+
interface ReasoningDetails {
|
|
403
|
+
reasoningText: string;
|
|
404
|
+
reasoningDetails?: {
|
|
405
|
+
reasoningContent?: string;
|
|
406
|
+
reasoningTokenCount?: number;
|
|
407
|
+
};
|
|
408
|
+
}
|
|
409
|
+
interface CacheMetadata {
|
|
410
|
+
cacheCreationInputTokens: number;
|
|
411
|
+
cacheReadInputTokens: number;
|
|
412
|
+
}
|
|
413
|
+
interface AnthropicMetadata {
|
|
414
|
+
cacheCreationInputTokens: number;
|
|
415
|
+
cacheReadInputTokens: number;
|
|
416
|
+
reasoningText?: string;
|
|
417
|
+
reasoningDetails?: {
|
|
418
|
+
reasoningContent?: string;
|
|
419
|
+
reasoningTokenCount?: number;
|
|
420
|
+
};
|
|
421
|
+
}
|
|
422
|
+
interface ToolError {
|
|
423
|
+
toolName: string;
|
|
424
|
+
toolCallId: string;
|
|
425
|
+
error: unknown;
|
|
426
|
+
}
|
|
427
|
+
declare namespace openai_d_exports {
|
|
428
|
+
export { OPENAI_MODEL_GROUPS, OPENAI_MODEL_IDS, OPENAI_PRESETS, OpenAIMetadata, createOpenAI, extractCachedPromptTokens, extractOpenAIMetadata, extractPredictionTokens, extractReasoningTokens, openai, supportsPromptCaching, supportsReasoningMode, supportsServiceTier, supportsStructuredOutputs, withPredictedOutput, withPromptCache, withReasoningMode, withServiceTier, withStrictMode, withStructuredOutput };
|
|
429
|
+
}
|
|
430
|
+
interface GenerationResult$2 {
|
|
431
|
+
providerOptions?: SDKSharedV3ProviderMetadata;
|
|
432
|
+
}
|
|
433
|
+
declare const OPENAI_MODEL_IDS: {
|
|
434
|
+
readonly GPT_5: "gpt-5";
|
|
435
|
+
readonly GPT_5_MINI: "gpt-5-mini";
|
|
436
|
+
readonly GPT_5_NANO: "gpt-5-nano";
|
|
437
|
+
readonly GPT_5_CHAT_LATEST: "gpt-5-chat-latest";
|
|
438
|
+
readonly GPT_41: "gpt-4.1";
|
|
439
|
+
readonly GPT_41_MINI: "gpt-4.1-mini";
|
|
440
|
+
readonly GPT_41_NANO: "gpt-4.1-nano";
|
|
441
|
+
readonly GPT_4O: "gpt-4o";
|
|
442
|
+
readonly GPT_4O_LATEST: "chatgpt-4o-latest";
|
|
443
|
+
readonly GPT_4O_MINI: "gpt-4o-mini";
|
|
444
|
+
readonly GPT_4O_AUDIO: "gpt-4o-audio-preview";
|
|
445
|
+
readonly GPT_4O_REALTIME: "gpt-4o-realtime-preview";
|
|
446
|
+
readonly GPT_4_TURBO: "gpt-4-turbo";
|
|
447
|
+
readonly GPT_4: "gpt-4";
|
|
448
|
+
readonly GPT_4_32K: "gpt-4-32k";
|
|
449
|
+
readonly GPT_35_TURBO: "gpt-3.5-turbo";
|
|
450
|
+
readonly GPT_35_TURBO_INSTRUCT: "gpt-3.5-turbo-instruct";
|
|
451
|
+
readonly O1: "o1";
|
|
452
|
+
readonly O1_MINI: "o1-mini";
|
|
453
|
+
readonly O1_PREVIEW: "o1-preview";
|
|
454
|
+
readonly O3: "o3";
|
|
455
|
+
readonly O3_MINI: "o3-mini";
|
|
456
|
+
readonly O4_MINI: "o4-mini";
|
|
457
|
+
readonly CODEX_MINI_LATEST: "codex-mini-latest";
|
|
458
|
+
readonly COMPUTER_USE_PREVIEW: "computer-use-preview";
|
|
459
|
+
readonly WHISPER_1: "whisper-1";
|
|
460
|
+
readonly GPT_4O_MINI_TRANSCRIBE: "gpt-4o-mini-transcribe";
|
|
461
|
+
readonly GPT_4O_TRANSCRIBE: "gpt-4o-transcribe";
|
|
462
|
+
readonly TTS_1: "tts-1";
|
|
463
|
+
readonly TTS_1_HD: "tts-1-hd";
|
|
464
|
+
readonly GPT_4O_MINI_TTS: "gpt-4o-mini-tts";
|
|
465
|
+
readonly GPT_IMAGE_1: "gpt-image-1";
|
|
466
|
+
readonly DALL_E_3: "dall-e-3";
|
|
467
|
+
readonly DALL_E_2: "dall-e-2";
|
|
468
|
+
readonly EMBEDDING_3_SMALL: "text-embedding-3-small";
|
|
469
|
+
readonly EMBEDDING_3_LARGE: "text-embedding-3-large";
|
|
470
|
+
readonly EMBEDDING_ADA_002: "text-embedding-ada-002";
|
|
471
|
+
readonly MODERATION_LATEST: "text-moderation-latest";
|
|
472
|
+
readonly MODERATION_STABLE: "text-moderation-stable";
|
|
473
|
+
};
|
|
474
|
+
declare const OPENAI_MODEL_GROUPS: {
|
|
475
|
+
readonly REASONING_MODELS: readonly ["o1", "o1-mini", "o1-preview", "o3", "o3-mini", "o4-mini", "codex-mini-latest", "computer-use-preview"];
|
|
476
|
+
readonly GPT5_FAMILY: readonly ["gpt-5", "gpt-5-mini", "gpt-5-nano", "gpt-5-chat-latest"];
|
|
477
|
+
readonly CHAT_MODELS: readonly ["gpt-5", "gpt-5-mini", "gpt-5-nano", "gpt-5-chat-latest", "gpt-4o", "gpt-4o-mini", "gpt-4-turbo", "gpt-4.1", "gpt-4.1-mini", "gpt-4", "gpt-4-32k", "gpt-3.5-turbo"];
|
|
478
|
+
readonly VISION_MODELS: readonly ["gpt-4o", "gpt-4o-mini", "gpt-4-turbo", "gpt-4.1", "gpt-4.1-mini", "gpt-5", "gpt-5-mini"];
|
|
479
|
+
readonly LEGACY_MODELS: readonly ["gpt-4", "gpt-4-32k", "gpt-3.5-turbo", "gpt-3.5-turbo-instruct"];
|
|
480
|
+
};
|
|
481
|
+
declare function withStructuredOutput(responseFormat?: 'json_object' | 'json_schema', strictJsonSchema?: boolean): {
|
|
482
|
+
openai: {
|
|
483
|
+
responseFormat: {
|
|
484
|
+
type: "json_object" | "json_schema";
|
|
485
|
+
};
|
|
486
|
+
strictJsonSchema: boolean;
|
|
487
|
+
};
|
|
488
|
+
};
|
|
489
|
+
declare function withReasoningMode(maxCompletionTokens?: number, reasoningEffort?: 'minimal' | 'low' | 'medium' | 'high'): {
|
|
490
|
+
providerOptions: {
|
|
491
|
+
openai: {
|
|
492
|
+
maxCompletionTokens: number;
|
|
493
|
+
reasoningEffort: "low" | "medium" | "high" | "minimal";
|
|
494
|
+
};
|
|
495
|
+
};
|
|
496
|
+
};
|
|
497
|
+
declare function withPredictedOutput(prediction: string): {
|
|
498
|
+
openai: {
|
|
499
|
+
prediction: {
|
|
500
|
+
type: string;
|
|
501
|
+
content: string;
|
|
502
|
+
};
|
|
503
|
+
};
|
|
504
|
+
};
|
|
505
|
+
declare function withPromptCache(cacheEnabled?: boolean, promptCacheKey?: string): {
|
|
506
|
+
openai: Record<string, unknown>;
|
|
507
|
+
};
|
|
508
|
+
declare function withServiceTier(tier?: 'auto' | 'flex' | 'priority' | 'default'): {
|
|
509
|
+
openai: {
|
|
510
|
+
serviceTier: "default" | "auto" | "priority" | "flex";
|
|
511
|
+
};
|
|
512
|
+
};
|
|
513
|
+
declare function withStrictMode(enabled?: boolean): {
|
|
514
|
+
openai: {
|
|
515
|
+
strict: boolean;
|
|
516
|
+
};
|
|
517
|
+
};
|
|
518
|
+
declare const OPENAI_PRESETS: {
|
|
519
|
+
readonly FAST: {
|
|
520
|
+
readonly openai: {
|
|
521
|
+
readonly serviceTier: "flex";
|
|
522
|
+
};
|
|
523
|
+
readonly temperature: 0.5;
|
|
524
|
+
readonly maxOutputTokens: 1024;
|
|
525
|
+
};
|
|
526
|
+
readonly ACCURATE: {
|
|
527
|
+
readonly openai: {
|
|
528
|
+
readonly serviceTier: "priority";
|
|
529
|
+
};
|
|
530
|
+
readonly temperature: 0;
|
|
531
|
+
readonly topP: 1;
|
|
532
|
+
};
|
|
533
|
+
readonly CREATIVE: {
|
|
534
|
+
readonly frequencyPenalty: 0.5;
|
|
535
|
+
readonly presencePenalty: 0.5;
|
|
536
|
+
readonly temperature: 0.9;
|
|
537
|
+
readonly topP: 0.98;
|
|
538
|
+
};
|
|
539
|
+
readonly REASONING: {
|
|
540
|
+
readonly maxOutputTokens: 30000;
|
|
541
|
+
readonly openai: {
|
|
542
|
+
readonly reasoningEffort: "high";
|
|
543
|
+
readonly reasoningSummary: "auto";
|
|
544
|
+
};
|
|
545
|
+
readonly temperature: 0.2;
|
|
546
|
+
};
|
|
547
|
+
readonly CODING: {
|
|
548
|
+
readonly maxOutputTokens: 8192;
|
|
549
|
+
readonly openai: {
|
|
550
|
+
readonly responseFormat: {
|
|
551
|
+
readonly type: "json_object";
|
|
552
|
+
};
|
|
553
|
+
readonly logprobs: true;
|
|
554
|
+
readonly topLogprobs: 3;
|
|
555
|
+
};
|
|
556
|
+
readonly temperature: 0.2;
|
|
557
|
+
readonly topP: 0.95;
|
|
558
|
+
};
|
|
559
|
+
};
|
|
560
|
+
declare function supportsReasoningMode(modelId: string): boolean;
|
|
561
|
+
declare function supportsServiceTier(modelId: string): boolean;
|
|
562
|
+
declare function supportsStructuredOutputs(modelId: string): boolean;
|
|
563
|
+
declare function supportsPromptCaching(modelId: string): boolean;
|
|
564
|
+
declare function extractReasoningTokens(result: GenerationResult$2): number | undefined;
|
|
565
|
+
declare function extractCachedPromptTokens(result: GenerationResult$2): number | undefined;
|
|
566
|
+
declare function extractPredictionTokens(result: GenerationResult$2): {
|
|
567
|
+
accepted?: number;
|
|
568
|
+
rejected?: number;
|
|
569
|
+
} | undefined;
|
|
570
|
+
declare function extractOpenAIMetadata(result: GenerationResult$2): OpenAIMetadata | null;
|
|
571
|
+
interface OpenAIMetadata {
|
|
572
|
+
responseId?: string;
|
|
573
|
+
reasoningTokens?: number;
|
|
574
|
+
cachedPromptTokens?: number;
|
|
575
|
+
acceptedPredictionTokens?: number;
|
|
576
|
+
rejectedPredictionTokens?: number;
|
|
577
|
+
logprobs?: Array<{
|
|
578
|
+
token: string;
|
|
579
|
+
logprob: number;
|
|
580
|
+
bytes?: number[];
|
|
581
|
+
top_logprobs?: Array<{
|
|
582
|
+
token: string;
|
|
583
|
+
logprob: number;
|
|
584
|
+
bytes?: number[];
|
|
585
|
+
}>;
|
|
586
|
+
}>;
|
|
587
|
+
}
|
|
588
|
+
declare namespace google_d_exports {
|
|
589
|
+
export { GOOGLE_MODEL_GROUPS, GOOGLE_MODEL_IDS, GOOGLE_PRESETS, GOOGLE_SAFETY_PRESETS, createGoogleGenerativeAI, google, googleTools, isGemmaModel, supportsGoogleSearch, supportsThinking, supportsUrlContext, withEmbeddingConfig, withGoogleImageGeneration, withResponseModalities, withSafetySettings, withStructuredOutputs, withThinking, withYouTubeContext };
|
|
590
|
+
}
|
|
591
|
+
declare const googleTools: {
|
|
592
|
+
readonly googleSearch: (typeof google.tools)['googleSearch'];
|
|
593
|
+
readonly urlContext: (typeof google.tools)['urlContext'];
|
|
594
|
+
readonly codeExecution: (typeof google.tools)['codeExecution'];
|
|
595
|
+
};
|
|
596
|
+
declare const GOOGLE_MODEL_IDS: {
|
|
597
|
+
readonly GEMINI_3_FLASH: "gemini-3-flash";
|
|
598
|
+
readonly GEMINI_20_FLASH: "gemini-2.0-flash";
|
|
599
|
+
readonly GEMINI_15_PRO: "gemini-1.5-pro";
|
|
600
|
+
readonly GEMINI_15_PRO_LATEST: "gemini-1.5-pro-latest";
|
|
601
|
+
readonly GEMINI_15_FLASH: "gemini-1.5-flash";
|
|
602
|
+
readonly GEMINI_15_FLASH_LATEST: "gemini-1.5-flash-latest";
|
|
603
|
+
readonly GEMINI_15_FLASH_8B: "gemini-1.5-flash-8b";
|
|
604
|
+
readonly GEMINI_15_FLASH_8B_LATEST: "gemini-1.5-flash-8b-latest";
|
|
605
|
+
readonly GEMMA_3_27B_IT: "gemma-3-27b-it";
|
|
606
|
+
readonly GEMMA_3_9B_IT: "gemma-3-9b-it";
|
|
607
|
+
readonly GEMMA_2_2B_IT: "gemma-2-2b-it";
|
|
608
|
+
readonly GEMMA_2_9B_IT: "gemma-2-9b-it";
|
|
609
|
+
readonly GEMMA_2_27B_IT: "gemma-2-27b-it";
|
|
610
|
+
readonly GEMINI_EMBEDDING_001: "gemini-embedding-001";
|
|
611
|
+
readonly TEXT_EMBEDDING_004: "text-embedding-004";
|
|
612
|
+
readonly IMAGEN_3_GENERATE_002: "imagen-3.0-generate-002";
|
|
613
|
+
readonly GEMMA_2_2B: "gemma-2-2b-it";
|
|
614
|
+
readonly GEMMA_2_9B: "gemma-2-9b-it";
|
|
615
|
+
readonly GEMMA_2_27B: "gemma-2-27b-it";
|
|
616
|
+
};
|
|
617
|
+
declare const GOOGLE_MODEL_GROUPS: {
|
|
618
|
+
readonly THINKING_MODELS: readonly ["gemini-3-flash"];
|
|
619
|
+
readonly GEMINI_MODELS: readonly ["gemini-3-flash", "gemini-1.5-pro", "gemini-1.5-pro-latest", "gemini-1.5-flash", "gemini-1.5-flash-latest", "gemini-1.5-flash-8b", "gemini-1.5-flash-8b-latest"];
|
|
620
|
+
readonly MULTIMODAL_MODELS: readonly ["gemini-3-flash", "gemini-1.5-pro", "gemini-1.5-pro-latest", "gemini-1.5-flash", "gemini-1.5-flash-latest", "gemini-1.5-flash-8b", "gemini-1.5-flash-8b-latest"];
|
|
621
|
+
readonly SEARCH_CAPABLE_MODELS: readonly ["gemini-3-flash", "gemini-1.5-pro", "gemini-1.5-pro-latest", "gemini-1.5-flash", "gemini-1.5-flash-latest", "gemini-1.5-flash-8b", "gemini-1.5-flash-8b-latest"];
|
|
622
|
+
readonly URL_CONTEXT_MODELS: readonly ["gemini-3-flash"];
|
|
623
|
+
readonly GEMMA_MODELS: readonly ["gemma-3-27b-it", "gemma-3-9b-it", "gemma-2-2b-it", "gemma-2-9b-it", "gemma-2-27b-it"];
|
|
624
|
+
readonly IMAGE_GENERATION_MODELS: readonly ["imagen-3.0-generate-002"];
|
|
625
|
+
};
|
|
626
|
+
declare function withThinking(budgetTokens?: number, includeThoughts?: boolean): {
|
|
627
|
+
providerOptions: {
|
|
628
|
+
google: {
|
|
629
|
+
thinkingConfig: {
|
|
630
|
+
thinkingBudget: number;
|
|
631
|
+
includeThoughts: boolean;
|
|
632
|
+
};
|
|
633
|
+
};
|
|
634
|
+
};
|
|
635
|
+
};
|
|
636
|
+
type GoogleSafetySetting = {
|
|
637
|
+
readonly category: 'HARM_CATEGORY_HATE_SPEECH' | 'HARM_CATEGORY_DANGEROUS_CONTENT' | 'HARM_CATEGORY_HARASSMENT' | 'HARM_CATEGORY_SEXUALLY_EXPLICIT';
|
|
638
|
+
readonly threshold: 'HARM_BLOCK_THRESHOLD_UNSPECIFIED' | 'BLOCK_LOW_AND_ABOVE' | 'BLOCK_MEDIUM_AND_ABOVE' | 'BLOCK_ONLY_HIGH' | 'BLOCK_NONE';
|
|
639
|
+
};
|
|
640
|
+
declare const GOOGLE_SAFETY_PRESETS: {
|
|
641
|
+
readonly STRICT: readonly [{
|
|
642
|
+
readonly category: "HARM_CATEGORY_HATE_SPEECH";
|
|
643
|
+
readonly threshold: "BLOCK_LOW_AND_ABOVE";
|
|
644
|
+
}, {
|
|
645
|
+
readonly category: "HARM_CATEGORY_DANGEROUS_CONTENT";
|
|
646
|
+
readonly threshold: "BLOCK_LOW_AND_ABOVE";
|
|
647
|
+
}, {
|
|
648
|
+
readonly category: "HARM_CATEGORY_HARASSMENT";
|
|
649
|
+
readonly threshold: "BLOCK_LOW_AND_ABOVE";
|
|
650
|
+
}, {
|
|
651
|
+
readonly category: "HARM_CATEGORY_SEXUALLY_EXPLICIT";
|
|
652
|
+
readonly threshold: "BLOCK_LOW_AND_ABOVE";
|
|
653
|
+
}];
|
|
654
|
+
readonly BALANCED: readonly [{
|
|
655
|
+
readonly category: "HARM_CATEGORY_HATE_SPEECH";
|
|
656
|
+
readonly threshold: "BLOCK_MEDIUM_AND_ABOVE";
|
|
657
|
+
}, {
|
|
658
|
+
readonly category: "HARM_CATEGORY_DANGEROUS_CONTENT";
|
|
659
|
+
readonly threshold: "BLOCK_MEDIUM_AND_ABOVE";
|
|
660
|
+
}, {
|
|
661
|
+
readonly category: "HARM_CATEGORY_HARASSMENT";
|
|
662
|
+
readonly threshold: "BLOCK_MEDIUM_AND_ABOVE";
|
|
663
|
+
}, {
|
|
664
|
+
readonly category: "HARM_CATEGORY_SEXUALLY_EXPLICIT";
|
|
665
|
+
readonly threshold: "BLOCK_MEDIUM_AND_ABOVE";
|
|
666
|
+
}];
|
|
667
|
+
readonly PERMISSIVE: readonly [{
|
|
668
|
+
readonly category: "HARM_CATEGORY_HATE_SPEECH";
|
|
669
|
+
readonly threshold: "BLOCK_ONLY_HIGH";
|
|
670
|
+
}, {
|
|
671
|
+
readonly category: "HARM_CATEGORY_DANGEROUS_CONTENT";
|
|
672
|
+
readonly threshold: "BLOCK_ONLY_HIGH";
|
|
673
|
+
}, {
|
|
674
|
+
readonly category: "HARM_CATEGORY_HARASSMENT";
|
|
675
|
+
readonly threshold: "BLOCK_ONLY_HIGH";
|
|
676
|
+
}, {
|
|
677
|
+
readonly category: "HARM_CATEGORY_SEXUALLY_EXPLICIT";
|
|
678
|
+
readonly threshold: "BLOCK_ONLY_HIGH";
|
|
679
|
+
}];
|
|
680
|
+
readonly NONE: readonly [{
|
|
681
|
+
readonly category: "HARM_CATEGORY_HATE_SPEECH";
|
|
682
|
+
readonly threshold: "BLOCK_NONE";
|
|
683
|
+
}, {
|
|
684
|
+
readonly category: "HARM_CATEGORY_DANGEROUS_CONTENT";
|
|
685
|
+
readonly threshold: "BLOCK_NONE";
|
|
686
|
+
}, {
|
|
687
|
+
readonly category: "HARM_CATEGORY_HARASSMENT";
|
|
688
|
+
readonly threshold: "BLOCK_NONE";
|
|
689
|
+
}, {
|
|
690
|
+
readonly category: "HARM_CATEGORY_SEXUALLY_EXPLICIT";
|
|
691
|
+
readonly threshold: "BLOCK_NONE";
|
|
692
|
+
}];
|
|
693
|
+
};
|
|
694
|
+
declare function withSafetySettings(preset: keyof typeof GOOGLE_SAFETY_PRESETS | ReadonlyArray<GoogleSafetySetting>, overrides?: Record<string, string>): {
|
|
695
|
+
providerOptions: {
|
|
696
|
+
google: {
|
|
697
|
+
safetySettings: Record<string, string>;
|
|
698
|
+
};
|
|
699
|
+
};
|
|
700
|
+
};
|
|
701
|
+
declare function withResponseModalities(modalities: Array<'TEXT' | 'AUDIO' | 'IMAGE'>): {
|
|
702
|
+
providerOptions: {
|
|
703
|
+
google: {
|
|
704
|
+
responseModalities: ("TEXT" | "AUDIO" | "IMAGE")[];
|
|
705
|
+
};
|
|
706
|
+
};
|
|
707
|
+
};
|
|
708
|
+
declare function withStructuredOutputs(schema?: Record<string, unknown> | boolean, mode?: 'AUTO' | 'STRICT'): {
|
|
709
|
+
providerOptions: {
|
|
710
|
+
google: {
|
|
711
|
+
structuredOutputs: {
|
|
712
|
+
enabled: boolean;
|
|
713
|
+
mode: "AUTO" | "STRICT";
|
|
714
|
+
schema?: undefined;
|
|
715
|
+
};
|
|
716
|
+
};
|
|
717
|
+
};
|
|
718
|
+
} | {
|
|
719
|
+
providerOptions: {
|
|
720
|
+
google: {
|
|
721
|
+
structuredOutputs: {
|
|
722
|
+
schema: Record<string, unknown> | undefined;
|
|
723
|
+
mode: "AUTO" | "STRICT";
|
|
724
|
+
enabled?: undefined;
|
|
725
|
+
};
|
|
726
|
+
};
|
|
727
|
+
};
|
|
728
|
+
};
|
|
729
|
+
declare function withEmbeddingConfig(options: {
|
|
730
|
+
taskType?: 'SEMANTIC_SIMILARITY' | 'CLASSIFICATION' | 'CLUSTERING' | 'RETRIEVAL_DOCUMENT' | 'RETRIEVAL_QUERY' | 'QUESTION_ANSWERING' | 'FACT_VERIFICATION' | 'CODE_RETRIEVAL_QUERY';
|
|
731
|
+
outputDimensionality?: number;
|
|
732
|
+
}): {
|
|
733
|
+
providerOptions: {
|
|
734
|
+
google: {
|
|
735
|
+
outputDimensionality?: number | undefined;
|
|
736
|
+
taskType?: "SEMANTIC_SIMILARITY" | "CLASSIFICATION" | "CLUSTERING" | "RETRIEVAL_DOCUMENT" | "RETRIEVAL_QUERY" | "QUESTION_ANSWERING" | "FACT_VERIFICATION" | "CODE_RETRIEVAL_QUERY" | undefined;
|
|
737
|
+
};
|
|
738
|
+
};
|
|
739
|
+
};
|
|
740
|
+
declare function withYouTubeContext(videoUrl: string, includedFeatures?: Array<'TRANSCRIPT' | 'COMMENTS' | 'METADATA'>): {
|
|
741
|
+
providerOptions: {
|
|
742
|
+
google: {
|
|
743
|
+
youtubeContext: {
|
|
744
|
+
videoUrl: string;
|
|
745
|
+
includedFeatures: ("TRANSCRIPT" | "COMMENTS" | "METADATA")[];
|
|
746
|
+
};
|
|
747
|
+
};
|
|
748
|
+
};
|
|
749
|
+
};
|
|
750
|
+
declare function withGoogleImageGeneration(quality?: 'LOW' | 'MEDIUM' | 'HIGH', count?: number, size?: number): {
|
|
751
|
+
providerOptions: {
|
|
752
|
+
google: {
|
|
753
|
+
imageGeneration: {
|
|
754
|
+
quality: "LOW" | "MEDIUM" | "HIGH";
|
|
755
|
+
count: number;
|
|
756
|
+
size: number;
|
|
757
|
+
};
|
|
758
|
+
};
|
|
759
|
+
};
|
|
760
|
+
};
|
|
761
|
+
declare const GOOGLE_PRESETS: {
|
|
762
|
+
readonly quick: {
|
|
763
|
+
readonly temperature: 0.7;
|
|
764
|
+
readonly topP: 0.9;
|
|
765
|
+
readonly providerOptions: {
|
|
766
|
+
google: {
|
|
767
|
+
safetySettings: Record<string, string>;
|
|
768
|
+
};
|
|
769
|
+
};
|
|
770
|
+
readonly maxOutputTokens: 1024;
|
|
771
|
+
};
|
|
772
|
+
readonly thinking: {
|
|
773
|
+
readonly temperature: 0.3;
|
|
774
|
+
readonly topP: 0.8;
|
|
775
|
+
readonly providerOptions: {
|
|
776
|
+
google: {
|
|
777
|
+
safetySettings: Record<string, string>;
|
|
778
|
+
};
|
|
779
|
+
};
|
|
780
|
+
readonly maxOutputTokens: 4096;
|
|
781
|
+
};
|
|
782
|
+
readonly creative: {
|
|
783
|
+
readonly temperature: 0.9;
|
|
784
|
+
readonly topP: 0.95;
|
|
785
|
+
readonly providerOptions: {
|
|
786
|
+
google: {
|
|
787
|
+
safetySettings: Record<string, string>;
|
|
788
|
+
};
|
|
789
|
+
};
|
|
790
|
+
};
|
|
791
|
+
readonly precise: {
|
|
792
|
+
readonly temperature: 0.1;
|
|
793
|
+
readonly topP: 0.7;
|
|
794
|
+
readonly providerOptions: {
|
|
795
|
+
google: {
|
|
796
|
+
structuredOutputs: {
|
|
797
|
+
enabled: boolean;
|
|
798
|
+
mode: "AUTO" | "STRICT";
|
|
799
|
+
schema?: undefined;
|
|
800
|
+
};
|
|
801
|
+
};
|
|
802
|
+
};
|
|
803
|
+
} | {
|
|
804
|
+
readonly temperature: 0.1;
|
|
805
|
+
readonly topP: 0.7;
|
|
806
|
+
readonly providerOptions: {
|
|
807
|
+
google: {
|
|
808
|
+
structuredOutputs: {
|
|
809
|
+
schema: Record<string, unknown> | undefined;
|
|
810
|
+
mode: "AUTO" | "STRICT";
|
|
811
|
+
enabled?: undefined;
|
|
812
|
+
};
|
|
813
|
+
};
|
|
814
|
+
};
|
|
815
|
+
};
|
|
816
|
+
};
|
|
817
|
+
declare function supportsThinking(modelId: string): boolean;
|
|
818
|
+
declare function supportsGoogleSearch(modelId: string): boolean;
|
|
819
|
+
declare function supportsUrlContext(modelId: string): boolean;
|
|
820
|
+
declare function isGemmaModel(modelId: string): boolean;
|
|
821
|
+
declare namespace xai_d_exports {
|
|
822
|
+
export { GROK_MODEL_GROUPS, GROK_MODEL_IDS, GrokModelCapabilities, WebSearchSource, XAISearchMetadata, XAISource, XSearchSource, createXai, extractSearchMetadata, extractSources$1 as extractSources, xai as grok, grokImage, supportsImageGeneration, supportsLiveSearch, supportsReasoningEffort, supportsVision, withReasoningEffort, withSearchParameters, withSearchSources };
|
|
823
|
+
}
|
|
824
|
+
interface GenerationResult$1 {
|
|
825
|
+
sources?: Array<{
|
|
826
|
+
url: string;
|
|
827
|
+
title: string;
|
|
828
|
+
snippet: string;
|
|
829
|
+
publishedDate?: string;
|
|
830
|
+
author?: string;
|
|
831
|
+
}>;
|
|
832
|
+
providerOptions?: SDKSharedV3ProviderMetadata;
|
|
833
|
+
}
|
|
834
|
+
declare const grokImage: (modelId: (string & {}) | "grok-2-image") => _ai_sdk_provider0.ImageModelV3;
|
|
835
|
+
declare const GROK_MODEL_IDS: {
|
|
836
|
+
readonly GROK_4: "grok-4";
|
|
837
|
+
readonly GROK_3: "grok-3";
|
|
838
|
+
readonly GROK_3_LATEST: "grok-3-latest";
|
|
839
|
+
readonly GROK_3_FAST: "grok-3-fast";
|
|
840
|
+
readonly GROK_3_FAST_LATEST: "grok-3-fast-latest";
|
|
841
|
+
readonly GROK_3_MINI: "grok-3-mini";
|
|
842
|
+
readonly GROK_3_MINI_LATEST: "grok-3-mini-latest";
|
|
843
|
+
readonly GROK_3_MINI_FAST: "grok-3-mini-fast";
|
|
844
|
+
readonly GROK_3_MINI_FAST_LATEST: "grok-3-mini-fast-latest";
|
|
845
|
+
readonly GROK_2: "grok-2";
|
|
846
|
+
readonly GROK_2_LATEST: "grok-2-latest";
|
|
847
|
+
readonly GROK_2_1212: "grok-2-1212";
|
|
848
|
+
readonly GROK_2_VISION: "grok-2-vision";
|
|
849
|
+
readonly GROK_2_VISION_LATEST: "grok-2-vision-latest";
|
|
850
|
+
readonly GROK_2_VISION_1212: "grok-2-vision-1212";
|
|
851
|
+
readonly GROK_CODE_FAST_1: "grok-code-fast-1";
|
|
852
|
+
readonly GROK_BETA: "grok-beta";
|
|
853
|
+
readonly GROK_VISION_BETA: "grok-vision-beta";
|
|
854
|
+
readonly GROK_2_IMAGE: "grok-2-image";
|
|
855
|
+
};
|
|
856
|
+
declare const GROK_MODEL_GROUPS: {
|
|
857
|
+
readonly REASONING_EFFORT_MODELS: readonly ["grok-3-mini", "grok-3-mini-latest", "grok-3-mini-fast", "grok-3-mini-fast-latest", "grok-code-fast-1"];
|
|
858
|
+
readonly VISION_MODELS: readonly ["grok-2-vision", "grok-2-vision-latest", "grok-2-vision-1212", "grok-vision-beta"];
|
|
859
|
+
};
|
|
860
|
+
declare function withSearchParameters(options?: {
|
|
861
|
+
mode?: 'auto' | 'on' | 'off';
|
|
862
|
+
returnCitations?: boolean;
|
|
863
|
+
fromDate?: string;
|
|
864
|
+
toDate?: string;
|
|
865
|
+
maxSearchResults?: number;
|
|
866
|
+
sources?: Array<WebSearchSource | XSearchSource | NewsSearchSource | RSSSearchSource>;
|
|
867
|
+
}): {
|
|
868
|
+
xai: {
|
|
869
|
+
searchParameters: {
|
|
870
|
+
mode: "auto" | "on" | "off";
|
|
871
|
+
returnCitations: boolean;
|
|
872
|
+
fromDate: string | undefined;
|
|
873
|
+
toDate: string | undefined;
|
|
874
|
+
maxSearchResults: number;
|
|
875
|
+
sources: string[] | (WebSearchSource | XSearchSource | NewsSearchSource | RSSSearchSource)[];
|
|
876
|
+
};
|
|
877
|
+
};
|
|
878
|
+
};
|
|
879
|
+
declare function withSearchSources(...sources: Array<WebSearchSource | XSearchSource | NewsSearchSource | RSSSearchSource>): {
|
|
880
|
+
xai: {
|
|
881
|
+
searchParameters: {
|
|
882
|
+
mode: "auto" | "on" | "off";
|
|
883
|
+
returnCitations: boolean;
|
|
884
|
+
fromDate: string | undefined;
|
|
885
|
+
toDate: string | undefined;
|
|
886
|
+
maxSearchResults: number;
|
|
887
|
+
sources: string[] | (WebSearchSource | XSearchSource | NewsSearchSource | RSSSearchSource)[];
|
|
888
|
+
};
|
|
889
|
+
};
|
|
890
|
+
};
|
|
891
|
+
declare function withReasoningEffort(effort: 'low' | 'high'): {
|
|
892
|
+
xai: {
|
|
893
|
+
reasoningEffort: "low" | "high";
|
|
894
|
+
};
|
|
895
|
+
};
|
|
896
|
+
declare function supportsLiveSearch(modelId: string): boolean;
|
|
897
|
+
declare function supportsReasoningEffort(modelId: string): boolean;
|
|
898
|
+
declare function supportsVision(modelId: string): boolean;
|
|
899
|
+
declare function supportsImageGeneration(modelId: string): boolean;
|
|
900
|
+
declare function extractSources$1(result: GenerationResult$1): XAISource[];
|
|
901
|
+
declare function extractSearchMetadata(result: GenerationResult$1): XAISearchMetadata | null;
|
|
902
|
+
interface WebSearchSource {
|
|
903
|
+
type: 'web';
|
|
904
|
+
country?: string;
|
|
905
|
+
allowedWebsites?: string[];
|
|
906
|
+
excludedWebsites?: string[];
|
|
907
|
+
safeSearch?: boolean;
|
|
908
|
+
}
|
|
909
|
+
interface XSearchSource {
|
|
910
|
+
type: 'x';
|
|
911
|
+
xHandles: string[];
|
|
912
|
+
}
|
|
913
|
+
interface NewsSearchSource {
|
|
914
|
+
type: 'news';
|
|
915
|
+
country?: string;
|
|
916
|
+
excludedWebsites?: string[];
|
|
917
|
+
safeSearch?: boolean;
|
|
918
|
+
}
|
|
919
|
+
interface RSSSearchSource {
|
|
920
|
+
type: 'rss';
|
|
921
|
+
links: string[];
|
|
922
|
+
}
|
|
923
|
+
interface XAISource {
|
|
924
|
+
url: string;
|
|
925
|
+
title?: string;
|
|
926
|
+
snippet?: string;
|
|
927
|
+
sourceType: 'url';
|
|
928
|
+
}
|
|
929
|
+
interface XAISearchMetadata {
|
|
930
|
+
queriesUsed: number;
|
|
931
|
+
sourcesFound: number;
|
|
932
|
+
searchTime: number;
|
|
933
|
+
}
|
|
934
|
+
interface GrokModelCapabilities {
|
|
935
|
+
liveSearch: boolean;
|
|
936
|
+
reasoningEffort: boolean;
|
|
937
|
+
}
|
|
938
|
+
declare namespace perplexity_d_exports {
|
|
939
|
+
export { PERPLEXITY_MODEL_GROUPS, PERPLEXITY_MODEL_IDS, PerplexityImage, PerplexityMetadata, PerplexitySource, PerplexityUsageMetadata, extractImages, extractProviderMetadata, extractSources, extractUsageMetadata, isReasoningModel, isResearchModel, supportsCitations, supportsImageResponses, supportsWebSearch, withImages, withResearchMode };
|
|
940
|
+
}
|
|
941
|
+
interface GenerationResult {
|
|
942
|
+
providerOptions?: SDKSharedV3ProviderMetadata;
|
|
943
|
+
sources?: PerplexitySource[];
|
|
944
|
+
}
|
|
945
|
+
declare const PERPLEXITY_MODEL_IDS: {
|
|
946
|
+
readonly SONAR_PRO: "sonar-pro";
|
|
947
|
+
readonly SONAR: "sonar";
|
|
948
|
+
readonly SONAR_REASONING_PRO: "sonar-reasoning-pro";
|
|
949
|
+
readonly SONAR_REASONING: "sonar-reasoning";
|
|
950
|
+
readonly SONAR_DEEP_RESEARCH: "sonar-deep-research";
|
|
951
|
+
};
|
|
952
|
+
declare const PERPLEXITY_MODEL_GROUPS: {
|
|
953
|
+
readonly RESEARCH_MODELS: readonly ["sonar-deep-research", "sonar-pro", "sonar"];
|
|
954
|
+
readonly REASONING_MODELS: readonly ["sonar-reasoning-pro", "sonar-reasoning"];
|
|
955
|
+
readonly MULTIMODAL_MODELS: readonly ["sonar-reasoning-pro", "sonar-reasoning", "sonar-pro", "sonar"];
|
|
956
|
+
};
|
|
957
|
+
declare function withImages(): {
|
|
958
|
+
providerOptions: {
|
|
959
|
+
perplexity: {
|
|
960
|
+
return_images: boolean;
|
|
961
|
+
};
|
|
962
|
+
};
|
|
963
|
+
};
|
|
964
|
+
declare function withResearchMode(returnImages?: boolean): {
|
|
965
|
+
providerOptions: {
|
|
966
|
+
perplexity: {
|
|
967
|
+
return_images: boolean;
|
|
968
|
+
};
|
|
969
|
+
};
|
|
970
|
+
temperature: 0.2;
|
|
971
|
+
maxOutputTokens: 4096;
|
|
972
|
+
};
|
|
973
|
+
declare function supportsImageResponses(modelId: string): boolean;
|
|
974
|
+
declare function supportsWebSearch(modelId: string): boolean;
|
|
975
|
+
declare function supportsCitations(modelId: string): boolean;
|
|
976
|
+
declare function isReasoningModel(modelId: string): boolean;
|
|
977
|
+
declare function isResearchModel(modelId: string): boolean;
|
|
978
|
+
declare function extractSources(result: GenerationResult): PerplexitySource[];
|
|
979
|
+
declare function extractImages(result: GenerationResult): PerplexityImage[];
|
|
980
|
+
declare function extractUsageMetadata(result: GenerationResult): PerplexityUsageMetadata | null;
|
|
981
|
+
declare function extractProviderMetadata(result: GenerationResult): PerplexityMetadata | null;
|
|
982
|
+
interface PerplexitySource {
|
|
983
|
+
url: string;
|
|
984
|
+
title?: string;
|
|
985
|
+
snippet?: string;
|
|
986
|
+
}
|
|
987
|
+
interface PerplexityImage {
|
|
988
|
+
imageUrl: string;
|
|
989
|
+
originUrl: string;
|
|
990
|
+
height?: number;
|
|
991
|
+
width?: number;
|
|
992
|
+
}
|
|
993
|
+
interface PerplexityUsageMetadata {
|
|
994
|
+
citationTokens: number;
|
|
995
|
+
numSearchQueries: number;
|
|
996
|
+
}
|
|
997
|
+
interface PerplexityMetadata {
|
|
998
|
+
usage?: PerplexityUsageMetadata;
|
|
999
|
+
images?: PerplexityImage[];
|
|
1000
|
+
sources?: PerplexitySource[];
|
|
1001
|
+
}
|
|
1002
|
+
//#endregion
|
|
1003
|
+
export { getModelsByTier as S, CreateLanguageModelOptions as _, anthropic_d_exports as a, getCheapestModel as b, TOKENS as c, TokenPreset as d, TopPPreset as f, modelSupportsTools as g, modelSupportsStreaming as h, openai_d_exports as i, TOP_P as l, modelSupportsReasoning as m, xai_d_exports as n, CommonMode as o, commonModes as p, google_d_exports as r, TEMPS as s, perplexity_d_exports as t, TemperaturePreset as u, createLanguageModel as v, getModelTier as x, estimateCost as y };
|
|
1004
|
+
//# sourceMappingURL=index-DotINT7o.d.mts.map
|