Clarity Tool
Appearance
Clarity Tool is a lightweight web application designed to help Wikipedia, Wikidata, and Wikimedia Commons editors identify and fill missing information in articles. It suggests relevant data from Wikidata and allows editors to add or edit details directly. If an article is missing an image, the tool provides a quick link to search Wikimedia Commons or upload a new image if none exists. Its goal is to make editing faster, easier, and more complete for contributors.
Features
[edit]- Detects missing infobox data in Wikipedia articles
- Suggests relevant facts from Wikidata
- Provides quick links to Wikimedia Commons for image search or upload
- Enables inline editing of article metadata
- Lightweight Flask-based architecture for fast deployment
Installation
[edit]Clone the repository
[edit]git clone https://gitlab.wikimedia.org/toolforge-repos/clarity-tool.git
cd clarity-tool
Manual dependency setup (Toolforge)
[edit]Toolforge does not support pip, so dependencies must be manually installed:
- Flask
- Requests
- BeautifulSoup (version 4.12.2)
Add these to your Python path in `app.py` and `app/__init__.py`:
import sys
sys.path.insert(0, "/data/project/clarity-tool/flask")
sys.path.insert(0, "/data/project/clarity-tool/requests")
sys.path.insert(0, "/data/project/clarity-tool/beautifulsoup4-4.12.2")
Start the webservice
[edit]webservice stop
webservice --backend=kubernetes python3.11 start
Monitor logs:
tail -f ~/www/python/src/uwsgi.log
Usage
[edit]Visit: clarity-tool.toolforge.org
How to use
[edit]- Enter a Wikipedia article title.
- Review suggested data from Wikidata.
- Search or upload images via Wikimedia Commons.
- Edit metadata inline and submit changes.
File Structure
[edit]clarity-tool/
├── app/
│ ├── __init__.py
│ ├── main/
│ │ └── routes.py
├── static/
├── templates/
├── app.py
Contributing
[edit]- Fork the repository
- Submit merge requests via GitLab
- Follow Wikimedia coding standards
Support
[edit]For bugs or feature requests, open an issue on GitLab or contact Toolforge maintainers.