Tax deduction automation for Australian households
Project description
taxing
Tax deduction automation for Australian households.
Ingests bank & trading platform data, classifies transactions, calculates deductions, and optimizes capital gains sequencing across tax brackets.
Quick Start
# Test
just test
# Lint + format
just lint
just format
# Full CI
just ci
Structure
src/
core/ Pure domain logic (classify, deduce, capital gains)
io/ I/O adapters (bank converters, ingest, persist)
pipeline.py Orchestration (ingest → classify → deduce)
cli/ CLI entry points
docs/
context.md Active session entry point
architecture.md Deep design reference (principles, patterns, data flow)
phase_2b_design.md Phase 2b bracket-aware sequencing design
TAX_OG_PORTING_ANALYSIS.md Feature comparison with tax-og
rules/
*.txt Rule files for classification (54 categories)
tests/
unit/ Pure logic tests
integration/ Full pipeline tests
Architecture
Phase 1 (complete): Transaction pipeline
- Ingest: Multi-bank support (ANZ, CBA, Beem, Wise)
- Classify: Rule-based categorization (54 categories)
- Deduce: Percentage-based deductions
- Persist: CSV outputs (transactions, deductions, summary)
- Status: 114 tests, zero lint
Phase 2a (complete): Capital gains core
- FIFO with loss harvesting prioritization
- CGT discount (50% for holdings >365 days)
- Trade ingestion (ingest_trades, ingest_trades_dir)
- Integrated into pipeline
- Status: 29 tests, parity validated vs tax-og
Phase 2b (complete): Bracket-aware deduction optimizer
- Greedy algorithm: allocate to lowest-bracket persons first
- CLI:
taxing optimize --fy 25 --persons alice,bob - Reads Phase 1 outputs (deductions per person)
- Pools and optimally allocates to minimize total tax
- See
docs/phase_2b_cli.md - Status: 8 tests
Phase 3a (complete): Property expense aggregator
- Aggregates rent, water, council, strata from CSV files
- CLI:
taxing property --fy 25 --person alice - PropertyExpensesSummary with category totals
- See
docs/phase_3a_property.md - Status: 19 tests
Phase 3b (complete): Holdings model
- Ticker, units, cost_basis, current_price
- Current value & unrealized gain properties
- Load from holdings.csv
- Supports fractional & large positions
- Status: 18 tests
Phase 2c (complete): Multi-year capital gains planning
- Loss carryforward tracking indefinitely across years
- Realize gains in lowest-bracket years first
- Harvest losses to offset current & future gains
- CLI:
taxing gains-plan --projection 25:30%,26:45% --gains [...] --losses [...] - Status: 18 tests, 205 tests total
Data Model
Money(amount: Decimal, currency: Currency)
Transaction(date, amount, description, source_bank, source_person, category?, is_transfer?)
Trade(date, code, action, units, price, fee, source_person)
Gain(fy, raw_profit, taxable_gain, action)
Type-safe, immutable, no silent bugs. See docs/architecture.md for full details.
Design Principles
- Pure functions: No side effects, testable without I/O
- Immutability: Frozen dataclasses, prevents accidental mutations
- Contracts: Protocols define behavior, tests verify compliance
- No globals: Config passed as arguments
- Agent-friendly: Modular, type-hinted, well-tested
Next Steps
- Phase 3c: Rental income + depreciation tracking
- Phase 2d: Advanced constraints (Medicare Levy, HELP, ILP)
- Phase 3d: Portfolio rebalancing optimization
See docs/context.md for quick reference, docs/architecture.md for deep design.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file taxing-0.1.0.tar.gz.
File metadata
- Download URL: taxing-0.1.0.tar.gz
- Upload date:
- Size: 37.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/2.1.3 CPython/3.12.10 Darwin/24.5.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c707055851d233267ba1908c0cfe35c29601aa2a180415f09ea4f41590c77cc3
|
|
| MD5 |
4cb12fb703925c4849f932000821daf7
|
|
| BLAKE2b-256 |
44e8c05b6a2b238f6f7478fc999b68806cad7b5e19d40077dd7076eb8c7ff328
|
File details
Details for the file taxing-0.1.0-py3-none-any.whl.
File metadata
- Download URL: taxing-0.1.0-py3-none-any.whl
- Upload date:
- Size: 53.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/2.1.3 CPython/3.12.10 Darwin/24.5.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0effbe965d404a84ae58b3204290fe0074e06abce8ba3de71801fa417435cd54
|
|
| MD5 |
ade0403fe051a29fcf9c471d9d8e1f0a
|
|
| BLAKE2b-256 |
84699d3d53ad4dbc17baef0c8b1fa6031d7c087150672b3684862c60940bc56d
|