UNPKG

@gensx/vercel-ai-sdk

Version:
26 lines (22 loc) 1.1 kB
/** * Check out the docs at https://www.gensx.com/docs * Find us on Github https://github.com/gensx-inc/gensx * Find us on Discord https://discord.gg/F5BSU8Kc */ import * as gensx from '@gensx/core'; import * as ai from 'ai'; // eslint-disable-next-line @typescript-eslint/no-explicit-any function createGSXComponent(name, fn) { return gensx.Component(name, fn); } // Cast to the more specific type const StreamObject = createGSXComponent("StreamObject", ai.streamObject); const StreamText = createGSXComponent("StreamText", ai.streamText); const GenerateText = createGSXComponent("GenerateText", ai.generateText); // Cast to the more specific type const GenerateObject = createGSXComponent("GenerateObject", ai.generateObject); const Embed = createGSXComponent("Embed", ai.embed); const EmbedMany = createGSXComponent("EmbedMany", ai.embedMany); const GenerateImage = createGSXComponent("GenerateImage", ai.experimental_generateImage); export { Embed, EmbedMany, GenerateImage, GenerateObject, GenerateText, StreamObject, StreamText, createGSXComponent }; //# sourceMappingURL=index.js.map