Agent skill

Beancount Import

by bex-co in bex-co/beancount-io

Import a bank or card CSV, OFX/QFX, or QIF export into an existing Beancount ledger.

MITAuto-check passedBusiness, Finance & HR

Install Beancount Import

skills CLI
$ npx skills add bex-co/beancount-io --skill beancount-import -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install bex-co/beancount-io beancount-import --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/bex-co/beancount-io.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/.claude/skills/beancount-import .claude/skills/beancount-import && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
beancount-import
GitHub stars
296
Token cost
~3k tokens
SKILL.md length
1,358 words
Files
22 (incl. references)
Skills in repo
27
Repo updated
First seen
Licence
MIT

At a glance

Import a bank or card CSV, OFX/QFX, or QIF export into an existing Beancount ledger.

  • Works in 7 steps: Discover → Normalize → Stage → …
  • Recording an export
  • SKILL.md covers Prefer bea, Scope — what this skill does…, Workflow and What NOT to do
  • Instructions only: no scripts, shell commands, URLs or credentials in SKILL.md

What it does

Beancount Import is an agent skill from bex-co/beancount-io. Import a bank or card CSV, OFX/QFX, or QIF export into an existing Beancount ledger. Normalize signs, suggest categories from existing accounts, review duplicates and confirm before writing through bea. Use for recording an export; skip statement reconciliation, full finance-app migrations, reusable importer authoring, and individual options trades.

Its SKILL.md is about 3k tokens, which your agent loads only when the skill is triggered. The skill folder holds 24 other files, including reference files (for example `evals/evals.json` and `references/bea-import.md`).

It sits in Business, Finance & HR, covering Accounting and bookkeeping and CSV and tabular files. The repository describes itself as: 💰 Double-entry bookkeeping made easy — plain-text accounting for humans and AI agents. Polished iOS & Android app built with React Native + Expo. The licence is MIT.

When your agent uses it

  • Recording an export
  • Skip statement reconciliation
  • Full finance-app migrations
  • Reusable importer authoring

Example prompts

  • “/beancount-import”

Workflow steps

7 steps, taken from the step headings in SKILL.md.

  1. Discover
  2. Normalize
  3. Stage
  4. Dedup
  5. Suggest
  6. Confirm
  7. Write + Verify

What it can do on your machine

Read from SKILL.md and the folder at commit 5614bc7. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    No scripts in the folder and no shell commands in SKILL.md (its code samples are bash).

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Beancount Import loads about 3k tokens when it runs, and up to ~9k if it reads all its reference files. Until then it costs about 92 tokens; SKILL.md has 1,358 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~92
When it runs · the whole SKILL.md, loaded when a task matches
~3k
With references · SKILL.md plus every file in references/, read only if the agent opens them
~9k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from bex-co/beancount-io at commit 5614bc7, republished under its MIT licence (© bex-co). 1,358 words, ~3,049 tokens.

