- Notifications
You must be signed in to change notification settings - Fork0
decryptable/libai
Folders and files
| Name | Name | Last commit message | Last commit date | |
|---|---|---|---|---|
Repository files navigation
To install:
npm i github:decryptable/libai
importlibaifrom"libai";importgenerateAuthTokenfrom"./dist/utils/generateAuthToken";constmain=async()=>{constauthToken=awaitgenerateAuthToken();if(!authToken)return;console.log(`Auth token:${authToken}`)constmodels=awaitlibai.getModels();constselectedModel=models[0];console.log("Selected model:",selectedModel)constmessage="Hey there! How are you?";constwebSearch=true;letfinalResponse="";awaitlibai.getChatResponse(message,authToken,selectedModel.id,webSearch,null,(streamData)=>{if(streamData.content){process.stdout.write(streamData.content);finalResponse+=streamData.content;}});console.log(`\nFinal Response:${finalResponse}`);};main()
About
Access AI services without any API keys!
Topics
Resources
Uh oh!
There was an error while loading.Please reload this page.
Stars
Watchers
Forks
Uh oh!
There was an error while loading.Please reload this page.







