Computational Quality Control for Crowdsourcing
Project description
Crowd-Kit: Computational Quality Control for Crowdsourcing
Crowd-Kit is a powerful Python library that implements commonly-used aggregation methods for crowdsourced annotation and offers the relevant metrics and datasets. We strive to implement functionality that simplifies working with crowdsourced data.
Currently, Crowd-Kit contains:
- implementations of commonly-used aggregation methods for categorical, pairwise, textual, and segmentation responses;
- metrics of uncertainty, consistency, and agreement with aggregate;
- loaders for popular crowdsourced datasets.
Also, the learning
subpackage contains PyTorch implementations of deep learning from crowds methods and advanced aggregation algorithms.
Installing
To install Crowd-Kit, run the following command: pip install crowd-kit
. If you also want to use the learning
subpackage, type pip instal crowd-kit[learning]
.
If you are interested in contributing to Crowd-Kit, use Pipenv to install the library with its dependencies: pipenv install --dev
. We use pytest for testing.
Getting Started
This example shows how to use Crowd-Kit for categorical aggregation using the classical Dawid-Skene algorithm.
First, let us do all the necessary imports.
from crowdkit.aggregation import DawidSkene
from crowdkit.datasets import load_dataset
import pandas as pd
Then, you need to read your annotations into Pandas DataFrame with columns task
, worker
, label
. Alternatively, you can download an example dataset:
df = pd.read_csv('results.csv') # should contain columns: task, worker, label
# df, ground_truth = load_dataset('relevance-2') # or download an example dataset
Then, you can aggregate the workers' responses using the fit_predict
method from the scikit-learn library:
aggregated_labels = DawidSkene(n_iter=100).fit_predict(df)
Implemented Aggregation Methods
Below is the list of currently implemented methods, including the already available (✅) and in progress (🟡).
Categorical Responses
Method | Status |
---|---|
Majority Vote | ✅ |
One-coin Dawid-Skene | ✅ |
Dawid-Skene | ✅ |
Gold Majority Vote | ✅ |
M-MSR | ✅ |
Wawa | ✅ |
Zero-Based Skill | ✅ |
GLAD | ✅ |
KOS | ✅ |
MACE | ✅ |
BCC | 🟡 |
Multi-Label Responses
Method | Status |
---|---|
Binary Relevance | ✅ |
Textual Responses
Method | Status |
---|---|
RASA | ✅ |
HRRASA | ✅ |
ROVER | ✅ |
Image Segmentation
Method | Status |
---|---|
Segmentation MV | ✅ |
Segmentation RASA | ✅ |
Segmentation EM | ✅ |
Pairwise Comparisons
Method | Status |
---|---|
Bradley-Terry | ✅ |
Noisy Bradley-Terry | ✅ |
Learning from Crowds
Method | Status |
---|---|
CrowdLayer | ✅ |
CoNAL | ✅ |
Citation
- Ustalov D., Pavlichenko N., Tseitlin B. Learning from Crowds with Crowd-Kit. 2023. arXiv: 2109.08584 [cs.HC].
@misc{CrowdKit,
author = {Ustalov, Dmitry and Pavlichenko, Nikita and Tseitlin, Boris},
title = {{Learning from Crowds with Crowd-Kit}},
year = {2023},
publisher = {arXiv},
eprint = {2109.08584},
eprinttype = {arxiv},
eprintclass = {cs.HC},
url = {https://arxiv.org/abs/2109.08584},
language = {english},
}
Questions and Bug Reports
- To report a bug, post an issue on the Toloka/bugreport page.
- To find answers to common questions or start a new discussion, join our English-speaking Slack community.
License
© Crowd-Kit team authors, 2020–2023. Licensed under the Apache License, Version 2.0. See LICENSE file for more details.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for crowd_kit-1.2.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | c7cee149469e9221d80019106baab55331a7a291fd42eeb1602e77dd084f8b92 |
|
MD5 | 764c42e5fb5381d38ab6c2847095869c |
|
BLAKE2b-256 | d741196262ca93180b3a1766f5cdb6875141d393566f9398c1948c3adbe5e1c6 |