https://github.com/sureshbeekhani/langgraph-based-ai-agent-chatbot
The LangGraph-based AI Agent Chatbot is an open-source project that leverages the power of LangGraph, FastAPI, and Streamlit
https://github.com/sureshbeekhani/langgraph-based-ai-agent-chatbot
fastapi groq-models langgraph streamlit
Last synced: about 2 months ago
JSON representation
The LangGraph-based AI Agent Chatbot is an open-source project that leverages the power of LangGraph, FastAPI, and Streamlit
- Host: GitHub
- URL: https://github.com/sureshbeekhani/langgraph-based-ai-agent-chatbot
- Owner: SURESHBEEKHANI
- Created: 2025-01-29T05:58:26.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2025-01-29T16:05:21.000Z (over 1 year ago)
- Last Synced: 2025-03-26T02:11:09.494Z (about 1 year ago)
- Topics: fastapi, groq-models, langgraph, streamlit
- Language: Python
- Homepage:
- Size: 5.86 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: Readme.md
Awesome Lists containing this project
README
# LangGraph-based AI Agent Chatbot
This project is a LangGraph-based AI Agent Chatbot deployed on Hugging Face Spaces. It uses FastAPI for the backend and Streamlit for the frontend.
## Features
- Define custom AI agents with system prompts.
- Select from a list of Groq models.
- Optionally allow the agent to perform web searches.
- Interact with the AI agent through a user-friendly interface.
## Requirements
- Docker
- Python 3.9+
## Setup
### 1. Clone the Repository
```bash
git clone https://github.com/yourusername/LangGraph-based-AI-Agent-Chatbot.git
cd LangGraph-based-AI-Agent-Chatbot
```
### 2. Create a `.env` File
Create a `.env` file in the root directory and add your API keys:
```plaintext
GROQ_API_KEY=your_groq_api_key
TAVILY_API_KEY=your_tavily_api_key
```
### 3. Build and Run the Docker Container
```bash
docker build -t langgraph-ai-agent .
docker run -p 8501:8501 -p 9999:9999 langgraph-ai-agent
```
### 4. Access the Application
Open your browser and go to `http://localhost:8501` to access the Streamlit frontend.
## File Structure
- `frontend.py`: Streamlit app for the user interface.
- `backend.py`: FastAPI app for handling API requests.
- `ai_agent.py`: Logic for interacting with the AI agent.
- `Dockerfile`: Docker configuration for containerizing the application.
- `requirements.txt`: List of Python dependencies.
## Usage
1. Define your AI agent by entering a system prompt.
2. Select a Groq model from the list.
3. Optionally enable web search.
4. Enter your query and click "Ask Agent!" to get a response.
## License
This project is licensed under the MIT License.