Rulvar API reference / @rulvar/bridge-ai-sdk
@rulvar/bridge-ai-sdk
Bridge adapter that wraps a Vercel AI SDK LanguageModelV4 model as a Rulvar provider adapter, covering the long tail of providers; models on other specification versions are rejected by a runtime check, and the package is, by design, the highest-churn one in the project. Exports bridgeAiSdk.
Part of Rulvar, an embeddable TypeScript engine for durable, budget-bounded multi-agent LLM workflows, where a completed LLM call is never paid for twice. Full documentation: docs.rulvar.com.
Install
bash
pnpm add @rulvar/core @rulvar/bridge-ai-sdkAdd the AI SDK provider package you are bridging alongside it.
Documentation
License
Interfaces
| Interface | Description |
|---|---|
| BridgeAiSdkOptions | @rulvar/bridge-ai-sdk: wraps any Vercel AI SDK LanguageModelV4 as a Rulvar ProviderAdapter (https://docs.rulvar.com/guide/providers). Documented as the highest-churn package of the set: it tracks the @ai-sdk/provider major line and its provider-major bumps are the most likely driver of post-1.0 BREAKING majors. |
Functions
| Function | Description |
|---|---|
| aiSdkErrorToWire | @rulvar/bridge-ai-sdk: wraps any Vercel AI SDK LanguageModelV4 as a Rulvar ProviderAdapter (https://docs.rulvar.com/guide/providers). Documented as the highest-churn package of the set: it tracks the @ai-sdk/provider major line and its provider-major bumps are the most likely driver of post-1.0 BREAKING majors. |
| bridgeAiSdk | @rulvar/bridge-ai-sdk: wraps any Vercel AI SDK LanguageModelV4 as a Rulvar ProviderAdapter (https://docs.rulvar.com/guide/providers). Documented as the highest-churn package of the set: it tracks the @ai-sdk/provider major line and its provider-major bumps are the most likely driver of post-1.0 BREAKING majors. |