一疊單據,影完相就掉喺電話入面,到月底先嚟後悔。呢個流程將「入賬」拆成四步:上載、提取、整理成表、出摘要 —— 每步都有 prompt,貼咗就用得。最後仲有一段進階玩法:唔再逐步指揮,而係畀個目標同規則 AI,等佢自己行完成個流程。
🧾 四步流程
① 上載單據 — 影相或者 PDF 都得,一次過掉晒入去。
② 提取欄位 — 日期、商戶、類別、金額 —— 讀單據上面真係有嘅字。
③ 整理成表 — 一行一筆,欄位次序你話事,出 CSV 直接貼入試算表。
④ 支出摘要 — 總額、類別佔比、最大五筆,一段過貼入月結。
① 上載單據
相片、PDF、截圖都得。唔使特別排版,但有幾樣嘢會直接影響之後幾步讀得準唔準:
- 影全張單,四個角都要入鏡 —— 剪走咗個總額,後面所有數都錯
- 光線平均,唔好有陰影或者反光壓住啲數字
- 摺痕同皺咗嘅位攤平,熱敏紙尤其易花
- 一次過上載同一個月嘅單據,唔好分幾次 —— 後面搵異常要成個月一齊睇先睇得出
② 提取欄位
呢一步嘅重點唔係「快」,係「唔好估」。單據影得矇、商戶名印得細、金額有個摺痕壓住 —— AI 係有能力幫你填得好順暢嘅,而嗰個先係最危險。所以 prompt 入面幾條規則,全部都係叫佢喺唔肯定嘅時候留白同標記,而唔係補一個好似啱嘅數畀你。
I've uploaded receipts (photos or PDFs). Extract these fields from each one, one block per receipt: - date (YYYY-MM-DD) - merchant - category (meals / transport / office supplies / software / marketing / professional services / travel / other) - amount and currency - payment method (only if it's on the receipt) - receipt number (only if it's on the receipt) Rules: 1. Read only what is actually visible on the receipt. If you can't read it, write "unclear" — do not guess. 2. Take the total printed on the receipt as the amount. If the line items don't add up to that total, give me both numbers and flag the mismatch. 3. List service charge, tip and tax separately. Don't fold them in as ordinary spending. 4. When you're done, list the fields you were unsure about, so I can check them myself.
③ 整理成表
格式你自己話事,下面 prompt 入面用緊嘅係一個可以直接開工嘅版本:日期|商戶|類別|金額|幣種|付款方式|單據編號|備註。想加「項目」或者「客戶」欄,改一行就得。
Turn those receipts into a table, one row per entry, with these columns in this order: date | merchant | category | amount | currency | payment method | receipt number | notes Rules: 1. Dates always YYYY-MM-DD, so they sort properly. 2. Amounts as digits only — no currency symbols, no thousands separators (e.g. 1280.50). Currency goes in its own column. 3. Use only the categories I listed. Don't invent new ones. If something genuinely fits none of them, write "other" and explain in the notes column. 4. Leave a field blank if you couldn't read it. Don't write "N/A", and don't guess. 5. Output as CSV so I can paste it straight into Google Sheets or Excel. 6. No totals row at the bottom — I'll calculate that in the spreadsheet.
兩個位好多人踩親:金額唔好連貨幣符號一齊寫(試算表會當佢文字,加唔到數),同埋唔好叫佢喺最後加一行總計(一 sort 就散晒)。
④ 支出摘要
有咗張表,摘要先有意思 —— 因為每個數都計得返出嚟。呢一步唔係叫 AI「講吓感想」,而係叫佢由張表計返總額、類別佔比、最大嗰五筆,寫成一段可以直接貼入月結嘅嘢。
Using the table above, write an expense summary I can paste straight into a spreadsheet or a monthly report: 1. Total spend for the period, by currency 2. Each category's amount and share, largest first 3. The five largest individual expenses, with dates and merchants 4. If I've given you last period's figures, compare: which categories rose, and by what percentage 5. One closing line: the single thing most worth noticing this period Rules: every number must be calculated from the table. Don't add anything that isn't in it, and don't state a conclusion stronger than the data supports.
⑤ 生成一個互動 HTML Dashboard
摘要係一段文字,dashboard 係一版可以㩒、可以篩、可以拉 slider 嘅嘢。呢個 prompt 由頭做起——讀單據、分類、查異常、做分析——最後直接畀你一個 .html 檔案:四張 KPI card、類別分佈 bar chart、異常警示卡、可以搜尋同排序嘅交易表,仲有三條慳錢模擬 slider。完全 self-contained,冇 CDN、唔使上網,雙擊就開到。
Goal:
From all the invoices / receipts I've uploaded, extract the spending, categorise it, check for anomalies, analyse it, and then generate a downloadable, interactive, self-contained HTML dashboard.
Do the whole thing in one pass. Don't check in with me step by step.
====================
A. Read every receipt
====================
Extract these fields from each one:
- date
- merchant
- category
- amount
- currency
- payment method (only if it's on the receipt)
- receipt number (only if it's on the receipt)
- line-item amounts
- tax
- service charge
- tip
- notes
Reading rules:
1. Use only what is actually visible on the receipt.
2. Leave a field blank if it's unreadable, absent, or uncertain. Don't guess.
3. Dates always YYYY-MM-DD.
4. Take the printed total as the amount.
5. If the line items don't add up to the total:
- keep the total
- compute the sum of the line items
- compute the difference
- flag it as "line items don't reconcile"
6. Record tax, service charge and tip separately. Don't treat them as ordinary items.
7. If one PDF contains several receipts, split it into separate transactions.
8. Any receipt you cannot read reliably goes into "needs input from me".
====================
B. Categorise
====================
Use only these 8 categories:
- meals
- transport
- office supplies
- software subscriptions
- marketing
- professional services
- travel
- other
Do not add categories.
If you can't decide reliably:
- categorise as "other"
- write the reason in the notes
====================
C. Anomaly checks
====================
Check every transaction for:
1. The same merchant charging repeatedly in a short window
- flag similar amounts on the same day or very close together especially
2. An amount more than 50% above the average for its category
- only calculate this if the category has at least 2 valid transactions
- show:
- the amount
- the category average
- the percentage above it
3. A merchant appearing for the first time this month
- only judge this if I've also given you previous months
- with no history, don't assume it's the first time
4. A receipt total that doesn't match its line items
5. A merchant that clearly doesn't fit its category
- flag only where there is enough evidence
- don't guess
Every anomaly must name:
- date
- merchant
- amount
- receipt number
- why it was flagged
====================
D. Analyse
====================
Calculate:
1. Total spend
- separated by currency
- do not convert between currencies yourself
2. For each category:
- amount
- share of total spend
- sorted largest to smallest
3. Top 5 largest expenses:
- date
- merchant
- category
- amount
4. Recurring vs one-off costs
Call something "recurring" only where there is evidence, such as:
- an explicit subscription
- a recurring monthly fee
- appearing across several months
If you only have this month:
- software subscriptions may be marked "possibly recurring"
- but don't claim it definitely repeats monthly
5. Identify:
- the largest spending category
- the largest single expense
- the anomaly most worth checking
- where spending is most concentrated
Every conclusion must be supported by actual transaction figures.
====================
E. Generate the interactive HTML dashboard
====================
When the analysis is done, generate a complete HTML file.
The HTML must be:
- self-contained
- a single .html file
- CSS and JavaScript all inline
- no external libraries
- no CDN
- no internet required
- openable directly in a browser
- mobile responsive
- dark premium SaaS dashboard styling
- visually clean, avoiding long blocks of text
- using colour hierarchy for the important numbers
Colour meaning:
Purple:
- totals
- the primary KPI
Green:
- normal items
- potential savings
- positive / healthy indicators
Amber:
- large expenses
- worth noticing but not necessarily wrong
Red:
- anomalies
- duplicated charges
- mismatches
- anything needing a human to check
====================
F. Dashboard layout
====================
Four KPI cards along the top:
1. Total Spend
2. Largest Category
3. Largest Transaction
4. Flags to Review
Each card:
- one big number
- a short label
- one line of supporting info
- not much text
Then:
SECTION 1
"Category breakdown"
A horizontal bar chart showing:
- category
- amount
- %
- highest first
No external chart library.
Plain HTML/CSS bars.
SECTION 2
"Anomalies / worth checking"
Each anomaly as a coloured alert card:
Red:
- duplicate charges
- mismatches
Amber:
- more than 50% above the category average
Green:
- checked and normal
Plus a button:
"Show / hide anomalies"
====================
G. Key takeaways
====================
No long paragraph.
Use coloured pills / chips for at most 4–6 key insights, for example:
- Top 3: professional services → travel → marketing
- the largest single expense is XX% of total spend
- X anomalies need checking
- one category is XX% of total spend
- one set of line items is off by HKD XX
Keep them short.
====================
H. Interactive savings simulator
====================
From the three largest categories that could plausibly be adjusted, generate three sliders.
For example:
Cut professional services:
0–30%
Cut travel:
0–40%
Cut marketing:
0–30%
If the actual largest categories are not those three, use whichever real categories are largest and reasonably adjustable.
For example:
- meals
- software subscriptions
- office supplies
As a slider moves, recalculate live:
1. Estimated savings
2. New monthly spending
3. Total spending reduction %
This must update live in JavaScript.
Note:
This is only a scenario simulator.
State on the dashboard:
"Scenario modelling based on current spending only. Not a projection of actual savings."
====================
I. Interactive transactions table
====================
List every transaction in full.
Columns:
date
merchant
category
amount
currency
payment method
receipt number
With these interactive controls:
1. Search
- merchant
- invoice number
2. Category filter
3. Sort:
- date newest → oldest
- date oldest → newest
- amount high → low
- amount low → high
4. An "anomalies only" button
5. A reset button
6. A counter:
"Showing X of Y transactions"
7. Clicking any transaction:
expands the details below it
Showing:
- merchant
- date
- category
- amount
- payment method
- receipt number
- why it was flagged (if it was)
====================
J. Recommendations
====================
Produce at most 5 specific recommendations.
Each one needs:
1. a short title
2. one line of action
3. supporting evidence
Format:
Recommendation:
"Review professional service scope"
Action:
"Revisit the quote, the scope, or what is being delivered."
Evidence:
"Freelance Designer HKD 1,800 + Consultant HKD 400 = HKD 2,200, which is 48.1% of total spend."
Important:
Do not invent recommendations to reach five.
If the data only supports 2–3 sound ones:
give 2–3.
Do not offer:
- investment advice
- tax advice
- legal advice
Only cost control and what the spending data itself shows.
====================
K. Evidence requirement
====================
Every significant conclusion must be traceable back to transactions.
For example:
Don't just write:
"Professional services are too high."
Write:
"Professional services HKD 2,200, from:
- Freelancer HKD 1,800
- Consultant HKD 400
Together 48.1% of total spend this period."
Every percentage must be calculated from the actual figures.
Don't make numbers up.
====================
L. Needs input from me
====================
At the bottom of the dashboard, add:
"Needs input from me"
Listing everything that was:
- unreadable
- missing a date
- missing a merchant
- missing an amount
- missing a currency
- impossible to confirm as a duplicate
- impossible to confirm as a first-time merchant, for lack of history
- impossible to confirm as a recurring pattern, for lack of history
If there is none:
show "Nothing needs adding at the moment."
====================
M. Fake/demo data rule
====================
If I ask for a demo and some of the data is invented:
Label it clearly:
DEMO DATA
And state:
"Invented transactions are shown only to demonstrate the dashboard, and do not represent a real financial position."
If these are real invoices:
add no fake data at all.
====================
N. Final output
====================
At the end, simply:
1. finish the analysis
2. generate the HTML file
3. confirm the HTML opens standalone
4. confirm every button / filter / slider actually has a working JavaScript function
5. confirm there are no external dependencies
6. give me a download link for the HTML
Do not ask me first:
"Shall I generate it?"
or
"What style would you like?"
Just do it.
If a little data is missing:
do the rest of the analysis anyway and put the gaps under "needs input from me".
Treat a receipt as incomplete only when the transaction amount is genuinely unknowable.
Most important:
accurate numbers beat impressive visuals.
Never fill a gap with a guess.呢個 prompt 好長,但唔好刪剩一句「整個 dashboard 畀我」。長嗰啲位,大部分都係喺度封死 AI 自己填數嘅空間:讀唔到就留白、百分比要計返、每個結論要對得返邊一筆交易、冇歷史資料就唔准話人哋係「第一次出現」。刪咗佢哋,你會收到一個好靚、但數字信唔過嘅 dashboard。
入賬嘅底線: AI 整嘅表係副本,唔係憑證 —— 原本嗰張單據要留返底。落賬之前,至少抽查總額同日期:呢兩樣一錯,成張表都要重做。
🤖 進階:用 AI Agent 做財務規劃
頭四步係你逐步指揮,AI 逐步做。進階玩法係反過嚟:你只係講清楚目標同規則,AI 自己行完成個流程先覆你。一個月幾十張單據,逐張傾你會癲,呢個時候先真係慳到時間。
- 讀取 — 逐張單據攞日期、商戶、金額、幣種。
- 分類 — 用固定嘅類別清單,唔准自己發明。
- 找異常 — 重複扣款、高過平均、新商戶、總額對唔上、類別放錯。
- 分析 — 邊幾類佔最多?邊啲係固定開支、邊啲係一次性?
- 摘要 — 一頁以內:總額、類別分佈、Top 5、異常清單。
- 建議 — 三個具體慳錢做法,每個都要指返邊幾筆數支持。
「異常」呢兩個字,你唔定義,AI 就會自己定義。所以 prompt 入面要寫死:幾多百分比叫高、幾耐之內叫重複、邊種情況叫類別放錯。
Goal: from this month's spending, identify the major expenses, the anomalies, and anything worth my attention. I'm giving you every receipt for the month at once. Work through this whole routine yourself — don't check in at each step: 1. Read: extract date, merchant, category, amount and currency from each receipt. 2. Categorise: use only these fixed categories — meals / transport / office supplies / software / marketing / professional services / travel / other. 3. Find anomalies: flag anything matching one of these — - the same merchant charging more than once in a short window - an amount more than 50% above the average for its category - a merchant appearing for the first time this month - a receipt total that doesn't match its line items - a merchant that doesn't belong in the category it landed in 4. Analyse: which categories dominate? Which costs recur every month, and which were one-offs? 5. Summarise: one page or less — total, category breakdown, top 5 expenses, the anomaly list. 6. Recommend: three specific ways to spend less, each pointing at the actual expenses that support it. Rules: - Every conclusion must name the receipt or the line it came from. Don't tell me anything I can't trace back. - Anything you couldn't read, or that's missing data, goes in a "needs input from me" list. Don't fill it in yourself. - No investment or tax advice. Only what the numbers themselves show. - Work through all six steps, then reply once.
最要緊嗰條規則係「每個結論都要講返邊張單支持」。有咗佢,你可以抽幾條返去核;冇咗佢,你只係得到一段讀落好有道理、但你查唔到嘅嘢。
最後提醒: 呢個流程幫你慳嘅係入資料嘅時間,唔係幫你做會計判斷。稅務點報、邊啲使費可以扣,去問你嘅會計師 —— AI 做得最好嗰部分,係喺你見到佢之前,將啲數執到整整齊齊。
