CSC/ECE 517 Fall 2016/ E1700 Integrate Google doc editor/viewer: Difference between revisions

From Expertiza_Wiki
Jump to navigation Jump to search
No edit summary
No edit summary
 
(40 intermediate revisions by 3 users not shown)
Line 5: Line 5:
=='''Project Description'''==
=='''Project Description'''==


Currently the instructor creates rubrics for an assignment through questionnaires which students use to review other students' submissions. The only way reviewers can suggest some more changes to the author is by using the 'additional comments' section in the review form which is not very helpful. In this project we will be looking towards improving this functionality by adding an extra medium through which multiple reviewers can collectively comment on the author's work and collaborate their answers in a constructive way. This will be achieved by embedding Google docs into Expertiza. Every project will have a Google doc link for itself which the reviewers can access and make further comments about the project. Once on the Google doc, the reviewer's comments will be posted anonymously, the reviewer's comment will be anonymous to both, other fellow reviewers as well as the author. This feature will help the author to better understand where is his work exactly lacking and how exactly should the changes be worked upon based on the comments received. The reviewers will just need the Google doc link to post comments and it wouldn't be required to login into Expertiza for using this feature.
Currently the instructor creates rubrics for an assignment through questionnaires which students use to review other students' submissions. The only way reviewers can suggest some more changes to the author is by using the 'additional comments' section in the review form which is not very helpful. In this project we will be looking towards improving this functionality by adding an extra medium through which multiple reviewers can collectively comment on the author's work and collaborate their answers in a constructive way. We are planning to achieve this by enabling alert messages to the authors and the reviewers who will use the newly created Google document links embedded into Expertiza. For every Assignment created, the Instructors have been given a new criteria to make the review comments as anonymous. Depending on the criteria set, the Authors will be provided with notifications on two things: the permission setting of the Google Doc(Allow users with link to comment only) and to make reviewer comments anonymous. The Author of every Assignment will then need to create a Google doc based on these notifications. The links once submitted can be accessed by reviewers to submit their reviews. The reviewers also get notifications if they need to review the Assignments anonymously. If the anonymous setting is enabled, the reviewers will need to log out from all their Google accounts before opening the Google doc. Once on the Google doc, the reviewer's comments will be posted anonymously, the reviewer's comment will be anonymous to both, other fellow reviewers as well as the author. This feature will help the author to better understand where is his work exactly lacking and how exactly should the changes be worked upon based on the comments received. The reviewers will just need the Google doc link to post comments and it wouldn't be required to login into Expertiza or any google account for using this feature.


== '''Key Points To Consider''' ==
== '''Key Points To Consider''' ==


The Google doc editor needs to be embedded in expertiza or it should be made as a pop up window
* The alert message should only pop up when the Faculty has indicated to do so (alert messages only whe Google Doc hyperlinks are uploaded, and when Anonymous commenting is Enabled )
* The settings for the Google doc should be set to "anyone with link can comment"
* The Google Doc link needs to be added on the Assignment submissions page by the Author of the project
* A peer reviewer need not login to Google to comment on the doc, and all peer reviewer comments must be anonymous
* The settings for the Google Doc should be set to "Anyone with the link can comment" by the Author
* If more than one user comment on the Google doc at the same time, any conflicts that may arise should be handled well
* A Peer Reviewer needs be directed not to login to any Google account to comment on the doc, and all Peer Reviewer comments shall be anonymous
* Multiple commenting at a specific instance is taken care of by the Google Document settings and it will be placed one below the other


== '''Approach''' ==
== '''Approach''' ==


Generally, we can always create a Google document, slide presentation, or spreadsheet using Google Drive and then embed that document anywhere in our application using iFrame as a dynamic rich content editor. The rich content editor is used in features that support the editor (Announcements, Quizzes or Collaborative Reviewing in our case). Any time you make changes to the Google document (like comments), it will be automatically updated in the application's content editor.
The first phase of our project aimed at embedding a Google document which enables the project Author to automatically generate a Google document with specified permissions for the reviews such that when a reviewer makes a comment it appears without his identity.  
   
We succeeded in authorizing the user to the Google documents by using the google-client-API (aouth + signet) credentials and the API console also showed positive results for the "request" sent over to the client and created a google document but to access that particular binary file we had to set the permission rights of the service account for which the google document is created which is different from the credentials accountWe also tried hard coding and giving all access rights to anyone who wanted to open the file but it seems practically impossible to get those rights.
===Creating Google document, Setting Up its Link===


