We build computation engines from first principles — in OCaml, Rust, and Elm — for mathematics, Vedic astrology, music theory, and structured educational content. Not wrappers. Not fine-tunes. Original work.
Part of ApasHub ecosystemThree OCaml engines that power computation across the entire Apas platform — mathematics, astrology, and music.
Arbitrary-precision number tower with symbolic computation and Vedic mathematics sutras. Powers all numerical work across ApasLearners and ApasCreative.
Full Jyotish computation engine covering natal charts through divisional charts, all major dasha systems, and classical yoga detection.
Layered music generation library from theory through synthesis — covering Indian and Western traditions with a unified interval and scale system.
Two Elm-based systems that turn JSON blocks into rendered educational content — on web, mobile, and inside AI responses.
Universal block system covering 14 UI block types, interactive elements, story blocks, language blocks, and learning blocks. The same JSON spec powers ApasLearners, ApasBooks, ApasCreative, and AI chat responses from ApasAgents. Inline markup parser, KaTeX math rendering, WebGPU/WGSL shader blocks, and 5 plot types including histogram, heatmap, and candlestick.
Purpose-built diagram system with modules for FlowChart, Mindmap, Cycle diagrams, Relationship maps, Geometry (with polycurve, junction, freecurve, LaTeX labels), Ray Optics, Plot2D with 13 plot types, and astrology charts — North and South Indian kundali, dasha timelines, transit wheels. Wired to Rust API and OCaml backends.
Streaming agent platform with named agents (Apas, Nova, Astra, Sage, Quill, Muse, Atlas, Axiom), knowledge base injection, builtin and HTTP tool executors, prompt caching, cost tracking, and ContentKit block format as the universal response format. Axiom agent is wired directly to the OCaml GTMath engine.
Offline authoring pipeline for original educational content grounded in source material. pgvector embeddings prevent hallucination by anchoring AI tutor responses to verified ContentKit blocks — not freeform generation. NCERT Biology structure complete across 12 topics per chapter. Common Core Mathematics Grade 6 authored.
Every layer chosen deliberately — not for familiarity, but for what the problem demands.
| Language | System | Why |
|---|---|---|
| OCaml | GTMath, Jyotish, GTMusic engines | Algebraic types make number towers and ASTs natural. Strong type system catches domain errors at compile time. Fast enough for computation servers. |
| Rust / Axum | apas-agents, apas-admin | Memory safety without GC overhead. Async performance for SSE streaming. Axum's extractor pattern keeps agent routing clean. |
| Elm | ContentKit, DiagramKit, Geometry Editor | No runtime exceptions. Enforced immutability prevents the class of UI bugs that cause VirtualDOM corruption. Every block type is a variant — exhaustive pattern matching. |
| Django | accounts.apashub.com — auth, billing | OTP registration, JWT issuance, Razorpay subscription management. Admin panel with unmanaged models for Rust-owned tables. |
| PostgreSQL | Primary database — all domains | Domain schemas: content, questions, crm, promo, platform, contests. Partial unique indexes for diagram slug normalisation. pgvector for RAG embeddings. |
| WebGPU / WGSL | Shader blocks in ContentKit | Physics and mathematics visualisations that run on the GPU directly from structured content blocks. Three delivery modes: CDN URL, DB id, inline. |
The dominant approach to AI tutoring is to prompt a general model and hope it stays accurate. We think this is wrong for education — especially for subjects like JEE Physics or Jyotish where precision is non-negotiable.
Our approach: author content once in verified ContentKit blocks, embed it with pgvector, and anchor every AI response to those blocks. The AI explains — it does not invent. The OCaml engine computes — it does not estimate.
This is slower to build. It is correct by construction.
GTMath, Jyotish, and GTMusic are built from scratch in OCaml — not wrappers around a third-party CAS or astrology library. We own the computation.
ContentKit JSON blocks are the universal format across every surface — web, mobile, AI responses, PDFs, books. One spec, every renderer.
Vedic mathematics, Jyotish, Sanskrit — these are rigorous systems. We treat them with the same engineering rigour as a physics engine.
OCaml and Elm's type systems eliminate whole classes of runtime errors. In an education product, a wrong answer is worse than no answer.
Write to research@apashub.com · For partnerships and B2B, use the ApasHub contact page