Audit financials
Compare staged financials against confirmed income statements and report accuracy per monthFrom its SKILL.md
npx -y skills add clenisa/optimal-cli --skill audit-financialsAssembled from the repository path, not quoted from the project. Check it against their README if it does not work.
2 things to look at
- no licenseNo license file was found in the repository. Code published without one is not open source by default, so using it at work is a question for whoever answers licensing questions where you are.
- 0 stars0 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.
SKILL.md
1.4 KB, as published. Nobody here has run it
Purpose
Verifies data accuracy between stg_financials_raw (staged from NetSuite XLSM/CSV) and confirmed_income_statements (from NetSuite income statement CSVs). This is the most critical financial health check — every data session should start by running this.
Inputs
- months (optional): Comma-separated YYYY-MM strings to filter (e.g.,
2026-01,2025-12). Omit for all months. - tolerance (optional): Dollar tolerance for match detection. Default
1.00.
Steps
- Call
lib/returnpro/audit.ts::runAuditComparison(months?, tolerance?)to fetch and compare data - Paginate all
stg_financials_rawrows (amount is TEXT — parseFloat) - Paginate all
confirmed_income_statementsrows - Aggregate staging by
account_code|YYYY-MMkey - Compare each overlapping account: exact match, sign-flip match, or mismatch (within tolerance)
- Compute accuracy = (exactMatch + signFlipMatch) / overlap * 100
Output
Per-month table:
| Month | Confirmed | Staged | Match | Mismatch | Accuracy |
|---|---|---|---|---|---|
| 2026-01 | 189 | 91 | 83 | 8 | 91.2% |
Plus total staging rows and confirmed rows counts.
Flag any month below 100% accuracy — investigate mismatches and identify root causes.
Environment
Requires: RETURNPRO_SUPABASE_URL, RETURNPRO_SUPABASE_SERVICE_KEY