Download SKILL.mdSave it as .claude/skills/beancount-import/SKILL.md (or your agent's skills folder). This skill also uses 21 other files; get the full folder from GitHub.
name
beancount-import
description
Import a bank or card CSV, OFX/QFX, or QIF export into an existing Beancount ledger. Normalize signs, suggest categories from existing accounts, review duplicates and confirm before writing through bea. Use for recording an export; skip statement reconciliation, full finance-app migrations, reusable importer authoring, and individual options trades.

beancount-import

Turn a bank/card export file into categorized, deduplicated ledger entries — staged first, written only after explicit confirmation, idempotent on re-import.

This skill exists because the weekly export-to-ledger chore has three silent failure modes: a flipped sign convention corrupts every amount, a re-imported file double-books everything, and a guessed category buries mistakes the user won't find until tax time. The skill defuses all three the same way: it never guesses (ask once, persist the answer), it stamps every entry with an import-id so re-imports are no-ops, and it only ever suggests accounts that already exist in the ledger.

Prefer bea

Read beancount-init's references/bea-cli.md before running ledger commands: it defines explicit root/destination paths, JSON batches, checks, and safe retries. Without bea, use beancount-init's references/compatibility.md.

  • CSV the mapper can represent: read references/bea-import.md. Pass the confirmed sign, mapping, account, rules and destination on every preview and apply. Keep rules in the ledger repository after confirmation. Run the additional ±3-day manual-entry duplicate review; CLI duplicate detection alone does not cover it.
  • OFX/QIF or unsupported CSV semantics: run the normalization, dedup, suggestion and confirmation stages below, then use the shared JSON batch recipe, preserving import-id and flags. This also handles mixed per-row duplicate decisions that a single --duplicates policy cannot express.
  • Tested Beangulp workflows: enable with bea engine enable beangulp (requires system libmagic), then bea ingest identify|extract|archive with the actual runner supplied via --config. Ordinary CSV needs no Beangulp.

The agent interprets the source and reviews the rows; bea validates and writes the approved directives. Do not append directive text on this path.

Scope — what this skill does and does not touch

Does: parse one export file per run; stage, dedup, and categorize its rows; append confirmed transactions (with import-id metadata) and any needed open directives to one existing file.

Does not: edit or delete existing entries; create the target file (it must already exist and be reachable from the main file — a file nothing includes silently swallows entries); fetch data from banks (see references/getting-data.md for how users export, incl. SimpleFIN); reconcile balances (that is beancount-reconcile — suggest running it after a large import); touch option, plugin, or include directives.

Read references/formats.md before parsing any new or format-changed source (repeat imports with a stored config stanza apply the stored mapping directly) and references/dedup.md before the dedup pass. Both encode edge cases that are easy to get wrong.

Workflow

Seven stages, in order: Discover → Normalize → Stage → Dedup → Suggest → Confirm → Write + Verify.

1. Discover

Find beancount files in the working directory:

bash
fd -e beancount -e bean . | head -20
# fallback: find . -maxdepth 4 \( -name '*.beancount' -o -name '*.bean' \)

The "main" file has option/plugin/include directives at the top, or is the largest with open directives. Then establish:

  • Source account — which open account this export belongs to (e.g. Assets:Bank:Checking, Liabilities:CreditCard:Amex). Map from the user's words or the file's contents; if ambiguous, ask — never guess which account an export feeds.
  • Config block — for every source, including CSV through bea, a comment block at the top of the main file starting with ;; beancount-import config. It records, per source, everything learned on the first import so repeat imports ask zero questions. Re-read it rather than re-detecting.
  • Append target — the file where this account's transactions live (main file or an included sub-file, possibly year-bucketed). It must already exist.
  • Payee history — the ledger's existing payee→account patterns (the Suggest stage's training data).

Config block format — one source stanza per export source:

;; beancount-import config
;; source: chase-checking
;;   account: Assets:Bank:Checking
;;   format: csv  columns: date=1,desc=2,amount=3  date_format: MDY  sign: negative=outflow
;;   append_target: ./transactions/2026.beancount
;;   imports: 3
;; source: amex-card
;;   account: Liabilities:CreditCard:Amex
;;   format: csv  columns: date=1,desc=2,debit=3,credit=4  date_format: MDY  sign: debit=outflow
;;   append_target: ./transactions/2026.beancount
;;   imports: 1
;; source: other-bank
;;   account: Assets:Bank:Savings
;;   format: csv  columns: date=1,desc=2,amount=3,type=4  date_format: MDY  sign: type=D|W=outflow,C=inflow
;;   append_target: ./transactions/2026.beancount
;;   imports: 1

Bump imports: only when entries are written (a fully-deduped no-op changes nothing). For sources requiring custom normalization, when it reaches 3+, suggest once: "you've imported this source N times — want me to codify it as a tested beangulp importer via beancount-importer-author?" Simple CSV mappings already provide repeatable imports and need no graduation nudge. For CSV, also record the exact csv_mapping: including sign=bank|ledger, date_format: as a strptime format, and durable rules: path. These supplement the human-readable source settings; bea's cache does not preserve sign.

2. Normalize

Turn the file into normalized rows: date, amount (ledger sign), payee/description, pending?, native-id?. Read references/formats.md first. In brief:

  • Detect CSV vs OFX vs QIF. OFX rows carry a FITID (the native ID — feeds dedup); CSV/QIF usually don't.
  • First time seeing a source: propose the column mapping, confirm it with the user, persist it after the write confirmation to the config block. Repeat imports: apply the stored mapping silently.
  • Map amounts to the ledger's sign convention for the source account — the full sign rules live in references/formats.md (canonical; same convention as beancount-reconcile). Debit/credit split columns, all-positive amounts with a type column, DMY vs MDY — when ambiguous, ask, never guess. A wrong guess here corrupts every row.
