Give the interpreter real Celtic Cross meanings and --format/--lang support

- guidance.c now prints last, after the full spread; both it and main.c's
  new Celtic Cross readout pull real Waite card meanings via tarot_data.c
  instead of just naming cards.
- interpreter-cli gains --format text|html|json and --lang en|de, matching
  deck-engine - required linking engine/src/tarot_data.c and i18n.c into
  the interpreter binary (a narrow, documented exception to its earlier
  "no engine .c files" policy) and writing German translations for
  narrative.c's/guidance.c's own text.
This commit is contained in:
ml
2026-07-11 19:39:30 +02:00
parent 41422adf98
commit 1662d550c7
23 changed files with 1894 additions and 296 deletions
+32 -15
View File
@@ -7,11 +7,10 @@
A Pebble smartwatch app that produces a daily personalized tarot (Celtic
Cross) and astrology (natal chart + transits) reading.
**Status:** only the core engine exists so far — a plain-C, dependency-free
This repository holds the core engine: a plain-C, dependency-free
library and standalone CLI (`dist/deck-engine`) that computes a full
reading without needing a Pebble device, emulator, or SDK. The watchapp
itself hasn't been built yet; the engine is designed so it can be linked
into it later without rework.
reading without needing a Pebble device, emulator, or SDK, designed so
it links straight into Pebble watch code without rework.
## What it computes
@@ -45,10 +44,14 @@ engine/
the user.properties template.
dist/ Build output (gitignored) — see below.
interpreter/ Separate module + binary (dist/interpreter-cli):
scores how significant a day's transits are
and prints a short narrative note for each,
reading deck-engine's --format json output
(see CLAUDE.md).
scores how significant a day's transits are,
reads out the full Celtic Cross spread with
every card's meaning, and closes with guidance
(every day, tailored to how significant it is)
tying the top transit to the spread, reading
deck-engine's --format json output. Supports
--format text|html|json and --lang en|de for
its own output too (see CLAUDE.md).
docs/ Architecture/dataflow diagrams, input/output format reference.
Makefile Single root Makefile, builds both engine/ and interpreter/.
```
@@ -94,16 +97,23 @@ dist/deck-engine --seed "2026-07-03" \
```
**Interpreter** (`interpreter/`, built by the same root `make`):
scores how significant a day's transits are, reading `deck-engine`'s
`--format json` output — the two binaries compose over that JSON, they're
never linked together. `dist/run-interpreter.sh` is the daily-use
equivalent of `run-engine.sh` (same OS clock + `user.properties` inputs),
piping straight into `interpreter-cli`:
scores how significant a day's transits are, reads out the full Celtic
Cross spread with every card's meaning, and closes with guidance tying
the day's biggest transit to the Attitude/Outcome cards - reading
`deck-engine`'s `--format json` output. Its own output supports the same
`--format text|html|json` and `--lang en|de` as `deck-engine` (note this
`--lang` is independent of whatever language `deck-engine` was run
with - `--format json` is always language-independent, see
`docs/input-output-format.md`). `dist/run-interpreter.sh` is the
daily-use equivalent of `run-engine.sh` (same OS clock + `user.properties`
inputs, including `user.properties`' `lang=`), piping straight into
`interpreter-cli`:
```bash
dist/deck-engine ... --format json | dist/interpreter-cli
dist/deck-engine ... --format json | dist/interpreter-cli [--format text|html|json] [--lang en|de]
# or, for daily use:
dist/run-interpreter.sh
dist/run-interpreter.sh # text output, language from user.properties
dist/run-interpreter.sh html de # HTML report with card art, override the language
```
## License
@@ -124,3 +134,10 @@ Transit narrative text in `interpreter/src/narrative.c` is condensed
from Sepharial's *Transits and Planetary Periods* (1920), also in the
public domain, except the Moon and Pluto entries, which are original
(see the file's own comment).
Guidance text in `interpreter/src/guidance.c` is original, written for
this project.
`engine/i18n/de.lang`'s translations of the above two files' text
(`narrative.*`/`guidance.*` keys) are original German translations made
for this project, same status as its card/spread text.