From 5dfbb0eb172aa950518f4ef68ca515355550a198 Mon Sep 17 00:00:00 2001 From: Jessica <8203518+jessicah25@users.noreply.github.com> Date: Fri, 26 Aug 2022 12:09:36 -0400 Subject: [PATCH] update to mephisto 2.0.1 --- .../crowdsourcing/tasks/dialcrowd/webapp-results/package.json | 2 +- .../components/requesters/template/category/CategoryQuality.js | 2 +- parlai/crowdsourcing/tasks/dialcrowd/webapp/package.json | 2 +- .../webapp/src/components/dialcrowd/worker_category.js | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/parlai/crowdsourcing/tasks/dialcrowd/webapp-results/package.json b/parlai/crowdsourcing/tasks/dialcrowd/webapp-results/package.json index 03405d424af..843ea66ef9c 100644 --- a/parlai/crowdsourcing/tasks/dialcrowd/webapp-results/package.json +++ b/parlai/crowdsourcing/tasks/dialcrowd/webapp-results/package.json @@ -18,7 +18,7 @@ "file-saver": "^1.3.8", "history": "^4.7.2", "material-icons-react": "^1.0.0", - "mephisto-task": "^1.0.3", + "mephisto-task": "2.0.1", "npm": "^6.1.0", "random-seed": "^0.3.0", "react": "16.13.1", diff --git a/parlai/crowdsourcing/tasks/dialcrowd/webapp-results/src/components/requesters/template/category/CategoryQuality.js b/parlai/crowdsourcing/tasks/dialcrowd/webapp-results/src/components/requesters/template/category/CategoryQuality.js index 1d5db796d8c..9bb1d4613f3 100644 --- a/parlai/crowdsourcing/tasks/dialcrowd/webapp-results/src/components/requesters/template/category/CategoryQuality.js +++ b/parlai/crowdsourcing/tasks/dialcrowd/webapp-results/src/components/requesters/template/category/CategoryQuality.js @@ -87,7 +87,7 @@ function getWorkerQuality(t) { var passes_duplicate = {'total': 0, 'passes': 0} var passes_golden = {'total': 0, 'passes': 0} - user['mephisto_data']['outputs']['final_data'].forEach((data, j) => { + user['mephisto_data']['outputs']['annotations'].forEach((data, j) => { try{ if (!(data['id'])){} else{ diff --git a/parlai/crowdsourcing/tasks/dialcrowd/webapp/package.json b/parlai/crowdsourcing/tasks/dialcrowd/webapp/package.json index a0ff3d5cc1b..39c3ffc0ac3 100644 --- a/parlai/crowdsourcing/tasks/dialcrowd/webapp/package.json +++ b/parlai/crowdsourcing/tasks/dialcrowd/webapp/package.json @@ -13,7 +13,7 @@ "antd": "^4.16.13", "@ant-design/icons": "^4.6.4", "bootstrap": "^4.3.1", - "mephisto-task": "^1.0.3", + "mephisto-task": "2.0.1", "react": "16.13.1", "react-bootstrap": "^0.32.4", "react-dom": "16.13.1", diff --git a/parlai/crowdsourcing/tasks/dialcrowd/webapp/src/components/dialcrowd/worker_category.js b/parlai/crowdsourcing/tasks/dialcrowd/webapp/src/components/dialcrowd/worker_category.js index ec781782702..aad9ba1e57a 100755 --- a/parlai/crowdsourcing/tasks/dialcrowd/webapp/src/components/dialcrowd/worker_category.js +++ b/parlai/crowdsourcing/tasks/dialcrowd/webapp/src/components/dialcrowd/worker_category.js @@ -104,7 +104,7 @@ class WorkerCategory extends React.Component { this.setState({submitted: true}); this.annotations.push({feedback: this.feedback}); // send the annotation to the backend - this.props.onSubmit(this.annotations); + this.props.onSubmit({"annotations": this.annotations}); } }