{"id":13557664,"url":"https://github.com/Grasia/WikiChron","last_synced_at":"2025-04-03T12:31:04.096Z","repository":{"id":37601787,"uuid":"108455157","full_name":"Grasia/WikiChron","owner":"Grasia","description":"Data visualization tool for wikis evolution","archived":false,"fork":false,"pushed_at":"2022-07-12T13:50:23.000Z","size":48480,"stargazers_count":19,"open_issues_count":17,"forks_count":8,"subscribers_count":3,"default_branch":"develop","last_synced_at":"2025-03-18T15:21:45.709Z","etag":null,"topics":["analyzer","data-analysis","data-science","data-visualization","datascience","dump","evolution","graphs","history","history-dump","mediawiki-wikis","plot","research-tool","time-series","visualization","web-service","wiki","wikia","wikimedia","wikis"],"latest_commit_sha":null,"homepage":"http://wikichron.science/","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"agpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Grasia.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-10-26T19:16:04.000Z","updated_at":"2023-01-02T02:13:56.000Z","dependencies_parsed_at":"2022-07-13T08:31:09.097Z","dependency_job_id":null,"html_url":"https://github.com/Grasia/WikiChron","commit_stats":null,"previous_names":[],"tags_count":44,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Grasia%2FWikiChron","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Grasia%2FWikiChron/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Grasia%2FWikiChron/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Grasia%2FWikiChron/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Grasia","download_url":"https://codeload.github.com/Grasia/WikiChron/tar.gz/refs/heads/develop","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247002185,"owners_count":20867421,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["analyzer","data-analysis","data-science","data-visualization","datascience","dump","evolution","graphs","history","history-dump","mediawiki-wikis","plot","research-tool","time-series","visualization","web-service","wiki","wikia","wikimedia","wikis"],"created_at":"2024-08-01T12:04:28.669Z","updated_at":"2025-04-03T12:30:59.085Z","avatar_url":"https://github.com/Grasia.png","language":"Python","funding_links":[],"categories":["Python","data-visualization"],"sub_categories":[],"readme":"# WikiChron\nWikiChron is a web tool for the analysis and visualization of the evolution of wiki online communities.\n\nIt analyzes the history dump of a wiki and give you nice graphs plotting that data.\n\n# Development\n\n## Install\n### Dependencies\n* Python 3.6.*\n* pip3\n* [Dash framework](https://plot.ly/dash)\n* [Grasia Dash Components](https://github.com/Grasia/grasia-dash-components)\n* [pandas](https://pandas.pydata.org/)\n* (Production only) [Redis Cache](https://redis.io/)\n* [python-igraph](https://igraph.org/python/) -\u003e it's a C package so it depends on your OS\n* [tkinter](https://wiki.python.org/moin/TkInter)\n\n### Install instructions\n#### Tkinter\nIf you are using Linux (and probably Mac OS X too), likely you will need to manually install the tkinter utility. You can check if tkinter is already installed in your system by [following these instructions](https://wiki.python.org/moin/TkInter#Checking_your_Tkinter_support).\n\nTo install it, if you are in Ubuntu or derivatives you can use this command:\n\n`sudo apt-get install python3-tk`\n\nIf you are using pyenv, you should follow the instructions posted in [this answer of stack overflow](https://stackoverflow.com/a/45622282/2904315).\n\n#### igraph\nThe dependency `python-igraph` needs to compile some C code, so, in order to install it, you priorly need some dev libraries for python, xml, zlib and C compiler utilities.\n\nFor Ubuntu 18.04 (bionic) or newer versions you can directly install igraph for python3 with:\n\n`sudo apt-get install python3-igraph`\n\nFor older versions of Ubuntu (16.04 and derivatives), you need to install the following dependencies prior to be able to compile and install igraph with pip:\n\n`sudo apt-get install build-essential python3-dev libxml2 libxml2-dev zlib1g-dev`\n\n#### Other deps\nAfter that, simply run: `pip3 install -r requirements.txt`. pip will install all the remaining dependencies you need.\n\nIn case of versions of linux where igraph for python3 is not available in your package manager, you need to use the requirements file which includes the igraph package in order to be built and installed with pip:\n`pip3 install -r requirements+igraph.txt`\n\n### Using a virtual environment\nA good pratice is to use a virtual environment in order to isolate the development environment from your personal stuff. This skips issues about having different Python versions, pip packages in the wrong place or requiring sudo privileges and so on.\n\nIn order to do this, first install [virtualenv](http://docs.python-guide.org/en/latest/dev/virtualenvs/), either from your package manager or from pip.\n\nThen, create a new virtual environment in the repo root folder with:\n`virtualenv -p python3 venv/`\n\nActivate the virtual environment:\n`source venv/bin/activate`\n\nAnd finally, install dependencies here:\n`pip install -r requirements.txt`\n\n## Input wiki data\nLikely, the source data for wikichron will come from a XML file with the full edit history of the wikis you want to analyze. [Go here if you want to learn more about Wikimedia XML dumps](https://www.mediawiki.org/wiki/Manual:Backing_up_a_wiki#Backup_the_content_of_the_wiki_(XML_dump)).\n\nIn order to get such XML dump, [you can follow the instructions explained in the WikiChron's wiki](https://github.com/Grasia/WikiChron/wiki/How-to-add-a-new-wiki#get-the-dump).\n\n### Process the dump\nSecondly, you'll need to convert that xml raw data into a processed csv that WikiChron can load and work with.\n\nFor that transformation, you should use our [wiki-dump-parser script](https://pypi.org/project/wiki-dump-parser/). You can find a short guide on how to use this script [in this page of the WikiChron's wiki](https://github.com/Grasia/WikiChron/wiki/How-to-add-a-new-wiki#process-the-dump).\n\n## Provide some metadata of the wiki\nWikichron needs one last thing in order to serve the visualization of a wiki for you.\n\nYou need to have a `wikis.json` file in your data_dir/ directory with some metadata of the wikis you want to explore; like the number of pages, the number of users, the user ids of the bots, etc.\n\nYou can find some helpful instructions on how to edit or automatically generate this file using a script [in this page of the WikiChron's wiki](https://github.com/Grasia/WikiChron/wiki/How-to-add-a-new-wiki#modify-the-wikisjson-file).\n\n## Run the application\nUse: `python3 -m wikichron` or `python3 wikichron/app.py`\n\nThe webapp will be locally available under http://127.0.0.1:8880/app/\n\nOptionally, you can specify a directory with the csv data of the wikis you want to analyze with the environment variable: `WIKICHRON_DATA_DIR`.\n\nFor instance, suppose that your data is stored in `/var/tmp`, you might launch wikichron using that directory with:\n\n`WIKICHRON_DATA_DIR='/var/tmp' python3 wikichron/app.py`\n\nIt will show all the files ending in .csv as wikis available to analyze and plot.\n\n## Development environment\n\nTo get errors messages, backtraces and automatic reloading when source code changes, you must set the environment variable: FLASK_ENV to 'development', i.e.: `export FLASK_ENV=development` prior to launch `app.py`.\n\nThere is a simple but handy script called `run_develop.sh` which set the app for development environment and launches it locally.\n\nYou can get more information on this in the [Flask documentation](http://flask.pocoo.org/docs/1.0/server/).\n\n# Deployment\nThe easiest way is to use [Docker](#Docker).\n\nOtherwise, follow the Dash instructions: https://plot.ly/dash/deployment and inspect the `deploy.sh` script, which launches the app with the latest code in master and provides the appropriate arguments. Check it out and modify to suit your needs.\n\n## gunicorn config\n\nFor the deployment you need to set some configuration in a file called `gunicorn_config.py`.\n\nYou can start by copying the sample config file located in this repo and then edit the config parameters needed to suit your specific needs:\n\n`cp sample_gunicorn_config.py gunicorn_config.py`\n\nThe documentation about the gunicorn settings allowed in this file can be found [in the official gunicorn documentation](https://docs.gunicorn.org/en/stable/settings.html#settings).\n\nThe environment variable `WIKICHRON_DATA_DIR` is bypassed directly to WikiChron and sets the directory where WikiChron will look for the wiki data files, as it was explained previously in the [Run the application section](#run-the-application).\n\n## Setup cache\nIf you want to run WikiChron in production, you should setup a RedisDB server and add the corresponding parameters to the cache.py file.\n\nLook at the [FlaskCaching documentation](https://pythonhosted.org/Flask-Caching/#rediscache) for more information about caching.\n\n## Flask deployment config\n\nThis webapp use some configurable parameters related to the Flask instance underneath. Those paramenters are such as hostname, port and ip address for the cache and need to be set in a file called \"production_config.cfg\" which should be located inside the directory called \"wikichron\". An example of the values for those parameters are in the file called \"sample_production_config.cfg\". So simply copy that file and edit them accordingly:\n\n`cp wikichron/sample_production_config.cfg wikichron/production_config.cfg`\n\n## Docker\n\nYou can use Docker to deploy WikiChron. The sample configurations are already set to use get the docker compose working smoothly.\n\nJust copy the sample config files to the appropriate names (as explained above) and run:\n\n`docker-compose up`\n\nThis will start up the wikichron webserver as well as a redis instance to use for the cache.\n\nIf, for any reason, you wanted to start a standalone docker instance for wikichron (without redis), you could use a command similar to this one:\n\n`docker run --mount type=bind,source=/var/data/wiki_dumps/csv,target=/var/data/wiki_dumps/csv -p 8080:8080 -it wikichron:latest`\n\n# Third-party licenses\n\n## Font Awesome\nWe are using icons from the [font-awesome](https://fontawesome.com) repository. These icons are subjected to the Creative Commons Attribution 4.0 International license. [You can find to the terms of their license here](https://fontawesome.com/license).\nIn particular, we are using the following icons: share-alt-solid, info-circle\n\n### Modifications in font awesome icons\n* The file: `share.svg` is a modification of the [`share-alt-solid.svg`](https://fontawesome.com/icons/share-alt?style=solid) file provided by fontawesome.\n\n# Publications\n\nWikiChron is used for science and, accordingly, we have presented the tool in some scientific conferences. Please, cite us if you use the tool for your research work:\n* Abel Serrano, Javier Arroyo, and Samer Hassan. 2018. Webtool for the Analysis and Visualization of the Evolution of Wiki Online Communities. In Proceedings of the European Conference on Information Systems 2018 (ECIS '18). 10 pages.\n  * [Freely available here](https://aisel.aisnet.org/cgi/viewcontent.cgi?article=1072\u0026context=ecis2018_rip)\n* Abel Serrano, Javier Arroyo, and Samer Hassan. 2018. Participation Inequality in Wikis: A Temporal Analysis Using WikiChron. In Proceedings of the 14th International Symposium on Open Collaboration (OpenSym '18). ACM, New York, NY, USA, Article 12, 7 pages. DOI: https://doi.org/10.1145/3233391.3233536.\n  * [Freely available here](https://dl.acm.org/ft_gateway.cfm?id=3233536\u0026ftid=1990377\u0026dwn=1\u0026#URLTOKEN#)\n* Youssef El Faqir, Javier Arroyo, and Abel Serrano. 2019. Visualization of the evolution of collaboration and communication networks in wikis. In Proceedings of the 15th International Symposium on Open Collaboration (OpenSym '19). ACM, New York, NY, USA, Article 11, 10 pages. DOI: https://doi.org/10.1145/3306446.3340834\n  * [Freely available here](https://dl.acm.org/ft_gateway.cfm?id=3340834\u0026ftid=2081714\u0026dwn=1\u0026CFID=101134713\u0026CFTOKEN=9a778a0ea905f655-A60DF1FA-F5CB-B00E-E4FABE674D9C267E)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FGrasia%2FWikiChron","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FGrasia%2FWikiChron","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FGrasia%2FWikiChron/lists"}