Extension:Evaluation WikiFlow

From MediaWiki.org
Jump to navigation Jump to search
MediaWiki extensions manual
Crystal Clear action run.svg
Evaluation WikiFlow
Release status: unmaintained
Implementation Page action, Special page
Description Evaluation workflow
Author(s) EnricoDagatalk
Latest version 0.3
MediaWiki 1.11.1+
License No license specified
Download http://ontologydesignpatterns.org/evalwf/0.3/EvaluationWikiFlow-0.3.zip
Extension:Evaluation_WikiFlow/README
Extension:Evaluation_WikiFlow/CHANGELOGS
Added rights
  • viewevaluation
  • askforreview
  • assignreview
  • certify
Hooks used
ArticleSave
ArticleSaveComplete
ArticleViewHeader
LanguageGetMagic
SpecialPageExecuteBeforeHeader
SkinTemplateContentActions
UnknownAction
Translate the Evaluation WikiFlow extension if it is available at translatewiki.net
Check usage and version matrix.

What can this extension do?[edit]

Evaluation WikiFlow enhance MediaWiki with evaluation workflow, supporting all the life-cycle of a certification process of the content of the wiki pages.

Usage[edit]

Evaluation workflow[edit]

Evaluation workflow is performed through the following special pages:

  • Special:AskForReview
  • Special:AssignReview
  • Special:MakeReview
  • Special:Certify

while information about article state, pending reviews and assignments can be found at these pages:

  • Special:WaitingForReviews
  • Special:AssignedReviews

Evaluation tab[edit]

All articles belonging to a category to evaluate (see configuration for details) will have the evaluation section (tab) added to the actions menu.

The evaluation section shows information about the article reviews, assignments and provide buttons to perform the following actions:

Ask for review[edit]

Users with the askforreview permission can ask for a review about the current article. Performing this action will mark the article with the custom Category Waiting for review. The same action can be performed through the special page Special:AskForReview, by typing the article's title in the form provided.

Make review[edit]

Users with the makereview permission can make reviews by clicking the related button in the evaluation section or using the special page Special:MakeReview. Review article will be created in the custom namespace Review with the title UserName about PageName. If the article object of the review belongs to category Waiting for review, annotation is deleted.

Assign review[edit]

Users with the assignreview permission can perform this operation. Clicking the button from the evaluation section will prepare the form provided by the special page Special:AssignReview with the page name precompiled. User can fill in the username of the Reviewer and assign the review. Article object of the assignment will belongs to category Review assigned. This annotation will be deleted when the reviewer will create a review through the Special:MakeReview.

Certify[edit]

Users with the certify permission can perform this action directly from the evaluation section, to precompile the form provided by the Special:Certify page with the current article's pagename.

The interface allows two modes: the move page mode and the lock and copy mode:

Certify by move[edit]

Page is renamed. Categories that marked the article as 'to evaluate' are deleted. User can also write the old name of the article, to don't perform move operation.

Certify by lock and copy[edit]

Page edition and moving is protected and content is used for a new page (all subpages are also copied, following the base page). This could be useful if site permissions are configured depending on namespaces, to let some users have different rights on articles to evaluate and certified.

Installation[edit]

Requirements[edit]

MediaWiki: 1.11.1+ is required.

Version tested are also:

  • 1.12.*
  • 1.13.0, 1.13.1, 1.13.2

Non functional for:

  • Bitnami - MediaWiki - 1.16.2

Other versions have not been tested yet... (if someone does it with newer versions, feel free to add notice here)

Required extensions:

Suggested extensions:

Download instructions[edit]

You can download the version 0.3 here

Unzip the package and copy the folder EvaluationWikiflow in your $IP/extensions directory.

To install this extension, you need first to run the SQL query in the file db/createtables.sql, then add the following to LocalSettings.php:

require_once("$IP/extensions/EvaluationWikiflow/includes/EW_Settings.php");

NOTE: If your wiki uses table prefixes, you need to alter table names in the createtable.sql file.

Configuration[edit]

To configure the extension you must follow these steps:

Step 1 (optional)[edit]

Define the namespace index for the reviews in your LocalSettings.php and the name of the semantic property for the relation between review and article reviewed:

