Metadata-Version: 2.4
Name: custom-react-agent
Version: 0.1.0
Summary: A custom ReAct agent using Groq, Tavily, Wikipedia, and a calculator tool.
Requires-Python: >=3.10
Description-Content-Type: text/markdown
Requires-Dist: groq
Requires-Dist: python-dotenv
Requires-Dist: tavily-python
Requires-Dist: wikipedia

# Custom ReAct Agent

A small importable Python package for a Groq-powered ReAct agent with Tavily search, Wikipedia lookup, and calculator tools.

## Setup

```powershell
pip install custom-react-agent
```

## API Keys

This package does not include API keys. Set your own keys before running the agent:

```powershell
$env:GROQ_API_KEY="your_groq_api_key_here"
$env:TAVILY_API_KEY="your_tavily_api_key_here"
$env:GROQ_MODEL="llama-3.1-8b-instant"
```

Or create a `.env` file in the folder where you run the command:

```env
GROQ_API_KEY=your_groq_api_key_here
TAVILY_API_KEY=your_tavily_api_key_here
GROQ_MODEL=llama-3.1-8b-instant
```

For local development from this repository:

```powershell
cd "C:\Custom ReAct Agent - Copy"
python -m pip install -e .
```

## Usage

```python
from custom_react_agent import ReActAgent

agent = ReActAgent(verbose=False)
answer = agent.run("What is 25 * 19?")
print(answer)
```

You can also run it from the command line:

```powershell
custom-react-agent "Calculate 123 * 456"
```

or:

```powershell
python -m custom_react_agent "Search for the latest Python release"
```

## Safe Build

The real `.env` file is private and should never be uploaded. This project includes `.env.example` as a safe template.

Build and check the package:

```powershell
cd "C:\Custom ReAct Agent - Copy"
Remove-Item -Recurse -Force dist, build -ErrorAction SilentlyContinue
python -m pip install --upgrade build twine
python -m build
python -m twine check dist/*
```

Before uploading, inspect the source archive and confirm `.env` is not listed:

```powershell
tar -tf dist\custom_react_agent-0.1.0.tar.gz
```
