Skip to content

Commit aed965b

Browse files
Merge pull request #1111 from AI4Bharat/revert-1110-ana-mas
Revert "task analytics for superchecker"
2 parents 67afb18 + 1372458 commit aed965b

File tree

11 files changed

+150
-653
lines changed

11 files changed

+150
-653
lines changed

src/redux/reducers/Progress/TaskAnalytics.js

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ import C from "../../constants";
22

33
let initialState = {
44
data: [],
5+
originalData: [],
56
};
67

78
const diffAnnotationReview = (payload) => {
@@ -13,11 +14,7 @@ const diffAnnotationReview = (payload) => {
1314
languages: (value?.language),
1415
annotation_cumulative_tasks_count: (value?.ann_cumulative_tasks_count),
1516
review_cumulative_tasks_count: (value?.rew_cumulative_tasks_count),
16-
sup_cumulative_tasks_count : (value?.sup_cumulative_tasks_count),
17-
diff_annotation_rev_sup: (value?.ann_cumulative_tasks_count - value?.rew_cumulative_tasks_count-value?.sup_cumulative_tasks_count),
18-
diff_annotation_rev: (value?.ann_cumulative_tasks_count - value?.rew_cumulative_tasks_count),
19-
diff_annotation_sup: (value?.ann_cumulative_tasks_count - value?.sup_cumulative_tasks_count),
20-
diff_rev:(value?.rew_cumulative_tasks_count-value?.sup_cumulative_tasks_count),
17+
diff_annotation_review: (value?.ann_cumulative_tasks_count - value?.rew_cumulative_tasks_count)
2118
};
2219
})
2320
})
@@ -32,7 +29,8 @@ const reducer = (state = initialState, action) => {
3229
switch (action.type) {
3330
case C.FETCH_TASK_ANALYTICS_DATA:
3431
const data = diffAnnotationReview(action.payload);
35-
return { ...state, data };
32+
return { ...state, originalData: action.payload, data };
33+
3634

3735
default:
3836
return {

src/redux/reducers/WorkspaceDetails/GetTaskAnalytics.js

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -15,11 +15,7 @@ const diffAnnotationReview = (payload) => {
1515
languages: (value?.language),
1616
annotation_cumulative_tasks_count: (value?.ann_cumulative_tasks_count),
1717
review_cumulative_tasks_count: (value?.rew_cumulative_tasks_count),
18-
sup_cumulative_tasks_count : (value?.sup_cumulative_tasks_count),
19-
diff_annotation_rev_sup: (value?.ann_cumulative_tasks_count - value?.rew_cumulative_tasks_count-value?.sup_cumulative_tasks_count),
20-
diff_annotation_rev: (value?.ann_cumulative_tasks_count - value?.rew_cumulative_tasks_count),
21-
diff_annotation_sup: (value?.ann_cumulative_tasks_count - value?.sup_cumulative_tasks_count),
22-
diff_rev:(value?.rew_cumulative_tasks_count-value?.sup_cumulative_tasks_count),
18+
diff_annotation_review: (value?.ann_cumulative_tasks_count - value?.rew_cumulative_tasks_count)
2319
};
2420
})
2521
})

