Uploading with Commonsbot

Published: Dec 7, 2021 by Steve Baskauf

A few months ago, as part of our WikiProject Vanderbilt Fine Arts Gallery, we received permission to upload Public Domain works from the Vanderbilt Fine Arts Gallery to Wikimedia Commons, where they will be more accessible to the public.

To make this happen, I put in some more work on Commonsbot, a Python script that I’d been hacking away at for about a year. It’s now nominally functional, and I used it to upload just under 300 high-resolution images of two-dimensional works.

There are existing tools for uploading images to Commons, but Commonsbot not only uploads the images with metadata based on the Artwork template, but it also adds Structured data on Commons that backlinks the Commons media item to its corresponding Wikidata item. It also generates the necessary CSV data for another script I wrote, VanderBot, to create a P18 (image) link from the Wikidata item to the new Commons media item.

For example, one of our works whose image was uploaded to Commons is now linked to its Wikidata item: https://www.wikidata.org/wiki/Q104032737.

We can now do fun stuff with the images like create SPARQL-based visualizations such as an image grid showing Kress collection works donated to the Gallery in the 1960’s.

Share

Latest Posts

Humboldt Extension for Ecological Inventories Published
Humboldt Extension for Ecological Inventories Published

The Humboldt Extension for Ecological Inventories is a new metadata vocabulary that extends the Darwin Core Standard to make it possible to describe the inventories and sampling events that are used to collect organism occurrence data. This is the largest extension to Darwin Core since the original vocabulary was ratified in 2009 and it represents over three years of work by the Humboldt Extension Task Group. This group of international experts met weekly over that time period to develop the vocabulary, carry out implementation testing, and publish the vocabulary and associated documentation.

Camtrap DP paper published
Camtrap DP paper published

Camera trapping is an increasingly important method used by ecologists for monitoring animals in the wild. Camera trap data has previously been difficult to publish by conventional means, since the data includes many related images or videos that must be associated with the occurrence data. The new Camtrap DP standard provides a way to package camera trap data based on the open Frictionless Data Package specification. Camtrap DP datasets can be easily exchanged or published to the Global Biodiversity Information Facility (GBIF) where the included occurrence data will be integrated with biodiversity data collected by other means.

Nine hundred images added to Wikimedia Commons from ACT
Nine hundred images added to Wikimedia Commons from ACT

Charlotte Lew and I have been working for some time to improve access to images in the Art in the Christian Tradition database by linking descriptive metadata in Wikidata to the corresponding artwork images in Wikimedia Commons. In the first part of the project, we were primarily cleaning up and linking Wikidata metadata to images that were already in Commons.