3. Stage

Build candidate transactions in memory — nothing touches the ledger yet. One candidate per normalized row: date, flag (! if the source marks it pending, else *), payee, source-account posting at the exact row amount, counter-account left for Suggest, import-id computed per references/dedup.md.

Show full SKILL.md (568 more words)Show less
4. Dedup

Read references/dedup.md first. Two layers, in order:

  1. Exact — scan existing entries for import-id metadata matching a candidate's ID. Match → drop the candidate, count it as already imported.
  2. Fuzzy — for surviving candidates, look for existing entries without import-id metadata (manual or pre-convention entries) posting the same amount to the source account within ±3 days with a similar description. Each hit becomes a suspected duplicate: shown in the review table for the user to decide keep/skip — never silently skipped, never silently double-entered.

Use the same confirmed sign, account, and source identities on every run. Exact reimports yield zero new entries; unresolved or previously skipped fuzzy matches still need review. Read references/bea-import.md before treating a CLI preview as complete deduplication.

5. Suggest

Categorize each candidate's counter-account from the ledger's own history. Read references/categorization.md first. The hard rules:

  • The candidate set is exactly the accounts already opened in the ledger. Never invent an account, however plausible.
  • Confident prior for the payee → reuse it, cite it as the reason. No confident prior → Expenses:Uncategorized (propose its open if missing) and flag for refinement.
  • Every suggestion carries a confidence (high / medium / low) and a one-line reason, shown in the review table.
6. Confirm

Show the user everything, then ask. Never write before an explicit yes.

Nothing to import (every row already imported, no suspected-duplicate decisions open): skip the review table and the yes/no prompt entirely — report the no-op ("4 already imported, 0 new — nothing to do") and write nothing, not even the config block.

  1. Target file — one explicit path.
  2. Summary counts — rows in file / already imported (skipped) / suspected duplicates (awaiting decision) / to import.
  3. Suspected duplicates — each with the existing entry it may duplicate; ask keep or skip.
  4. New open directives — only if needed (typically Expenses:Uncategorized).
  5. Review table — one line per candidate: date, payee, amount, suggested account, confidence, reason.
  6. A clear yes/no prompt; on partial disagreement, let the user correct specific rows and re-present.

Example:

Target file: ./transactions/2026.beancount
Source: chase-checking → Assets:Bank:Checking (May 2026 export, 12 rows)

Already imported (skipped):  4
Suspected duplicates:        1   → 2026-05-03 "ACME REFUND" 25.00 may duplicate the manual
                                   entry dated 2026-05-04 — import anyway, or skip? (skip/import)
To import:                   7

New account opens:
2026-05-01 open Expenses:Uncategorized

| date       | payee              | amount  | account                  | conf | reason                     |
|------------|--------------------|---------|--------------------------|------|----------------------------|
| 2026-05-07 | TRADER JOES #123   | -54.20  | Expenses:Food:Groceries  | high | 6 prior TRADER JOES entries|
| 2026-05-22 | CITY PARKING AUTH  | -12.00  | Expenses:Uncategorized   | low  | no prior match — refine    |
| …          |                    |         |                          |      |                            |

Append these 7 transactions to ./transactions/2026.beancount? (yes/no)
7. Write + Verify

After the user's yes:

  1. Create the approved durable rules file and open any approved missing accounts using the shared root-scoped add open recipe.
  2. Re-preview CSV with the complete confirmed options and final rules path. Apply using references/bea-import.md, or write the approved normalized batch with the shared add transactions recipe and explicit --into. Preserve every external row's import-id; batch writes do not deduplicate.
  3. Update only the reviewed config comment block, then run bea --file "$ledger" --json --no-input check on the root.

On success report imported/skipped counts, duplicate decisions, and flagged uncategorized rows. Suggest beancount-reconcile after a large import. On failure surface the exact error and any earlier successful steps. Inspect current IDs before retrying; a failed assertion or later command does not undo a successful transaction batch. Never report an unvalidated success.

