Agent skill

Tax Liability Tracking

by agiprolabs in agiprolabs/claude-trading-skills

Real-time tax liability analysis for active crypto traders with proportional cost basis, gain classification, and tax-aware trading signals

MITAuto-check passedBusiness, Finance & HR

Install Tax Liability Tracking

skills CLI
$ npx skills add agiprolabs/claude-trading-skills --skill tax-liability-tracking -a claude-code

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

GitHub CLI
$ gh skill install agiprolabs/claude-trading-skills tax-liability-tracking --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/agiprolabs/claude-trading-skills.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/tax-liability-tracking .claude/skills/tax-liability-tracking && 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
tax-liability-tracking
GitHub stars
410
Token cost
~2.4k tokens
SKILL.md length
1,019 words
Files
3 (incl. scripts, references)
Skills in repo
68
Repo updated
First seen
Licence
MIT

At a glance

Real-time tax liability analysis for active crypto traders with proportional cost basis, gain classification, and tax-aware trading signals

  • Works in 6 steps: Day Trader Tax Tracking → Swing Trader with House-Money Plays → Long-Term Holder Monitoring → …
  • Tasks that involve Tax preparation
  • SKILL.md covers Why This Matters, Core Concepts, Capabilities and Prerequisites, plus 5 more sections
  • Runs Python scripts from its folder

What it does

Tax Liability Tracking is an agent skill from agiprolabs/claude-trading-skills. Real-time tax liability analysis for active crypto traders with proportional cost basis, gain classification, and tax-aware trading signals

Its SKILL.md is about 2.4k tokens, which your agent loads only when the skill is triggered. The skill folder holds 4 other files, including scripts and reference files (for example `references/planned_features.md` and `scripts/tax_tracker.py`).

It sits in Business, Finance & HR, covering Tax preparation and Trading and backtesting. The repository describes itself as: 68 trading, DeFi, and quantitative finance Agent Skills. Works with Claude Code, Cursor, Codex, Gemini CLI, and 30+ other tools. The licence is MIT.

When your agent uses it

  • Tasks that involve Tax preparation
  • Tasks that involve Trading and backtesting

Example prompts

  • “/tax-liability-tracking”

Requirements

  • Python 3

Workflow steps

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

  1. Day Trader Tax Tracking
  2. Swing Trader with House-Money Plays
  3. Long-Term Holder Monitoring
  4. Tax-Loss Harvesting
  5. Year-End Tax Planning
  6. Multi-Token Portfolio

What it can do on your machine

Read from SKILL.md and the folder at commit 981e1d7. 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

    Ships 1 file in scripts/ (Python), which the agent can run.

    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

Tax Liability Tracking loads about 2.4k tokens when it runs, and up to ~4k if it reads all its reference files. Until then it costs about 41 tokens; SKILL.md has 1,019 words of instructions outside code blocks.

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

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); the scripts in this folder are not scanned.

SKILL.md

The full file from agiprolabs/claude-trading-skills at commit 981e1d7, republished under its MIT licence (© agiprolabs). 1,019 words, ~2,375 tokens.

