David542
David542

Reputation: 110382

How to add a user to a Qualification

I added up a Qualification in the UI of mechanical turk. How would i then add a worker to that. Here is what I'm trying:

qualification_id = '3RVX62BZKNDM4K4RT7JU0YN4QTRLP2' # this has been added
worker_id = 'A1D23ERS0X4J9D' # this user has already answered a HIT

Something like (in pseudo-code):

qual = Qualifcation('3RVX62BZKNDM4K4RT7JU0YN4QTRLP2').add_worker('A1D23ERS0X4J9D')

How would I do this in practice, such that only pre-specified workers can work on my HITs?

Upvotes: 3

Views: 783

Answers (1)

miwe
miwe

Reputation: 563

If you understand the nature of assigning qualifications (as shown below), you will easily be able to find the appropriate methods for your code.

On mTurk, you assign a qualification to a worker, and not vice versa. For example, in the requester browser user interface, you would do the following to assign a qualification to a worker which has already solved a hit for you:

  1. Go to manage > workers
  2. Find and click on the correct worker id, then click on assign a qualification type

The Mturk API provides two methods to assign a qualification:

  1. Assign Qualification Operation (If the worker has not requested the qualification)
  2. Grant Qualification Operation (If the worker has requested the qualification)

With boto, according to it's API, you can use these operations as follows:

  1. assign_qualification(qualification_type_id, worker_id, value=1, send_notification=True)--> boto api link
  2. grant_qualification(qualification_request_id, integer_value=1) --> boto API link

Note 1: If I'm not mistaken, you can only assign a qualification to workers who have actually solved one of your hits (or who have requested the qualification), but not to workers with whom you did not yet have any correspondence so far. However, MTurk was recently updated and I don't know if this has changed. Note 2: If you have one final list of worker id's, to which you want to assign a qualification (for example from a previous hit), you might want to consider to use the command line tools.

Upvotes: 5

Related Questions