Spaces:
Sleeping
Sleeping
| # Setup Guide (VS Code) | |
| ## Prerequisites | |
| - Python 3.11 or higher β download from [python.org](https://python.org) | |
| - Git β download from [git-scm.com](https://git-scm.com) | |
| - VS Code β download from [code.visualstudio.com](https://code.visualstudio.com) | |
| --- | |
| ## Step 1 β Open the project | |
| 1. Unzip `teamforge.zip` | |
| 2. In VS Code: **File β Open Folder** β select the `teamforge` folder | |
| 3. Open the terminal: **View β Terminal** (or `Ctrl + `` ` ``) | |
| --- | |
| ## Step 2 β Create virtual environment | |
| **Windows:** | |
| ``` | |
| python -m venv venv | |
| venv\Scripts\activate | |
| ``` | |
| **Mac / Linux:** | |
| ``` | |
| python3 -m venv venv | |
| source venv/bin/activate | |
| ``` | |
| You should see `(venv)` appear at the start of your terminal prompt. | |
| > **If `python -m venv venv` hangs or errors:** | |
| > - Try `py -m venv venv` (Windows) | |
| > - Try `python3 -m venv venv` (Mac/Linux) | |
| > - Or skip venv and just run `pip install -r requirements.txt` directly | |
| --- | |
| ## Step 3 β Install dependencies | |
| ``` | |
| pip install -r requirements.txt | |
| ``` | |
| This installs: pydantic, openai, rich, pytest, ruff | |
| --- | |
| ## Step 4 β Run the demo (no API key needed!) | |
| ``` | |
| python demo.py | |
| ``` | |
| You will see a beautiful step-by-step agent trace in your terminal. | |
| --- | |
| ## Step 5 β Run the tests | |
| ``` | |
| pytest tests/test_environment.py -v | |
| ``` | |
| All 21 tests should pass (green). | |
| --- | |
| ## Step 6 β Get a free Groq API key | |
| 1. Go to [console.groq.com](https://console.groq.com) | |
| 2. Sign up (free, no credit card) | |
| 3. Create an API key | |
| 4. Copy `.env.example` β `.env` and paste your key: | |
| ``` | |
| cp .env.example .env | |
| ``` | |
| Then open `.env` and set: | |
| ``` | |
| GROQ_API_KEY=gsk_your_key_here | |
| ``` | |
| --- | |
| ## Step 7 β Run the benchmark | |
| **Windows:** | |
| ``` | |
| set GROQ_API_KEY=gsk_your_key_here | |
| python benchmark.py --model llama3-8b-8192 | |
| ``` | |
| **Mac / Linux:** | |
| ``` | |
| export GROQ_API_KEY=gsk_your_key_here | |
| python benchmark.py --model llama3-8b-8192 | |
| ``` | |
| --- | |
| ## Common Issues | |
| | Problem | Fix | | |
| |---------|-----| | |
| | `python` not found | Use `python3` or `py` instead | | |
| | `venv` command hangs | Skip it, run `pip install -r requirements.txt` directly | | |
| | `ModuleNotFoundError: rich` | Run `pip install -r requirements.txt` | | |
| | `git: command not found` | Install Git from git-scm.com | | |
| | Terminal shows `>>>` | You're in Python REPL β press `Ctrl+Z` then Enter to exit | | |
| --- | |
| ## File Structure | |
| ``` | |
| teamforge/ | |
| βββ demo.py β run this first | |
| βββ benchmark.py β model comparison | |
| βββ baseline_inference.py β single agent run | |
| βββ environment.py β core environment | |
| βββ models.py β data models | |
| βββ grader.py β scoring | |
| βββ reward.py β reward function | |
| βββ tasks/ β easy / medium / hard / bonus | |
| βββ sandbox/ β git isolation | |
| βββ tests/ β test suite | |
| βββ results/ β benchmark output | |
| βββ requirements.txt β dependencies | |
| βββ .env.example β copy to .env with your API key | |
| βββ README.md β full documentation | |
| ``` | |