The no-bea write/check procedure is in beancount-init's references/compatibility.md; keep the same proposal and dedup semantics.

What NOT to do

  • Don't write anything without an explicit yes, and never to a file that doesn't already exist.
  • Don't guess column semantics, sign conventions, or date formats — ask once, persist to the config block.
  • Don't invent account names — existing accounts or Expenses:Uncategorized, nothing else.
  • Don't silently skip or silently import a suspected duplicate — the user decides.
  • Don't edit existing entries, and don't import the same file's rows twice (import-id is the guarantee).
  • Don't reconcile, migrate full SaaS history, or build reusable importers — route to beancount-reconcile, beancount-migrate, beancount-importer-author.

© bex-co, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 21 other files (references) in skills/.claude/skills/beancount-import of bex-co/beancount-io.

  • SKILL.md
  • evals/evals.json
  • evals/files/eval11_export.csv
  • evals/files/eval12_export.csv
  • evals/files/eval1_export.csv
  • evals/files/eval1_ledger.beancount
  • evals/files/eval2_export.csv
  • evals/files/eval2_ledger.beancount
  • evals/files/eval3_export.ofx
  • evals/files/eval3_ledger.beancount
  • evals/files/eval4_export.ofx
  • evals/files/eval4_ledger.beancount
  • evals/files/eval5_export.csv
  • evals/files/eval5_ledger.beancount
  • evals/files/eval6_export.csv
  • evals/files/eval6_ledger.beancount
  • evals/files/eval9_ledger.beancount
  • references/bea-import.md
  • … and 4 more

Open the folder on GitHubat commit 5614bc7

Compare with similar skills

Beancount Import next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Beancount Import compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Beancount Import this skillbex-co/beancount-io296—~3kAutomated safety check: PassMIT
Journalkazukinagata/shinkoku365—~2.3kAutomated safety check: PassMIT
Mx Macro Datahiboys/ExploreFinance364—~1.7kAutomated safety check: PassNone
Map Tokenreportazalio/map-framework156—~2.5kAutomated safety check: PassMIT
Remofirst Local Dev Loopjeremylongshore/tons-of-skills-marketplace2.8k—~1.1kAutomated safety check: PassMIT
Remofirst Upgrade Migrationjeremylongshore/tons-of-skills-marketplace2.8k—~1.2kAutomated safety check: PassMIT

Similar skills

  • Journal

    kazukinagata/shinkoku

    This skill should be used when the user wants to record bookkeeping entries (仕訳), import transaction data from CSV files, receipts, or invoices, or manage their general ledger.

    365 GitHub stars~2.3k tokensUpdated 1 mo ago
    Business, Finance & HRAuto-check passed
  • Mx Macro Data

    hiboys/ExploreFinance

    基于东方财富数据库,支持自然语言查询全球宏观经济数据,涵盖国民经济核算、价格指数、货币金融、财政收支、对外贸易、就业民生、产业运行等多个领域,适配各类宏观经济研究、市场分析、政策解读等多元专业场景需求。返回结果包含数据说明及 csv 文件。Natural language query for macroeconomic data from financial databases…

    364 GitHub stars~1.7k tokensUpdated 3 mo ago
    Business, Finance & HRAuto-check passed
  • Map Tokenreport

    azalio/map-framework

    Show per-subtask/agent token accounting (input, output, cache read/creation, cost, cache-hit ratio) for the current branch.

    156 GitHub stars~2.5k tokensUpdated 2 days ago
    Business, Finance & HRAuto-check passed
  • Remofirst Local Dev Loop

    jeremylongshore/tons-of-skills-marketplace

    Rehearse RemoFirst imports, report reconciliation, and operator controls offline with synthetic fixtures before touching a client account.

    2.8k GitHub stars~1.1k tokensUpdated yesterday
    Business, Finance & HRAuto-check passed
  • Remofirst Upgrade Migration

    jeremylongshore/tons-of-skills-marketplace

    Control a RemoFirst workflow cutover to supported Workday, ADP, report, or CSV exchange with reconciliation and rollback.

    2.8k GitHub stars~1.2k tokensUpdated yesterday
    Business, Finance & HRAuto-check passed
  • Webflow Migration Deep Dive

    jeremylongshore/tons-of-skills-marketplace

    Migrate external or cross-site content into Webflow CMS with schema mapping, staged batches, reconciliation, and controlled publication.

    2.8k GitHub stars~1.2k tokensUpdated yesterday
    Business, Finance & HRAuto-check passed

