LTT Engine Room · Internal

PrimaHQ Claims Starter Prompt

Paste-and-go prompt for a new claims build.
v1
24-Jun-26
PrimaHQClaimsStarterPrompt.md
LTT Outsourced CFO Sdn. Bhd.

PrimaHQ Claims — New-Client Build Prompt (paste this at the start of the next chat)

You are helping LTT Outsourced CFO Sdn. Bhd. build a "PrimaHQ Claims" expense-claim app for a NEW client, matching our existing internal standard. Do NOT invent a new design — reuse our template and conventions exactly. I will upload a starter kit (template + build spec + helper). Follow it.

What to produce

A single self-contained offline .html app (double-click to run, no server) plus a separate receipts pack .json, identical in structure/behaviour to our current build. Same five tabs: Dashboard · Expenses · Excluded · Export · Settings, an Entity dropdown in the top bar, the SparkReceipt-style branded per-month report, Bukku full-year export, direct PDF/HTML export, and a Google-Sheets master.

Files I will give you (the starter kit)

What I will provide for the client

  1. Scanned receipts for the year (monthly folders / zips / PDFs).
  2. A 3-tab classification workbook (Claims to submit (not via bank), Excluded - bank-paid & dup, Excluded - utilities & rental) with columns: Reference No., Date, Supplier/Payee, Description, Original Category, Acct Code, Account (PrimaHQ classification), Amount (RM), Original Ref, Status, Source File, Page(s).
  3. Client branding: legal name, registration/SSM no., TIN, address, and a logo (PNG/JPG).

Build steps (do these in order)

  1. Parse the workbook → build the dataset JSON (one row per line item). Claims tab → inc:"in"; both excluded tabs → inc:"out". Fields: id, client, clientName, date(YYYY-MM-DD true doc date), month, supplier, desc, category(=account name), ref, amount, note("Status: … | was: …"), file(relative path), pages[ints], type, inc. Type default: Utilities/Telephone/Rental → "Bill (Credit Purchase)", else "Cash Bill".
  2. Collect distinct accounts → seed categories {name, code, bukku:"", excluded:false} (codes from the Acct Code column). Merge with our standard COA list.
  3. Embed the logo (trim white, base64 data URI). Auto-set the client's report accent (spine) to the logo's dominant colour. Fill reg, tin, addr.
  4. Inject dataset/seedcats/clientdefaults/logo into app2_template.html → write the final .html. Write big files via a bash heredoc on the Linux side (host writes can truncate), then node --check the extracted <script>.
  5. Generate the receipts pack with gen_receipts_hq.py (point it at the client's receipt source; keys = file + "|" + page; ~80 DPI / JPEG q38 / max width 850; run in batches of ~100–130 pages). Use a fuzzy filename resolver (normalise apostrophes/spaces/case) + distinctive-token fallback.
  6. Deliver: the app .html, the receipts pack .json, and a Google-Sheets master .xlsx.

Classification rules (apply consistently)

True-date placement (client ledger date beats stale receipt date); partial claims = only the marked amount; utility arrears = current-month charge only; LTT supplier house-style Brand (Legal Sdn. Bhd.).Outlet, keep Chinese; exclude rental/utilities/payroll/bank-paid/duplicates from the claim.

LTT internal standard (must follow)

Start by confirming you have the starter kit and the three client inputs, then ask me for anything missing before building.

ler.lttcfo.ai/appclaim