Questions tagged [wikidata]

Wikidata is a free, collaborative, multilingual database, collecting structured data to provide support for Wikipedia, Wikimedia Commons, and the other wikis of the Wikimedia movement. One can retrieve all data using Wikidata Query Service (Wikidata SPARQL endpoint) or Wikidata API (Wikidata MediaWiki API extension). If you are completely new both to SPARQL and MediaWiki API, please consider to ask your question on opendata.stackexchange.com.

Wikidata is a free, collaboratively edited knowledge base operated by the Wikimedia Foundation. It is intended to provide a common source of certain data types (for example, birth dates) which can be used by Wikimedia projects such as Wikipedia. This is similar to the way Wikimedia Commons provides storage for media files and access to those files for all Wikimedia projects.

Concepts:

Wikidata is a document-oriented database, focused around items. Each item represents a topic (or an administrative page used to maintain Wikipedia) and is identified by a unique number, prefixed with the letter Q — for example, the item for the topic Politics is Q7163. This enables the basic information required to identify the topic the item covers to be translated without favouring any one language.

Information is added to items by creating statements. Statements take the form of key-value pairs, with each statement consisting of a property (the key) and a value linked to the property.

Wikidata statement

Further reference:

887 questions
0
votes
1 answer

Extracting description and keywords from Wikipedia in php and mysql

i have a web page with all links of Featured articles from Wikipedia, and i extract title, description and keywords of all them. But i have a problem, when the web crawler begins to extract the content of articles, the field description in my db…
-1
votes
1 answer

Get start date of marriage through a Wikidata SPARQL query

I would like to change this query which only provides the start date of marriage for one item (wd:Q42) WHERE {wd:Q42 p:P26 ?statement. ?statement ps:P26 ?spouse; pq:P580 ?starttime; pq:P582 ?endtime. …
F Gh
  • 65
  • 8
-1
votes
2 answers

Wikidata query with values from CSV-File

I would like to do a Wikidata query of many values that are listed in a column of a CSV file on my computer. How can I load the values from the CSV file into the Wikidata query automatically without copying them in manually? So far I have worked…
MrLibre
  • 1
  • 2
-1
votes
1 answer

Wikipedia metadata dump?

I need metadata for wikipedia articles (title, views, time edited, categories, etc.). I was looking through the dumps at https://dumps.wikimedia.org/enwiki/20221201/ and there's so many that I'm not sure what to choose. I don't need a full dump…
Jabrove
  • 718
  • 5
  • 13
-1
votes
1 answer

Sample code to convert Wikidata dumps to Gremlin format

Could you share a sample code to convert Wikidata dumps to Gremlin format, please? I would like to load the converted Gremlin CSV data into AWS Neptune.
MAK
  • 1,915
  • 4
  • 20
  • 44
-1
votes
1 answer

query wikidata cities names in arabic and english

I need to get cities names in arabic and english from wikidata also after that I need to get states names in arabic and english is it available to download the query return data or copy it to excel or csv?
Sara Shoukry
  • 1
  • 1
  • 2
-1
votes
1 answer

How to get Wikidata Labels using Python?

For example, I have a Wikidata relation Q134041, how can I get the label website?
Zimu Wang
  • 77
  • 1
  • 3
-1
votes
2 answers

synchronizing wikibase and neo4j

recently I want to use wikibase as my knowledgebase and neo4j as knowledge graph, which gives me the ability to inferring on my knowledgebase. so I need to synchronizing wikibase and neo4j data and schema. How can I reach this goal ? is there any…
Reza
  • 33
  • 5
-1
votes
1 answer

How can I query Wikidata to get a list of all people in Node.js?

I would like to query like this: Query WikiData for all entities where the property instance of (P31) has the value human (Q5). How do I do that using Node.js? Searching for this on the web leads to things like this, example SPARQL queries, but I…
Lance
  • 75,200
  • 93
  • 289
  • 503
-1
votes
2 answers

How use wikidata api to access to the statements

I'm trying to get information from Wikidata. For example, to access to "cobalt-70" I use the API. API_ENDPOINT = "https://www.wikidata.org/w/api.php" query = "cobalt-70" params = { 'action': 'wbsearchentities', 'format': 'json', …
-1
votes
1 answer

Why variable + Label is not working in SPARQL

In the examples of the SPARQL of Wikidata, we have this one: SELECT ?h ?date WHERE { ?h wdt:P31 wd:Q5 . ?h wdt:P569 ?date . OPTIONAL {?h wdt:P570 ?d } FILTER (?date > "1880-01-01T00:00:00Z"^^xsd:dateTime) FILTER…
Jack Green
  • 141
  • 2
  • 12
-1
votes
1 answer

query a webpage for variable entity using a consistent URL structure

Would someone please help me to understand how I might inject into my program a query to this webpage? There are two parameters that need to be set, i.e. "Site:", is where you enter the language and site code. & "Page:", you must put in the exact…
smatthewenglish
  • 2,831
  • 4
  • 36
  • 72
-2
votes
1 answer

Download entire history of a Wikipedia page in HTML Format

I want to download the entire revision history of a single article on Wikipedia in HTML format, thanks to this question question, I am getting the entire history of a Wikipedia page in a JSON format but I want to get as a HTML format with images and…
-2
votes
1 answer

How to open custom wikidata RDF dumps

I have created a custom wikidata dump from https://wdumps.toolforge.org/ . Can anyone please tell me how to open and read that dump file ? File comes in .nt format You can find recent dump files here: https://wdumps.toolforge.org/dumps
-2
votes
1 answer

How to populate local instance of Wikibase with some selected data from Wikidata

I set up a local instance of wikibase following this guide. Now at http://localhost:8282 I can access a SPARQL interface which look very much like https://query.wikidata.org/ – good. However, there seems to be no "preinstalled" data in my local…
cknoll
  • 2,130
  • 4
  • 18
  • 34
1 2 3
59
60