-
Notifications
You must be signed in to change notification settings - Fork 0
/
mturk.html
250 lines (241 loc) · 16.3 KB
/
mturk.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
<!-- You must include this JavaScript file -->
<script src="https://assets.crowd.aws/crowd-html-elements.js"></script>
<!-- For the full list of available Crowd HTML Elements and their input/output documentation,
please refer to https://docs.aws.amazon.com/sagemaker/latest/dg/sms-ui-template-reference.html -->
<!-- You must include crowd-form so that your task submits answers to MTurk -->
<crowd-form answer-format="flatten-objects">
<p><b>Imagine you're reading about "<a href="${corresponding_goal_url}" target="_blank">How to ${corresponding_goal}"</a>, which suggests a step:</b></p>
<p>
<h3><b>"${step}"</b></h3>
</p>
<p><b>For each of the articles below, pick one of the following options: </b></p>
<p>1: The article explains exactly how to do the step.</p>
<p>2: The article explains something close enough, but it's too general.</p>
<p>3: The article explains something close enough, but it's too specific.</p>
<p>4: The article explains something related, but I don't think I can do the step with the instructions.</p>
<p>5: The article is unrelated to the step.</p>
<p><b>If available, a preview of the article will be given in italics.</b></p>
<!-- The crowd-classifier element will create a tool for the Worker to select the
correct answer to your question.
Your image file URLs will be substituted for the "image_url" variable below
when you publish a batch with a CSV input file containing multiple image file URLs.
To preview the element with an example image, try setting the src attribute to
"https://s3.amazonaws.com/cv-demo-images/one-bird.jpg" -->
<!--<crowd-form name="form">-->
<div style="display: flex" class="q">
<p><b>Does this article <a href="${negative_goal_url}" target="_blank">"How to ${negative_goal}"</a> help explain how to do that step?</b></p>
<p><br/><i style="font-size: 12px">${negative_goal_description}</i>
<form style="margin-top: 35px">
<select id='chooseNegative' name='chooseNegative'>
<option selected="selected" value="" disabled></option>
<option value="1">1: The article explains exactly how to do the step.</option>
<option value="2">2: The article explains something close enough, but it's too general.</option>
<option value="3">3: The article explains something close enough, but it's too specific.</option>
<option value="4">4: The article explains something related, but I don't think I can do the step with the instructions.</option>
<option value="0">5: The article is unrelated to the step.</option>
</select>
</form>
</p>
</div>
<div style="display: flex" class="q">
<p><b>Does this article <a href="${retrieved_goal_url_1}" target="_blank">"How to ${retrieved_goal_1}"</a> help explain how to do that step?</b></p>
<!--<crowd-input type="text" name="word1" placeholder="(1,2,3,4,0)" style="width: 120px"></crowd-input>-->
<p><br/><i style="font-size: 12px">${retrieved_goal_description_1}</i>
<form style="margin-top: 35px">
<select id='choose1' name='choose1'>
<option selected="selected" value="" disabled></option>
<option value="1">1: The article explains exactly how to do the step.</option>
<option value="2">2: The article explains something close enough, but it's too general.</option>
<option value="3">3: The article explains something close enough, but it's too specific.</option>
<option value="4">4: The article explains something related, but I don't think I can do the step with the instructions.</option>
<option value="0">5: The article is unrelated to the step.</option>
</select>
</form>
</p>
</div>
<div style="display: flex" class="q">
<p><b>Does this article <a href="${retrieved_goal_url_2}" target="_blank">"How to ${retrieved_goal_2}"</a> help explain how to do that step?</b></p>
<p><br/><i style="font-size: 12px">${retrieved_goal_description_2}</i>
<form style="margin-top: 35px">
<select id='choose2' name='choose2'>
<option selected="selected" value="" disabled></option>
<option value="1">1: The article explains exactly how to do the step.</option>
<option value="2">2: The article explains something close enough, but it's too general.</option>
<option value="3">3: The article explains something close enough, but it's too specific.</option>
<option value="4">4: The article explains something related, but I don't think I can do the step with the instructions.</option>
<option value="0">5: The article is unrelated to the step.</option>
</select>
</form>
</p>
</div>
<div style="display: flex" class="q">
<p><b>Does this article <a href="${retrieved_goal_url_3}" target="_blank">"How to ${retrieved_goal_3}"</a> help explain how to do that step?</b></p>
<p><br/><i style="font-size: 12px">${retrieved_goal_description_3}</i>
<form style="margin-top: 35px">
<select id='choose3' name='choose3'>
<option selected="selected" value="" disabled></option>
<option value="1">1: The article explains exactly how to do the step.</option>
<option value="2">2: The article explains something close enough, but it's too general.</option>
<option value="3">3: The article explains something close enough, but it's too specific.</option>
<option value="4">4: The article explains something related, but I don't think I can do the step with the instructions.</option>
<option value="0">5: The article is unrelated to the step.</option>
</select>
</form>
</p>
</div>
<div style="display: flex" class="q">
<p><b>Does this article <a href="${retrieved_goal_url_4}" target="_blank">"How to ${retrieved_goal_4}"</a> help explain how to do that step?</b></p>
<p><br/><i style="font-size: 12px">${retrieved_goal_description_4}</i>
<form style="margin-top: 35px">
<select id='choose4' name='choose4'>
<option selected="selected" value="" disabled></option>
<option value="1">1: The article explains exactly how to do the step.</option>
<option value="2">2: The article explains something close enough, but it's too general.</option>
<option value="3">3: The article explains something close enough, but it's too specific.</option>
<option value="4">4: The article explains something related, but I don't think I can do the step with the instructions.</option>
<option value="0">5: The article is unrelated to the step.</option>
</select>
</form>
</p>
</div>
<div style="display: flex" class="q">
<p><b>Does this article <a href="${retrieved_goal_url_5}" target="_blank">"How to ${retrieved_goal_5}"</a> help explain how to do that step?</b></p>
<p><br/><i style="font-size: 12px">${retrieved_goal_description_5}</i>
<form style="margin-top: 35px">
<select id='choose5' name='choose5'>
<option selected="selected" value="" disabled></option>
<option value="1">1: The article explains exactly how to do the step.</option>
<option value="2">2: The article explains something close enough, but it's too general.</option>
<option value="3">3: The article explains something close enough, but it's too specific.</option>
<option value="4">4: The article explains something related, but I don't think I can do the step with the instructions.</option>
<option value="0">5: The article is unrelated to the step.</option>
</select>
</form>
</p>
</div>
<div style="display: flex" class="q">
<p><b>Does this article <a href="${retrieved_goal_url_6}" target="_blank">"How to ${retrieved_goal_6}"</a> help explain how to do that step?</b></p>
<p><br/><i style="font-size: 12px">${retrieved_goal_description_6}</i>
<form style="margin-top: 35px">
<select id='choose6' name='choose6'>
<option selected="selected" value="" disabled></option>
<option value="1">1: The article explains exactly how to do the step.</option>
<option value="2">2: The article explains something close enough, but it's too general.</option>
<option value="3">3: The article explains something close enough, but it's too specific.</option>
<option value="4">4: The article explains something related, but I don't think I can do the step with the instructions.</option>
<option value="0">5: The article is unrelated to the step.</option>
</select>
</form>
</p>
</div>
<div style="display: flex" class="q">
<p><b>Does this article <a href="${gold_goal_url}" target="_blank">"How to ${gold_goal}"</a> help explain how to do that step?</b></p>
<p><br/><i style="font-size: 12px">${gold_goal_description}</i>
<form style="margin-top: 35px">
<select id='chooseGold' name='chooseGold'>
<option selected="selected" value="" disabled></option>
<option value="1">1: The article explains exactly how to do the step.</option>
<option value="2">2: The article explains something close enough, but it's too general.</option>
<option value="3">3: The article explains something close enough, but it's too specific.</option>
<option value="4">4: The article explains something related, but I don't think I can do the step with the instructions.</option>
<option value="0">5: The article is unrelated to the step.</option>
</select>
</form>
</p>
</div>
<div style="display: flex" class="q">
<p><b>Does this article <a href="${retrieved_goal_url_7}" target="_blank">"How to ${retrieved_goal_7}"</a> help explain how to do that step?</b></p>
<p><br/><i style="font-size: 12px">${retrieved_goal_description_7}</i>
<form style="margin-top: 35px">
<select id='choose7' name='choose7'>
<option selected="selected" value="" disabled></option>
<option value="1">1: The article explains exactly how to do the step.</option>
<option value="2">2: The article explains something close enough, but it's too general.</option>
<option value="3">3: The article explains something close enough, but it's too specific.</option>
<option value="4">4: The article explains something related, but I don't think I can do the step with the instructions.</option>
<option value="0">5: The article is unrelated to the step.</option>
</select>
</form>
</p>
</div>
<div style="display: flex" class="q">
<p><b>Does this article "<a href="${retrieved_goal_url_8}" target="_blank">"How to ${retrieved_goal_8}"</a> help explain how to do that step?</b></p>
<p><br/><i style="font-size: 12px">${retrieved_goal_description_8}</i>
<form style="margin-top: 35px">
<select id='choose8' name='choose8'>
<option selected="selected" value="" disabled></option>
<option value="1">1: The article explains exactly how to do the step.</option>
<option value="2">2: The article explains something close enough, but it's too general.</option>
<option value="3">3: The article explains something close enough, but it's too specific.</option>
<option value="4">4: The article explains something related, but I don't think I can do the step with the instructions.</option>
<option value="0">5: The article is unrelated to the step.</option>
</select>
</form>
</p>
</div>
<div style="display: flex" class="q">
<p><b>Does this article "<a href="${retrieved_goal_url_9}" target="_blank">"How to ${retrieved_goal_9}"</a> help explain how to do that step?</b></p>
<p><br/><i style="font-size: 12px">${retrieved_goal_description_9}</i>
<form style="margin-top: 35px">
<select id='choose9' name='choose9'>
<option selected="selected" value="" disabled></option>
<option value="1">1: The article explains exactly how to do the step.</option>
<option value="2">2: The article explains something close enough, but it's too general.</option>
<option value="3">3: The article explains something close enough, but it's too specific.</option>
<option value="4">4: The article explains something related, but I don't think I can do the step with the instructions.</option>
<option value="0">5: The article is unrelated to the step.</option>
</select>
</form>
</p>
</div>
<div style="display: flex" class="q">
<p><b>Does this article "<a href="${retrieved_goal_url_10}" target="_blank">"How to ${retrieved_goal_10}"</a> help explain how to do that step?</b></p>
<p><br/><i style="font-size: 12px">${retrieved_goal_description_10}</i>
<form style="margin-top: 35px">
<select id='choose10' name='choose10'>
<option selected="selected" value="" disabled></option>
<option value="1">1: The article explains exactly how to do the step.</option>
<option value="2">2: The article explains something close enough, but it's too general.</option>
<option value="3">3: The article explains something close enough, but it's too specific.</option>
<option value="4">4: The article explains something related, but I don't think I can do the step with the instructions.</option>
<option value="0">5: The article is unrelated to the step.</option>
</select>
</form>
</p>
</div>
<short-instructions>
<p>In the given artcles, answer using the numerical key if it explains how to do a particular step</p>
<p>A preview will be given of the article in italics. </p>
</short-instructions>
<!-- Use the full-instructions section for more detailed instructions that the
Worker can open while working on the task. Including more detailed
instructions and additional examples of good and bad answers here can
help get good results. You can include any HTML here. -->
<full-instructions header="How relevant are the articles?">
<h2>Detailed instructions</h2>
<p>Choose the corresponding numerical answer </p>
</full-instructions>
<!--</crowd-image-classifier>-->
</crowd-form>
<script type='text/javascript'>
function validateForms() {
return document.getElementById("choose1").value &&
document.getElementById("choose2").value &&
document.getElementById("choose3").value &&
document.getElementById("choose4").value &&
document.getElementById("choose5").value &&
document.getElementById("choose6").value &&
document.getElementById("choose7").value &&
document.getElementById("choose8").value &&
document.getElementById("choose9").value &&
document.getElementById("choose10").value &&
document.getElementById("chooseGold").value &&
document.getElementById("chooseNegative").value;
}
document.querySelector('crowd-form').onsubmit = function(e) {
if (!validateForms()) {
e.preventDefault();
alert("Please provide an answer for all questions.");
}
}
</script>