'use strict';
import 'dotenv/config';
import { generateText, streamText } from 'ai';
import { createGoogleGenerativeAI } from '@ai-sdk/google';
import { envSettingKeys } from '../../common/infra/env-setting-keys.js';
import { getStringEnvSetting } from '../../../fd-toolbox/infra/env-functions.js';

var __defProp=Object['defineProperty'],__name=(_0xa8affd,_0x2deb7a)=>__defProp(_0xa8affd,'name',{'value':_0x2deb7a,'configurable':!![]});const geminiVersion='gemini-3-flash-preview',google=createGoogleGenerativeAI({'apiKey':getStringEnvSetting(envSettingKeys['aiApiKey'])??void(0x15d7*0x1+0x20c4+-0x369b)});async function getAiGoogleGeneratedText(_0x2d50cd){const _0x2b7d40=await generateText({'model':google(getStringEnvSetting(envSettingKeys['aiModelName'])??geminiVersion),'prompt':_0x2d50cd['prompt'],'system':_0x2d50cd['systemPrompt'],'tools':_0x2d50cd['tools']});return _0x2b7d40;}__name(getAiGoogleGeneratedText,'getAiGoogleGeneratedText');async function getAiGoogleStreamText(_0x26a171){const _0x4409ee=streamText({'model':google(getStringEnvSetting(envSettingKeys['aiModelName'])??geminiVersion),'prompt':_0x26a171['prompt'],'system':_0x26a171['systemPrompt'],'tools':_0x26a171['tools']});return _0x4409ee['textStream'];}__name(getAiGoogleStreamText,'getAiGoogleStreamText');

export { getAiGoogleGeneratedText, getAiGoogleStreamText };
