Skip to content

Commit

Permalink
Added UI for creating new qualifications in TaskReview app
Browse files Browse the repository at this point in the history
  • Loading branch information
meta-paul committed Nov 2, 2023
2 parents e55bb9a + 118ff5d commit 42a0931
Show file tree
Hide file tree
Showing 11 changed files with 124 additions and 565 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -42,5 +42,5 @@ mephisto:
- 6463d44ed1b61a8fb4e0765a
- 6463d488c2f2821eaa2fa13f
- name: "ApprovalRateEligibilityRequirement"
minimum_approval_rate: 0
minimum_approval_rate: 1
maximum_approval_rate: 100
16 changes: 9 additions & 7 deletions mephisto/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,8 @@ If you don't want to engage any cloud infrastructure, you can run all sample pro
A few notes:
- If a project breaks and does not shut down cleanly, you may need to remove `tmp` directory in repo root before re-launching. (Otherwise you could see errors like Prometeus cannot start, etc.)
- To see more browser links for task units (assignments) within a TaskRun, check console logs (and remember to use correct port)
- If you termiante a TaskRun, you can launch it again, and results from all TaskRuns will be automatically collated
- If you terminate a TaskRun, you can launch it again, and results from all TaskRuns will be automatically collated
- Note that most detailed logs are written into files in `outputs/` directory in repo root (not in the console)

---

Expand All @@ -78,7 +79,7 @@ A simple project with HTML-based UI task template [simple_static_task](../exampl
--build \
--publish 3001:3000 \
--rm mephisto_dc \
cd /mephisto/examples/simple_static_task && python ./static_test_script.py
python /mephisto/examples/simple_static_task/static_test_script.py
```
- Browser page (for the first task unit): [http://localhost:3001/?worker_id=x&assignment_id=1](http://localhost:3001/?worker_id=x&assignment_id=1)
- Browser page should display an image, instruction, select and file inputs, and a submit button.
Expand All @@ -96,7 +97,7 @@ A simple project with React-based UI task template [static_react_task](../exampl
--build \
--publish 3001:3000 \
--rm mephisto_dc \
cd /mephisto/examples/static_react_task && python ./run_task.py
python /mephisto/examples/static_react_task/run_task.py
```
- Browser page (for the first task unit): [http://localhost:3001/?worker_id=x&assignment_id=1](http://localhost:3001/?worker_id=x&assignment_id=1).
- Browser page should display an instruction line and two buttons (green and red).
Expand All @@ -117,7 +118,7 @@ A more complex example featuring worker-generated dynamic input: [mnist](../exam
apt install curl && \
pip install grafana torch pillow numpy && \
mephisto metrics install && \
cd /mephisto/examples/remote_procedure/mnist && python ./run_task.py
python /mephisto/examples/remote_procedure/mnist/run_task.py
```
- Browser page (for the first task unit): [http://localhost:3001/?worker_id=x&assignment_id=1](http://localhost:3001/?worker_id=x&assignment_id=1).
- Browser page should display instructions and a layout with 3 rectangle fields for drawing numbers with a mouse, each field having inputs at the bottom.
Expand Down Expand Up @@ -221,7 +222,7 @@ This is a sample YAML configuration to run your Task on **AWS EC2** architect wi
- 6463d3922d7d99360896228f
- 6463d40e8d5d2f0cce2b3b23
- name: "ApprovalRateEligibilityRequirement"
minimum_approval_rate: 0
minimum_approval_rate: 1
maximum_approval_rate: 100
```

Expand All @@ -240,13 +241,14 @@ This is a sample YAML configuration to run your Task on **AWS EC2** architect wi
```
or simply embed that command into your docker-compose entrypoint script.

2. Launch a new TaskRun (instead of `examples/simple_static_task` here specify path to your own Task code)
2. Launch a new TaskRun (instead of `examples/simple_static_task` here specify path to your own Task code; `HYDRA_FULL_ERROR=1` is optional and prints out detailed error info)

```shell
docker-compose -f docker/docker-compose.dev.yml run \
--build \
--rm mephisto_dc \
cd /mephisto/examples/simple_static_task && python ./static_test_prolific_script.py
rm -rf /mephisto/tmp && \
HYDRA_FULL_ERROR=1 python /mephisto/examples/simple_static_task/static_test_prolific_script.py
```

This TaskRun script will spin up an EC2 server, upload your React Task App to it, and create a Study on Prolific. Now all eligible workers will see your Task Units (with links poiting to EC2 server) on Prolific, and can complete it.
Expand Down
Loading

0 comments on commit 42a0931

Please sign in to comment.