# Third-party data and code in LangFlame

Everything the site *teaches* — the curriculum, the Hebrew and Spanish
translations, the 字理 notes, the courses, the recordings — is original work.
What follows is everything that is not, where it comes from and what its
licence asks of us.

The two files this notice exists for are the ones that carry a copyleft
obligation and are **served to the browser**: the stroke data behind the
writing practice, and the character data behind the word panels. Both are
free to use, including commercially. Neither is free of conditions.

| what we ship | where it is on the site | source | licence |
|---|---|---|---|
| stroke outlines and medians | `zh/vocab-strokes.js` (writing practice) | makemeahanzi `graphics.txt` | **Arphic Public License** |
| character readings and glosses | `zh/vocab-data.js` (word panels) | makemeahanzi `dictionary.txt` | **LGPL v3 or later** |
| English glosses inside those definitions | same file | CC-CEDICT, via makemeahanzi | CC BY-SA |
| the writing animation library | `zh/hanzi-writer.js` | Hanzi Writer 3.7.3 | MIT |
| pinyin candidate ordering | `zh/data/junda-freq.tsv` | Jun Da, *Modern Chinese Character Frequency List* | academic use with citation |
| component glyph images | fetched at runtime from glyphwiki.org | GlyphWiki | see below |
| the speech | `audio/**` | ElevenLabs (`eleven_v3`) | per the account's plan terms |

Licence texts we ship are in `licenses/` — the Arphic Public License, LGPL v3
and GPL v2 verbatim. The footer of every page in the Chinese section links the
Arphic text directly.

**Decomposition is no longer shipped.** It fed the decomposer, the decomposer
came off the site, and the data went on being baked into the file every
visitor downloads for another three weeks. It is a build input in
`zh/data/hanzi.tsv` and reaches no browser. That matters here rather than only
in the changelog, because the decomposition was the one place CHISE material
(GPL v2) sat beside makemeahanzi material (LGPL v3) in something distributed —
six characters of it, on the live site: 五 今 友 弟 有 面.

## What each one actually asks

**Arphic Public License** (the strokes). Arphic released their fonts in 1999
under a licence that permits use, copying and distribution, including in a
commercial product, on three conditions: the copyright notice travels with the
work, changes are marked as changes, and derived work stays under the same
licence. The stroke data is derived from those fonts, so the site is a
distributor of APL material and owes the notice and the licence text. It does
**not** oblige the rest of the site to be APL — the strokes are a separate
work, not a modification of the application.

**LGPL v3+** (the character data). The obligation that matters for data
shipped as a file is the same one: pass on the licence, say where it came
from, and do not add restrictions. Using the data from a page does not make
the page LGPL.

**CC BY-SA** (the CC-CEDICT glosses). Attribution — present in the footer of
every page in the Chinese section — and share-alike on the *derived data file*,
not on the site around it.

**GPL v2** (the CHISE fallback structures). Same shape: the file we distribute
carries the licence.

**MIT** (Hanzi Writer). The copyright header is kept verbatim at the top of
`zh/hanzi-writer.js`.

**GlyphWiki.** Images are hot-linked, never copied into the repo, and only for
components that have no Unicode codepoint. Nothing of theirs is redistributed.

**The fonts are not ours to ship and we do not ship any.** `HanaMinPUA` is
named in the CSS as a *local* family: it renders for a reader who already has
Hanazono installed and falls back otherwise. No font file is in this
repository.

## Known gaps

These are open, and listed here rather than left implicit.

1. **`zh/data/hanzi.tsv` still mixes LGPL v3 and GPL v2 material in one
   file.** `tools/merge_ids.py` takes structure from makemeahanzi first and
   from CHISE for the 449 characters makemeahanzi declines, and writes both
   into the same file. The two are not compatible in a single combined work.
   This is no longer a distribution question — nothing derived from that
   column reaches a browser, and the repository is private — but the clean
   form is still to keep the CHISE-derived rows in a file of their own and
   load the two side by side, and that is what to do before this file is
   published or the column is used again.
2. **The ElevenLabs rights depend on the plan.** Audio generated on a paid
   plan may be used commercially; the free tier may not, and requires
   attribution. The site sells Pro features, so the account must be on a plan
   that grants those rights.
3. **Jun Da's list** is offered for research and teaching with citation. The
   citation is in the footer; a commercial product is a different context from
   the one the list was published for, and is worth a line of permission.
