Skip to content

tiluckdave/nyaysathi-backend

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

42 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

NyaySathi Backend

This repository contains the backend code for NyaySathi project. Nyay Sathi is an AI powered platform where people can get legal guidance and advice for their legal quiries through voice input and output in their regional language.

The backend is build using FLask and it is deployed on replit. This flask server is responsible for the following tasks.

  1. Handling the incoming requests from the frontend.
  2. Using RAG (Retrival Augemented Generation) model with OpenAI's GPT 3 embeddings to generate response for the user's query.
  3. Using Indian Kanoon API to fetch relevant legal documents for the user's query to train the RAG model.
  4. Using Narakeet API to convert the generated response into audio.
  5. Sending the response back to the frontend.

Getting Started

  • Setup a virtual environment and install the dependencies.
python3 -m venv venv
source venv/bin/activate
pip install -r requirements.txt
  • Create a .env file and add the following variables.
OPENAI_KEY=<your openai api key>
ORG=<your openai org id>
NARAKEET_KEY=<your narakeet api key>
  • Run the flask server.
flask run
  • The server will be running on port 5000.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages