LedgerLou Docs is optimized for desktop.

Please open this page on a device with a wider screen.

Agent Guide

A standalone behavioural guide for AI agents working with LedgerLou over MCP. Drop the file into your agent’s context window — as CLAUDE.md, .cursorrules or in the system prompt — to enforce the accounting rules client-side.

Download

agent-guide.md (English)  |  agent-guide-german.md (German)

Ready to use. Drop it into your project root or agent configuration directory.

MCP resource

The guide is also available as an MCP resource. Clients with resources/read support can fetch it at runtime:

URI: ledgerlou://agent-guide      (English)
URI: ledgerlou://agent-guide/de   (Deutsch)
MIME: text/markdown

Skills vs this guide

Beyond this cross-cutting guide, the MCP server ships task-scoped playbooks as MCP prompts. The guide teaches how to behave (confirmations, account lookups, tax discipline); skills teach what to do for a specific workflow (close a month, process an invoice, reconcile a bank statement).

When to load each

  • Always load this guide — drop it in the system prompt so every turn respects the base rules.
  • Load a skill on demand — call prompts/list to discover available skills, then prompts/get before starting the matching workflow.
  • Scope-gated — a skill only appears in prompts/list when the caller holds all of its required scopes.
  • Locale-aware — the server auto-selects EN/DE from the tenant locale; agents can override with args.locale.

Built-in skills

  • process_incoming_invoice — AP workflow (OCR → vendor → expense account → tax scenario → booking → invoice record).
  • process_outgoing_invoice — AR workflow incl. credit notes.
  • reconcile_bank_transactionscandidate_kind semantics, splits, bulk + recovery.
  • tenant_setup_migration — new-tenant bootstrap + legacy migration (admin-only, requires config:write).

Clients without prompt support

If your client does not surface MCP prompts, fetch the skill markdown directly as a resource:

URI: ledgerlou://skills/process_incoming_invoice         (English)
URI: ledgerlou://skills/process_incoming_invoice/de      (Deutsch)
URI: ledgerlou://skills/process_outgoing_invoice[/de]
URI: ledgerlou://skills/reconcile_bank_transactions[/de]
URI: ledgerlou://skills/tenant_setup_migration[/de]
MIME: text/markdown

Both an English and a German variant are exposed per skill. The /de suffix returns the German playbook.

Usage examples

Claude CLAUDE.md

Drop the file as CLAUDE.md into the project root. Claude Code and Claude Desktop load it into the context automatically.

cp agent-guide.md ./CLAUDE.md
Cursor .cursorrules

Cursor loads .cursorrules from the project root as system-level instructions.

cp agent-guide.md ./.cursorrules
Custom System prompt

For custom agents or frameworks, embed the guide content in the system prompt or load it at runtime via the MCP resource URI.

const guide = await mcpClient.readResource("ledgerlou://agent-guide");
systemPrompt += guide.contents[0].text;

Why client-side prompting?

Server instructions alone are not enough
  • Not every MCP client surfaces server_instructions prominently — some clients ignore or deprioritise them, which reduces compliance.
  • Client-side context is always loaded — as CLAUDE.md, .cursorrules or in the system prompt, the rules are present from turn one.
  • Wider context — the guide explains what LedgerLou is, how German bookkeeping works, common mistakes and the domain vocabulary. Protocol-level instructions focus on tool-specific rules.
  • Redundancy improves compliance — repeating critical rules on both server and client reduces hallucinated account numbers, skipped confirmations and mis-handled tax treatment significantly.

Full guide

The complete guide is shown below. For the raw Markdown file, use the download link above.

Base rules

  1. Always confirm before writes — show a summary and wait for explicit approval.
  2. Always look up accounts — use search_accounts / list_accounts. Never guess account numbers.
  3. Always look up tax codes — call list_tax_codes. Never assume tax codes.
  4. Confirm tax treatment — show tax rate, classification, code and amounts. Mandatory.
  5. Read tools need no confirmation — query tools may be called freely.

Automatic tax lines

When tax_code is set on a posting line, LedgerLou creates the tax-account entries automatically. Provide only ledger-account lines with gross amounts. Never add manual tax lines (1406, 3806 etc.) alongside tax_code.

Key workflows

  • Incoming invoice: list_inbox_documents → list_vendors → create_vendor → search_accounts → confirm tax → post_booking → create_invoice → confirm_inbox_document → reconcile (open_liability)
  • Outgoing invoice: list_customers → create_customer → search_accounts → confirm tax → post_booking → create_outgoing_invoice → reconcile (open_receivable)
  • Credit note: post_booking (reversal) → create_outgoing_invoice (type=credit_note)

Bank reconciliation

Transaction typecandidate_kind
Vendor paymentopen_liability
Customer paymentopen_receivable
Fees, transfers, otherbank_booking

Common mistakes

  • Using bank_booking for vendor/customer payments (invoice stays permanently open)
  • Guessing account numbers instead of looking them up
  • Skipping tax confirmation
  • Using manual tax lines alongside tax_code
  • Reconciling before posting + invoice creation