export-beancount

export-beancount is a skill for Claude Code from cynco-labs/ai-accounting-skills. It costs 28 tokens per session (642 once invoked), scanned A, original, MIT.

A workflow for exporting balanced accounting journals into Beancount, a text-based bookkeeping ledger used as the official record of the accounts.

In plain words
What is it for?
Use it to create a final or provisional Beancount ledger from working-paper journals and a chart of accounts, with an optional balance check.
Why use it?
It keeps the final ledger consistent with the prepared journals and refuses to export entries whose debits and credits do not balance.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Needs its repository: it runs a file that does not travel with it, so clone the repository first. The line is python3 scripts/export_to_beancount.py \.

Part of the accounting-engagement plugin — 45 skills shipped together

Good fit Use it to create a final or provisional Beancount ledger from working-paper journals and a chart of accounts, with an optional balance check.

Compare 6 skills from other repositories ↓
Install

Getting it into your agent

It runs from inside its repository, so the clone comes first — what it calls does not travel with the file alone.

Clone the repo
git clone --depth 1 https://github.com/cynco-labs/ai-accounting-skills
agentmods
npx agentmods add skills/cynco-labs/ai-accounting-skills/export-beancount

Made for: Claude Code.

Or install accounting-engagement, the plugin that ships this one along with the rest of its 45 skills.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for export-beancount

README.md
[![agentmods](https://agentmods.dev/badge/skills/cynco-labs/ai-accounting-skills/export-beancount/github.svg)](https://agentmods.dev/skills/cynco-labs/ai-accounting-skills/export-beancount)
Your own site
<a href="https://agentmods.dev/skills/cynco-labs/ai-accounting-skills/export-beancount"><img src="https://agentmods.dev/badge/skills/cynco-labs/ai-accounting-skills/export-beancount/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for export-beancount

Your own site · 80×15
<a href="https://agentmods.dev/skills/cynco-labs/ai-accounting-skills/export-beancount"><img src="https://agentmods.dev/badge/skills/cynco-labs/ai-accounting-skills/export-beancount.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 28 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 642 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00028 $0.00642
Opus 5 $0.00014 $0.00321
Sonnet 5 $0.00006 $0.00128
Haiku 4.5 $0.00003 $0.00064

Measured 12d ago against content hash 5c0591a999c1, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-12, from the pricing page.

Security

Grade A, and why

export-beancount scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 12d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

accounting-engagement/skills/export-beancount/SKILL.md · 90 lines

How it starts

The opening of the file, as written. The whole thing — 90 lines — stays where its author put it; the contents beside it link to each section on GitHub.

/export-beancount

Purpose

Push final (or draft-marked) books into Beancount — the ledger system of record.

workpapers/journals*.json + COA → ledger/main.beancount → Fava

Excel remains human working papers. Beancount is where the ledger lives for agents and git.

Load: references/beancount_integration.md

When

Situation Output
QC passed / finalise done ledger/main.beancount
User wants mid-engagement preview ledger/draft.beancount (label provisional)
Unbalanced journals Refuse until fixed

Preconditions

  1. workpapers/journals.json exists (and journals_ye.json if YE posted)
  2. Prefer workpapers/coa.json or entity COA template
  3. Each JE: sum(debit) = sum(credit)
  4. pip install beancount recommended for --bean-check

Command

python3 scripts/export_to_beancount.py \
 --client-dir "<client_workspace>" \
 --output "<client_workspace>/ledger/main.beancount" \
 --bean-check

Or explicit paths:

python3 scripts/export_to_beancount.py \
 --journals workpapers/journals.json \
 --journals-ye workpapers/journals_ye.json \
 --coa references/coa_templates/coa_sdn_bhd.json \
 --currency MYR \
 --title "LEGAL NAME SDN. BHD." \
 --output ledger/main.beancount \
 --bean-check

What the exporter does

  1. Map COA codes → Beancount accounts (Assets:…, Liabilities:…, Equity:…, Income:…, Expenses:…)
  2. Emit open directives
  3. Emit one Beancount transaction per journal entry (DR +, CR −)
  4. Write *.account_map.json sidecar
  5. Optional bean-check

Completion

Done when: ledger/main.beancount written from balanced journals; refuse if any JE unbalanced.

Outputs

  • ledger/main.beancount (or draft path)
  • ledger/main.beancount.account_map.json
  • Update engagement_state.json: artifact beancount_ledger, stage note

Next

  • validate-beancount if check not run
  • open-fava to show the user

Failure modes

Issue Action
Unbalanced JE Stop; fix journals
bean-check fail Show stderr; fix mapping/dates
Missing beancount install pip install beancount fava once

Read the full file on GitHub · 90 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 12d ago First seen · 90 lines · 28 tokens per session scan A 5c0591a999c1

Subscribe to this mod's changes

export-beancount is a skill published in the GitHub repository cynco-labs/ai-accounting-skills (3 stars, last pushed 2mo ago), licensed MIT. It adds 28 tokens to every session and 642 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other skills, from other repositories

countbean-accounting

Rules for writing correct double-entry Beancount transactions when managing a Countbean cloud book — account naming, how to balance postings, categorisation, and safe ingestion. Use whenever recording, importing, or correcting financial data in a Countbean book.

CPUtester5465/countbean-plugin · 54 tokens

bookkeeping

Use when a small business needs audit-ready books — a chart of accounts, posting a transaction to the right account and side, clearing an uncategorized bank feed, cash vs accrual, or a ledger that won't tie to the bank. NOT interpreting the numbers — runway, burn, P&L cadence (that is finance-ops), NOT issuing…

ericrisco/rsc-harness · 84 tokens

jangbu-jongso

A Korean tax-document checklist generator for individuals, freelancers, sole-company owners, mixed earners, and certain business owners.

kimlawtech/korean-jangbu-for · 139 tokens

korean-jangbu-for

A Korean bookkeeping assistant for startups, freelancers, sole proprietors, and one-person companies. It processes financial files locally, helps classify transactions, and prepares accounting and tax outputs.

kimlawtech/korean-jangbu-for · 144 tokens

jangbu-import

A data-import workflow for turning bank files, card records, spreadsheets, receipts, tax invoices, and statement PDFs into a standard set of 13 transaction fields. OCR, or optical character recognition, is used to read information from document images and PDFs.

kimlawtech/korean-jangbu-for · 97 tokens

jangbu-connect

A setup guide for connecting Korean tax, bank, card, and social-insurance data through CODEF, an external API service. It explains how users obtain their own CODEF credentials and store them locally.

kimlawtech/korean-jangbu-for · 98 tokens