The ManishAstro: Bridging Ancient Wisdom and Modern Engineering
Inspiration
For centuries, Vedic Astrology (Jyotish) has served as a guide for understanding life paths, career alignment, and relationship dynamics. However, modern users seeking astrological insights are often forced to choose between two extremes:
- Outdated Legacy Tools: Web portals designed in the early 2000s that are difficult to navigate, cluttered with ads, and lack modern responsive UI design.
- Commercialized Apps: Modern apps that prioritize engagement loops, notifications, and fear-mongering over deep, authentic astronomical calculation.
Furthermore, professional astrologers struggle with administrative overhead, having to manually draw charts, write custom report PDFs, and manage billing.
ManishAstro was born to bridge this gap. I wanted to build a premium, white-label workspace that empowers practitioners (like Manish) with precise calculations, provides developers with access to a robust API, and gives consumers clear, AI-synthesized, actionable insights.
What It Does
ManishAstro acts as a multi-layered platform designed for three distinct user groups:
For Seekers & Consumers:
- Natal Dossier: Instantly computes planetary positions, degree placements, and Nakshatras across multiple divisional charts—specifically the D1 (Lagna/Birth), D9 (Navamsa/Spouse & Dharma), and D10 (Dashamsha/Profession) charts.
- Kundli Milan: Evaluates relationship compatibility through the 36-point Ashtakoot matching system.
- AI Life Reports: Translates raw astronomical configurations into natural language career guidelines, helping users understand their professional archetype, strengths, and optimal timing.
For Astrological Practitioners:
- White-Label Portal: Astrologers can configure custom brand details (name, email, phone, website, and footer greetings) to be printed directly onto client report PDFs.
- Payment Integration: Built-in hooks allow practitioners to process orders directly through the dashboard.
For Developers:
- Developer Console: Provides API key generation, query telemetry, request quota tracking, and an interactive playground to test calculation endpoints.
How I Built It
ManishAstro is divided into two primary subsystems: a high-performance mathematical engine written in Go and a highly responsive Next.js frontend web app.
1. The Astronomical & Vedic Logic Engine
The underlying calculations rely on astronomical algorithms utilizing the Swiss Ephemeris.
Sidereal Longitude Conversion
Vedic astrology uses the sidereal zodiac (based on fixed stars) rather than the tropical zodiac (based on seasons). To convert planetary positions, we compute the tropical longitude $\lambda_{\text{tropical}}$ and subtract the Lahiri Ayanamsa difference $\theta_{\text{Ayanamsa}}$:
$$\lambda_{\text{sidereal}} = \lambda_{\text{tropical}} - \theta_{\text{Ayanamsa}} \pmod{360^\circ}$$
Ashtakoot Compatibility Scoring
For relationship matching, the system calculates the weighted sum of 8 distinct dimensional attributes (Kootas) between the Moon placements of both partners:
$$S_{\text{Ashtakoot}} = \sum_{i=1}^{8} w_i \cdot s_i$$
Where $w_i$ represents the max points (weights) allocated to each Koota, and $s_i \in [0, 1]$ represents the compatibility match ratio for that specific Koota. The weights are distributed as follows:
$$\sum_{i=1}^{8} w_i = 1_{\text{(Varna)}} + 2_{\text{(Vashya)}} + 3_{\text{(Tara)}} + 4_{\text{(Yoni)}} + 5_{\text{(Maitri)}} + 6_{\text{(Gana)}} + 7_{\text{(Bhakoot)}} + 8_{\text{(Nadi)}} = 36$$
A score of $S_{\text{Ashtakoot}} \ge 18$ is traditionally considered favorable, though the system cross-references this with Manglik Dosha severity:
$$D_{\text{Mangal}} = f(\text{Mars placements in Houses 1, 2, 4, 7, 8, 12})$$
2. Frontend & AI Layer
- Next.js 16 & React 19: Built with Server Actions and API proxy routes for high-speed server rendering. Styled with Tailwind CSS v4 to create a warm, premium, "editorial" brand aesthetic using HSL color variables (cream, terracotta, and soft sage greens).
- AI Synthesis Layer: We integrate with advanced language models to interpret data.
- Fallback Routing: We implement a resilient multi-tier AI routing framework that automatically handles rate-limiting and service disruptions by falling back to faster, high-availability model pools under the hood to ensure continuous service.
- Client-Side Document Export: Uses
html2canvasandjspdfto convert DOM charts into vectorized print dossiers on demand.
Challenges I Ran Into
1. Historical Timezone and Coordinates Complexity
Astrological calculations require coordinate precision up to minutes of arc: $$\text{Latitude } (\phi), \text{ Longitude } (\lambda)$$ Getting historical local timezone offsets right is notoriously difficult. For instance, before 1947, India had multiple regional time offsets (like Calcutta Time at $\text{UTC} + 5\text{h } 53\text{m } 20\text{s}$). We solved this by implementing database-backed custom coordinate mappings and using strict geocoding integrations to guarantee accurate local-to-UTC translations.
2. Eliminating AI Astrological Hallucinations
Initial prototypes allowed the AI model to infer chart facts from a user's birth details. However, language models are notoriously bad at orbital mechanics and would consistently hallucinate planetary placements (e.g., claiming Mars was in Taurus when it was in Gemini).
- The Solution: We decoupled calculation from interpretation. The Go engine deterministically calculates planetary coordinates and active yogas, which are packaged into a strict JSON payload. The AI synthesis layer is given a strict system instruction prohibiting it from performing celestial logic; its sole responsibility is to translate the pre-calculated JSON variables into natural language.
3. State Syncing in White-Label PDF Generation
Ensuring that custom practitioner settings (e.g., name, phone number) successfully rendered across client-side PDF components without causing hydration mismatches in Next.js Server Components. We resolved this by building a dedicated I18nProvider context combined with client-side state hooks that capture the updated layout settings before rendering the PDF canvas.
Accomplishments I am Proud Of
- Unified Astro Inspector: A beautiful, responsive interface that loads D1, D9, and D10 charts side-by-side, adapting to desktop and mobile layouts.
- Zero-Math AI Pipeline: By strictly feeding the engine's pre-computed parameters into the AI interpretation service, we created highly accurate, contextual reports that never hallucinate chart facts.
- Resilient Rate-Limiting Fallback: Built an automated fallback pipeline that silently rescues user requests during API bottlenecks by swapping models under the hood.
What I Learned
- Keep Calculation Deterministic: AI is an excellent copywriter and interpreter, but a poor calculator. Never trust a language model with orbital math or index calculations; calculate first, summarize second.
- TypeScript Schema Contracts are Crucial: Setting strict interfaces for the AI's JSON output ensures that UI components never break due to unexpected field names or missing arrays.
- Aesthetics Matter as Much as Math: An interface that feels premium and responsive makes ancient traditional calculations feel modern, trustworthy, and engaging.
What's Next for ManishAstro
- Expanded Reports: Launching the Wealth (D2 chart) Report and Relationship & Synastry Report (D9 Navamsa comparative evaluation).
- Interactive Vimshottari Dasha Gantt Chart: Creating a dynamic timeline showing active major ($Mahadasha$) and minor ($Antardasha$) planetary cycles across the user's lifespan.
- ** Developer Platform Expansion:** Introducing usage-based billing tiers, custom event webhooks for external integrations, and exposing advanced transit calculation endpoints..
Built With
- amazon-ec2
- amazon-rds-relational-database-service
- amazon-web-services
- aws-ecr
- cashfree
- css3
- golang
- html5
- javascript
- next.js
- react
- tailwind
- typescript
- vercel
Log in or sign up for Devpost to join the conversation.