Spaces:
Runtime error
Runtime error
File size: 2,484 Bytes
a57e209 758a727 a57e209 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 |
---
title: Agentic AI-powered chatbot with tools
emoji: 🐨
colorFrom: blue
colorTo: red
sdk: streamlit
sdk_version: 1.42.0
app_file: app.py
pinned: false
license: apache-2.0
short_description: Agentic AI chatbot using LangGraph and LangChain tools.
---
# Agentic Chatbot with LangGraph, LangChain, and Python
This project demonstrates how to build an **Agentic AI-powered chatbot with tools** using [LangGraph](https://github.com/langchain-ai/langgraph), [LangChain](https://github.com/langchain-ai/langchain), and Python. The chatbot leverages agentic workflows to handle complex, multi-step conversations with users.
## Features
- **Agentic Reasoning:** The chatbot can plan, reason, and execute tasks using agent-based logic.
- **Modular Design:** Built with LangGraph for flexible conversational flows.
- **Extensible:** Easily add new tools, memory, or integrations.
- **Supports OpenAI and Groq Models:** Works with both OpenAI and Groq LLMs via API keys.
## Requirements
- Python 3.8+
- `langchain`
- `langgraph`
- `streamlit`
- (Optional) OpenAI API key or Groq API key
## Usage
1. **Clone the repository:**
```bash
git clone https://github.com/abhinavranjan-ai/agenticai-chatbot-with-tools.git
## Installation
```bash
pip install -r requirements.txt
```
2. **Configure your environment:**
- Launch the app and enter your OpenAI or Groq API key in the Streamlit UI when prompted.
3. **Run the chatbot app:**
```bash
streamlit run app.py
```
## How It Works
- **LangChain** provides the language model interface and agent tools.
- **LangGraph** manages the conversational flow as a graph, enabling complex agentic behaviors.
- **Streamlit** powers the user interface, allowing users to input their API keys and interact with the chatbot.
- The chatbot receives user input, reasons about the task, and responds or takes actions accordingly.
## Example
```
User: What's the weather in Paris and set a reminder for tomorrow.
Bot: The weather in Paris is sunny. Reminder set for tomorrow.
```
## Customization
- Add new tools or memory modules in `chatbot.py`.
- Modify the agent's reasoning logic using LangChain's agent framework.
## Try It Online
You can try the chatbot app instantly in your browser via [Hugging Face Spaces](https://huggingface.co/spaces/abhinavranjan-ai/langgraph-project).
> **Note:** If you find this project helpful, feel free to [follow me on LinkedIn](https://www.linkedin.com/in/abhinav-ranjan-ai/)!
|