* First and foremost a provision (button) for creating a Google document is added to the ''Your Work'' page of ''Assignments''.
The second half of the project aimed at creating a flash box which directs the author to set the comment rights on the review google document as decided by the professor subject to the condition and complexity of the project. This will happen on the go and the author is notified to "enable commenting rights only" only if the faculty checks the option for that particular project.  
* When the authors would select this button before submitting their assignment, a new Google doc is created.
On the other side whenever the reviewers click on the google document link attached to the project for reviewing or commenting on a project they will get a notification alert to log out of all google accounts in order to assure the anonymity of the reviewer. This is done because google documents does not support complete anonymity. In this the assumption is that the google doc is created in the same manner as the other hyperlinks are added.
* The document's Sharing criteria is set using google docs API such that the authors of the team can edit the document.
* Sharing criteria is also set such that anyone else having the link to this document can only comment.
* The authors would then copy paste their content, to be reviewed, on to the document.


===Modifications for Instructors===


[[File:Doceditor.png]]
* When an instructor will create a new assignment, he should be able to select a checkbox if he wants to enable anonymous commenting for google docs.
* If the instructor selects this then the authors will not be able to identify the individuals commenting on the doc.
* The below image shows how we aim to create a checkbox about the same for the instructor.  




* Now the file sharable link must be pasted while submitting an Assignment in expertiza as shown below.
[[File:newassign.png|center|]]
* The new Google doc link will be saved with other hyperlinks in the 'submitted_hyperlinks' column of 'teams' table.


===Modifications for Authors===


[[File:Googledoc.png]]
* The authors need to create a Google doc, input their assignment content for Review and submit the hyperlink as shown below.


===Publishing the document to Web===
[[File:Hyperlink.png|center|]]


* Open the File menu in Google doc and select Publish to the web....
* We will try to create an alert message whenever the author submits a google doc link.  
* Make sure that the Automatically republish when changes are made checkbox is selected. Click the Start publishing button.
* The alert message will ask the author to change the sharing settings of the doc to 'Anyone with the link can comment'.
* When a confirmation prompt pops up, click the OK button.
* This message should be thrown only when the author submits a google doc link and not any other link.  
* Click on the Embed tab to get the below screen, now copy the text in order to use it in our expertiza code.
* The below image shows the desirable alert message when author tries to submit a google doc link.




[[File:Publish.png]]
[[File:google doc.png|center|]]


===Security Risks===
===Modifications for Reviewers===


As mentioned in the requirement document, there are 2 security risks associated with this project, they are:
*A situtation where more than one people comment on the doc and mess up the content.
*Possible security violations like an user with access to the link deletes all the content on that doc.


Proposed solution to mitigate the risk:
* If the instructor has enabled anonymous commenting on google docs then the reviewer should see an alert message which will ask the reviewer to log out from all google accounts before opening the google doc link.
*To address these two issues we'll be modifying the access rights of the google doc associated with that project.
* The reviewer will need to logout because google allows anonymous commenting on a doc only if the user is currently not logged into any google account.
*We'll by default assign all new users who access the page only the 'can comment' access right and only the author team will have 'can edit' rights.
* The below image shows the desirable alert message when a reviewer tries to review a project which has google docs in its submission and anonymous commenting is enabled.




[[File:can_comment.png]]
[[File:anonymous.png|center|]]


===Illustration of Google Doc with Anonymous Reviews===


*As it can be seen, Google doc has 3 access levels and the 'can comment' option will allow the users only to add more comments on the Google doc. They won't be able to edit or delete previously entered comments.
* As explained above, once every author creates a Google document for their assignment, they can input their content for reviewal. (For example, their wikipedia article)
*Doing this will ensure that no user even unintentionally will be able to delete or edit previous comments which might be of great value to the authors of that project.
* On following the above permission settings and security points, authors can upload the shareable link for commenting
* One reviewers anonymously comment on the doc, this doc would look like the below image:


[[File:Actualdoc.png|center|]]


===Embedding the document editor in expertiza===


* Our aim is to incorporate the dynamic content editor in the Review Assignments page, so that all the users can make collaborative suggestions in the document at the time of Review.
===Security Risks===
* In order to embed this editor, the code needs to be added in the View page for student responses.
* For example, to embed the editor for Assignment Responses the above code must be incorporated in the view.html.erb file in the response controller, as shown below.


As mentioned in the requirement document, there are 2 security risks associated with this project, they are:
*A situation where the peer reviewer forgets to logout would result in his/ her name being added to the history of document edits which will reveal the identity.
*Possible security violations like an user with access to the link deletes all the content on that doc.


[[File:Iframecode.png]]
Proposed solution to mitigate the risk:
*When a reviewer goes on the page of submitted contents, he'll be shown an alert message to logout from google accounts if there exists a google docs link in the submitted content and instructor has enabled anonymous commenting.
*The authors of the project will be shown an alert to modify the settings of their google doc to 'Anyone with the link can comment' when they submit a google doc link.




