Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 27 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -156,6 +156,33 @@ on the `compression` parameter.
pytest
```

## Unicode Prototype

To prototype an "all properties except Unihan" UCD build against Unicode 17.0.0,
download the non-Unihan XML plus the text UCD bundle and analyze every
per-codepoint property with:

```bash
python prototype_ucd_all.py --download \
--json-out data/ucd/17.0.0/prototype-summary.json
```

The prototype uses `ucd.nounihan.flat.zip` as the primary source and
supplements the small set of non-Unihan properties not present in the XML
(`FC_NFKC`, `Gr_Link`, `Hyphen`, `Name_Alias`, `XO_*`, and empty `isc`)
from the text UCD files. It also applies a couple of property-specific
prototype transforms: `bmg` is packed as `bmg(u) - u`, and Hangul syllables
are elided from `dm` so they can be handled algorithmically.

By default it uses a runtime-oriented profile that excludes names and the
specialist `kEH_*`, `kTGT_*`, and `kNSHU_*` property families. Use
`--profile full` to analyze the full non-Unihan property surface instead.
Pass `--c-out path/to/ucd_runtime.c` to also emit a single C source file with
one accessor per selected property.
Deprecated UCD properties such as `FC_NFKC`, `Gr_Link`, and `XO_*` are omitted.
Pass `--pooled-c-out path/to/ucd_pooled.c` to prototype a shared-string C
backend for the string-heavy runtime properties.

## History

I first wrote something like this back in 2001 when I needed it in FriBidi:
Expand Down
Loading