Download SKILL.mdSave it as .claude/skills/tax-liability-tracking/SKILL.md (or your agent's skills folder). This skill also uses 2 other files; get the full folder from GitHub.
name
tax-liability-tracking
description
Real-time tax liability analysis for active crypto traders with proportional cost basis, gain classification, and tax-aware trading signals
license
MIT
metadata.author
agipro
metadata.version
0.1.0
metadata.category
trading

Tax Liability Tracking

Real-time tax liability analysis purpose-built for active Solana traders. Track proportional cost basis across partial sells, classify realized vs unrealized gains, project quarterly tax obligations, and surface tax-aware signals that feed back into trading decisions.

Why This Matters

Active crypto traders generate hundreds of taxable events per year. Without real-time tracking:

  • You do not know your actual after-tax P&L until year-end
  • Partial sells (the "house money" play) create cost basis confusion
  • Short-term vs long-term classification shifts your effective tax rate by 15-20%
  • Tax-loss harvesting windows close without you noticing
  • Quarterly estimated payments become guesswork

This skill keeps a running tax ledger alongside your trading activity so every decision incorporates its tax consequence.

Core Concepts

Proportional Cost Basis for Partial Sells

This is the most critical concept. When you sell a portion of a position, the cost basis splits proportionally — it does not shift to zero for the remaining tokens.

Example — The Accumulate / House-Money Play:

  1. Buy: 1,000 tokens at $1.00 each. Total cost basis = $1,000.
  2. Partial sell: Sell 800 tokens at $1.25 each. Proceeds = $1,000.
  3. What happened:
    • The 800 sold tokens had proportional cost basis = 800 x $1.00 = $800
    • Realized gain on the sale = $1,000 - $800 = $200
    • The remaining 200 tokens retain cost basis = 200 x $1.00 = $200
    • The remaining tokens are NOT "free" — they carry their original per-unit cost

Common mistake: Recording the partial sell as "capital recovered, remaining basis = $0." This understates the realized gain on the partial sell and overstates the gain when the remaining tokens are eventually sold. The total tax owed is the same either way, but the timing and classification (short-term vs long-term) can differ significantly.

Gain Classification
ClassificationHolding PeriodUS Federal Rate (2024)
Short-term capital gain< 1 yearOrdinary income rate (10-37%)
Long-term capital gain>= 1 year0%, 15%, or 20%

Each tax lot tracks its own acquisition date. Partial sells consume lots in the order specified by your accounting method (FIFO, LIFO, or specific identification).

SOL-Denominated Trading with USD Reporting

Solana traders typically think in SOL but US tax obligations are denominated in USD. Every taxable event requires:

  1. SOL price at acquisition — establishes USD cost basis
  2. SOL price at disposition — establishes USD proceeds
  3. Token price in SOL at both events — converted to USD via SOL/USD rate

The skill tracks SOL/USD rates at each event timestamp to compute USD-denominated gains.

Realized vs Unrealized Gains
  • Realized: Position closed (fully or partially). Taxable event occurred.
  • Unrealized: Position still open. No tax event yet, but contributes to estimated liability if you plan to close before year-end.

The after-tax P&L view shows both, with unrealized gains marked at current estimated tax rates.

Capabilities

Tax Lot Tracking
  • Record buys, sells, and token-to-token swaps as taxable events
  • Maintain per-lot cost basis with acquisition date
  • Support FIFO, LIFO, and specific identification accounting methods
  • Handle partial sells with proportional cost basis allocation
Gain Classification Engine
  • Classify each realized gain as short-term or long-term
  • Track days remaining until long-term threshold for each open lot
  • Flag positions approaching the 1-year boundary
Quarterly Tax Projection
  • Estimate federal tax liability using progressive bracket rates
  • Include state tax estimate (configurable rate)
  • Project Q1-Q4 estimated payment amounts
  • Track cumulative realized gains by quarter
Tax-Aware Trading Signals
  • Long-term threshold alert: "Position crosses long-term threshold in N days"
  • Profit-taking cost: "Taking profit here triggers $X short-term liability"
  • Loss harvesting: "You have $X in unrealized losses available to harvest"
  • Timing value: "Selling now vs waiting 30 days saves $X in taxes"
  • Wash sale warning: "Repurchasing within 30 days may trigger wash sale rules"
After-Tax P&L View
  • Standard trading P&L alongside estimated after-tax P&L
  • Per-position breakdown of pre-tax and after-tax returns
  • Running year-to-date tax liability total
Show full SKILL.md (405 more words)Show less

Prerequisites

  • Python 3.10+
  • No external dependencies for core tracking (stdlib only)
  • Historical SOL/USD prices for accurate USD conversion
  • Trade history in structured format (timestamp, side, token, amount, price)

Quick Start

python
from tax_tracker import TaxTracker, Trade

tracker = TaxTracker(
    accounting_method="fifo",
    federal_bracket=0.32,   # Your marginal federal rate
    state_rate=0.05,        # Your state income tax rate
    long_term_rate=0.15,    # Your long-term capital gains rate
)

# Record the accumulate/house-money play
tracker.add_trade(Trade(
    timestamp="2025-06-15T10:00:00Z",
    side="buy",
    token="BONK",
    amount=1_000_000,
    price_usd=0.00002,      # Per-token price in USD
    total_usd=20.00,
))

tracker.add_trade(Trade(
    timestamp="2025-07-20T14:30:00Z",
    side="sell",
    token="BONK",
    amount=800_000,          # Sell 80% to recover capital
    price_usd=0.000025,
    total_usd=20.00,
))

# Check what happened
summary = tracker.position_summary("BONK")
print(f"Realized gain: ${summary.realized_gain:.2f}")
# Realized gain: $4.00  (sold 800k at $0.000025 = $20, basis = $16, gain = $4)

print(f"Remaining basis: ${summary.remaining_cost_basis:.2f}")
# Remaining basis: $4.00  (200k tokens x $0.00002 = $4)

print(f"Classification: {summary.gain_type}")
# Classification: short-term  (held ~35 days)

# Tax-aware signals
signals = tracker.get_signals("BONK", current_price_usd=0.00003)
for signal in signals:
    print(f"  [{signal.type}] {signal.message}")
# [long_term_countdown] Position crosses long-term threshold in 330 days
# [profit_taking_cost] Taking full profit triggers $2.80 short-term liability

Use Cases

1. Day Trader Tax Tracking

Track hundreds of daily trades, all short-term. Focus on quarterly estimated payment accuracy and cumulative liability.

2. Swing Trader with House-Money Plays

Partial sell to recover capital, let remaining position ride. Proportional cost basis ensures both legs are tracked correctly.

3. Long-Term Holder Monitoring

Track positions approaching the 1-year long-term threshold. Signals alert when selling now vs waiting N days changes the tax classification.

4. Tax-Loss Harvesting

Identify positions with unrealized losses. Harvest losses to offset gains while being mindful of wash sale rules.

5. Year-End Tax Planning

Project remaining quarterly liability, identify optimization opportunities before Dec 31.

6. Multi-Token Portfolio

Track cost basis and gains across dozens of tokens simultaneously, with per-token and aggregate views.

Accounting Methods

FIFO (First In, First Out)

Sells consume the oldest lots first. Default for most traders. Generally results in more long-term gains if you have been accumulating over time.

LIFO (Last In, First Out)

Sells consume the newest lots first. Can minimize short-term gains if recent purchases were at higher prices.

Specific Identification

Choose which lots to sell. Maximum flexibility for tax optimization, but requires careful record-keeping. Must be elected before the trade, not after.

Integration with Trading Workflow

Trade Signal → Tax-Aware Filter → Execute/Defer Decision
                    │
                    ├─ "Short-term gain: $X liability"
                    ├─ "Long-term in N days — consider waiting"
                    ├─ "Loss harvest opportunity: $X offset"
                    └─ "Net after-tax profit: $Y"

The tax-aware filter does not block trades — it provides information so the trader can make informed decisions about timing.

Files

References
  • references/planned_features.md — Detailed feature list, proportional cost basis math with worked examples, gain classification rules, quarterly estimation methodology
Scripts
  • scripts/tax_tracker.py — Demo implementation with proportional cost basis, gain classification, tax-aware signals, and quarterly projection. Run with --demo for an example accumulate/house-money scenario.

Limitations

  • US federal and state tax rules only (no international tax support yet)
  • Does not handle staking rewards, airdrops, or DeFi yield as income events (planned)
  • Wash sale rules are flagged but not automatically enforced
  • Token-to-token swaps treated as sell + buy (two taxable events) per IRS guidance
  • Does not generate official tax forms (use for tracking and planning only)

Disclaimer

Tax calculations produced by this skill are for informational tracking purposes only. Cryptocurrency tax law is complex and evolving. All tax figures should be verified by a qualified tax professional before filing. This skill does not constitute tax advice. Consult a CPA or tax attorney for guidance specific to your situation.

© agiprolabs, 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 2 other files (scripts, references) in skills/tax-liability-tracking of agiprolabs/claude-trading-skills.

  • SKILL.md
  • references/planned_features.md
  • scripts/tax_tracker.py

Open the folder on GitHubat commit 981e1d7

Compare with similar skills

Tax Liability Tracking 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.

Tax Liability Tracking compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Tax Liability Tracking this skillagiprolabs/claude-trading-skills410—~2.4kAutomated safety check: PassMIT
India Itr CopilotLoki200399/india-itr-copilot147—~2.4kAutomated safety check: PassMIT
Itr Walakaranb192/itr-wala871—~3.6kAutomated safety check: PassMIT
Tushare Datazillionare/zillionare3212 repos~2.3kAutomated safety check: PassNone
Tradingview MCPatilaahmettaner/tradingview-mcp5k—~1.3kAutomated safety check: PassMIT
Digital Oraclekomako-workshop/digital-oracle878—~5.9kAutomated safety check: PassMIT

Similar skills

  • India Itr Copilot

    Loki200399/india-itr-copilot

    Documents-first copilot for preparing Indian Income Tax Returns (ITR-1/2/3/4, any assessment year).

    147 GitHub stars~2.4k tokensUpdated 2 mo ago
    Business, Finance & HRAuto-check passed
  • Itr Wala

    karanb192/itr-wala

    File Indian income tax returns (ITR) for FY 2025-26 / AY 2026-27.

    871 GitHub stars~3.6k tokensUpdated 6 days ago
    Business, Finance & HRAuto-check passed
  • Tushare Data

    zillionare/zillionare

    面向中文自然语言的 Tushare 数据研究技能。用于把“看看这只股票最近怎么样”“帮我查财报趋势”“最近哪个板块最强”“北向资金在买什么”“给我导出一份行情数据”这类请求,转成可执行的数据获取、清洗、对比、筛选、导出与简要分析流程。适用于 A 股、指数、ETF/基金、财务、估值、资金流、公告新闻、板块概念与宏观数据等研究场景。

    321 GitHub starsUsed in 2 repos~2.3k tokens
    Business, Finance & HRAuto-check passed
  • Tradingview MCP

    atilaahmettaner/tradingview-mcp

    AI Trading Intelligence — live prices, 30+ technical indicators, backtesting (6 strategies), walk-forward overfitting detection, trade logs, equity curves, licensed news sentiment (Marketaux), and…

    5k GitHub stars~1.3k tokensUpdated yesterday
    Business, Finance & HRAuto-check passed
  • Digital Oracle

    komako-workshop/digital-oracle

    Answer prediction questions using market trading data, not opinions.

    878 GitHub stars~5.9k tokensUpdated 2 mo ago
    Business, Finance & HRAuto-check passed
  • Polyclaw

    chainstacklabs/polyclaw

    Trade on Polymarket via split + CLOB execution. An agent skill from chainstacklabs/polyclaw.

    359 GitHub starsUsed in 1 repo~2k tokens
    Business, Finance & HRAuto-check passed

More from agiprolabs/claude-trading-skills

All 68 skills in this repo
  • Backtrader

    agiprolabs/claude-trading-skills

    Event-driven backtesting with bar-by-bar execution, complex order types, multiple analyzers, and custom indicators

    410 GitHub stars~2.4k tokensUpdated 1 mo ago
    Auto-check passed
  • Birdeye API

    agiprolabs/claude-trading-skills

    Solana token market data via Birdeye — prices, OHLCV, trades, token metadata, security checks, and trader activity

    410 GitHub stars~1.8k tokensUpdated 1 mo ago
    Auto-check passed
  • Coingecko API

    agiprolabs/claude-trading-skills

    Broad crypto market data from CoinGecko covering 13,000+ tokens.

    410 GitHub stars~1.6k tokensUpdated 1 mo ago
    Auto-check passed
  • Cointegration Analysis

    agiprolabs/claude-trading-skills

    Cointegration testing for pairs trading using Engle-Granger, Johansen, and rolling stability analysis

    410 GitHub stars~2.1k tokensUpdated 1 mo ago
    Auto-check passed
  • Copy Trading

    agiprolabs/claude-trading-skills

    Wallet evaluation, monitoring, and copy-trade strategy design for Solana DEX trading

    410 GitHub stars~2.4k tokensUpdated 1 mo ago
    Auto-check passed
  • Correlation Analysis

    agiprolabs/claude-trading-skills

    Cross-asset correlation analysis including rolling correlation, hierarchical clustering, tail dependence, and regime-dependent correlation

    410 GitHub stars~2.4k tokensUpdated 1 mo ago
    Auto-check passed

Questions about Tax Liability Tracking

What does Tax Liability Tracking do?

Real-time tax liability analysis for active crypto traders with proportional cost basis, gain classification, and tax-aware trading signals. Tax Liability Tracking is an agent skill from agiprolabs/claude-trading-skills.

When should I use Tax Liability Tracking?

Tax Liability Tracking fits situations like: tasks that involve Tax preparation; tasks that involve Trading and backtesting.

How do I install Tax Liability Tracking in Claude Code?

Run `npx skills add agiprolabs/claude-trading-skills --skill tax-liability-tracking -a claude-code`. Or copy the skill folder (skills/tax-liability-tracking in agiprolabs/claude-trading-skills) into .claude/skills/tax-liability-tracking in your project. Claude Code loads it when a task matches its description.

How do I install Tax Liability Tracking in Codex?

Run `npx skills add agiprolabs/claude-trading-skills --skill tax-liability-tracking -a codex`. Or copy the skill folder (skills/tax-liability-tracking in agiprolabs/claude-trading-skills) into .agents/skills/tax-liability-tracking in your project. Codex loads it when a task matches its description.

Can I use Tax Liability Tracking 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 agiprolabs/claude-trading-skills --skill tax-liability-tracking -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/tax-liability-tracking, .gemini/skills/tax-liability-tracking, .github/skills/tax-liability-tracking and .opencode/skills/tax-liability-tracking in your project.

What does Tax Liability Tracking need to run?

Going by SKILL.md and its folder, Tax Liability Tracking needs Python for the scripts in its folder. Our summary lists: Python 3.

Does Tax Liability Tracking 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 Tax Liability Tracking 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. The check reads SKILL.md only: the scripts in the folder are not scanned, so read them before running anything.

What licence does Tax Liability Tracking use?

Tax Liability Tracking is published under the MIT licence (declared in SKILL.md). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Tax Liability Tracking use?

About 2.4k tokens (SKILL.md is roughly 9.5k 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 1.6k tokens, read only when the agent opens those files.

What are the alternatives to Tax Liability Tracking?

Skills that share tags, products or a category with Tax Liability Tracking: India Itr Copilot (Loki200399/india-itr-copilot, 147 stars), Itr Wala (karanb192/itr-wala, 871 stars), Tushare Data (zillionare/zillionare, 321 stars) and Tradingview MCP (atilaahmettaner/tradingview-mcp, 5k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Tax Liability Tracking?

agiprolabs (a GitHub user) maintains it in agiprolabs/claude-trading-skills, which has 410 GitHub stars. The repository holds 68 skills in this directory. The repository was last updated on September 3, 2026.

Source: agiprolabs/claude-trading-skills on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.