* On building the code and running expertiza, we must be able to see the Google doc editor successfully embedded in the Assignment Reviews page.
[[File:can_comment.png|thumb=can_comment.png|center|alt = ScreenShot of google document settings|ScreenShot of google document settings]]
* In the below image, we can see the frame where the saved Google doc is embedded. Instead of embedding the doc, we can also have a pop-up window of the doc.
* All the text in ''black'' in the below image, is the content added by the authors. Hence this cannot be edited by the reviewers.
* The text in colored font are the comments made by reviewers. The below comments have been written for illustrations sake.
* The comments in reality would be different and will be shown on the right side of the document page. (We can correlate this with comments made in MS Word document)
* The users need not login to Google in order to comment in the document. Hence, the comments made will be anonymous.
* If the users are already logged in to Google, constraints will be set such that their ''ID'' is hidden and their comments are still made anonymous.




[[File:Embeddoc.png]]
*As it can be seen, Google doc has 3 access levels and the 'can comment' option will allow the users only to add more comments on the Google doc. They won't be able to edit or delete previously entered comments.
 


== '''Project File and Database additions''' ==


* The new outcome will involve accessing the database table 'assignments' and we will make  a change to the schema of the table by adding a column 'allow_anonymous_commenting' of the type 'Boolean' to indicate whether the professor has asked the project developers to have a review document created with the rights of anonymous comments. 
* To incorporate the database changes we will generate a migration file in the "db" migrate named: '_add_allow_anonymous_commenting_to_assignemnnts.rb'
* The 'factories' file in the spec will have a variable added with the default value set as 'FALSE'
* '_genral.html.erb' page in the edit assignments view will have a 'check box' and a label added to it.
* A function will be added in the 'assignments_form' model which sets the visibility to false/ true depending on the input
* Newly added Google doc hyperlinks will be saved with other assignment hyperlinks in the 'submitted_hyperlinks' column of 'teams' table.


== '''Testing Plan''' ==
== '''Testing Plan''' ==
Line 92: Line 96:


i. Any user having the doc link should only be able to comment on the Google doc<br>
i. Any user having the doc link should only be able to comment on the Google doc<br>
ii. Changes made in the original Google doc should be reflected in the embedded doc editor in expertiza <br>
ii. Alert should be shown to the authors only while submitting a google doc link <br>
iii. Users need not login to comment in the Google doc<br>
iii. Users need not login to comment in the Google doc<br>
iv. All comments made must be anonymous<br>
iv. Alert should be shown to the reviewers only if the submissions contain a google doc link and anonymous commenting is enabled<br>
v. Multiple comments made at the same time should not lead to any conflicts <br>
v. Multiple comments made at the same time should not lead to any conflicts <br>



Latest revision as of 02:51, 5 December 2016

Expertiza Background

Expertiza is an educational web application created and maintained by the joint efforts of the students and the faculty at NCSU. It’s an open source project developed on Ruby on Rails platform and it’s code is available on Github. Using Expertiza students can bid for a particular project topic and the faculty assigns the same to different groups. Students can track their grades for previous projects and make new submissions for current projects. It also allows students to review each other’s work and improve their work upon this feedback.

Project Description

Currently the instructor creates rubrics for an assignment through questionnaires which students use to review other students' submissions. The only way reviewers can suggest some more changes to the author is by using the 'additional comments' section in the review form which is not very helpful. In this project we will be looking towards improving this functionality by adding an extra medium through which multiple reviewers can collectively comment on the author's work and collaborate their answers in a constructive way. We are planning to achieve this by enabling alert messages to the authors and the reviewers who will use the newly created Google document links embedded into Expertiza. For every Assignment created, the Instructors have been given a new criteria to make the review comments as anonymous. Depending on the criteria set, the Authors will be provided with notifications on two things: the permission setting of the Google Doc(Allow users with link to comment only) and to make reviewer comments anonymous. The Author of every Assignment will then need to create a Google doc based on these notifications. The links once submitted can be accessed by reviewers to submit their reviews. The reviewers also get notifications if they need to review the Assignments anonymously. If the anonymous setting is enabled, the reviewers will need to log out from all their Google accounts before opening the Google doc. Once on the Google doc, the reviewer's comments will be posted anonymously, the reviewer's comment will be anonymous to both, other fellow reviewers as well as the author. This feature will help the author to better understand where is his work exactly lacking and how exactly should the changes be worked upon based on the comments received. The reviewers will just need the Google doc link to post comments and it wouldn't be required to login into Expertiza or any google account for using this feature.

Key Points To Consider

  • The alert message should only pop up when the Faculty has indicated to do so (alert messages only whe Google Doc hyperlinks are uploaded, and when Anonymous commenting is Enabled )
  • The Google Doc link needs to be added on the Assignment submissions page by the Author of the project
  • The settings for the Google Doc should be set to "Anyone with the link can comment" by the Author
  • A Peer Reviewer needs be directed not to login to any Google account to comment on the doc, and all Peer Reviewer comments shall be anonymous
  • Multiple commenting at a specific instance is taken care of by the Google Document settings and it will be placed one below the other

