Architecture docs

ESHANA architecture

Concept diagrams generated from diagrams/arch_specs.py. Press play to walk each numbered flow.

ESHANA: one JSON entry point, three thin shells

Every surface calls Engine::execute_json, so the CLI, the Python package and the HTML report cannot disagree.

all steps
ESHANA: one JSON entry point, three thin shells ESHANA: one JSON entry point, three thin shells Every surface calls Engine::execute_json, so the CLI, the Python package and the HTML report cannot disagree. 1 2 3 4 5 6 7 Request (JSON) when + place + settings positions · chart · human_design numerology · compare · graph eshana-time civil time to UTC with tz rules fold / gap refused, never guessed leap seconds, delta-T eshana-ephemeris analytic provider (no files) spk provider (your DE440s) precession, nutation, aberration eshana-engine vedic.parashari@0.1 human_design.basic@0.1 numerology, houses, graph Envelope (JSON) calculated values, labelled provenance + assumptions interpretations: always [] eshana CLI JSON in the terminal eshana (Python) Chart objects execute(request) eshana-report one HTML file, every chart How it flows 1 A request names an instant (UTC, or civil time plus zone) and the settings used 2 The instant becomes TT and UT time scales and Julian dates 3 A provider returns apparent ecliptic positions in one frame 4 Rule packs derive signs, houses, nakshatra, dasha and gates; each value is labelled 5 The CLI prints the envelope as JSON 6 Python returns the same data as a dict or a Chart 7 The report renderer turns the envelope into one self-contained HTML file

Download: animated SVG · draw.io (editable)

The numbered steps
#From → toWhat happens
1Request (JSON) → eshana-timeA request names an instant (UTC, or civil time plus zone) and the settings used
2eshana-time → eshana-ephemerisThe instant becomes TT and UT time scales and Julian dates
3eshana-ephemeris → eshana-engineA provider returns apparent ecliptic positions in one frame
4eshana-engine → Envelope (JSON)Rule packs derive signs, houses, nakshatra, dasha and gates; each value is labelled
5Envelope (JSON) → eshana CLIThe CLI prints the envelope as JSON
6Envelope (JSON) → eshana (Python)Python returns the same data as a dict or a Chart
7Envelope (JSON) → eshana-reportThe report renderer turns the envelope into one self-contained HTML file

Compute, Derive, Interpret: the engine stops after Derive

Each value carries an epistemic label. Interpretation is a separate, opt-in layer that ESHANA does not ship.

all steps
Compute, Derive, Interpret: the engine stops after Derive Compute, Derive, Interpret: the engine stops after Derive Each value carries an epistemic label. Interpretation is a separate, opt-in layer that ESHANA does not ship. 1 2 3 4 1 · Compute positions, houses, time scales label: calculated checked against JPL DE440s 2 · Derive nakshatra, bhava, dasha, gates label: tradition_rule rule pack and version recorded 3 · Interpret meanings, predictions, advice labels: speculative / hypothesis NOT in the engine: interpretations = [] Your layer a plugin, notebook or app must label what it adds can cite rule ids from the envelope Refusals sidereal without ayanamsha ambiguous or skipped local time polar Placidus houses How it flows 1 Computed numbers feed the tradition rules; the rule version travels with every result 2 The engine does not cross this line: interpretations is always an empty list 3 Anything beyond the line is yours, and has to say what kind of claim it is 4 When the input cannot support an answer, ESHANA refuses with a stable ESH- error code

Download: animated SVG · draw.io (editable)

The numbered steps
#From → toWhat happens
11 · Compute → 2 · DeriveComputed numbers feed the tradition rules; the rule version travels with every result
22 · Derive → 3 · InterpretThe engine does not cross this line: interpretations is always an empty list
33 · Interpret → Your layerAnything beyond the line is yours, and has to say what kind of claim it is
42 · Derive → RefusalsWhen the input cannot support an answer, ESHANA refuses with a stable ESH- error code

How a birth chart is proven right: five independent layers

No layer trusts the one below it. A failure in any layer says which kind of disagreement it is.