More from bex-co/beancount-io

All 27 skills in this repo
  • Beancount Close

    bex-co/beancount-io

    Close an accounting period in a Beancount ledger by reconciling each active account through beancount-reconcile, checking assertions and recurring gaps, reviewing flags, then proposing a commit with…

    296 GitHub stars~1.4k tokensUpdated today
    Auto-check passed
  • Beancount Importer Author

    bex-co/beancount-io

    Write or repair a reusable Beangulp importer from a sample bank export, with reviewed golden files and a passing test harness.

    296 GitHub stars~2k tokensUpdated today
    Auto-check passed
  • Beancount Init

    bex-co/beancount-io

    Scaffold a new Beancount ledger with bea init and validation, with optional Fava browser setup when requested.

    296 GitHub stars~1.2k tokensUpdated today
    Auto-check: notes
  • Beancount Options

    bex-co/beancount-io

    Record a described options trade or lifecycle event as validated Beancount transactions through bea, after review and confirmation.

    296 GitHub stars~3.7k tokensUpdated today
    Auto-check passed
  • Beancount Reconcile

    bex-co/beancount-io

    Reconcile one Beancount account against a CSV statement or pasted PDF text.

    296 GitHub stars~4.1k tokensUpdated today
    Auto-check passed
  • Mobile Release

    bex-co/beancount-io

    Summarize mobile changes since the previous release, bump the Beancount mobile version, prepare localized release notes and listings, and release to the Apple App Store and Google Play.

    296 GitHub stars~3.5k tokensUpdated today
    Auto-check passed

Questions about Beancount Import

What does Beancount Import do?

Import a bank or card CSV, OFX/QFX, or QIF export into an existing Beancount ledger. Beancount Import is an agent skill from bex-co/beancount-io. Import a bank or card CSV, OFX/QFX, or QIF export into an existing Beancount ledger.

When should I use Beancount Import?

Beancount Import fits situations like: recording an export; skip statement reconciliation; full finance-app migrations; reusable importer authoring.

How do I install Beancount Import in Claude Code?

Run `npx skills add bex-co/beancount-io --skill beancount-import -a claude-code`. Or copy the skill folder (skills/.claude/skills/beancount-import in bex-co/beancount-io) into .claude/skills/beancount-import in your project. Claude Code loads it when a task matches its description.

How do I install Beancount Import in Codex?

Run `npx skills add bex-co/beancount-io --skill beancount-import -a codex`. Or copy the skill folder (skills/.claude/skills/beancount-import in bex-co/beancount-io) into .agents/skills/beancount-import in your project. Codex loads it when a task matches its description.

Can I use Beancount Import in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add bex-co/beancount-io --skill beancount-import -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/beancount-import, .gemini/skills/beancount-import, .github/skills/beancount-import and .opencode/skills/beancount-import in your project.

What does Beancount Import need to run?

SKILL.md names no scripts, command-line tools or credentials: Beancount Import is instructions for the agent only.

Does Beancount Import access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Beancount Import safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Beancount Import use?

Beancount Import is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Beancount Import use?

About 3k tokens (SKILL.md is roughly 12k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 6k tokens, read only when the agent opens those files.

What are the alternatives to Beancount Import?

Skills that share tags, products or a category with Beancount Import: Journal (kazukinagata/shinkoku, 365 stars), Mx Macro Data (hiboys/ExploreFinance, 364 stars), Map Tokenreport (azalio/map-framework, 156 stars) and Remofirst Local Dev Loop (jeremylongshore/tons-of-skills-marketplace, 2.8k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Beancount Import?

bex-co (a GitHub organization) maintains it in bex-co/beancount-io, which has 296 GitHub stars. The repository holds 27 skills in this directory. The repository was last updated on October 9, 2026.

Source: bex-co/beancount-io on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.