Commit 22df0212 by solashirai Committed by Piotr Mitros

updated old info

parent b88e5287
This is the repository for the Crowd Sourced Hinter XBlock. The Crowd Sourced Hinter serves to provide students with hints when they incorrectly answer a problem within a course (currently tested for text and numerical input type questions).
This is the repository for the Crowdsource Hinter XBlock. The Crowdsource Hinter serves to provide students with hints when they incorrectly answer a problem within a course (currently tested for text and numerical input type questions).
This XBlock is still under construction. To be implemented are methods to properly moderate reported hints (currently a staff member must answer each question to view crude moderation options).
This XBlock is still a prototype.
An example of a student recieving a hint
![CrowdSourcedHinter Hint Screenshot](crowdsourcedhinter_hint.png)
![CrowdSourceHinter Hint Screenshot](crowdsourcehinter_hint.png)
An example of a hint giving feedback
![CrowdSourcedHinter Student Feedback Screenshot](crowdsourcedhinter_feedback.png)
An example of after a student corrects their answer
![CrowdSourceHinter Screenshot](crowdsourcehinter_correct.png)
To bring the crowd sourced hinter into a demo course:
First, follow https://github.com/edx/edx-platform/blob/master/docs/en_us/developers/source/xblocks.rst#testing for general xblock creation.
The name of the module to set in the advanced settings tab is "crowdxblock" (this will likely be changed in the near future to something like "crowd_sourced_hinter").
The name of the module to set in the advanced settings tab is "crowdsourcehinter".
After creating a new unit, add the crowdsourcedhinter XBlock into a course just like any other XBlock. The name of the crowd sourced hinter may not show up in studio for some unknown reason, but an empty space where its name should be will be clickable (problem to be identified/fixed...).
After creating a new unit, add the crowdsourcehinter XBlock into a course just like any other XBlock. The name of the crowd sourced hinter may not show up in studio for some unknown reason, but an empty space where its name should be will be clickable (problem to be identified/fixed...).
What It Does:
The two key features of the crowd sourced hinter are the abilities to show students hints and to have the students themselves create hints to be shown to future students.
The two key features of the crowdsource hinter are the abilities to show students hints and to have the students themselves create hints to be shown to future students.
When a student incorrectly answers a text input type problem, the crowd sourced hinter will look through its database to search for a hint that has been stored for that exact incorrect answer input (i.e. when the database is large enough, two different incorrect answers would not receive the same hint). If hints exist for a student's incorrect answer, this hint is shown to the student. The student then may have the opportunity to input their answer again, which may prompt another hint to be displayed.
When a student incorrectly answers a problem, the hinter will look through its database to search for a hint that has been stored for that exact incorrect answer input (i.e. when the database is large enough, two different incorrect answers would not receive the same hint). If hints exist for a student's incorrect answer, this hint is shown to the student. The student then may have the opportunity to input their answer again, which may prompt another hint to be displayed.
After a student re-submits an answer correctly, they can rate hints as well as submit new hints. Rating hints works by upvoting, downvoting, or reporting hints. Students can submit new hints for each incorrect answer that has been made, and this hint will be stored only for that specific incorrect answer.
After a student re-submits an answer correctly, they can rate hints for their usefulness or contribute a new hint to be used by other students. Rating hints works by upvoting, downvoting, or reporting hints. The new hint that is contributed by a student is specific to the incorrect answer that they make (currently the first incorrect answer will be prompted for contributing new hints).
......@@ -198,7 +198,7 @@ function CrowdsourceHinter(runtime, element, data){
* incorrect answers. Triggered by clicking the "submit hint" button.
* @param submitHintButtonHTML is the "submit hint" button clicked
*/
function submit_new_hint(){ return function(submitHintButtonHTML){
function submitNewHint(){ return function(submitHintButtonHTML){
//add the newly created hint to the hinter's pool of hints
if($('.csh_student_text_input', element).val().length > 0){
var studentAnswer = unescape(submitHintButtonHTML.currentTarget.attributes['answer'].value);
......@@ -209,14 +209,14 @@ function CrowdsourceHinter(runtime, element, data){
url: runtime.handlerUrl(element, 'add_new_hint'),
data: JSON.stringify({"submission": newHint, "answer": studentAnswer}),
success: function() {
Logger.log('crowd_hinter.submit_new_hint', {"student_answer": studentAnswer, "new_hint_submission": newHint})
Logger.log('crowd_hinter.submitNewHint', {"student_answer": studentAnswer, "new_hint_submission": newHint})
}
});
$('.csh_student_text_input', element).remove();
$(submitHintButtonHTML.currentTarget).remove();
}
}}
$(element).on('click', '.csh_submit_new', submit_new_hint($(this)));
$(element).on('click', '.csh_submit_new', submitNewHint($(this)));
/**
* Send vote data to modify a hint's rating (or mark it as reported). Triggered by
......@@ -224,7 +224,7 @@ function CrowdsourceHinter(runtime, element, data){
* the student correctly submits an answer).
* @param rateHintButtonHTML is the rate_hint button clicked (upvote/downvote/report)
*/
function rate_hint(){ return function(rateHintButtonHTML){
function rateHint(){ return function(rateHintButtonHTML){
rating = rateHintButtonHTML.currentTarget.attributes['data-rate'].value;
$('.csh_hint_text', element).attr('rating', rating);
hint = $('.csh_hint_text', element).attr('hint_received');
......@@ -234,14 +234,14 @@ function CrowdsourceHinter(runtime, element, data){
url: runtime.handlerUrl(element, 'rate_hint'),
data: JSON.stringify({"student_rating": rating, "hint": hint, "student_answer": student_answer}),
success: function() {
Logger.log('crowd_hinter.rate_hint.click.event', {"hint": hint, "student_answer": student_answer, "rating": rating})
Logger.log('crowd_hinter.rateHint', {"hint": hint, "student_answer": student_answer, "rating": rating})
$('.csh_rate_hint', element).attr('class', 'csh_rate_hint_completed');
}
});
}}
$(element).on('click', '.csh_rate_hint', rate_hint($(this)));
$(element).on('click', '.csh_rate_hint', rateHint($(this)));
function report_hint(){ return function(reportHintButtonHTML){
function reportHint(){ return function(reportHintButtonHTML){
hint = $('.csh_hint_text', element).attr('hint_received');
student_answer = $('.csh_hint_text', element).attr('student_answer');
$.ajax({
......@@ -249,19 +249,19 @@ function CrowdsourceHinter(runtime, element, data){
url: runtime.handlerUrl(element, 'rate_hint'),
data: JSON.stringify({"student_rating": "report", "hint": hint, "student_answer": student_answer}),
success: function() {
Logger.log('crowd_hinter.report_hint.click.event', {"hint": hint, "student_answer": student_answer})
Logger.log('crowd_hinter.reportHint', {"hint": hint, "student_answer": student_answer})
}
});
}}
$(element).on('click', '.csh_report_hint', report_hint($(this)));
$(element).on('click', '.csh_report_hint', reportHint($(this)));
/**
* Remove a reported hint from the reported moderation area (for staff only). Hints
* are removed from the moderation area regardless of whether they are to be permanently removed
* from the hint pool or not. Called by staff_rate_hint.
* from the hint pool or not. Called by staffRateHint.
*/
function removeReportedHint(){
Logger.log('crowd_hinter.staff_rate_hint.click.event', {"hint": hint, "student_answer": student_answer, "rating": rating});
Logger.log('crowd_hinter.staffRateHint', {"hint": hint, "student_answer": student_answer, "rating": rating});
$(".csh_hint_value[value='" + hint + "']", element).remove();
}
......@@ -270,11 +270,11 @@ function CrowdsourceHinter(runtime, element, data){
* hint pool or not. Triggered by clicking a staff_rate button.
* @param staffRateHintButtonHTML is the csh_staff_rate button that was clicked
*/
function staff_rate_hint(){ return function(staffRateHintButtonHTML){
function staffRateHint(){ return function(staffRateHintButtonHTML){
hint = $(staffRateHintButtonHTML.currentTarget).parent().find(".csh_hint").text();
rating = staffRateHintButtonHTML.currentTarget.attributes['data-rate'].value
student_answer = "Reported";
Logger.log('crowd_hinter.staff_rate_hint.click.event', {"hint": hint, "student_answer": student_answer, "rating": rating});
Logger.log('crowd_hinter.staff_rate_hint', {"hint": hint, "student_answer": student_answer, "rating": rating});
$.ajax({
type: "POST",
url: runtime.handlerUrl(element, 'rate_hint'),
......@@ -282,6 +282,6 @@ function CrowdsourceHinter(runtime, element, data){
success: removeReportedHint()
});
}}
$(element).on('click', '.csh_staff_rate', staff_rate_hint($(this)));
$(element).on('click', '.csh_staff_rate', staffRateHint($(this)));
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment