Skip to main content

xdformat

.xd is a plain-text format for crossword puzzles, modeled after the simplicity of markdown. A complete puzzle -- metadata, grid, clues, answers, notes -- is one small UTF-8 file that can be read, edited, diffed, and grepped like any other text file:

Title: New York Times, Saturday, January 1, 1955
Author: Anthony Morse
Editor: Margaret Farrar
Rebus: 1=HEART 2=DIAMOND 3=SPADE 4=CLUB
Date: 1955-01-01


1ACHE#ADAM#2LIL
BLUER#GULL#MATA
EATIN#APEX#ICER
[...]


A1. Sadness. ~ HEARTACHE
A6. Progenitor. ~ ADAM
A10. Mae West stand-by. ~ DIAMONDLIL
[...]

D1. Vital throb. ~ HEARTBEAT
D2. Having wings. ~ ALATE
[...]

The format supports 99.99% of published crosswords and is intended to be convenient for bulk analysis by both humans and machines, from the present and into the future.

This repo holds the format specification and the reference tools for parsing .xd and converting other puzzle formats into it.

The spec

The xdformat Python package

The core package parses and emits .xd with no dependencies:

pip install xdformat
import xdformat

xd = xdformat.parse("nyt1955-01-01.xd")
xd.get_header("Title")        # "New York Times, Saturday, January 1, 1955"
xd.grid                       # list of row strings
for pos, clue, answer in xd.iterclues():
    ...
print(xd.to_unicode())        # canonical .xd text

The converters need the [convert] extra (pulls in puzpy and ipuz):

pip install xdformat[convert]

puz2xd foo.puz > foo.xd
puz2xd -o xd/ *.puz
ipuz2xd bar.ipuz > bar.xd

xdformat/crossword/ is a vendored fork of Simeon Visser's crossword library, updated for changes in the ipuz module.

  • century-arcade/xd -- the corpus pipeline: downloads puzzles from many sources, converts them (using additional publisher-specific converters), analyzes grids and clues, validates with xdlint.py, and builds the website at xd.saul.pw
  • gxd -- the corpus itself, 95k+ puzzles in .xd format (private; join #crosswords on the Discord to discuss getting access)
  • century-arcade/xdcontrib -- deprecated; its minimal converters were merged into this repo

Citing xd

If you publish any research or results using the xd crossword corpus, please cite xd accordingly:

Pwanson, Saul. (2019). "xd Crossword Corpus." Retrieved from http://xd.saul.pw

The year of publication should be the year that the corpus was accessed.

License

MIT; see LICENSE.

Metadata

Release files for xdformat 0.2.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 xdformat 0.2.0
File Size Uploaded Provenance
xdformat-0.2.0.tar.gz 27.2 kB With provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for xdformat 0.2.0
File Interpreter ABI Platform
xdformat-0.2.0-py3-none-any.whl Python 3 none any Details

Total release size: 49.8 kB

Release files / xdformat-0.2.0.tar.gz

Download URL xdformat-0.2.0.tar.gz
Size 27.2 kB
Tags Source
SHA-256 checksum
How to use checksums
7e1115af42f3891adc64ba75ed2e7026da08d890b1c38a6b6cca86e5203bfc52
BLAKE2b-256 checksum
How to use checksums
3487ab12230f427439c1ae821337395ba98c0bb64a8ee0f3b6bc840e78b8fd2d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 23, 2026.

Transparency log

Release files / xdformat-0.2.0-py3-none-any.whl

Download URL xdformat-0.2.0-py3-none-any.whl
Size 22.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
00634264273c7c718241f5fae141046ed70e42cdcc74aaefa7334a7d2356c77b
BLAKE2b-256 checksum
How to use checksums
af1469e50a7312f42f5776d9b00b2f82b51f278047652eb07c2efc4c3ce03079
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 23, 2026.

Transparency log

Security for xdformat 0.2.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

All 2 files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for xdformat-0.2.0.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 23, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.2.0 This release

2 release files Full provenance

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