Manages a particular kind of task; corresponds to a single TaskSpecification / HIT Type.
Manages a particular kind of task; corresponds to a single TaskSpecification / HIT Type. In here will be all of the logic related to how to review HITs, do quality control, keep track of auxiliary data, schedule which HITs should be uploaded when, etc.
Simplest HIT manager, which gets a fixed number of assignments for every prompt and approves all assignments immediately.
Simplest HIT manager, which gets a fixed number of assignments for every prompt and approves all assignments immediately. NOTE: this will crash if you try to have > 100 assignments per HIT. could possibly be fixed but seems not necessary since that's a kind of ridic use case.
Complete configuration for running on production.
Complete configuration for running on the sandbox.
Takes a list of TaskSpecification
s and hosts an HTTP server that can serve them all concurrently.
Takes a list of TaskSpecification
s and hosts an HTTP server that can serve them all concurrently.
Requires a file application.conf
in your resources folder with requisite fields defining the interface
and ports (see the file in the sample project for reference).
For testing, HTTP is fine, but if you want to run on MTurk, you need HTTPS to work.
For this, you need (also in your resources folder) a globally trusted SSL certificate,
a PKCS12-formatted keystore named <domain>.p12
, a password named <domain>-keystore-password
.
Starts upon construction.
Contains the global configuration of our usage of the MTurk API, including relevant values (URLs, API hooks) and whether we are running on production or in the sandbox.
Actor that behaves as an endpoint for interfacing with the task through the SBT console.
Actor that behaves as an endpoint for interfacing with the task through the SBT console. The hit manager (ActorRef) passed into the constructor needs to be the one associated with the helper object passed into the constructor.
Specifies a kind of task to run on MTurk.
Specifies a kind of task to run on MTurk.
The code defining an individual task type will be here.
An instance of this class will correspond to a single HIT Type ID,
which is Mechanical Turk's way of categorizing HITs uploaded to the system.
This specifies the method to convert from Prompt
s
(as in, the type parameter seen all over this project) into XML strings
that are POSTed to the MTurk API as questions shown to annotators.
It also has a method for converting from annotator responses (also XML strings)
into Response
s.
To implement the actual logic & interface of a task, the work is done in the client-side code.
TaskSpecification is also responsible for holding HIT Type ID of its HIT Type.
Implements the logic of the web server that hosts the given MTurk tasks.
Implements the logic of the web server that hosts the given MTurk tasks. Each TaskSpecification has its own Flow that specifies how to respond to WebSocket messages from clients. This web service hosts the JS code that clients GET, and delegates Websocket messages to their tasks' flows.
It also hosts a sample version of each task at http(s)://<domain>:<port>/task/<task key>/preview.
Contains the general HTML template for all tasks.
Provides classes for managing tasks on Mechanical Turk.