Model API guide
Model Guide for you to implement FLock model
Last updated
Model Guide for you to implement FLock model
Last updated
Generate API Key via
Create Model via
TypeScript
JavaScript
.env
Create an .env
file in the root directory or in your existing env file, add the followings:
Create a flockModel.ts
Create a async/await
function flockModel
wrapping the API call
use axios.post
method for request
We will pass two parameters
question
knowledge_source_id
get the response of the call
We chose to use try/catch
to handle any error during the call to debug the process.
RAG chat with a conversation history.
Successful Response