Skip to content
This repository has been archived by the owner on Nov 28, 2023. It is now read-only.

foxminchan/GovernmentChatbot

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

banner


Government Chatbot - A LLM Application 🤖

Government Chatbot is a monorepo project built with Nx technology. It is a set of extensible dev tools for monorepos, which helps you develop like Google, Facebook, and Microsoft.

Table of Contents

Overview

This repository hosts an innovative chatbot solution that intelligently manages and streamlines the process of resolving diverse administrative procedures. Powered by advanced language models, the chatbot ensures smooth navigation through complex tasks, ensuring an intuitive and user-friendly experience for all users.

Methodology

Retrieval Augmented Generation (RAG) represents an innovative paradigm that harnesses the combined strengths of the ChatGPT API, LangChain, and Weaviate. This sophisticated integration facilitates a seamless amalgamation of information retrieval and content generation, resulting in outputs that are not only accurate and coherent but also infused with creativity and depth. By capitalizing on the individual capabilities of each component, RAG effectively bridges the gap between data-driven precision and the art of nuanced communication, catering to a diverse spectrum of user requirements and preferences.

Retrieval Augmented Generation

Technology Stack

Getting Started

💻 Infrastructure

  • Docker - Docker is an open platform for developing, shipping, and running applications.
  • WSL 2 - The Windows Subsystem for Linux lets developers run a GNU/Linux environment.
  • Nodejs - Node.js® is a JavaScript runtime built on Chrome's V8 JavaScript engine.
  • npm - npm is the package manager for the Node JavaScript platform.
  • Pulumi - Pulumi is a manage infrastructure, secrets, and configurations intuitively on any cloud.

📦 Services

  • MongoDB - MongoDB is a general purpose, document-based, distributed database built for modern application developers and for the cloud era.
  • ChatGPT API - ChatGPT is a large-scale pretrained generative model for conversation. It is trained on 147M conversation-like exchanges extracted from Reddit comment chains over a period spanning from 2005 through 2017.
  • Weaviate - Weaviate is an open-source vector database. It allows you to store data objects and vector embeddings from your favorite ML-models, and scale seamlessly into billions of data objects.
  • LLMonitor - LLMonitor is an observability, analytics and tests for AI agents and chatbots.

🛠️ Setup

First, clone the repository to your local machine:

git clone https://github.com/foxminchan/GovernmentLLM

Next, navigate to the root directory of the project and install the dependencies:

npm install --force

🚀 Running the application

For the website, you can run the following command:

npx nx serve website

For the docs, you can run the following command:

npx nx serve docs

For the API , you can run the following command:

npx nx serve api

Warning If you run the API in the first time, you need to generate the prisma client by running the following command:

cd apps/api && npx prisma generate

Make sure you have setup the environment variables in the .env file for API and Website. The sample of the .env file is in the .env.example file.

To set up the infrastructure, you can run the following command:

npx nx up iac

Note Make sure you have installed the pulumi CLI, have pulumi account and AWS credentials.

Dependency Graph

You can see the dependency graph of the project by running the following command:

npx nx dep-graph

License

This project is licensed under the MIT License - see the LICENSE file for details