← ClaudeAtlas

token-frugal-intent-ladder-skilllisted

Token-frugal AI ladder architecture for natural language transactional inputs: 0-token regex and semantic heuristics, active vs passive cashflow disambiguation, clean note extraction, and human-in-the-loop draft gates.
4ntiDandruff/zero-bloat-skills · ★ 1 · AI & Automation · score 74
Install: claude install-skill 4ntiDandruff/zero-bloat-skills
# Token-Frugal Intent Ladder Skill A tiered natural-language normalization architecture that processes 90%+ of transactional inputs deterministically without spending a single LLM token. Eliminates API costs, eliminates model hallucination, and delivers sub-millisecond response times. Battle-tested in the **Kas Megapass** natural language cashbook engine (`kas.megapass.web.id/app/ai/normalizer.py`). --- ## 1. The Core Philosophy: "AI Fills, Never Commits" In financial, inventory, and mission-critical systems, never allow an AI model or heuristic to directly execute database writes. Always enforce a **Draft Review Gate**: ``` [ User Natural Text / Voice ] │ ▼ ┌─────────────────┐ │ AI Ladder │ ── Tier 1: Regex & Semantic Rules (0 tokens, <1ms) │ Normalizer │ ── Tier 2: User Overrides Table (0 tokens, <2ms) └────────┬────────┘ ── Tier 3: LLM Fallback (Only if ambiguous) │ ▼ [ Structured Draft Preview ] <-- Human glances at amount & category │ ▼ (User Taps "Simpan") [ Atomic Database Commit ] ``` --- ## 2. Active vs Passive Semantic Disambiguation A common failure mode in financial NLP is mixing up **Debts** (Hutang) and **Receivables** (Piutang) due to overlapping vocabulary ("pinjam", "utang", "talang"): * **Hutang (Cash IN / Liability)**: The user is the recipient of borrowed funds. * *"aku pinjam uang dari Budi 100rb"* * *"dapat talangan