# Slider

Source: https://www.potatoannotator.com/docs/annotation-types/slider

The slider type provides a draggable slider for selecting numeric values within a range. Ideal for confidence ratings, intensity scores, or any continuous numerical input.

![Slider annotation interface](/images/docs/slider-annotation.png "Draggable slider for continuous numeric annotation in Potato")

## Basic Configuration

```yaml
annotation_schemes:
  - name: "confidence"
    description: "How confident are you in this answer?"
    annotation_type: "slider"
    min: 0
    max: 100
    step: 1
    default: 50
```

## Configuration Options

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `name` | string | Yes | Unique identifier for the annotation |
| `description` | string | Yes | Instructions shown to annotators |
| `annotation_type` | string | Yes | Must be `"slider"` |
| `min` | number | Yes | Minimum slider value |
| `max` | number | Yes | Maximum slider value |
| `step` | number | No | Increment value (default: 1) |
| `default` | number | No | Initial slider position |
| `min_label` | string | No | Label for minimum end |
| `max_label` | string | No | Label for maximum end |
| `show_value` | boolean | No | Display current value (default: true) |

## Examples

### Confidence Rating

```yaml
- name: "confidence"
  description: "How confident are you in your annotation?"
  annotation_type: "slider"
  min: 0
  max: 100
  step: 5
  default: 50
  min_label: "Not confident at all"
  max_label: "Completely confident"
  show_value: true
```

### Intensity Scale

```yaml
- name: "intensity"
  description: "Rate the emotional intensity of this text"
  annotation_type: "slider"
  min: 1
  max: 10
  step: 1
  default: 5
  min_label: "Very mild"
  max_label: "Very intense"
```

### Percentage Input

```yaml
- name: "agreement"
  description: "What percentage of people would agree with this statement?"
  annotation_type: "slider"
  min: 0
  max: 100
  step: 1
  default: 50
  show_value: true
```

## Output Format

The slider annotation outputs a single numeric value:

```json
{
  "id": "item_1",
  "annotations": {
    "confidence": 75
  }
}
```

## When to Use Slider vs Number Input

- **Use Slider** when you want annotators to make quick, intuitive selections on a continuous scale
- **Use Number Input** when you need precise values or when the range is very large

## Best Practices

1. **Set sensible defaults** - Place the default at a meaningful position (often the midpoint)
2. **Use endpoint labels** - Help annotators understand what the scale represents
3. **Choose appropriate step sizes** - Smaller steps for fine-grained distinctions, larger for coarse ratings
4. **Keep ranges intuitive** - 0-100 or 1-10 are familiar to most annotators
