Product
- Paste Tamil verse. See syllable splits and metre labels.
- Classical rules run first.
- Nothing leaves your browser.
Tamil classical metre (yāppu) is strict structure. Most tools skip it or lock it in desktop-only files.
Tech and architecture
- Rust
- WASM
- TypeScript
- React
Architecture
- Rust parser compiles to WebAssembly (WASM) for the browser hot path
- React loads the module once and calls it for each analysis
- UI state stays in TypeScript; static hosting is enough for the demo
- Offline ML helpers stay out of the browser path; live analysis uses classical rules
Key components
- Rust metre crate: tokenization, syllable / acai structure, metre classification
- WASM bridge: typed exports the UI can call without reimplementing grammar in JavaScript
- React UI: reading-first panels for verse and labels
Data flow
- User text
- React state
- WASM parse
- Structured result
- Render
No network round-trip for the core path. Optional corpora or saved sessions stay outside the parser boundary so the linguistic core remains a pure function of input text.
Tradeoffs
- WASM payload size versus server-side NLP: first load costs bytes; later analysis is free and private
- Encoding classical rules in Rust is slower than a heuristic JS port; correctness and reuse outweigh one-time compile cost
- Browser-only demo limits heavy corpus jobs; fine for an interactive reading tool
Testing and ops
- Parser fixtures against known metre examples catch rule regressions
- UI smoke covers load-WASM and round-trip display
- Deploy is static: build WASM + frontend, ship. No database or model endpoint
More shipped walkthroughs in this set, or back to the landscape.