all steps
How a birth chart is proven right: five independent layers How a birth chart is proven right: five independent layers No layer trusts the one below it. A failure in any layer says which kind of disagreement it is. 1 2 3 4 5 6 1 · Mathematics time scales, precession, nutation unit and property tests Rust: 100+ tests 2 · JPL DE440s positions vs the kernel spk 0.3 arcsec; analytic measured golden fixture, Skyfield 3 · Swiss Ephemeris many charts, 1900-2100 ayanamsha, houses, nodes offline oracle, numbers only 4 · Published sites ProKerala snapshot (recorded) classical constants (Lahiri 1956) contributed references 5 · Re-derivation nakshatra, pada, dasha, D-charts a second implementation in the tests invariants on every chart Release gate PROMOTE / CONDITIONAL / BLOCK tolerances live in one file report: accuracy.md How it flows 1 Mathematics is trusted only after it reproduces the JPL kernel 2 The same charts are checked against a second, independent engine 3 Then against what real sites and published constants print, with tolerance for rounding 4 A disagreement beyond tolerance blocks the release 5 Derived values are recomputed from the longitudes by a separate implementation 6 Any mismatch is a bug in one of the two implementations, never ignored

Download: animated SVG · draw.io (editable)

The numbered steps
#From → toWhat happens
11 · Mathematics → 2 · JPL DE440sMathematics is trusted only after it reproduces the JPL kernel
22 · JPL DE440s → 3 · Swiss EphemerisThe same charts are checked against a second, independent engine
33 · Swiss Ephemeris → 4 · Published sitesThen against what real sites and published constants print, with tolerance for rounding
44 · Published sites → Release gateA disagreement beyond tolerance blocks the release
52 · JPL DE440s → 5 · Re-derivationDerived values are recomputed from the longitudes by a separate implementation
65 · Re-derivation → Release gateAny mismatch is a bug in one of the two implementations, never ignored

Five ways to use ESHANA, all on the same engine

Pick the surface that fits; the numbers are identical because they come from one entry point.

all steps
Five ways to use ESHANA, all on the same engine Five ways to use ESHANA, all on the same engine Pick the surface that fits; the numbers are identical because they come from one entry point. 1 2 3 4 5 6 You birth data, or just a date 1 · Terminal eshana chart vedic ... JSON on stdout, pipe to jq 2 · Python library pip install eshana Chart objects, execute() 3 · HTML report eshana-report ... -o chart.html one file, offline, printable 4 · Notebook or app chart.to_html() in place embed the SVG charts anywhere 5 · Planned Node/WASM, MCP server event search (AST-06) Engine::execute_json one entry point How it flows 1 Quickest: one command, JSON out 2 From code: the same requests as a typed API 3 To read or share: a complete chart report with every detail 4 The CLI is a thin shell over the engine 5 Chart objects drop into notebooks and apps; to_html() renders the report in place 6 Planned surfaces reuse the same envelope, so nothing about the maths changes

Download: animated SVG · draw.io (editable)

The numbered steps
#From → toWhat happens
1You → 1 · TerminalQuickest: one command, JSON out
2You → 2 · Python libraryFrom code: the same requests as a typed API
3You → 3 · HTML reportTo read or share: a complete chart report with every detail
41 · Terminal → Engine::execute_jsonThe CLI is a thin shell over the engine
52 · Python library → 4 · Notebook or appChart objects drop into notebooks and apps; to_html() renders the report in place
63 · HTML report → 5 · PlannedPlanned surfaces reuse the same envelope, so nothing about the maths changes

From a request to one self-contained HTML chart report

The renderer only formats what the engine computed. It adds no astrology of its own.

all steps
From a request to one self-contained HTML chart report From a request to one self-contained HTML chart report The renderer only formats what the engine computed. It adds no astrology of its own. 1 2 3 4 Request date, time, zone, place system, ayanamsha, houses Engine chart, human_design, numerology one envelope each eshana.report South + North Indian charts wheel, planets, houses D-charts, dasha, nakshatra chart.html inline CSS, SVG and data light / dark, print layout raw JSON embedded Sections you choose --sections chart,dasha,hd,numerology --theme light|dark|auto How it flows 1 The same request object is used for every system you ask for 2 Envelopes go to the renderer unchanged 3 One file out: no network, no fonts to fetch, safe to email or archive 4 You pick sections and theme; a section with no data is omitted, not faked

Download: animated SVG · draw.io (editable)

The numbered steps
#From → toWhat happens
1Request → EngineThe same request object is used for every system you ask for
2Engine → eshana.reportEnvelopes go to the renderer unchanged
3eshana.report → chart.htmlOne file out: no network, no fonts to fetch, safe to email or archive
4Sections you choose → eshana.reportYou pick sections and theme; a section with no data is omitted, not faked