All Projects → filbertkm → WikibaseImport

filbertkm / WikibaseImport

Licence: GPL-2.0 license
Import entities from another Wikibase instance (e.g. Wikidata)

Programming Languages

PHP
23972 projects - #3 most used programming language
shell
77523 projects

Projects that are alternatives of or similar to WikibaseImport

SemanticWikibase
Makes Wikibase data available in Semantic MediaWiki
Stars: ✭ 14 (-44%)
Mutual labels:  mediawiki, wikidata, wikibase
wikibot
Some MediaWiki bot examples including wikipedia, wikidata using MediaWiki module of CeJS library. 採用 CeJS MediaWiki 自動化作業用程式庫來製作 MediaWiki (維基百科/維基數據) 機器人的範例。
Stars: ✭ 26 (+4%)
Mutual labels:  mediawiki, wikidata
wikiapi
JavaScript MediaWiki API for node.js
Stars: ✭ 28 (+12%)
Mutual labels:  mediawiki, wikidata
Wptools
Wikipedia tools (for Humans): easily extract data from Wikipedia, Wikidata, and other MediaWikis
Stars: ✭ 371 (+1384%)
Mutual labels:  mediawiki, wikidata
database-of-embassies
Database of embassies and consulates. Download as CSV, no registration, public domain. Powered by Wikidata.
Stars: ✭ 33 (+32%)
Mutual labels:  wikidata
vicuna
Tool for uploading files to Wikimedia Commons and other Wikimedia projects
Stars: ✭ 36 (+44%)
Mutual labels:  mediawiki
cassandra-GLAM-tools
Support GLAMs in monitoring and evaluating their cooperation with Wikimedia projects
Stars: ✭ 17 (-32%)
Mutual labels:  mediawiki
petscan rs
The repo for the PetScan tool
Stars: ✭ 35 (+40%)
Mutual labels:  wikidata
entity-fishing
A machine learning tool for fishing entities
Stars: ✭ 176 (+604%)
Mutual labels:  wikidata
scalawiki
scalawiki is a MediaWiki client in Scala
Stars: ✭ 30 (+20%)
Mutual labels:  mediawiki
wikidata-qrank
Ranking signals for Wikidata
Stars: ✭ 31 (+24%)
Mutual labels:  wikidata
WikidataR
An R package for the Wikidata API
Stars: ✭ 49 (+96%)
Mutual labels:  wikidata
mediawiki-api-demos
Demo apps and code snippets in Python, Javascript and PHP demonstrating how to use various modules of the MediaWiki Action API
Stars: ✭ 125 (+400%)
Mutual labels:  mediawiki
go-wikidata
Wikidata API bindings in go.
Stars: ✭ 27 (+8%)
Mutual labels:  wikidata
ordia
Wikidata lexemes presentations
Stars: ✭ 21 (-16%)
Mutual labels:  wikidata
matomo-mediawiki-extension
www.mediawiki.org/wiki/Extension:Piwik_Integration
Stars: ✭ 18 (-28%)
Mutual labels:  mediawiki
Mermaid
Provides a parser function to generate diagrams and flowcharts with the help of the mermaid script language
Stars: ✭ 27 (+8%)
Mutual labels:  mediawiki
rdf2smw
Convert RDF to Semantic MediaWiki facts in MediaWiki XML format, with a standalone commandline tool
Stars: ✭ 18 (-28%)
Mutual labels:  mediawiki
tutorials
Collection of tutorials for various libraries and technologies
Stars: ✭ 98 (+292%)
Mutual labels:  mediawiki
Dota2WebApi
A Dota 2 Web API for Liquipedia
Stars: ✭ 24 (-4%)
Mutual labels:  mediawiki

WikibaseImport

Build Status

WikibaseImport is a MediaWiki extension that provides a maintenance script for importing entities from another Wikibase instance. (e.. Wikidata)

The script imports the specified entity or entities, including statements, sitelinks, labels, descriptions and aliases. The extension tracks the newly assigned entity id and the original id, so that any other entity that references can be linked appropriately.

The script also imports any referenced entities (e.g. properties, badge items, wikibase-item values) without the statements.

Install

Clone https://github.com/filbertkm/WikibaseImport.git to the extensions folder of your MediaWiki instance.

Then go into the WikibaseImport extension directory and run composer update.

Then, to enable the extension, add it in your LocalSettings.php file:

wfLoadExtension( 'WikibaseImport' );

The extension requires a new database table to map entity ids from the foreign wiki to corresponding ids in the local wiki.

To add the table, run MediaWiki's update.php maintenance script.

Usage

First, navigate to WikibaseImport ’s extension folder.

Import a specific entity:

php maintenance/importEntities.php --entity Q147

Import a list of entities from a text file:

php maintenance/importEntities.php --file presidents.csv

You need to create the csv with a list of entity ids. For example, get a list of entity ids from a query (e.g. Wikidata sparql).

Import all properties:

php maintenance/importEntities.php --all-properties

Import Wikidata entities with specified property:entityId value pair:

php maintenance/importEntities.php --query P131:Q64

Import a range of entities:

php maintenance/importEntities.php --range Q1:Q20

Import a list of entities printed by another program:

printf 'Q%s\n' {1..20} {100..120} | php maintenance/importEntities.php --stdin
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].