Internal module guide. This module is now part of
@astrology/chart-composer; use the public package README for application setup.
chart-core module
Assembles supplied astronomical facts into a reference frame, house placements and body rosters.
Start with the Composer reading guide for the complete request flow and glossary.
Public imports use @astrology/chart-composer; implementation files are not cross-package APIs.
See the package specification and task plan.
Assembly
assembleChartSnapshot(context, readSet, versions) consumes already acquired facts.
It admits the supplied read contexts and declarations, verifies body order and semantics version,
chooses the frame once, places bodies, and builds stable house rosters. It makes no port calls.
Lagna (the rising sign used as house one) uses the supplied ascendant (the ecliptic degree rising on the eastern horizon) and shared sign resolver. Moon/Sun use supplied body sign IDs.
Whole-sign placement uses integer sign distance; cusp placement calls the existing
resolveHouse helper, including exact-boundary and wraparound behavior.
Missing references or required cusp geometry fail rather than changing a convention.
resolveWholeSignHouse accepts semantic sign IDs; buildHouseRosters accepts minimal
{ body, house } placements so divisional charts (vargas) need no fabricated astronomical geometry.
Position-only contexts use houseSystem: null and frame: 'none'; angles and body houses remain
null and no house rosters are claimed. Moon/Sun frames can also retain their reference with no houses.
Geometry, original Binder aspects and both operation evidence blocks survive assembly by reference. No angular rounding, ayanamsa shift, dignity, combustion or planetary-war rule is added. ARMC (the right ascension of the meridian) stays equatorial right ascension, including in sidereal charts.
Read the implementation
Start at assemble.ts, which shows the order of admission and assembly. Follow frame.ts, placement.ts and rosters.ts for the three derived outputs. No step acquires astronomy.
Run pnpm check:chart-composer and pnpm test:chart-composer from the repository root.