python - MTurk API : Unable to see my created HIT on dashboard

标签 python boto3 mechanicalturk

我正在使用给出的教程 here .它说 HIT 已创建,但是当我转到此处 https://requestersandbox.mturk.com/ 时,我找不到我创建的项目。尽管个别工作人员 URL 确实返回 HIT 网络界面。

我想知道我不仅要自动创建 HIT,还要自动发布批处理的原因。我的代码如下:

MTURK_SANDBOX = 'https://mturk-requester-sandbox.us-east-1.amazonaws.com'
    mturk = boto3.client('mturk',
                         aws_access_key_id=ACCESS_KEY,
                         aws_secret_access_key=SECRET,
                         region_name='us-east-1',
                         endpoint_url=MTURK_SANDBOX
                         )

    print("I have $" + mturk.get_account_balance()['AvailableBalance'] + " in my Sandbox account")

    question = open('questions.xml', encoding='utf8').read()
    new_hit = mturk.create_hit(
        Title='Is this Tweet happy, angry, excited, scared, annoyed or upset?',
        Description='Read this tweet and type out one word to describe the emotion of the person posting it: happy, angry, scared, annoyed or upset',
        Keywords='text, quick, labeling',
        Reward='0.15',
        MaxAssignments=1,
        LifetimeInSeconds=172800,
        AssignmentDurationInSeconds=600,
        AutoApprovalDelayInSeconds=14400,
        Question=question,
    )
    print("A new HIT has been created. You can preview it here:")
    print("https://workersandbox.mturk.com/mturk/preview?groupId=" + new_hit['HIT']['HITGroupId'])
    print("HITID = " + new_hit['HIT']['HITId'] + " (Use to Get Results)")

最佳答案

Mechanical Turk 目前不提供通过 API 发布一批 HIT 的方法。您必须分别为它们中的每一个调用 CreateHIT

此外,通过 API 创建的 HIT 在 UI 中不可见。您可以通过 API 看到这些。您还可以使用 AWS 命令​​行 shell 来管理它们,因为它也使用 API。

来源:

  1. https://blog.mturk.com/tutorial-managing-mturk-hits-with-the-aws-command-line-interface-56eaabb7fd4c
  2. MTurk HITs created Through Java API are not showing on Manage Tab on UI

关于python - MTurk API : Unable to see my created HIT on dashboard,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/52931336/

相关文章:

在不聚合的情况下在 R 中 reshape (例如 MTurk 响应字符串)

python - 在 Windows 上的 python2.5 上安装 Openpyxl

python - 如何增加python CPU使用率

python - 如何向现有行添加新属性而不更改 Dynamodb 表的现有属性

python - Mac OS 上导入 boto3 错误

python - 奇怪的是,使用某些 URL 无法为 Amazon Mechanical Turk 制作 HIT?

python - 使用类的 __call__ 方法作为 Numpy curve_fit 的输入

Python MySQLdb : Is it possible to insert a cursor object without parsing it?

amazon-web-services - 使用 python 中的 cloudformation 在 ApiGateway 中为私有(private)类型设置端点 ID

java - 在 ant 中定义 Main-Class 用于捆绑 jar 的混淆