openlibrary / README.md
sayshara's picture
Update README.md
eae22a8 verified
---
tags:
- openlibrary
- bibliographic
- books
- parquet # ← list items start with “-”, not “*”
license: cc0-1.0 # recognised by the Hub
configs:
- config_name: authors
data_files: 'authors/*.parquet' # quote any value that contains “*”
description: All OpenLibrary author records.
- config_name: editions
data_files: 'editions/*.parquet'
description: All book-edition records (ISBN-level).
- config_name: works
data_files: 'works/*.parquet'
description: Abstract “work” records (title-level).
---
# 📚 OpenLibrary Parquet Mirror
An up‑to‑date, stream‑ready mirror of the official **OpenLibrary** public data dumps, converted to snappy‑compressed Parquet.
> **Source:** [https://openlibrary.org/developers/dumps](https://openlibrary.org/developers/dumps)
## 💾 Repository organization
```
openlibrary/
├── authors/ # authors_0.parquet, authors_1.parquet, … (≈ 1-2 GB each)
├── editions/ # editions_0.parquet, editions_1.parquet, …
└── works/ # works_0.parquet, works_1.parquet, …
```
## 🏃 Quick start
```python
from datasets import load_dataset
# stream authors only
authors = load_dataset("sayshara/openlibrary", "authors", split="train", streaming=True)
for i, rec in enumerate(authors):
if i == 5:
break
print(rec["name"], rec.get("birth_date"))
```
## 📝 Schema notes
* Missing columns for a given record are stored as `NULL`.
* Top‑level JSON objects from the dump are flattened; nested structures are preserved as JSON‑encoded strings.
* The raw JSON produced by OpenLibrary loosely follows per‑entity schemata maintained in the [`openlibrary‑client` repo](https://github.com/internetarchive/openlibrary-client/tree/master/olclient/schemata):
* [`authors.schema.json`](https://github.com/internetarchive/openlibrary-client/blob/master/olclient/schemata/author.schema.json)
→ governs objects from **`ol_dump_authors_latest.txt.gz`**.
* [`editions.schema.json`](https://github.com/internetarchive/openlibrary-client/blob/master/olclient/schemata/edition.schema.json)
→ governs objects from **`ol_dump_editions_latest.txt.gz`**.
* [`works.schema.json`](https://github.com/internetarchive/openlibrary-client/blob/master/olclient/schemata/work.schema.json)
→ governs objects from **`ol_dump_works_latest.txt.gz`**.
| Field example | Type | Notes |
| ----------------- | ------ | ------------------------------------ |
| `key` | string | e.g. `/authors/OL23919A` |
| `latest_revision` | double | revision id (via OL) |
| `birth_date` | string | free‑text date |
| `remote_ids` | string | JSON string of `{"wikidata": "Q42"}` |
---
## 📜 License
OpenLibrary dedicates its catalog data to the **public domain** under the
[CC0 1.0 Universal (Public‑Domain Dedication)](https://creativecommons.org/publicdomain/zero/1.0/) license. 
For more information, see: [https://openlibrary.org/help/faq/using](https://openlibrary.org/help/faq/using)
Because this Parquet mirror is a direct transformation of that catalog, **all
files in this dataset are likewise released under CC0 1.0**. You may copy,
modify, redistribute, and use them for any purpose without permission or
attribution. (Attribution to OpenLibrary/Internet Archive is appreciated but
not legally required.)
---
Maintainer • [@sayshara](https://huggingface.co/sayshara)