Giter VIP home page Giter VIP logo

pollo's Introduction

๐Ÿฅ Pollo: a tool for crowd-sourced polling

Pollo is repo is for AMT annotation tasks for computer vision purposes (e.g., qualitative user studies). The main idea for this repo is to specify a JSON file describing each HIT (Human Intelligence Task) which will then dynamically populate a website (via JavaScript) with the task. A notebook lets you create and manage your HITs.

Getting started

Install the repo as a package

pip install pollo

If you want the latest version, you can clone and install in editable mode.

git clone https://github.com/ethanweber/pollo.git
cd pollo
pip install -e .

Your first project

The quickest way to understand this code it to look at our example. Here are the steps!

  1. Start the server.

    cd example_project
    pollo-server
  2. Open the examples/image_project/requester.ipynb file and step through it.

Folder structure

Here is what a project folder structure looks like.

example-project/
โ”œโ”€โ”€ data/
โ”‚   โ”œโ”€โ”€ hits/
โ”‚   โ”‚   โ””โ”€โ”€ <hit_name>.json          # HIT (Human Intelligence Task) data
โ”‚   โ”œโ”€โ”€ responses/
โ”‚   โ”‚   โ””โ”€โ”€ <hit_name>.json          # Responses to HITs
โ”‚   โ”œโ”€โ”€ local_responses/
โ”‚   โ”‚   โ””โ”€โ”€ <hit_name>.json          # Local responses to HITs
โ”‚   โ””โ”€โ”€ media/                       # Media assets like images or videos
โ”‚       โ”œโ”€โ”€ images/
โ”‚       โ””โ”€โ”€ videos/
โ”œโ”€โ”€ requester.ipynb                  # Main notebook for HITs management
โ”œโ”€โ”€ mturk_creds.json                 # AWS Mechanical Turk credentials
โ””โ”€โ”€ mturk_database.pkl               # Database for tracking HITs

Place MTurk credentials in a file named "mturk_creds.json". It should have the following content.

{
    "aws_access_key_id": "<aws_access_key_id>",
    "aws_secret_access_key": "<aws_secret_access_key>"
}

Server details

You need to host your server with an HTTPS domain to be compatible with AMT. Go to our reverse proxy docs for details on how to set this up. After this, you should be able to navigate to the following URLs.

# an interface to ask the hit questions
https://myurl.mydomain/hits-interface/<hit_name>

# an interface showing the responses to a hit
https://myurl.mydomain/responses-interface/<hit_name>

# an interface showing the local responses to a hit
https://myurl.mydomain/local_responses-interface/<hit_name>

# a file tree
https://myurl.mydomain/media/

Projects that used our code

Here are some projects that have used this code (or versions of it). The code presented in this repo is a general implementation for qualitative user studies. However, it was and can be modified for more specific use cases.

pollo's People

Contributors

ethanweber avatar

Stargazers

Hang avatar Luchao Qi avatar Justin Kerr avatar  avatar Pu Cao avatar  avatar Hongwei Yi avatar

Watchers

Vongani Maluleke avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.