ernesto genai
1.0.0
This project is a chatbot application that uses Azure OpenAI to provide responses. The chatbot is designed to help users fulfill their IRS documents properly in Portuguese.
Clone the repository:
git clone https://github.com/gmaragao/ernesto-genai
cd ernesto-genai
Install dependencies:
npm install
Create a .env
file in the root directory and add your Azure OpenAI credentials:
AZURE_OPENAI_ENDPOINT=your_azure_openai_endpoint
AZURE_OPENAI_API_KEY=your_azure_openai_api_key
BACKEND_ENDPOINT=http://localhost:3000/api/chat
Start the Express server:
node server.js
Open index.html
in your browser to interact with the chatbot.
POST /api/chat
: Sends a user message to the Azure OpenAI service and returns the chatbot's response.GET /api/config
: Returns the backend endpoint configuration.server.js
: The Express server that handles API requests.index.html
: The frontend of the chatbot application..env
: Environment variables for configuration.