File size: 1,971 Bytes
5a49ee7 c502324 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 |
---
title: Vibe Check Translations
emoji: π
colorFrom: gray
colorTo: green
sdk: gradio
sdk_version: 5.38.2
app_file: app.py
pinned: false
short_description: A/B test translations
---
# Translation A/B Testing App
A Gradio app for comparing translation quality between different model configurations through A/B testing.
## Features
- **Language Selection**: Choose from available languages in the S3 bucket
- **Side-by-Side Comparison**: Compare translations from "few-shots" vs "no-few-shots" configurations
- **Randomized Presentation**: The order of configurations is randomized to avoid bias
- **Progress Tracking**: Shows current progress through the dataset
- **Results Summary**: Displays final vote counts and percentages
## Setup
1. Install dependencies:
```bash
pip install -r requirements.txt
```
2. Configure AWS credentials (for S3 access):
```bash
export AWS_ACCESS_KEY_ID=your_key
export AWS_SECRET_ACCESS_KEY=your_secret
# or use AWS CLI: aws configure
```
3. Run the app:
```bash
python app.py
```
The app will be available at `http://localhost:7860`
## Usage
1. **Select Language**: Choose a language from the dropdown menu
2. **Load Data**: Click "Load Data" to fetch translation pairs from S3
3. **Compare Translations**:
- Original text is shown at the top
- Two translations (A and B) are shown side by side
- Click "Choose Left" or "Choose Right" to select the better translation
4. **View Results**: After all comparisons, see the final vote counts
## Data Source
The app loads translation data from `s3://fineweb-multilingual-v1/experiments/translations/vibe-checks/` with the following structure:
- `{language}_Latn/few-shots.jsonl` - Translations with few-shot examples
- `{language}_Latn/no-few-shots.jsonl` - Translations without few-shot examples
Each JSONL file contains documents with:
- `text`: Original text to translate
- `id`: Unique document identifier
- `inference_results`: Array with translation results
|