Extension:AuthorReward

From MediaWiki.org
Jump to: navigation, search
MediaWiki extensions manualManual:Extensions
Crystal Clear action run.png
AuthorReward

Release status:Extension status beta

DescriptionTemplate:Extension#description Reward community-curated efforts in bio-wikis by contribution quantification and explicit authorship
Author(s)Template:Extension#username Zhang Zhang, Ming Tian, Lin Dai
MediaWikiTemplate:Extension#mediawiki Tested on 1.18.4
PHPTemplate:Extension#php 5.2.17 (apache2handler)
LicenseTemplate:Extension#license GPL
Download Project page
Git [Help]

Browse source code
View code changes
Note Note: No localisation updates provided by Translatewiki.nettranslatewiki.net.

Translate the AuthorReward extension if it is available at translatewiki.net

Check usage and version matrix.

The AuthorReward extension aims to provide a standard practice to reward community-curated efforts in biological knowledge wikis (bio-wikis). It quantifies researchers’ contributions, provides due recognition according to their quantitative contributions and gives explicit authorship in bio-wikis.

Installation[edit]

Compilation[edit]

Compilation of "AuthorReward.cpp".

  1. Install MySQL Connector/C++. Download MySQL Connector/C++ from http://dev.mysql.com/downloads/connector/cpp, unzip the downloaded package and copy the files in "lib" and "include" to "/usr/lib/" and "/usr/include/", respectively.

    For MAC users, the library might be copied in "/opt/local/include" and "/opt/include/cppconn", and please make corresponding changes in "makefile".
  2. Type "make" to compile "AuthorReward.cpp".

Run[edit]

Since edit distance is estimated for two different revisions for any wiki page, it may take time to run AuthorReward at the first time. Before running AuthorReward, export the following environmental variable.

  export LD_LIBRARY_PATH=/usr/local/lib 

Then type the following command to run AuthorReward.

  ./AuthorReward [hostname] [username] [password] [database name] [database table prefix] 

For example: export results into a file named "results.txt"

  ./AuthorReward localhost root 123456 ricewiki rice > results.txt &

Extension installation[edit]

Install the extension by adding the following code to LocalSettings.php.

  require_once( "$IP/extensions/AuthorReward/AuthorReward.php" );

Please note that it requires "ToggleDisplay" extension, which is also located in the package of AuthorReward. If "ToggleDisplay" was not installed, please also add the following code to "LocalSettings.php".

  require_once( "$IP/extensions/AuthorReward/ToggleDisplay.php" );

Set in crontab[edit]

Since edits in wiki are probably made frequently, it might be better to set AuthorReward to run automatically in background.

  1. Open the file named "AuthorReward.sh" and set the correponding variables according to your wiki.
  2. To run at a given time span, please type "crontab -e" and install "AuthorReward.sh" in crontab. The time could be set depending on the frequency of edits made in your wiki as well as the performance of server.

    For example, the following command is to run "AuthorReward.sh" at every 30 minutes.
  */30     *       *       *       *  sh /Your Pathway/AuthorReward.sh

Configuration parameters[edit]

  $wgAuthorRewardDecimal = 3; #Decimal number
  $wgAuthorRewardLamda = 0.001; #Normalized lamda value
  $wgAuthorRewardScoreCutOffForAuthorship = 1; #Cut-off score for giving the authorship
  $wgAuthorRewardHeader = "Please cite: "; #Header
  $wgAuthorRewardCaption = "Gene: "; #Caption

Reference[edit]

Bio-wikis installing AuthorReward[edit]

Screenshot[edit]

Sd1-ricewiki.png