src/ui/pages/container/Progress/MetaAnalytics/MetaAnalytics.jsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -231,9 +231,9 @@ export default function MetaAnalytics(props) {
231231
</Select>
232232
</FormControl>
233233
{/* <Grid item xs={12} sm={12} md={12} lg={12} xl={12} container justifyContent="space-between" alignItems="center"> */}
234-
<CustomButton label="Submit" sx={{ width: "120px" }} onClick={handleSubmit} />
235-
<Box display="flex" sx={{ width: { xs: "100px", md: "120px" }, height: "40px", marginRight: 1 }}alignItems="center">
236-
<CustomButton
234+
<CustomButton label="Submit" sx={{ width: "120px" }} onClick={handleSubmit} disabled={loading} />
235+
<Box display="flex" alignItems="center">
236+
<CustomButton
237237
onClick={handleClick}
238238
disabled={loading}
239239
sx={{ marginRight: 1 }}

src/ui/pages/container/Progress/MetaAnalytics/SentanceCountMetaAnalyticsChart.jsx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -108,7 +108,7 @@ export default function SentanceCountMetaAnalyticsChart(props) {
108108
</Box>
109109
<Box className={classes.topBarInnerBox}>
110110
<Typography style={{ fontSize: "0.875rem", fontWeight: "400" }}>
111-
Total Annotated Count
111+
Total Sentance Count
112112
</Typography>
113113
<Typography style={{ fontSize: "1.125rem", fontWeight: "400" }}>
114114
{totalSentanceCount &&
@@ -117,7 +117,7 @@ export default function SentanceCountMetaAnalyticsChart(props) {
117117
</Box>
118118
<Box className={classes.topBarInnerBox}>
119119
<Typography style={{ fontSize: "0.875rem", fontWeight: "400" }}>
120-
Pending Review Count
120+
Total Annotation Sentance Count
121121
</Typography>
122122
<Typography style={{ fontSize: "1.125rem", fontWeight: "400" }}>
123123
{totalAnnotationSentanceCount &&
@@ -126,7 +126,7 @@ export default function SentanceCountMetaAnalyticsChart(props) {
126126
</Box>
127127
<Box className={classes.topBarInnerBox}>
128128
<Typography style={{ fontSize: "0.875rem", fontWeight: "400" }}>
129-
Review Completed Count
129+
Total Quality/Reviewed Sentance Count
130130
</Typography>
131131
<Typography style={{ fontSize: "1.125rem", fontWeight: "400" }}>
132132
{totalReviewSentanceCount &&
@@ -218,4 +218,4 @@ export default function SentanceCountMetaAnalyticsChart(props) {
218218
</Paper>
219219
</Box>
220220
)
221-
}
221+
}

src/ui/pages/container/Progress/MetaAnalytics/WordCountMetaAnalyticsChart.jsx

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,8 @@ import {
1515

1616
export default function WordCountMetaAnalyticsChart(props) {
1717
const {analyticsData,graphCategory} = props
18+
console.log(analyticsData);
19+
1820
const classes = DatasetStyle();
1921
const [totalWordCount, setTotalWordCount] = useState();
2022
const [totalAnnotationWordCount, setTotalAnnotationWordCount] = useState();
@@ -212,7 +214,7 @@ export default function WordCountMetaAnalyticsChart(props) {
212214
</Box>
213215
<Box className={classes.topBarInnerBox}>
214216
<Typography style={{ fontSize: "0.875rem", fontWeight: "400" }}>
215-
Total Annotated Count
217+
Total Word Count
216218
</Typography>
217219
<Typography style={{ fontSize: "1.125rem", fontWeight: "400" }}>
218220
{totalWordCount &&
@@ -221,7 +223,7 @@ export default function WordCountMetaAnalyticsChart(props) {
221223
</Box>
222224
<Box className={classes.topBarInnerBox}>
223225
<Typography style={{ fontSize: "0.875rem", fontWeight: "400" }}>
224-
Pending Review Count
226+
Total Annotation Word Count
225227
</Typography>
226228
<Typography style={{ fontSize: "1.125rem", fontWeight: "400" }}>
227229
{totalAnnotationWordCount &&
@@ -230,7 +232,7 @@ export default function WordCountMetaAnalyticsChart(props) {
230232
</Box>
231233
<Box className={classes.topBarInnerBox}>
232234
<Typography style={{ fontSize: "0.875rem", fontWeight: "400" }}>
233-
Review Completed Count
235+
Total Quality/Reviewed Word Count
234236
</Typography>
235237
<Typography style={{ fontSize: "1.125rem", fontWeight: "400" }}>
236238
{totalReviewWordCount &&

0 commit comments

Comments
 (0)