Approach

The first phase of our project aimed at embedding a Google document which enables the project Author to automatically generate a Google document with specified permissions for the reviews such that when a reviewer makes a comment it appears without his identity. We succeeded in authorizing the user to the Google documents by using the google-client-API (aouth + signet) credentials and the API console also showed positive results for the "request" sent over to the client and created a google document but to access that particular binary file we had to set the permission rights of the service account for which the google document is created which is different from the credentials account. We also tried hard coding and giving all access rights to anyone who wanted to open the file but it seems practically impossible to get those rights.

The second half of the project aimed at creating a flash box which directs the author to set the comment rights on the review google document as decided by the professor subject to the condition and complexity of the project. This will happen on the go and the author is notified to "enable commenting rights only" only if the faculty checks the option for that particular project. On the other side whenever the reviewers click on the google document link attached to the project for reviewing or commenting on a project they will get a notification alert to log out of all google accounts in order to assure the anonymity of the reviewer. This is done because google documents does not support complete anonymity. In this the assumption is that the google doc is created in the same manner as the other hyperlinks are added.

Modifications for Instructors

  • When an instructor will create a new assignment, he should be able to select a checkbox if he wants to enable anonymous commenting for google docs.
  • If the instructor selects this then the authors will not be able to identify the individuals commenting on the doc.
  • The below image shows how we aim to create a checkbox about the same for the instructor.


Modifications for Authors

  • The authors need to create a Google doc, input their assignment content for Review and submit the hyperlink as shown below.
  • We will try to create an alert message whenever the author submits a google doc link.
  • The alert message will ask the author to change the sharing settings of the doc to 'Anyone with the link can comment'.
  • This message should be thrown only when the author submits a google doc link and not any other link.
  • The below image shows the desirable alert message when author tries to submit a google doc link.


Modifications for Reviewers

  • If the instructor has enabled anonymous commenting on google docs then the reviewer should see an alert message which will ask the reviewer to log out from all google accounts before opening the google doc link.
  • The reviewer will need to logout because google allows anonymous commenting on a doc only if the user is currently not logged into any google account.
  • The below image shows the desirable alert message when a reviewer tries to review a project which has google docs in its submission and anonymous commenting is enabled.


Illustration of Google Doc with Anonymous Reviews

  • As explained above, once every author creates a Google document for their assignment, they can input their content for reviewal. (For example, their wikipedia article)
  • On following the above permission settings and security points, authors can upload the shareable link for commenting
  • One reviewers anonymously comment on the doc, this doc would look like the below image:


Security Risks

As mentioned in the requirement document, there are 2 security risks associated with this project, they are:

  • A situation where the peer reviewer forgets to logout would result in his/ her name being added to the history of document edits which will reveal the identity.
  • Possible security violations like an user with access to the link deletes all the content on that doc.

Proposed solution to mitigate the risk:

  • When a reviewer goes on the page of submitted contents, he'll be shown an alert message to logout from google accounts if there exists a google docs link in the submitted content and instructor has enabled anonymous commenting.
  • The authors of the project will be shown an alert to modify the settings of their google doc to 'Anyone with the link can comment' when they submit a google doc link.


ScreenShot of google document settings


  • As it can be seen, Google doc has 3 access levels and the 'can comment' option will allow the users only to add more comments on the Google doc. They won't be able to edit or delete previously entered comments.


Project File and Database additions

  • The new outcome will involve accessing the database table 'assignments' and we will make a change to the schema of the table by adding a column 'allow_anonymous_commenting' of the type 'Boolean' to indicate whether the professor has asked the project developers to have a review document created with the rights of anonymous comments.
  • To incorporate the database changes we will generate a migration file in the "db" migrate named: '_add_allow_anonymous_commenting_to_assignemnnts.rb'
  • The 'factories' file in the spec will have a variable added with the default value set as 'FALSE'
  • '_genral.html.erb' page in the edit assignments view will have a 'check box' and a label added to it.
  • A function will be added in the 'assignments_form' model which sets the visibility to false/ true depending on the input
  • Newly added Google doc hyperlinks will be saved with other assignment hyperlinks in the 'submitted_hyperlinks' column of 'teams' table.

Testing Plan

This UI enhancement will be tested to check whether the following required functionalities are implemented successfully:

i. Any user having the doc link should only be able to comment on the Google doc
ii. Alert should be shown to the authors only while submitting a google doc link
iii. Users need not login to comment in the Google doc
iv. Alert should be shown to the reviewers only if the submissions contain a google doc link and anonymous commenting is enabled
v. Multiple comments made at the same time should not lead to any conflicts

References