How vedastro/vedastro works
Major Components
• Core Calculation Engine/Library:
– This is found mainly under the “Library” folder (plus “LibraryTests”, “MatchMLPipeline”, and modules like “MigrateGeoLocationData”). It includes modules for astrological calculations, event prediction (see the detailed explanation in the README), numerology and chart evaluation.
• API Layer:
– Located in the “API” folder (with its own project, Dockerfile, and program) plus “APITester” for validating endpoints. This layer exposes the astrological computations as RESTful services, including support for AI Astrologer and data retrieval. It is built with .NET (C#) and containerized (Docker) and deployed on Azure.
• Website and Mobile UI:
– In the “Website” and “Website_Mobile” folders, you have Blazor-based user interfaces that call the API. The website is a static web app using Blazor WebAssembly, with additional frontend assets (HTML, CSS, JS, images, and SEO configurations) provided to ensure a “drunk proof” user experience.
• Desktop and Console Applications:
– There are Desktop applications (in the “Desktop” folder with multiple platform-specific versions like MAUI app and a macOS launcher) and a “Console” app. These tools are likely used for purposes such as API launching, debugging, and offline calculations.
• Additional Modules:
– “LLMCoder” and “DocToEmbeddings” indicate extensions for language/AI functionality.
– “WebScraper” collects external astrological or related data.
– “StaticTableGenerator” and “Publisher” provide additional data generation/processing and deployment features.
– The “Others” directory contains archived and demo code, scripts (for container and build management) and assorted documentation files (including design artworks and examples).
Relationships and Interactions
• The User (via a browser or mobile device) interacts with the Website/Mobile UI components.
• The Website UI, mostly built with Blazor WebAssembly, sends API requests to the API backend (which runs as Azure Functions behind a CDN and uses Docker containers).
• The API layer internally calls methods in the Core Calculation Engine/Library to process astrological queries (for horoscope generation, event prediction, numerology, etc.).
• Desktop applications and the APITester serve as auxiliary utilities for testing, launching, and debugging rather than as primary production systems.
• Data comes in from multiple sources: static XML files (such as EventDataList.xml) for event prediction, CSV files for datasets (in directories like “HuggingFace”), and possibly dynamic input (via user submission) that gets processed by the calculation library.
• The system also uses a pipeline for Machine Learning (see “MatchMLPipeline”) that likely ties in with the astrological predictions and data generation.
• The use of Azure (via containerized images, DNS/CDN for custom domains, and Azure Table storage or other database services) is an important part of the deployment design.
Architectural Patterns and Design Principles
• Modular and Multi-Tier Separation: The project is divided logically between presentation (Website, Mobile, Desktop), business logic (Library/Calculation Engine), and service/API layers.
• Containerization and Cloud Deployment: The API is containerized and deployed via Docker and Azure Functions while leveraging Azure CDN and custom domain routing.
• Extensibility: The design “Build On Top” philosophy means that the Library’s prediction logic is exported as a NuGet package (.NET) and even published on PyPI for Python users, enabling integration with different ecosystems.
• Testing and Experimentation: Separate APITester, Console apps, and dedicated test projects (LibraryTests) indicate a focus on continuous integration testing.
• Multi-Platform UI: With separate projects for Desktop (across Windows, macOS, Linux, MAUI) and for Website/Mobile, the design embraces cross-platform user experience and “drunk proof” simple UI design principles.