End-of-day business report
Process with the playbook's report
This page describes the end-of-day business report of the Senior Financial Analyst & Controller playbook, set up as a process. File names and amounts are examples, not measured results; what you get depends on your files and the model you choose.
For: shop, café and restaurant owners who receive the day's sales and cost files from an accountant Runs: every day at 18:00 (Asia/Ho_Chi_Minh) and whenever you press Run nowDelivers: an Excel workbook and a short report (PDF) to your Telegram chat
1. Set it up with one sentence
- Install the Senior Financial Analyst & Controller agent from the catalog and open your shop's project.
- Connect your Telegram bot once (Settings → Connected Accounts → Telegram, paste the token; see Connected Accounts) and add it to the accounting group. The owner sends
/startto the bot once, so AMBA can reach the owner's chat. (You can also connect the bot from the first question below.) - Open the project → Processes tab and write, for example:
6 pm every day make the end-of-day business report from the files the accounting group sends and send it to me on Telegram; I can ask back and approve the bonus there.
- Answer the questions by tapping (at most 3): which group is "the accounting group", and who "me" is when AMBA cannot tell (the owner's chat, by name). The playbook's report brings the currency (VND), the staff list file (
sources/uploads/nhan_su.xlsx) and the history workbook (workings/lich_su_kinh_doanh.xlsx). - Read the lines and the AMBA will: line. Try it (optional) works on the files already in the project, writes only to a separate try-run folder and shows what would be sent — nothing is sent. Then press Turn on; if the owner's chat is new to AMBA, it first receives a short test message.
- Keep AMBA running. Processes run only while AMBA is open and the computer is awake. In Settings → General → Background & processes, keep Keep running in the background and Keep the computer awake for scheduled processes on (both are on by default) and turn on Start AMBA when I sign in. Closing the window then leaves AMBA in the tray (notification area on Windows, menu bar on macOS): the sidebar shows Processes on with the next run, and the tray menu can pause all processes or quit. AMBA cannot wake a computer that is asleep or switched off — leave the shop PC on at 18:00; if it was off, the report catches up within 24 hours when AMBA starts again.
To change it later, write under the card ("move the report to 7 pm") or tap the time line: +1 hour → Apply.
Files sent to the Telegram group or the Google Drive folder land in Sources, in sources/<source>/<YYYY-MM-DD>/ (the business day when AMBA can tell it on arrival, otherwise undated/). The report does not rely on the folder: it asks AMBA for the files of the business day.
Which day is a file?
AMBA works it out without the AI, from the strongest evidence it finds: a date column inside the file, a title such as "Ngày 07/10", the file name ("0710", "7.10", "ngay7"), the message sent with it ("hôm qua"), and finally the arrival time (before 10:00 counts as the previous day). A file holding several days is split by its rows; a duplicate or an older version of a re-sent report is not counted. A file whose day stays unclear is listed under Cần xác nhận in the report, and AMBA asks once in your chat "File … thuộc ngày nào?" — reply to that message with the date. Under Sources in the file tree, a day with such files carries an N need a date badge; click it to set the date yourself; see Project Sources.
2. What the process does
- Loads every sales and cost file of the day (Excel or CSV). Vietnamese amounts such as
1.234.000,1.234.000 ₫or(1.234)are read as numbers; a cell that cannot be read as an amount is listed in the report instead of being guessed. - Computes revenue, cost of goods sold, other costs, gross and net profit — by branch and product when the files have those columns — with SQL queries and workbook formulas, never by guessing. It compares the day with the previous day and the 7-day average.
- Writes
reports/YYYY-MM/YYYY-MM-DD_Bao_cao_kinh_doanh.xlsxand a short report (.mdwith a PDF copy). - Keeps one row per business day in
workings/lich_su_kinh_doanh.xlsx(date, revenue, costs, profit, staff hours and cost when available, bonus proposed, bonus approved). Running the same day again replaces that day's row and its own report files; it never adds a duplicate row and cannot overwrite your other files. - If the app was closed at 18:00, the run catches up when AMBA starts again (within 24 hours) and still reports the missed day, not the day it finally ran.
3. What the owner receives
A formatted Telegram message (bold headings, bullet lists, small tables aligned) with the day's headline figures, the comparison and notable changes. The workbook and the PDF the run created are attached with the caption "📊 Báo cáo kinh doanh ngày 11/10/2026". The bonus options appear only on days the agent proposed some.
Before sending, AMBA compares the figures in the message with the run's Excel file. If one contradicts it, the owner gets a short warning instead of the wrong text (the files are still attached) and the run in the chat explains it under Delivery notes.
4. Bonus advisory — advice only
When the day made a profit, the report adds 2–3 bonus options. Each option shows its amount, its share of the day's net profit, the staff cost share of revenue after the bonus, and how it would be split by hours, shift or role (from the staff list). The agent explains its reasoning from the history workbook — profit trend, staff cost share, revenue per staff member or shift, bonuses you approved before — and states its caveats, for example when there are fewer than 7 days of history.
There is no fixed rule and nothing is decided for you: the options are advice, the column "Bonus approved" stays empty until you decide, and you remain the one who approves and pays a bonus.
5. Ask the agent back on Telegram
Write it into the same sentence ("I can ask back and approve the bonus on Telegram"), or add it later with a sentence under the card ("let me ask back and approve on Telegram"). The process then answers the owner in the same chat that receives the report; the card shows the line Anytime — <owner> can ask back / approve on Telegram.
- Every text message the owner sends to the bot starts the agent; it replies in that chat within about a minute (AMBA must be running), in Vietnamese, in a few lines. The report ends with "💬 Anh/chị trả lời tin nhắn này để hỏi thêm hoặc báo quyết định." once this is on.
- Ask about the numbers, for example "sao hôm nay chi phí cao?". The agent answers from the project's files, the history workbook and the latest report, with figures read by tools; when a file or a day is missing it says so instead of guessing.
- Decide on the bonus in the chat, for example "duyệt phương án 2", "ok 1,5 triệu" or "không thưởng". The agent records your decision with your exact words (shown in What the agent knows as "<your name> on Telegram: “duyệt phương án 2”"), writes the amount into Bonus approved of that day's row in
workings/lich_su_kinh_doanh.xlsx, and confirms in one line. Later reports use it as a bonus you approved. - The thread is kept under the report's card as Conversation with <your name>, so follow-up questions have the earlier context and you can read the whole exchange on the PC.
- Replies to the "File … thuộc ngày nào?" question, messages in other chats and messages from bots are never treated as questions. Messages sent while the agent is still answering are answered together, in order.
