https://github.com/pablocastilla/fastapi_langchain
combining fast api and langchain
https://github.com/pablocastilla/fastapi_langchain
fastapi gradio langchain python
Last synced: 4 months ago
JSON representation
combining fast api and langchain
- Host: GitHub
- URL: https://github.com/pablocastilla/fastapi_langchain
- Owner: pablocastilla
- Created: 2023-09-20T12:28:46.000Z (almost 3 years ago)
- Default Branch: main
- Last Pushed: 2023-09-22T12:43:45.000Z (almost 3 years ago)
- Last Synced: 2024-05-09T00:23:01.679Z (about 2 years ago)
- Topics: fastapi, gradio, langchain, python
- Language: Python
- Homepage:
- Size: 125 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Introduction
This is a project to demostrate the use of a langchain chatbot with fastapi. The funcionality is
a bot that will get the user name, id and simptomps and will do the following:
- Generate a json with the user data, urgency and specialty
- Generate the response to the user
# Frontend
The frontend is a simple UI using gradio to display the chatbot.
# Backend
The backend is a fastapi server that uses the langchain chatbot to generate responses.
# How to run
With VS Code just launch backend and frontend, then go to http://127.0.0.1:7860 and start chatting.
# Best practices
- Virtual environment generated through pipenv. To start the environment just run `pipenv shell` and to install the dependencies `pipenv install`
- pre-commit hooks to validate stuff before commiting. To install the hooks run `pre-commit install`