Metadata-Version: 2.1
Name: llama-index-packs-gradio-react-agent-chatbot
Version: 0.2.0
Summary: llama-index packs gradio_react_agent_chatbot integration
License: MIT
Keywords: chatbot,gradio,react-agent,tools
Author: Your Name
Author-email: you@example.com
Maintainer: nerdai
Requires-Python: >=3.8.1,<4.0
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Requires-Dist: llama-index-core (>=0.11.0,<0.12.0)
Requires-Dist: llama-index-llms-openai (>=0.2.0,<0.3.0)
Requires-Dist: llama-index-tools-arxiv (>=0.2.0,<0.3.0)
Requires-Dist: llama-index-tools-wikipedia (>=0.2.0,<0.3.0)
Description-Content-Type: text/markdown

# Gradio ReActAgent Chatbot Pack

Create a ReActAgent Chatbot equipped with two LlamaHub tools, namely:
[ArxivToolSpec](https://llamahub.ai/l/tools-arxiv) and Wikipedia tool and
[WikipediaToolSpec](https://llamahub.ai/l/tools-wikipedia).

This pack's Gradio app is built using Gradio `Blocks`. User messages are submitted
via a `TextBox` Block, which are then handled by a LlamaIndex `ReActAgent` to generate a
response (calling required tools). The result is then sent to a `Chatbot` Block —
additionally the agent's thoughts are captured in an `HTML` Block.

## CLI Usage

You can download llamapacks directly using `llamaindex-cli`, which comes installed with the `llama-index` python package:

```bash
llamaindex-cli download-llamapack GradioReActAgentPack --download-dir ./gradio_react_agent_chatbot
```

You can then inspect the files at `./gradio_react_agent_chatbot` and use them as a template for your own project!

To run the app directly, use in your terminal:

```bash
export OPENAI_API_KEY="sk-...
python ./gradio_react_agent_pack/base.py
```

