Skip to content

VaraEco/Vara-BE

Repository files navigation

Vara-BE

Table of Contents

  1. Introduction
  2. Features
  3. Installation
  4. Code Overview

Introduction

Backend repository for Vara.

Features

  • Vara Chatbot

Installation

Steps

  1. Clone the repository:
    git clone https://github.com/VaraEco/Vara-BE.git
  2. Navigate to the project directory:
    cd Vara-BE
  3. Install dependencies:
    pip install -r requirements.txt
  4. Configure environment variables:
    PINECONE_API_KEY=''
    AWS_ACCESS_KEY_ID=''
    AWS_SECRET_ACCESS_KEY=''
  5. Run:
     python app.py

Code Overview

The backend currently only supports the chatbot functionality. The chatbot can be used to query the data inside the Green House Gas (GHG) Protocol document. We use the Pinecone vector database to house the chunks of the GHG protocol document. We used AWS Bedrock to provision the Large Language Model (LLM). When the user enters their query on the frontend, the query is redirected to this backend. We currently support chat history upto 6 previous conversations. The new query is transformed (if needed) considering the history. The transformed query is then used to retrieve the 4 most similar chunks from the GHG protocol document. This reetireved context along with the query is then passed to our LLM to generate a response which is then sent back to the frontend.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors