rawi
Version:
Rawi (راوي) is the developer-friendly AI CLI that brings the power of 12 major AI providers directly to your terminal. With seamless shell integration, persistent conversations, and 200+ specialized prompt templates, Rawi transforms your command line into
4 lines • 1.94 kB
JavaScript
/* Rawi (راوي) is the developer-friendly AI CLI that brings the power of 12 major AI providers directly to your terminal. With seamless shell integration, persistent conversations, and 200+ specialized prompt templates, Rawi transforms your command line into an intelligent development workspace. */
import{createGoogleGenerativeAI as n}from"@ai-sdk/google";import{streamText as a}from"ai";var l=["gemini-1.5-flash","gemini-1.5-flash-latest","gemini-1.5-flash-001","gemini-1.5-flash-002","gemini-1.5-flash-8b","gemini-1.5-flash-8b-latest","gemini-1.5-flash-8b-001","gemini-1.5-pro","gemini-1.5-pro-latest","gemini-1.5-pro-001","gemini-1.5-pro-002","gemini-2.0-flash","gemini-2.0-flash-001","gemini-2.0-flash-live-001","gemini-2.0-flash-lite","gemini-2.0-pro-exp-02-05","gemini-2.0-flash-thinking-exp-01-21","gemini-2.0-flash-exp","gemini-2.5-pro-exp-03-25","gemini-2.5-pro-preview-05-06","gemini-2.5-flash-preview-04-17","gemini-exp-1206","gemma-3-27b-it","learnlm-1.5-pro-experimental"],m=l.map(e=>({name:e,displayName:e})),d={name:"google",displayName:"\u{1F534} Google (Gemini)",models:m},h=async(e,r)=>{try{let o=e.providerSettings,i=o?.apiKey||e.apiKey;if(!i)throw new Error("API key is required for Google");let s=o?.baseURL||"https://generativelanguage.googleapis.com/v1beta",g=n({apiKey:i,baseURL:s}),t=a({model:g(e.model),prompt:r,temperature:e.temperature||.7,maxTokens:e.maxTokens||2048});return{textStream:t.textStream,fullResponse:t.text}}catch(o){throw new Error(`Error calling Google AI streaming API: ${o instanceof Error?o.message:String(o)}`)}};export{m as a,d as b,h as c};
/* Rawi (راوي) is the developer-friendly AI CLI that brings the power of 12 major AI providers directly to your terminal. With seamless shell integration, persistent conversations, and 200+ specialized prompt templates, Rawi transforms your command line into an intelligent development workspace. */
//# sourceMappingURL=chunk-THAGAVS3.js.map