$ewgReviewsNS=300; <!-- this is the default value -->
$ewgPropertyReviewAbout  = 'Review about'; <!-- this is the default value -->

Step 2 (optional)[edit]

Edit the file 'includes/EW_Settings.php' and define user rights and e-mail notification configurations (the ones showed are the default values):

$wgGroupPermissions ['*'] [EW_ACTION_VIEW] = false;
$wgGroupPermissions ['user'] [EW_ACTION_VIEW] = true;
$wgGroupPermissions ['user'] [EW_ACTION_ASK] = true;
$wgGroupPermissions ['user'] [EW_ACTION_MAKE] = true;
$wgGroupPermissions ['bureaucrat'] [EW_ACTION_ASSIGN] = true;
$wgGroupPermissions ['sysop'] [EW_ACTION_CERTIFY] = true;

$ewgNotifyAllContributors = false;
$ewgNotifyAllReviewers = false;
$ewgNotifyAllManagers = false;
//$ewgNotifyGroups[EW_ACTION_ASK] = 'bureaucrat';
//$ewgNotifyGroups[EW_ACTION_ASSIGN] = 'bureaucrat';
//$ewgNotifyGroups[EW_ACTION_MAKE] = 'bureaucrat';
//$ewgNotifyGroups[EW_ACTION_CERTIFY] = 'bureaucrat';

Step 3 (mandatory)[edit]

Define a Template for the reviews and add in the wiki text the following parser function:

{{#reviewabout:{{{ReviewAboutField|}}}|}}

This is important in order to make the system recognize pages that are Reviews and about which article.

Step 4 (mandatory)[edit]

Define a new semantic Form to use for reviews. This form must:

  • use the template created above;
  • use the custom input types:
    • 'reviewaboutpage' (mandatory)
    • 'reviewer' (optional)
    • 'reviewaboutrevision' (optional)

(see Extension:SemanticForms for more details about how to configure a form):

{{{for template|Review Template|label=New review}}}

[...]

Reviewer: {{{field|ReviewerField|input type=reviewer|hidens=1}}} 
<!-- this is optional, use it if you want to use this information in your template page -->

Review about: {{{field|ReviewAboutField|input type=reviewaboutpage|hidens=1}}} 
<!-- This is mandatory! (the option hidens can be 1 or 0 depending on how do you use 
it in the template definition)-->

Revision ID: {{{field|RevisionField|input type=reviewaboutrevision}}} 
<!-- this is optional, use it if you want to use this information in your template page -->

{{{field|ReviewText|mandatory|input type=textarea|rows=20|cols=60}}}

[...]
{{{end template}}}
[...]

IMPORTANT: The template variable in the example above {{{ReviewAboutField|}}} must have the form input type reviewaboutpage as in the example.

You will use this form only for Review creation. For edit action you need to setup a different form.

Step 5 (mandatory)[edit]

Add to the Category page of the articles to be evaluated the semantic property Form for reviews pointing to the review Form:

[[Form for reviews::Form:My_review_form]]

You can setup different review forms for different categories.

Step 6 (optional)[edit]

You can configure mail notifications by editing these pages:

  • MediaWiki:EWMailAsk
  • MediaWiki:EWMailAssign
  • MediaWiki:EWMailMake
  • MediaWiki:EWMailCertify

See the section #How to configure e-mail notifications.

User rights[edit]

Evaluation WikiFlow use five new user rights:

Permission Description Default group(s)
viewevaluation Rights for view Evaluation tab and statistics user

(all registered users)

askforreview Rights for asking for a review about an article user
assignreview Rights for assigning reviews to Users bureaucrat
makereview Rights for make review(s) user
certify Rights for certify articles sysop

Parser functions[edit]

EvalWF enhance wiki parser with some functions for managing revision and evaluation process, to use with Extension:ParserFunctions

About article's revision:

#iscurrent returns 1 if the review is about the current article's revision, 0 elsewhere
#revisionid returns the revision id of the article

About evaluation workflow state:

#iswaiting returns 1 if current article is waiting for review, 0 elsewhere
#isassigned returns 1 if current article has some assigned review pending (not done yet by the reviewer)
#iscertified returns 1 if article has been certified, 0 elsewhere
#needsedit returns 1 if a review about an article has been made, but after that article has not been enhanced

How to configure e-mail notifications[edit]

To enable e-mail notification you have to create the pages that will hold the message template.

The following sections show informations about e-mail customization. For each action you can setup a e-mail text using some placeholders.

In these pages wikitext is not supported.

Notification for action ask for review (MediaWiki:EWMailAsk)[edit]

Recipients are:

  • the User who requested the review
  • users who contributed to the article (if flag $ewgNotifyAllContributors=true)
  • reviewers: users that made a review before this request (if any) (if flag $ewgNotifyAllReviewers=true)
  • managers: users who have the grant of assigning reviews (default are members of the 'bureaucrat' group) (if flag $ewgNotifyAllManagers=true)

Edit the page at MediaWiki:EWMailAsk with the text of the email using the following placeholders, if needed:

{{{REQUESTED_BY_REAL_NAME}}} Real name of the user who requested the review
{{{REQUESTED_BY_USER_NAME}}} User name of the user who requested the review
{{{FULLPAGENAME}}} Full page name (with namespace)
{{{PAGENAME}}} Simple page name (without namespace)

Notification for action assign review (MediaWiki:EWMailAssign)[edit]

Recipients are:

  • the user who managed this assignment
  • the user that requested a review (if any) (if flag $ewgNotifyAllContributors=true);
  • the reviewer who received the assignment;

Edit the page at MediaWiki:EWMailAssign with the text of the mail using the following placeholders, if needed:

{{{ASSIGNED_BY_REAL_NAME}}} the real name of the user who managed the assignment
{{{ASSIGNED_BY_USER_NAME}}} the user name of the user who managed the assignment
{{{ASSIGNED_TO_REAL_NAME}}} the real name of the reviewer
{{{ASSIGNED_TO_USER_NAME}}} the user name of the reviewer
{{{FULLPAGENAME}}} the name of the page object of the review request (with namespace)
{{{PAGENAME}}} the name of the page object of the review request (without namespace)

Notification for action make review (MediaWiki:EWMailMake)[edit]

Recipients are:

  • the user who made the review
  • the user that requested a review (if any)
  • users who contributed to the article (if flag $ewgNotifyAllContributors=true)
  • manager who assigned the review (if any) (if flag $ewgNotifyAllManagers=true)

Edit the page at MediaWiki:EWMailAssign with the text of the mail using the following placeholders, if needed:

{{{REVIEWER_REAL_NAME}}} the real name of the user
{{{REVIEWER_USER_NAME}}} the user name
{{{FULLPAGENAME}}} the name of the page object of the review (with namespace)
{{{PAGENAME}}} the name of the page object of the review (without namespace)
{{{REVIEW_FULLPAGENAME}}} the name of the review page (with namespace)
{{{REVIEW_PAGENAME}}} the name of the review page (without namespace)

Notification for action Certify[edit]

Recipients are:

  • users who contributed to the article (if flag $ewgNotifyAllContributors=true)
  • users who made reviews of the article (if flag $ewgNotifyAllReviewers=true)
  • users who made assignments about the article (if flag $ewgNotifyAllManagers=true)

To configure the message, edit the page MediaWiki:EWMailCertify, using, if needed, the following placeholders:

{{{FULLPAGENAME}}} the name of the page that has been certified (with namespace)
{{{PAGENAME}}} the name of the page that has been certified (without namespace)
{{{CERTIFIED_FULLPAGENAME}}} the name of the page after certification (with namespace)
{{{CERTIFIED_PAGENAME}}} the name of the page after certification (without namespace)

Towards version 1.0[edit]

  • report evaluation wf -> export history in RDF
  • more easy configuration
  • multiple category/review configuration

E-mail features

  • Advise reviewer about a new assignment (added in version 0.3)
  • Advise author(s) of the proposal if a new review has been done (added in version 0.3)

Others

  • Advise the reviewer on login for new pending assignments

Versions log[edit]

  • 0.3 More improvements:
    • Added a select input to the Assign review special page for reviewers.
    • Added email notifications
    • Added Evaluation trace to the evaluation tab
    • More nice evaluation tab section
    • Categories to evaluate are detected from the Form for review property
  • 0.2 Messages added, some bugs fixed
  • 0.1

See also[edit]

This extension was developed for the Ontology Design Patterns portal, in order to support the OP evaluation workflow.