Files
formbricks/apps/web/lib/aiModels.ts
T
longvantruong 562b9c5296 chore: merge main in to mobile-sdk-custom (#5523)
Co-authored-by: Matti Nannt <mail@matthiasnannt.com>
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
Co-authored-by: Piyush Gupta <56182734+gupta-piyush19@users.noreply.github.com>
Co-authored-by: Anshuman Pandey <54475686+pandeymangg@users.noreply.github.com>
Co-authored-by: victorvhs017 <115753265+victorvhs017@users.noreply.github.com>
Co-authored-by: pandeymangg <anshuman.pandey9999@gmail.com>
Co-authored-by: Piyush Gupta <piyushguptaa2z123@gmail.com>
Co-authored-by: Dhruwang Jariwala <67850763+Dhruwang@users.noreply.github.com>
Co-authored-by: Victor Santos <victor@formbricks.com>
Co-authored-by: Dhruwang <dhruwangjariwala18@gmail.com>
Co-authored-by: Vijay <vijayraghav22@gmail.com>
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
Co-authored-by: Johannes <johannes@formbricks.com>
Co-authored-by: Peter Pesti-Varga <peter@lokin.hu>
Co-authored-by: Piyush Jain <122745947+d3vb0ox@users.noreply.github.com>
Co-authored-by: Jakob Schott <154420406+jakobsitory@users.noreply.github.com>
Co-authored-by: Gulshan Kumar <gulshanbahadur002@gmail.com>
Co-authored-by: Harsh Bhat <90265455+harshsbhat@users.noreply.github.com>
2025-04-28 09:32:17 +02:00

22 lines
730 B
TypeScript

import { createAzure } from "@ai-sdk/azure";
import {
AI_AZURE_EMBEDDINGS_API_KEY,
AI_AZURE_EMBEDDINGS_DEPLOYMENT_ID,
AI_AZURE_EMBEDDINGS_RESSOURCE_NAME,
AI_AZURE_LLM_API_KEY,
AI_AZURE_LLM_DEPLOYMENT_ID,
AI_AZURE_LLM_RESSOURCE_NAME,
} from "./constants";
export const llmModel = createAzure({
resourceName: AI_AZURE_LLM_RESSOURCE_NAME, // Azure resource name
apiKey: AI_AZURE_LLM_API_KEY, // Azure API key
})(AI_AZURE_LLM_DEPLOYMENT_ID || "llm");
export const embeddingsModel = createAzure({
resourceName: AI_AZURE_EMBEDDINGS_RESSOURCE_NAME, // Azure resource name
apiKey: AI_AZURE_EMBEDDINGS_API_KEY, // Azure API key
}).embedding(AI_AZURE_EMBEDDINGS_DEPLOYMENT_ID || "embeddings", {
dimensions: 512,
});