metadata
title: GAIA Unit 4 Agent
emoji: π§
colorFrom: gray
colorTo: blue
sdk: gradio
sdk_version: 4.44.0
app_file: app.py
pinned: false
license: apache-2.0
GAIA Unit 4 β Hugging Face Agents Course (final assignment)
This folder is a drop-in replacement for the course Space
agents-course/Final_Assignment_Template.
One-time: create your Space
- On Hugging Face, Duplicate the template Space above (or create a new Gradio Space and copy these files into the repo root).
- In the Space Settings β Repository secrets, add:
HF_TOKEN: a Hugging Face access token with read permission (for Inference API / serverless models).
- Optional Variables (or secrets) to tune models:
HF_INFERENCE_PROVIDERβ omit by default so the client usesauto: the first inference provider that supports your chosen model on the Hub. Do not sethf-inferenceunless that model lists it β many chat models (e.g. Qwen2.5-7B-Instruct) only support together / featherless-ai, and forcinghf-inferenceyields 404. If the auto order hits a provider that returns 401 (e.g. Novita), reorder providers in HF settings or pin e.g.HF_INFERENCE_PROVIDER=together.GAIA_TEXT_MODELβ defaultQwen/Qwen2.5-7B-Instruct(broad provider mapping via Together).GAIA_ASR_MODELβ defaultopenai/whisper-large-v3GAIA_VISION_MODELβ defaultmeta-llama/Llama-3.2-11B-Vision-InstructGAIA_API_URLβ defaulthttps://agents-course-unit4-scoring.hf.spaceGAIA_USE_CACHEβ1(default) or0to disablegaia_answers_cache.json
Keep the Space public so agent_code (β¦/tree/main) verifies for the leaderboard.
Local dry-run (no submission)
cd gaia_unit4_space
python -m venv .venv && source .venv/bin/activate
pip install -r requirements.txt
export HF_TOKEN=hf_...
python run_local_eval.py
This fetches /questions, runs the agent, prints answers, and writes local_eval_answers.json. It does not call /submit.
What was fixed vs the stock template
- Downloads attachments when
file_nameis set (GET /files/{task_id}). - Tool-using agent (web, Wikipedia, Python, Excel, ASR, vision, YouTube transcripts).
- Deterministic shortcuts for the reversed-English puzzle, Cayley-table commutativity,
.pystdout, and.xlsxfood-sales heuristic. - Optional Crypto tab (BTC/USD demo only; not used for GAIA).
Leaderboard
Submit scores via the Gradio app after logging in. Student leaderboard:
agents-course/Students_leaderboard.