Buckets:
| import { Effect } from "effect" | |
| import { PluginV2 } from "../../plugin" | |
| export const LLMGatewayPlugin = PluginV2.define({ | |
| id: PluginV2.ID.make("llmgateway"), | |
| effect: Effect.gen(function* () { | |
| return { | |
| "catalog.transform": Effect.fn(function* (evt) { | |
| for (const item of evt.provider.list()) { | |
| if (item.provider.enabled === false) continue | |
| if (item.provider.api.type !== "aisdk") continue | |
| if (item.provider.api.package !== "@ai-sdk/openai-compatible") continue | |
| if (item.provider.api.url !== "https://api.llmgateway.io/v1") continue | |
| evt.provider.update(item.provider.id, (provider) => { | |
| provider.request.headers["HTTP-Referer"] = "https://opencode.ai/" | |
| provider.request.headers["X-Title"] = "opencode" | |
| provider.request.headers["X-Source"] = "opencode" | |
| }) | |
| } | |
| }), | |
| } | |
| }), | |
| }) | |
Xet Storage Details
- Size:
- 906 Bytes
- Xet hash:
- 210573b9e4f8211f3bc7e60e99bec2a9f96961c3f01c119f6613dc68a311f8de
·
Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.