hey create me the GL analyzer which would help me to identify whole entry trial
- User
hey create me the GL analyzer which would help me to identify whole entry trial
Assistant
I'll build you a GL (General Ledger) Analyzer — a tool that lets you upload/paste GL data, groups lines into whole journal entries, generates a trial balance, and flags problem entries (unbalanced, weekend postings, round amounts, etc.). Let me check the project setup first.
Now the CSV parser with flexible header mapping:
Now the analysis engine — grouping into whole entries, trial balance, and anomaly flagging:
Now sample demo data with intentional issues baked in (unbalanced entry, weekend posting, duplicate, round amounts, single-line entry):
Now the UI components. First the Import panel and shared bits:
Now the Dashboard stat cards and the core Entry Explorer (whole-entry drill-down):
Now the Trial Balance view (with CSV export) and the Anomalies panel:
Now the main App with tab navigation, plus updating the page title:
Now let's build to verify everything compiles:
Build succeeded ✅ Your GL Analyzer is ready. Here's what it does:
📥 Import
- Paste or upload any CSV/TSV general ledger export (drag & drop supported)
- Smart column detection — automatically recognizes headers like
Entry No / JE # / Voucher / Doc No,Posting Date,Account,Debit/Creditor a signedAmountcolumn,Memo/Narration,Posted By. Also handles European number formats, parentheses negatives, and various date formats - Load Sample Data button so you can try it instantly
🧩 Whole Journal Entry Reconstruction (the core feature)
- GL lines are grouped by entry number so you see every complete entry — all debit and credit lines together
- Expand any entry to view its full line detail with entry totals
- Filter by All / Unbalanced / Flagged / Balanced and full-text search across entry IDs, accounts, and memos
- Unbalanced entries are outlined in red with the exact difference (Δ) shown
⚖️ Trial Balance
- Per-account debit, credit, and net (Dr − Cr) with visual balance bars
- Grand totals proving whether the ledger ties out
- One-click CSV export
🚩 Anomaly Detection (7 checks)
- Unbalanced entries (debits ≠ credits)
- Possible duplicates (same date, accounts, and amounts)
- Single-line entries (missing offsetting side)
- Large values (top 5% by amount)
- Round amounts (multiples of 1,000)
- Weekend postings
- Missing descriptions
Everything runs locally in the browser — no data leaves your machine. Try the "Load sample data" button; it includes deliberately broken entries (a 7,000 adjustment, and a duplicated $15,000 marketing entry) so you can see the analyzer catch them.
Files built:
src/types.ts,src/utils/parser.ts,src/utils/analysis.ts,src/data/sample.ts,src/components/ImportPanel.tsx,src/components/FlagBadge.tsx,src/components/StatCards.tsx,src/components/EntryExplorer.tsx,src/components/TrialBalance.tsx,src/components/Anomalies.tsx,src/App.tsx,index.html