计划执行与检查节点
executing-plans
按既定实施计划完成工作,保持过程检查和反馈。
receipt-accounting【效率与协作】Receipt register: payer, mode, gross amount received, invoice allocation, unapplied amount and TDS collected. Use for receipt and sales-income accounting.
独立 GitHub 快照 · 自动分类 · 以原作者文档为准
What it is: Money received, allocated to the right account, and reconciled to cash or bank.
Works out the smallest useful Receipt Accounting setup for the business in front of it, then builds it only when asked. The default output is a short recommendation, not a spreadsheet. Artifacts - CSV, SQL DDL, JSON Schema, Notion mapping - are produced on request, from one field list so they cannot drift apart.
Layer: Layer 3: Record. Fits: Starter stage. Table code: n/a.
The rule this table exists to enforce: a receipt is not sales income. Money can
arrive as collection of an existing receivable, as an advance from a customer, as a loan
received, or as capital contribution. Each of those lands in a different ledger, and only
one of them is income. This is why Receipt Type and Treats as Sale Income are fields and
not conventions, and why Amount Allocated and Unapplied Amount are both captured - the
difference between the gross received and the part that clears an invoice stays visible
instead of quietly inflating revenue.
Also use it when the user says "money received, allocated to the right account, and reconciled to cash or bank", or describes the same process happening in a spreadsheet, a document or someone inboxes.
Do not use it for: raising sales invoices, making payments, tax filing, or legal advice. This skill produces empty templates only - it never holds or processes real employee or customer data.
Follow the shared execution contract. The module-specific rules below define only domain fields, decisions, calculations, and safety constraints.
Read the request and pick the intent before asking anything.
Ask only if this is the highest-value missing fact; otherwise proceed without an opener:
Q: How do you record money received today?
Treat ambiguous replies as unanswered and ask which explicit option the user means. Record unknown values as Unknown; Unknown is not zero. A record must not be Done when a required check fails.
Skip anything the user already answered, in any earlier message. Ask the rest one at a time, and stop as soon as the remaining answers would not change the output.
Never invent an answer. If the user does not know, record it as unknown and carry on.
Hold the answers in this shape. It stays internal - it is not shown to the user unless they ask, and it never carries a value the user did not give.
module: receipt-accounting
intent: null # setup | advice | review | fix | build | convert | export
scale: null # Starter | Growth | Scale, only if the answer changes it
areas:
"Receipts": null
"Allocation": null
"Evidence": null
"Reconciliation": null
"Outcome": null
requested_outputs: [] # csv | sql | json | notion | xlsx - requested formats only
confirmed_facts: [] # only what the user actually said
open_questions: [] # the unanswered ones, in the order worth asking
Build an already requested artifact without asking again. For advice-only requests, give a short recommendation and offer the relevant artifact.
Recommended approach: One receipt record carrying the mode, the gross received, the receipt type, the invoice it clears and the unapplied balance, and post it to income only when the type says it is a sale.
Why this one: The trap on this table is that money in gets treated as revenue out. Forcing the type and the allocation before the entry closes is what keeps an advance or a loan out of the sales book.
Workflow: Money received → Mode and source recorded → Typed as collection, advance, loan or capital → Allocated to an invoice or held unapplied → Reconciled to bank or cash
Once the user asks for it, derive the fields from the confirmed context and emit the requested artifacts. For machine-readable text, keep prose outside the data; for files, provide a usable link. Report material validation failures or limitations separately.
A selected Notion output is rendered by notion-manual-import, so route the
Notion step there. When the user selects Notion, hand that step to
@notion-manual-import: it holds the CSV, the property
mapping, the import steps and the verification checklist, and it renders the Field
Reference below instead of defining a table of its own. Do not restate the mapping
here and do not improvise the import steps. Manual CSV and mapping outputs need no
connection. For requested workspace changes, follow the shared contract: verify actual
tool access and the target before writing. A user saying "connected" is not tool evidence.
Never ask for a Notion password or token.
Receipt Number,Receipt Date,Received From,Receipt Mode,Cash/Bank Account,Reference (Cheque/UTR/ID),Gross Amount Received,Receipt Type,Treats as Sale Income,Sales Invoice Allocated,Amount Allocated,Unapplied Amount,Adjust Against,TDS Collected on Receipt,Voucher Number,Ledger Account,Source Document,Reconciliation Status,Prepared By,Verified By,Entry Verified,Notes,Receipt ID
RCP-2026-0312,2026-08-19,Greyson Foods,Bank,HDFC Current ****0042,UTR-2026-0819,140000.00,Receivable Collection,No,SAL-2026-0033,130712.40,9287.60,Customer Advance - Greyson Foods,1307.12,VCH-2026-1027,Bank - HDFC Current,DOC-2026-0461,Unreconciled,Ananya Rao,Sneha Iyer,In progress,"Part collected against INV-2026-0733; TDS of 1307.12 remitted from this receipt; balance held as advance, not income.",
CREATE TABLE receipt_accounting (
receipt_number VARCHAR(255),
receipt_date DATE NOT NULL,
received_from VARCHAR(255),
receipt_mode VARCHAR(100) NOT NULL,
cash_bank_account VARCHAR(255),
reference_cheque_utr_id VARCHAR(255),
gross_amount_received NUMERIC(14,2) NOT NULL,
receipt_type VARCHAR(100) NOT NULL,
treats_as_sale_income VARCHAR(100) NOT NULL,
sales_invoice_allocated VARCHAR(255), -- relation -> target record
amount_allocated NUMERIC(14,2) NOT NULL,
unapplied_amount NUMERIC(14,2) NOT NULL,
adjust_against VARCHAR(255),
tds_collected_on_receipt NUMERIC(14,2) NOT NULL,
voucher_number VARCHAR(255),
ledger_account VARCHAR(255),
source_document VARCHAR(255), -- relation -> target record
reconciliation_status VARCHAR(100) NOT NULL,
prepared_by VARCHAR(255),
verified_by VARCHAR(255),
entry_verified VARCHAR(100) NOT NULL,
notes TEXT,
receipt_id SERIAL PRIMARY KEY,
created_at TIMESTAMP DEFAULT NOW(),
updated_at TIMESTAMP DEFAULT NOW()
);
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"title": "Receipt Accounting",
"type": "object",
"additionalProperties": false,
"properties": {
"Receipt Number": { "type": "string" },
"Receipt Date": { "type": "string", "format": "date" },
"Received From": { "type": "string" },
"Receipt Mode": { "type": "string" },
"Cash/Bank Account": { "type": "string" },
"Reference (Cheque/UTR/ID)": { "type": "string" },
"Gross Amount Received": { "type": "number" },
"Receipt Type": { "type": "string" },
"Treats as Sale Income": { "type": "string" },
"Sales Invoice Allocated": { "type": "string" },
"Amount Allocated": { "type": "number" },
"Unapplied Amount": { "type": "number" },
"Adjust Against": { "type": "string" },
"TDS Collected on Receipt": { "type": "number" },
"Voucher Number": { "type": "string" },
"Ledger Account": { "type": "string" },
"Source Document": { "type": "string" },
"Reconciliation Status": { "type": "string" },
"Prepared By": { "type": "string" },
"Verified By": { "type": "string" },
"Entry Verified": { "type": "string" },
"Notes": { "type": "string" },
"Receipt ID": { "type": "integer" }
},
"required": [
"Receipt Date",
"Receipt Mode",
"Gross Amount Received",
"Receipt Type",
"Treats as Sale Income",
"Amount Allocated",
"Unapplied Amount",
"TDS Collected on Receipt",
"Reconciliation Status",
"Entry Verified"
]
}
| CSV column | Notion property | Set after import |
|---|---|---|
| Receipt Number | Title | Use as the database title |
| Receipt Date | Date | Convert to Date |
| Received From | Text | Leave as Text |
| Receipt Mode | Select (add options after import) | Convert to Select, add options: "Cash", "Bank", "Cheque", "Fonepay/QR", "Other Digital Payment" |
| Cash/Bank Account | Text | Leave as Text |
| Reference (Cheque/UTR/ID) | Text | Leave as Text |
| Gross Amount Received | Number (format: currency) | Convert to Number, set format to Currency |
| Receipt Type | Select (add options after import) | Convert to Select, add options: "Sale Collection", "Receivable Collection", "Advance from Customer", "Loan Received", "Capital Contribution", "Other" |
| Treats as Sale Income | Select (add options after import) | Convert to Select, add options: "Yes", "No" |
| Sales Invoice Allocated | Relation (link to the target database) | Convert to Relation, link to the target database |
| Amount Allocated | Number (format: currency) | Convert to Number, set format to Currency |
| Unapplied Amount | Number (format: currency) | Convert to Number, set format to Currency |
| Adjust Against | Text | Leave as Text |
| TDS Collected on Receipt | Number (format: currency) | Convert to Number, set format to Currency |
| Voucher Number | Text | Leave as Text |
| Ledger Account | Text | Leave as Text |
| Source Document | Relation (link to the target database) | Convert to Relation, link to the target database |
| Reconciliation Status | Select (add options after import) | Convert to Select, add options: "Unreconciled", "Reconciled", "Difference" |
| Prepared By | Text | Leave as Text |
| Verified By | Text | Leave as Text |
| Entry Verified | Select (add options after import) | Convert to Select, add options: "Not started", "In progress", "Blocked", "Done", "Cancelled" |
| Notes | Text | Leave as Text |
| Receipt ID | Text (preserve source ID) | Keep imported IDs as Text; optionally add a separate Unique ID property |
The rows above are documentation examples only. Emit empty templates unless the user explicitly requests examples. Money stays currency, dates stay date, and anything pointing at another table stays relation.
| # | Field | Type | SQL | JSON Schema | Notion | CSV example |
|---|---|---|---|---|---|---|
| 1 | Receipt Number | text | VARCHAR(255) | string | Text | RCP-2026-0312 |
| 2 | Receipt Date | date | DATE | string, format: date | Date | 2026-08-19 |
| 3 | Received From | text | VARCHAR(255) | string | Text | Greyson Foods |
| 4 | Receipt Mode | select | VARCHAR(100) | string | Select (add options after import) | Bank |
| 5 | Cash/Bank Account | text | VARCHAR(255) | string | Text | HDFC Current ****0042 |
| 6 | Reference (Cheque/UTR/ID) | text | VARCHAR(255) | string | Text | UTR-2026-0819 |
| 7 | Gross Amount Received | currency | NUMERIC(14,2) | number | Number (format: currency) | 140000.00 |
| 8 | Receipt Type | select | VARCHAR(100) | string | Select (add options after import) | Receivable Collection |
| 9 | Treats as Sale Income | select | VARCHAR(100) | string | Select (add options after import) | No |
| 10 | Sales Invoice Allocated | relation | VARCHAR(255) | string | Relation (link to the target database) | SAL-2026-0033 |
| 11 | Amount Allocated | currency | NUMERIC(14,2) | number | Number (format: currency) | 130712.40 |
| 12 | Unapplied Amount | currency | NUMERIC(14,2) | number | Number (format: currency) | 9287.60 |
| 13 | Adjust Against | text | VARCHAR(255) | string | Text | Customer Advance - Greyson Foods |
| 14 | TDS Collected on Receipt | currency | NUMERIC(14,2) | number | Number (format: currency) | 1307.12 |
| 15 | Voucher Number | text | VARCHAR(255) | string | Text | VCH-2026-1027 |
| 16 | Ledger Account | text | VARCHAR(255) | string | Text | Bank - HDFC Current |
| 17 | Source Document | relation | VARCHAR(255) | string | Relation (link to the target database) | DOC-2026-0461 |
| 18 | Reconciliation Status | select | VARCHAR(100) | string | Select (add options after import) | Unreconciled |
| 19 | Prepared By | text | VARCHAR(255) | string | Text | Ananya Rao |
| 20 | Verified By | text | VARCHAR(255) | string | Text | Sneha Iyer |
| 21 | Entry Verified | select | VARCHAR(100) | string | Select (add options after import) | In progress |
| 22 | Notes | long_text | TEXT | string | Text | Part collected against INV-2026-0733; TDS of 1307.12 remitted from this receipt; balance held as advance, not income. |
| 23 | Receipt ID | id | SERIAL PRIMARY KEY | integer | Text (preserve source ID) | (blank) |
Receipt Mode
Cash | Bank | Cheque | Fonepay/QR | Other Digital Payment
Receipt Type
Sale Collection | Receivable Collection | Advance from Customer | Loan Received | Capital Contribution | Other
Treats as Sale Income
Yes | No
Reconciliation Status
Unreconciled | Reconciled | Difference
Entry Verified
Not started | In progress | Blocked | Done | Cancelled
Link fields: Sales Invoice Allocated, Source Document
Sales Invoice Allocated points at the sales book, so the receipt and the invoice it
clears can be read side by side. Source Document points at the filing register, so the
bank advice or receipt voucher is one lookup away. Neither link substitutes for
Receipt Type - a receipt can be fully allocated and still be an advance.
Prompt
Money comes in and we post all of it as sales. At month end the numbers never agree
with the bank.
Context first - one question per message, nothing already answered:
Q: How many receipts in a month? A: About forty.
Q: Cash, bank, digital? A: Mostly bank. Some Fonepay.
Q: Do you allocate receipts to invoices? A: Sometimes. The rest we just leave.
Recommended next step - offered, not built:
One receipt record carrying the mode, the gross received, the receipt type, the invoice it clears and the unapplied balance, and post it to income only when the type says it is a sale.
Workflow: Money received → Mode and source recorded → Typed as collection, advance, loan or capital → Allocated to an invoice or held unapplied → Reconciled to bank or cash
Want the CSV, SQL, JSON Schema and Notion mapping for this?
Receipt Type
first, then Treats as Sale Income, then allocate.TDS Collected on Receipt is a slice of the money received, not an addition to it. It is
the part of the allocation that is remitted to the government, so gross received still
equals amount allocated plus unapplied amount.Cash/Bank Account masked - the bank and the last four digits is all a register
needs, and the full number is what turns a register into a target.relation for anything that points at another table, text only for free text.currency, never text. Dates are date, never free text.Receipt Type and Treats as Sale Income are fields, not assumptions. Fill
them before the entry, not at month end.Unapplied Amount and carry it forward until it is identified.Receipt Mode is required; a receipt with no mode cannot be reconciled.Sales Invoice Allocated.Source Document target.TDS Collected on Receipt through to the return.I want to set up receipt accounting - every rupee received, its mode, its type, its
allocation against an invoice and its reconciliation to cash or bank - for my company.
Ask me one short question at a time, and only about what I have not already told you.
Then recommend the smallest setup that fits, and wait for me to ask before you build it.
When I ask, output CSV, SQL DDL, JSON Schema and a Notion property mapping. Data only.