ai-rating-app / README.md
aartstudio's picture
Upload 3 files
533c8c8 verified

A newer version of the Gradio SDK is available: 6.13.0

Upgrade
metadata
title: Groq AI Model Evaluator
emoji: 🧪
colorFrom: indigo
colorTo: purple
sdk: gradio
sdk_version: 4.0.0
app_file: app.py
pinned: false

Groq AI Model Evaluator – Gradio App for Hugging Face Spaces

This app lets a user compare three Groq-hosted AI models by:

  1. Entering a prompt (question or instruction).
  2. Viewing the responses from three different Groq models:
    • Model A: llama3-8b-8192
    • Model B: llama3-70b-8192
    • Model C: gemma-7b-it
  3. Rating each response from 1 to 5.
  4. Repeating this process for 5 rounds.
  5. At the end, the app aggregates the scores and shows a final ranking of the models based on the user's ratings.

API key

This Space uses the Groq Python SDK and expects a single environment variable:

  • GROQ_API_KEY – your Groq API key

In your Hugging Face Space:

  1. Go to Settings → Repository secrets.
  2. Add a secret named GROQ_API_KEY with your key value.
  3. Save. The app will read it via os.getenv("GROQ_API_KEY").

Files

  • app.py – main Gradio app
  • requirements.txt – Python dependencies
  • README.md – this documentation and Space configuration

Run locally

pip install -r requirements.txt
export GROQ_API_KEY="your_groq_api_key"
python app.py