Improve comments for each criteria in speaking grading.
This commit is contained in:
88
app.py
88
app.py
@@ -441,19 +441,19 @@ def grade_speaking_task_1():
|
|||||||
"task_response": {
|
"task_response": {
|
||||||
"Fluency and Coherence": {
|
"Fluency and Coherence": {
|
||||||
"grade": 0.0,
|
"grade": 0.0,
|
||||||
"comment": "extensive comment about fluency and coherence"
|
"comment": "extensive comment about fluency and coherence, use examples to justify the grade awarded."
|
||||||
},
|
},
|
||||||
"Lexical Resource": {
|
"Lexical Resource": {
|
||||||
"grade": 0.0,
|
"grade": 0.0,
|
||||||
"comment": "extensive comment about lexical resource"
|
"comment": "extensive comment about lexical resource, use examples to justify the grade awarded."
|
||||||
},
|
},
|
||||||
"Grammatical Range and Accuracy": {
|
"Grammatical Range and Accuracy": {
|
||||||
"grade": 0.0,
|
"grade": 0.0,
|
||||||
"comment": "extensive comment about grammatical range and accuracy"
|
"comment": "extensive comment about grammatical range and accuracy, use examples to justify the grade awarded."
|
||||||
},
|
},
|
||||||
"Pronunciation": {
|
"Pronunciation": {
|
||||||
"grade": 0.0,
|
"grade": 0.0,
|
||||||
"comment": "extensive comment about pronunciation on the transcribed answer"
|
"comment": "extensive comment about pronunciation on the transcribed answer, use examples to justify the grade awarded."
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -531,10 +531,22 @@ def grade_speaking_task_1():
|
|||||||
"comment": "The audio recorded does not contain enough english words to be graded.",
|
"comment": "The audio recorded does not contain enough english words to be graded.",
|
||||||
"overall": 0,
|
"overall": 0,
|
||||||
"task_response": {
|
"task_response": {
|
||||||
"Fluency and Coherence": 0,
|
"Fluency and Coherence": {
|
||||||
"Lexical Resource": 0,
|
"grade": 0.0,
|
||||||
"Grammatical Range and Accuracy": 0,
|
"comment": ""
|
||||||
"Pronunciation": 0
|
},
|
||||||
|
"Lexical Resource": {
|
||||||
|
"grade": 0.0,
|
||||||
|
"comment": ""
|
||||||
|
},
|
||||||
|
"Grammatical Range and Accuracy": {
|
||||||
|
"grade": 0.0,
|
||||||
|
"comment": ""
|
||||||
|
},
|
||||||
|
"Pronunciation": {
|
||||||
|
"grade": 0.0,
|
||||||
|
"comment": ""
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
@@ -609,19 +621,19 @@ def grade_speaking_task_2():
|
|||||||
"task_response": {
|
"task_response": {
|
||||||
"Fluency and Coherence": {
|
"Fluency and Coherence": {
|
||||||
"grade": 0.0,
|
"grade": 0.0,
|
||||||
"comment": "extensive comment about fluency and coherence"
|
"comment": "extensive comment about fluency and coherence, use examples to justify the grade awarded."
|
||||||
},
|
},
|
||||||
"Lexical Resource": {
|
"Lexical Resource": {
|
||||||
"grade": 0.0,
|
"grade": 0.0,
|
||||||
"comment": "extensive comment about lexical resource"
|
"comment": "extensive comment about lexical resource, use examples to justify the grade awarded."
|
||||||
},
|
},
|
||||||
"Grammatical Range and Accuracy": {
|
"Grammatical Range and Accuracy": {
|
||||||
"grade": 0.0,
|
"grade": 0.0,
|
||||||
"comment": "extensive comment about grammatical range and accuracy"
|
"comment": "extensive comment about grammatical range and accuracy, use examples to justify the grade awarded."
|
||||||
},
|
},
|
||||||
"Pronunciation": {
|
"Pronunciation": {
|
||||||
"grade": 0.0,
|
"grade": 0.0,
|
||||||
"comment": "extensive comment about pronunciation on the transcribed answer"
|
"comment": "extensive comment about pronunciation on the transcribed answer, use examples to justify the grade awarded."
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -631,7 +643,7 @@ def grade_speaking_task_2():
|
|||||||
{
|
{
|
||||||
"role": "system",
|
"role": "system",
|
||||||
"content": (
|
"content": (
|
||||||
'You are a helpful assistant designed to output JSON on this format: ' + str(json_format))
|
'You are a helpful assistant designed to output JSON on this format: ' + str(json_format))
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"role": "user",
|
"role": "user",
|
||||||
@@ -699,10 +711,22 @@ def grade_speaking_task_2():
|
|||||||
"comment": "The audio recorded does not contain enough english words to be graded.",
|
"comment": "The audio recorded does not contain enough english words to be graded.",
|
||||||
"overall": 0,
|
"overall": 0,
|
||||||
"task_response": {
|
"task_response": {
|
||||||
"Fluency and Coherence": 0,
|
"Fluency and Coherence": {
|
||||||
"Lexical Resource": 0,
|
"grade": 0.0,
|
||||||
"Grammatical Range and Accuracy": 0,
|
"comment": ""
|
||||||
"Pronunciation": 0
|
},
|
||||||
|
"Lexical Resource": {
|
||||||
|
"grade": 0.0,
|
||||||
|
"comment": ""
|
||||||
|
},
|
||||||
|
"Grammatical Range and Accuracy": {
|
||||||
|
"grade": 0.0,
|
||||||
|
"comment": ""
|
||||||
|
},
|
||||||
|
"Pronunciation": {
|
||||||
|
"grade": 0.0,
|
||||||
|
"comment": ""
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
@@ -820,10 +844,22 @@ def grade_speaking_task_3():
|
|||||||
"comment": "The audio recorded does not contain enough english words to be graded.",
|
"comment": "The audio recorded does not contain enough english words to be graded.",
|
||||||
"overall": 0,
|
"overall": 0,
|
||||||
"task_response": {
|
"task_response": {
|
||||||
"Fluency and Coherence": 0,
|
"Fluency and Coherence": {
|
||||||
"Lexical Resource": 0,
|
"grade": 0.0,
|
||||||
"Grammatical Range and Accuracy": 0,
|
"comment": ""
|
||||||
"Pronunciation": 0
|
},
|
||||||
|
"Lexical Resource": {
|
||||||
|
"grade": 0.0,
|
||||||
|
"comment": ""
|
||||||
|
},
|
||||||
|
"Grammatical Range and Accuracy": {
|
||||||
|
"grade": 0.0,
|
||||||
|
"comment": ""
|
||||||
|
},
|
||||||
|
"Pronunciation": {
|
||||||
|
"grade": 0.0,
|
||||||
|
"comment": ""
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -854,19 +890,19 @@ def grade_speaking_task_3():
|
|||||||
"task_response": {
|
"task_response": {
|
||||||
"Fluency and Coherence": {
|
"Fluency and Coherence": {
|
||||||
"grade": 0.0,
|
"grade": 0.0,
|
||||||
"comment": "extensive comment about fluency and coherence"
|
"comment": "extensive comment about fluency and coherence, use examples to justify the grade awarded."
|
||||||
},
|
},
|
||||||
"Lexical Resource": {
|
"Lexical Resource": {
|
||||||
"grade": 0.0,
|
"grade": 0.0,
|
||||||
"comment": "extensive comment about lexical resource"
|
"comment": "extensive comment about lexical resource, use examples to justify the grade awarded."
|
||||||
},
|
},
|
||||||
"Grammatical Range and Accuracy": {
|
"Grammatical Range and Accuracy": {
|
||||||
"grade": 0.0,
|
"grade": 0.0,
|
||||||
"comment": "extensive comment about grammatical range and accuracy"
|
"comment": "extensive comment about grammatical range and accuracy, use examples to justify the grade awarded."
|
||||||
},
|
},
|
||||||
"Pronunciation": {
|
"Pronunciation": {
|
||||||
"grade": 0.0,
|
"grade": 0.0,
|
||||||
"comment": "extensive comment about pronunciation on the transcribed answer"
|
"comment": "extensive comment about pronunciation on the transcribed answer, use examples to justify the grade awarded."
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -875,7 +911,7 @@ def grade_speaking_task_3():
|
|||||||
{
|
{
|
||||||
"role": "system",
|
"role": "system",
|
||||||
"content": (
|
"content": (
|
||||||
'You are a helpful assistant designed to output JSON on this format: ' + str(json_format))
|
'You are a helpful assistant designed to output JSON on this format: ' + str(json_format))
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
message = (
|
message = (
|
||||||
|
|||||||
Reference in New Issue
Block a user