npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2025 – Pkg Stats / Ryan Hefner

@neural-trader/agentic-accounting-mcp

v0.1.1

Published

Model Context Protocol (MCP) server for Claude Desktop integration, exposing intelligent accounting tools, tax calculators, and autonomous agents for AI-powered cryptocurrency financial analysis

Readme

🤖 Agentic Accounting MCP Server

npm version npm downloads License: MIT OR Apache-2.0 Model Context Protocol

Autonomous Accounting System via Model Context Protocol Expose powerful accounting tools to Claude and other AI assistants through MCP

Integrate advanced tax calculations, compliance checking, fraud detection, and financial reporting directly into Claude Desktop or any MCP-compatible client. Built on the Model Context Protocol, this server provides 10+ specialized accounting tools for autonomous financial operations.


✨ Features

  • 🧮 Tax Calculations - Multiple methods (FIFO, LIFO, HIFO, Specific ID, Average Cost)
  • 📋 Compliance Checking - Multi-jurisdiction regulatory validation
  • 🔍 Fraud Detection - Vector-based anomaly detection with confidence scoring
  • 💰 Tax-Loss Harvesting - Automated opportunity scanning for portfolio optimization
  • 📊 Report Generation - P&L, Schedule-D, Form 8949, audit trails
  • 📥 Transaction Ingestion - Support for Coinbase, Binance, Kraken, Etherscan, CSV
  • 📈 Position Tracking - Real-time asset position management
  • 🛡️ Merkle Proofs - Cryptographic verification for audit trails
  • 🧠 Learning System - Agent performance optimization with feedback loops
  • 📉 Performance Metrics - Comprehensive agent analytics and monitoring

🚀 Installation

Method 1: Install from npm

npm install -g @neural-trader/agentic-accounting-mcp

Method 2: Install in your project

npm install @neural-trader/agentic-accounting-mcp

Method 3: Use with Claude Desktop

Add to your Claude Desktop configuration (~/Library/Application Support/Claude/claude_desktop_config.json on macOS):

{
  "mcpServers": {
    "agentic-accounting": {
      "command": "npx",
      "args": [
        "-y",
        "@neural-trader/agentic-accounting-mcp"
      ]
    }
  }
}

💡 Tip: Restart Claude Desktop after updating the configuration to activate the MCP server.


⚡ Quick Start

Using with Claude Desktop

  1. Install the server (see Installation above)
  2. Restart Claude Desktop
  3. Use accounting tools in conversation:
Claude, can you calculate the tax liability for this Bitcoin sale using FIFO method?

Claude will automatically use the accounting_calculate_tax tool to process your request.

Using Programmatically

import { Server } from '@modelcontextprotocol/sdk/server/index.js';
import { StdioServerTransport } from '@modelcontextprotocol/sdk/server/stdio.js';

// Server starts automatically when imported
// Tools are available via MCP protocol

📖 Detailed Tutorial

1. Tax Calculation Workflow

Calculate capital gains and tax liability using various accounting methods:

In Claude:

I sold 0.5 BTC at $60,000. I originally bought:
- 0.3 BTC at $30,000 on Jan 1
- 0.4 BTC at $40,000 on Feb 1

Calculate my tax using FIFO method.

Behind the scenes, Claude uses:

{
  "tool": "accounting_calculate_tax",
  "arguments": {
    "transaction": {
      "asset": "BTC",
      "quantity": 0.5,
      "price": 60000,
      "date": "2024-03-01"
    },
    "method": "FIFO"
  }
}

Response:

{
  "method": "FIFO",
  "gainLoss": 12000,
  "costBasis": 18000,
  "proceeds": 30000,
  "taxLiability": 2880
}

2. Compliance Checking

Validate transactions against regulatory requirements:

In Claude:

Check if this $15,000 crypto-to-crypto swap complies with US regulations.

Tool call:

{
  "tool": "accounting_check_compliance",
  "arguments": {
    "transaction": {
      "type": "swap",
      "amount": 15000,
      "fromAsset": "ETH",
      "toAsset": "BTC"
    },
    "jurisdiction": "US"
  }
}

⚠️ Warning: Always consult with a licensed tax professional for production tax reporting. This tool provides automated analysis but is not a substitute for professional advice.

3. Fraud Detection

Analyze transactions for suspicious patterns:

In Claude:

Analyze this transaction for fraud:
- $50,000 transfer to new wallet
- Sent at 3 AM
- First transaction from this address

Tool call:

{
  "tool": "accounting_detect_fraud",
  "arguments": {
    "transaction": {
      "amount": 50000,
      "timestamp": "2024-03-01T03:00:00Z",
      "toAddress": "0xnew...",
      "isFirstTransaction": true
    }
  }
}

Response:

{
  "fraudScore": 0.72,
  "confidence": 0.85,
  "anomalies": [
    "Unusual transaction time",
    "First-time recipient",
    "Large amount"
  ],
  "riskLevel": "MEDIUM"
}

4. Tax-Loss Harvesting

Identify opportunities to reduce tax liability:

In Claude:

Scan my portfolio for tax-loss harvesting opportunities:
- 10 ETH bought at $3000 (now $2500)
- 1 BTC bought at $50000 (now $60000)
- 100 SOL bought at $150 (now $100)

Tool call:

{
  "tool": "accounting_harvest_losses",
  "arguments": {
    "positions": [...],
    "currentPrices": {
      "ETH": 2500,
      "BTC": 60000,
      "SOL": 100
    }
  }
}

5. Report Generation

Generate professional financial reports:

In Claude:

Generate a Schedule-D report for tax year 2024 with all my crypto transactions.

Tool call:

{
  "tool": "accounting_generate_report",
  "arguments": {
    "reportType": "schedule-d",
    "transactions": [...],
    "year": 2024
  }
}

📝 Note: Reports are generated in JSON format by default. Use the CLI tool for PDF/CSV export.


🔧 Available MCP Tools

1. accounting_calculate_tax

Calculate tax liability using specified accounting method.

Parameters:

  • transaction (object) - Transaction details
  • method (string) - FIFO | LIFO | HIFO | SPECIFIC_ID | AVERAGE_COST

2. accounting_check_compliance

Validate transaction compliance with regulatory rules.

Parameters:

  • transaction (object) - Transaction to validate
  • jurisdiction (string, optional) - US | EU | UK | etc.

3. accounting_detect_fraud

Analyze transaction for fraud using vector-based detection.

Parameters:

  • transaction (object) - Transaction to analyze

4. accounting_harvest_losses

Scan portfolio for tax-loss harvesting opportunities.

Parameters:

  • positions (array) - Array of open positions
  • currentPrices (object) - Current market prices

5. accounting_generate_report

Generate financial or tax report.

Parameters:

  • reportType (string) - pnl | schedule-d | form-8949 | audit
  • transactions (array) - Transactions to include
  • year (number, optional) - Tax year

6. accounting_ingest_transactions

Ingest transactions from external sources.

Parameters:

  • source (string) - coinbase | binance | kraken | etherscan | csv
  • data (array) - Raw transaction data

7. accounting_get_position

Get current position for an asset.

Parameters:

  • asset (string) - Asset symbol (e.g., "BTC", "ETH")
  • wallet (string, optional) - Wallet identifier

8. accounting_verify_merkle_proof

Verify Merkle proof for transaction audit trail.

Parameters:

  • transaction (object) - Transaction to verify
  • proof (object) - Merkle proof
  • rootHash (string) - Expected root hash

9. accounting_learn_from_feedback

Process feedback to improve agent performance.

Parameters:

  • agentId (string) - Agent identifier
  • rating (number) - Rating from 0 to 1
  • comments (string, optional) - Feedback text

10. accounting_get_metrics

Get performance metrics for an agent.

Parameters:

  • agentId (string) - Agent identifier
  • startDate (string, optional) - ISO format date
  • endDate (string, optional) - ISO format date

⚙️ Configuration

Claude Desktop Configuration

Edit claude_desktop_config.json:

{
  "mcpServers": {
    "agentic-accounting": {
      "command": "npx",
      "args": [
        "-y",
        "@neural-trader/agentic-accounting-mcp"
      ],
      "env": {
        "NODE_ENV": "production"
      }
    }
  }
}

Environment Variables

# Optional: Set log level
export LOG_LEVEL=debug

# Optional: Database connection
export DB_PATH=/path/to/accounting.db

Custom Configuration

For advanced users, you can run the server directly:

node node_modules/@neural-trader/agentic-accounting-mcp/dist/server.js

💡 Integration Examples

Example 1: Complete Tax Workflow

Claude, I need to calculate my 2024 crypto taxes:

1. Import transactions from my Coinbase account
2. Calculate gains using HIFO method
3. Check compliance with US regulations
4. Generate Form 8949
5. Identify any tax-loss harvesting opportunities

Please walk me through each step.

Claude will orchestrate multiple tools to complete this workflow automatically.

Example 2: Real-time Fraud Monitoring

Claude, monitor this transaction in real-time:
- Amount: $100,000
- Destination: 0xabc123...
- Time: 2024-11-16T14:30:00Z

Check for fraud indicators and verify the transaction proof.

Example 3: Portfolio Analysis

Claude, analyze my portfolio:
- Show current positions for all assets
- Calculate unrealized P&L
- Find tax-loss harvesting opportunities
- Generate a comprehensive report

🔗 Related Packages

Part of the Neural Trader Agentic Accounting ecosystem:


🐛 Troubleshooting

Server Not Starting

# Check if server is accessible
npx @neural-trader/agentic-accounting-mcp

# Expected output: "Agentic Accounting MCP Server running on stdio"

Tools Not Appearing in Claude

  1. Verify configuration file location
  2. Restart Claude Desktop completely
  3. Check for syntax errors in claude_desktop_config.json
  4. View logs: ~/Library/Logs/Claude/mcp*.log

Permission Issues

# Ensure executable permissions
chmod +x node_modules/.bin/agentic-accounting-mcp

💡 Tip: Enable debug logging with export LOG_LEVEL=debug for detailed troubleshooting information.


📚 Additional Resources


🤝 Contributing

Contributions are welcome! Please see CONTRIBUTING.md for guidelines.


📄 License

Licensed under MIT OR Apache-2.0. See LICENSE for details.


🌟 Credits

Created by ruv.io Website: neural-trader.ruv.io

Part of the Neural Trader autonomous trading and accounting platform.


Keywords: model-context-protocol, claude-desktop, ai-tools, mcp-server, accounting-automation, tax-calculation, compliance-checking, fraud-detection, cryptocurrency-accounting, autonomous-agents