Skip to main content

Heimdall - Wikidata connector

https://img.shields.io/badge/license-AGPL3.0-informational?logo=gnu&color=success https://www.repostatus.org/badges/latest/inactive.svg PyPI Version https://img.shields.io/badge/documentation-api-green https://gitlab.huma-num.fr/datasphere/heimdall/connectors/wikidata/badges/main/pipeline.svg https://gitlab.huma-num.fr/datasphere/heimdall/connectors/wikidata/badges/main/coverage.svg

What is this?

pyHeimdall is a tool for converting more easily one or more databases from one format to another. It leverages modules called “connectors”, responsible for conversion of data between specific databases schemas and the HERA format.

This repository implements a connector to Wikidata. The implementation was made without any intervention on pyHeimdall proper.

How can I use it?

Setup

This Wikidata pyHeimdall connector is available as a PyPI package named pyheimdall-wikidata. You can install it using the pip package manager:

pip install pyheimdall-wikidata

You can use pip to either upgrade or uninstall this connector, too:

pip install --upgrade pyheimdall-wikidata
pip uninstall pyheimdall-wikidata

Usage

import heimdall

HARRY_POTTER = 'https://www.wikidata.org/w/api.php?action=wbgetentities&ids=Q216930&format=json&languages=fr|en'
tree = heimdall.getDatabase(format='api:wikidata', url=HARRY_POTTER)
heimdall.createDatabase(tree, format='hera:xml', url='HARRY_POTTER.xml')

Please note that you don’t need to use pyheimdall-wikidata functions directly. As long as the package is installed on your system, pyHeimdall will automatically discover its features and allow you to use them as long as any other default or external connector.

Is it tested?

Of course! Here’s the coverage report.

How can I contribute?

This project welcomes any feedback or proposal. Details can be accessed here

License

GNU Affero General Public License version 3.0 or later

Metadata

Release files for pyheimdall-wikidata 1.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pyheimdall-wikidata 1.1.0
File Size Uploaded
pyheimdall_wikidata-1.1.0.tar.gz 16.2 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for pyheimdall-wikidata 1.1.0
File Interpreter ABI Platform
pyheimdall_wikidata-1.1.0-py2.py3-none-any.whl Python 3, Python 2 none any Details

Total release size: 32.3 kB

Release files / pyheimdall_wikidata-1.1.0.tar.gz

Download URL pyheimdall_wikidata-1.1.0.tar.gz
Size 16.2 kB
Tags Source
SHA-256 checksum
How to use checksums
b0a55a76f7009795f5fa7a14c4a03a72d47cf5ce36469366d57532219e2a4fc6
BLAKE2b-256 checksum
How to use checksums
c77913a5d92f07d357fb64a3be43dc1616984925cbcf126bf4963b751d3af1a0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.0.1 CPython/3.11.4

Release files / pyheimdall_wikidata-1.1.0-py2.py3-none-any.whl

Download URL pyheimdall_wikidata-1.1.0-py2.py3-none-any.whl
Size 16.1 kB
Tags Python 2 Python 3
SHA-256 checksum
How to use checksums
bbd447b28bfcf815d43dc7391d9a299cdf3b524ae9a24df585c9d0e7662d1774
BLAKE2b-256 checksum
How to use checksums
7583f1a556881be407ca87eeb276f29864113647590de64842fe0dfe9930b88d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.0.1 CPython/3.11.4

Release history Release notifications | RSS feed

This release

1.1.0 This release

2 release files

1.0.1

2 release files

1.0.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page