선택 (드롭다운)
Potato에서 드롭다운 선택 필드를 구성하여 긴 옵션 목록에 대한 단일 선택 어노테이션을 수행합니다. 필수 응답과 섞은 옵션 순서를 선택적으로 지정할 수 있습니다.
select 타입은 단일 선택을 위한 드롭다운 메뉴를 제공합니다. 라디오 버튼을 쓰면 시각적으로 부담스러운 더 긴 옵션 목록(5개 이상)에 가장 적합합니다.
Potato의 선택 드롭다운
기본 구성
yaml
annotation_schemes:
- name: "category"
description: "Select the document category"
annotation_type: "select"
labels:
- "news"
- "opinion"
- "tutorial"
- "review"
- "other"구성 옵션
| 필드 | 타입 | 필수 | 설명 |
|---|---|---|---|
name | string | 예 | 어노테이션의 고유 식별자 |
description | string | 예 | 어노테이터에게 표시되는 안내문 |
annotation_type | string | 예 | "select"여야 합니다 |
labels | array 또는 string | 예(use_predefined_labels를 설정한 경우 제외) | 선택할 옵션 목록 또는 한 줄에 옵션 하나씩 적은 텍스트 파일의 경로 |
use_predefined_labels | string | 아니오 | 기본 제공 목록("country", "ethnicity", "religion") |
required | boolean | 아니오 | 선택이 필수인지 여부 |
randomize_order | boolean | 아니오 | 어노테이터와 항목마다 옵션을 섞음. 기본 제공 목록은 자체 순서를 유지함 |
모든 드롭다운은 빈 -- select one -- 항목에서 열립니다. Potato는 select 스키마에서 default 키를 읽지 않습니다.
예시
문서 분류
yaml
- name: "document_type"
description: "What type of document is this?"
annotation_type: "select"
labels:
- "Research Paper"
- "News Article"
- "Blog Post"
- "Technical Documentation"
- "Legal Document"
- "Marketing Material"
- "Personal Communication"
- "Other"언어 선택
yaml
- name: "language"
description: "What language is this text written in?"
annotation_type: "select"
labels:
- "English"
- "Spanish"
- "French"
- "German"
- "Chinese"
- "Japanese"
- "Other"
required: true무작위 옵션 순서
yaml
- name: "genre"
description: "Select the genre of this text"
annotation_type: "select"
labels:
- "Fiction"
- "Non-fiction"
- "Poetry"
- "Drama"
randomize_order: true텍스트 파일에서 옵션 불러오기
긴 목록은 파일에 둘 수 있으며, 한 줄에 옵션 하나씩 적습니다.
yaml
- name: "language"
description: "Which language is this text in?"
annotation_type: "select"
labels: "options/languages.txt"경로는 task_dir을 기준으로, 그다음 설정 파일의 디렉터리를 기준으로 해석되며 task_dir 안에 있어야 합니다. 빈 줄은 건너뜁니다. Potato는 빈 파일과 같은 옵션을 두 번 나열한 파일을 거부합니다. 파일은 서버가 시작될 때 읽히므로 수정한 뒤에는 재시작해야 합니다. 설문 단계 파일도 같은 형식을 받습니다.
기본 제공 목록
yaml
- name: "country"
description: "Which country do you live in?"
annotation_type: "select"
use_predefined_labels: "country"use_predefined_labels가 있는 스킴에는 labels가 필요 없습니다. labels도 함께 설정하면 페이지에는 기본 제공 목록이 표시되고 서버 로그에는 labels가 무시된다는 경고가 남습니다. country, ethnicity, religion 이외의 이름은 시작 단계에서 서버를 멈추게 합니다.
출력 형식
select 응답은 select-one이라는 레이블 이름 아래에 저장되며, 선택된 옵션이 그 값입니다.
json
{
"instance_id": "item_1",
"user_id": "annotator1",
"labels": {
"category": {
"select-one": "tutorial"
}
},
"spans": {},
"links": {}
}Select와 Radio 중 무엇을 쓸지
| Select 사용 | Radio 사용 |
|---|---|
| 5개 이상 옵션 | 2~5개 옵션 |
| 어노테이터에게 잘 알려진 옵션 | 모든 옵션을 한눈에 봐야 할 때 |
| 공간이 제한적일 때 | 키보드 단축키가 중요할 때 |
| 옵션 레이블이 길 때 | 빠른 시각적 훑어보기가 필요할 때 |
모범 사례
- 옵션을 논리적으로 정렬하세요 - 알파벳순, 빈도순, 또는 의미적 묶음별로 정렬하세요
- "Other" 옵션을 포함하세요 - 목록이 모든 경우를 포괄하지 못할 수 있을 때
- 명확하고 구분되는 레이블을 사용하세요 - 모호하거나 겹치는 범주를 피하세요
- 모든 항목에 답이 필요하면
required: true를 설정하세요 - 모든 드롭다운은 빈 항목에서 열리며, 스키마가 필수가 아니면 어노테이터가 그 항목을 빈 채로 둘 수 있습니다