This document is a source-integrity map for the package.
It is not a manuscript-critical proof document, and it does not claim that every package rule is directly established from a single Sanskrit passage. The codebase mixes:
- Direct Panchang/Jyotisha conventions that are widely standard
- Package rule mappings attributed to traditional muhurta literature
- Regional or published almanac conventions
- Modern secondary references
- A few helpers that are explicitly heuristic or legacy
To keep this document stable, it uses file/function-level references instead of fragile line-number tables.
This document covers traditional source attributions.
Some package components are architectural helpers and are intentionally not tied to traditional texts:
OutputGeneratorService(output assembly wrapper around package services)CliBootstrap(standalone bootstrap helper for env/config/container wiring)
Currently, the package implements 237 top-level festival definitions within FestivalService::FESTIVALS. Each entry maps to a specific timing rule (Tithi, Nakshatra, Yoga, etc.) with associated metadata.
- Localization: user-facing outputs support
en,hi,gu. - Calendar conventions: both
amantaandpurnimantaare supported.
These are standard astronomical or calendrical conventions that are broadly stable across traditional Panchang computation.
| File | Functions/Constants | Source Attribution |
|---|---|---|
ClassicalTimeConstants.php |
GHATIKA_IN_MINUTES = 24PALA_IN_SECONDS = 24MUHURTA_IN_MINUTES = 48DEGREES_PER_NAKSHATRA = 360/27DEGREES_PER_TITHI = 12 |
Traditional convention: Sūrya Siddhānta-style astronomy and long-standing almanac convention |
Tithi.php |
fromLongitudes()getFractionRemaining() |
Traditional convention: 30 lunar days, each 12° Moon-Sun separation (Sūrya Siddhānta 1.29) |
Nakshatra.php |
fromLongitude()getPada() |
Traditional convention: 27 nakṣatras, each 13°20' (Sūrya Siddhānta 8.1) |
Yoga.php |
fromLongitudes() |
Traditional convention: 27 yogas, each 13°20' Sun-Moon sum (Sūrya Siddhānta 3.1-3) |
Karana.php |
fromTithi() |
Traditional convention: 11 karanas, each 6° Moon-Sun separation (Muhūrta Chintāmaṇi Chapter 2) |
These parts of the package are rulebooks encoded by the package. They may be inspired by or attributed to texts such as Muhūrta Chintāmaṇi, Bṛhat Saṃhitā, Muhūrta Mārtaṇḍa, Māyamata, Vaikhānasa Āgama, Aśvalāyana Gṛhya Sūtra, and related traditions.
They should be read as package mappings, not as proof that every table entry has been independently verified against a primary-edition Sanskrit text.
| File | Functions/Constants | Source Attribution |
|---|---|---|
ElectionalRuleBook.php |
UNIVERSAL_BAD_TITHISVARA_TITHI_YOGAS |
Package attribution: Muhurta Chintamani, Brihat Samhita, Mayamata, Vaikhanasa Agama, Ashvalayana Grihya Sutra |
ElectionalEvaluator.php |
calculatePanchakaDosha()calculateDagdhaTithi()calculateDagdhaYoga()calculateRiktaTithi()calculateAbhijitCancellation()generateRejectionReport() |
Package attribution: Muhurta Chintamani, Brihat Samhita, Gargiya Jyotisha |
PanchangService.php |
getElectionalSnapshot()getDailyMuhurtaEvaluation() |
Package attribution: Muhurta Chintamani, Muhurta Martanda |
These components implement festival and observance resolution where the package draws on traditional kala-nirṇaya style reasoning and fast/observance practice.
| File | Functions | Source Attribution |
|---|---|---|
FestivalService.php |
resolveFestivalsForDate()buildFestivalPayload()FestivalService::FESTIVALS catalog metadata |
Package convention: date-wise festival resolution with localized display fields and machine-stable calculation-basis metadata |
PanchangService.php |
getFestivalYearCalendar() |
Package convention: location-aware year aggregation, day_after festival orchestration, and adjacent duplicate consolidation |
KalaNirnayaEngine.php |
Festival karmakala_type handling:- madhyahna- nishitha- pradosha- aparahna- sunriseVaishnava Ekadashi handling |
Traditional convention: Nirṇaya Sindhu, Muhūrta Chintāmaṇi, Hari Bhakti Vilāsa |
BhadraEngine.php |
Bhadra/Vishti subdivision helpers | Package attribution: Muhūrta Chintāmaṇi, Nirṇaya Sindhu, Ernst Wilhelm's Classical Muhurta |
PanchangService.php |
Timed Bhadra windows Timed Varjyam windows Timed Amrita Kaal window Timed Pradosha window Daily Karmakala output assembly |
Published Panchang convention: Swiss Ephemeris-based live calculation |
These features are useful and intentionally included, but they are best described as published Panchang conventions or regional almanac systems, not universally fixed classical formulas.
| File | Functions | Source Attribution |
|---|---|---|
MuhurtaService.php |
calculateHora()calculateHoraTable()calculateChogadiya()calculateChogadiyaTable()calculateBadTimes()calculateDaylightFivefoldDivision()calculateNishitaMuhurta()calculateVijayaMuhurta()calculateGodhuliMuhurta()calculateSandhya()calculateGowriPanchangam()calculateKalaVela()calculatePrahara()calculateBrahmaMuhurta()calculateDurMuhurta()calculateVarjyam()calculateAmritaKaal()calculatePradoshaKaal()calculateLagnaTable() |
Published Panchang convention: Varies by tradition and regional practice |
PanchangService.php |
Daily output blocks: - Hora- Chogadiya- Hora_Full_Day- Chogadiya_Full_Day- Muhurta_Full_Day- Rahu_Kaal_Gulika_Yamaganda- Abhijit_Muhurta- Prahara_Full_Day- Daylight_Fivefold_Division- Brahma_Muhurta- Dur_Muhurta_Full_Day- Nishita_Muhurta- Vijaya_Muhurta- Godhuli_Muhurta- Sandhya- Gowri_Panchangam- Kala_Vela- Karmakala_Windows- Varjyam- Amrita_Kaal- Pradosha_Kaal- Lagna_Full_Day |
Published Panchang convention: Implementation follows published almanac patterns |
Notes:
Gowri_Panchangamis implemented as a Gowri-style 8-part day/night table based on the package's chosen published-table convention (Tamil Gowri/Pambu Panchangam)Kala_Velais based on a secondary-source rule pattern attributed to Saravali-style descriptions, not a source-critical Sanskrit editionGodhuli_MuhurtaandSandhyaare tradition-sensitive and may vary by schoolBrahma Muhurtatiming follows Ayurvedic sources (Aṣṭāṅga Hṛdaya, Charaka Saṃhitā, Manusmṛti)Varjyam,Amrita_Kaal, andPradosha_KaalinPanchangServiceare live-timed Panchang-day outputs and should be preferred over legacy scalar helpers when availableLagna_Full_Dayis a calculated ascendant-sign timing table for the day; it is not a natal/person-specific reading- Festival output metadata intentionally separates canonical rule values from localized companion labels. For example,
calculation_basis.month.valueremains the machine-stable Sanskrit month key for the configured calendar type, whilecalculation_basis.month.nameis localized for the active locale
These are present in the codebase but are not represented as fully verified primary-source logic.
| File | Functions | Notes |
|---|---|---|
ElectionalEvaluator.php |
calculateTransitMoorthy() |
Legacy heuristic: Unverified moorthy classifier |
ElectionalEvaluator.php |
calculateBhadra() legacy moon-sign heuristic |
Legacy heuristic: Prefer live-timed alternative in PanchangService |
ElectionalEvaluator.php |
calculateAmritaKaal() legacy Choghadiya-based helper |
Legacy heuristic: Prefer authoritative Amrita calculation |
ElectionalEvaluator.php |
calculateVarjyam() legacy Visha Ghati helper |
Legacy heuristic: Prefer KP System-based calculation |
Where the package has a more authoritative live-timed alternative, that alternative should be preferred over these helpers.
These components are implementation utilities and should not be interpreted as traditional-rule sources:
| File | Functions | Notes |
|---|---|---|
OutputGeneratorService.php |
generateFestivals()generateEclipses()generateTodayPanchang()generateAll() |
Output composition layer around PanchangService / EclipseService |
CliBootstrap.php |
init()makePanchangService()makeEclipseService()makeOutputGenerator() |
Standalone bootstrapping utility for scripts |
This list is descriptive. Inclusion here means the package references or attributes logic to that source or tradition somewhere in code or docs. It does not mean every usage has been independently verified against a critical Sanskrit edition.
- Sūrya Siddhānta
- Muhūrta Chintāmaṇi
- Muhūrta Mārtaṇḍa
- Kālaprakāśikā
- Nirṇaya Sindhu
- Ernst Wilhelm's Classical Muhurta
- Manusmṛti
- Aṣṭāṅga Hṛdaya
- Charaka Saṃhitā
- Bṛhat Saṃhitā
- Bṛhat Jātaka
- Nārada Saṃhitā
- Sarāvalī
- Gargiya Jyotisha
- Śrīmad Bhāgavata Purāṇa
- Tamil Gowri Panchangam
- Pambu Panchangam
- Māyamata
- Vaikhānasa Āgama
- Aśvalāyana Gṛhya Sūtra
- Hari Bhakti Vilāsa
- KP System (Krishnamurti Paddhati)
- Sandhyāvandanam Tradition
- ❌ It does not claim that every package rule is 1:1 proven from a single primary text
- ❌ It does not claim that all regional or sectarian variants are covered
- ❌ It does not claim that modern almanac conventions are identical across traditions
- ❌ It does not use brittle line-number references that become false after normal code changes
- ❌ It does not claim independent verification against critical Sanskrit editions
When adding or modifying source attributions in code, use these prefixes:
| Prefix | When to Use | Example |
|---|---|---|
Traditional convention: |
Stable Panchang arithmetic or long-standing calendrical units | Traditional convention: Sūrya Siddhānta 1.29 |
Package attribution: |
Package encodes a rulebook or mapping from traditional literature | Package attribution: Muhurta Chintamani Chapter 4 |
Published Panchang convention: |
Daily-window systems where practice varies by region | Published Panchang convention: Tamil Gowri table |
Legacy or heuristic |
Helper is not the preferred authoritative path | Legacy heuristic: prefer live-timed alternative |