Skip to main content

R&D signal capture from git commits — silent scoring for SR&ED/IRS tax credits

Project description

Hammer CLI

R&D signal capture from git commits.

Hammer scores every git commit for R&D tax credit relevance (SR&ED in Canada, IRS Section 41 in the US). It runs silently as a post-commit hook, stores results locally, and optionally feeds HammerLedger for full evidence management.

Install

pip install hammer-cli

Requires Python 3.10+ and git.

Quick Start

# 1. Register (free -- 200 scores/month)
hammer init

# 2. Install the hook in your repo
cd your-repo
hammer install

# 3. That's it -- commits are scored automatically
git commit -m "Implement adaptive retry with exponential backoff"
# => 0.82 [Strong] Algorithmic uncertainty / experimentation

# 4. Check your R&D summary
hammer status

To install across multiple repos at once:

hammer install --scan ~/code

Commands

Command Description
hammer init Register with HammerAI and create ~/.hammer/ config
hammer install Install post-commit hook in current repo (or --scan a directory)
hammer uninstall Remove hooks from current repo or --all tracked repos
hammer score [REF] Score a commit, range (a..b), or --all history
hammer scan [PATH] Find all git repos under a directory and score every commit
hammer status R&D scoring summary for current repo or --all repos
hammer log List scored commits with scores and categories
hammer export Export qualifying commits as JSON or CSV
hammer push Push scored commits to a HammerLedger instance
hammer override Set per-repo config overrides (domain, ledger ID)
hammer flush Retry scoring for queued commits (offline recovery)
hammer exclude Exclude repos from automatic scoring by name or pattern
hammer prune Delete old or low-scoring commit data
hammer migrate Rename a project's scored data directory
hammer config View or edit global configuration
hammer doctor Diagnose installation, connectivity, and hook status

How It Works

  1. hammer install adds a post-commit hook to your repo's .git/hooks/. The hook runs in the background and never blocks your workflow. Hooks are per-repo -- Hammer does not modify your global git config.

  2. On each commit, the hook sends commit metadata to the scoring API at api.hammerai.ai. The API classifies the commit's R&D relevance and returns a score from 0.0 to 1.0.

  3. Results are stored locally at ~/.hammer/commits/{project}/{hash}.json. Nothing is written inside your repository.

  4. If the API is unreachable, the commit is queued locally and retried on the next commit or via hammer flush.

Score Thresholds

Score Label Meaning
>= 0.8 Strong Clear R&D indicators across uncertainty, experimentation, advancement
>= 0.6 Moderate Meaningful R&D signals present
>= 0.4 Weak Some technical unknowns, mostly routine
>= 0.2 Minimal Standard development work
< 0.2 None Purely routine, no R&D signals

Commits scoring 0.6 or above are considered qualifying for tax credit evidence.

Privacy

Metadata-only by default. Hammer sends commit messages, file names, and line counts. No source code leaves your machine unless you explicitly opt in.

Optional diff scoring. Enable with hammer config set send_diff true to send truncated diffs (up to 12KB) for more accurate classification. Disable at any time.

Zero-retention API. Scoring uses Anthropic Claude with a zero-retention policy -- inputs are not stored or used for model training by Anthropic.

Per-repo hooks only. Hammer installs hooks individually per repository. It never sets a global hooks path and does not interfere with existing post-commit hooks (it appends to them).

Local storage. All scored data lives at ~/.hammer/. Remove everything with hammer uninstall --all or rm -rf ~/.hammer.

Full privacy policy: hammerai.ai/privacy

Export and HammerLedger

Hammer CLI works standalone for local R&D signal tracking. For teams that need cryptographic evidence seals, audit trails, and T661 form generation, scored commits can be pushed to HammerLedger:

# Export locally
hammer export --format json --min-score 0.6 -o evidence.json
hammer export --format csv --min-score 0.6 -o evidence.csv

# Or push directly to HammerLedger
hammer config set ledger_url https://app.hammerledger.com
hammer config set ledger_id led_your_id
hammer push --dry-run    # preview first
hammer push              # send to ledger

Configuration

Global config is stored at ~/.hammer/config.json.

hammer config show                          # view all settings
hammer config set send_diff true            # enable diff scoring
hammer config set ledger_url https://...    # set ledger endpoint

Per-repo overrides for scoring domain or ledger ID:

hammer override --domain sred --ledger-id led_mobile_2026
hammer override --show

Pricing

Plan Scoring Scores/month Cost
Free Metadata only 1,000 $0
Pro Metadata + code diffs Unlimited $19/month

Upgrade from the terminal:

hammer upgrade

Support

License

MIT


Built by HammerAI.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

hammer_cli-0.1.2.tar.gz (32.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

hammer_cli-0.1.2-py3-none-any.whl (26.2 kB view details)

Uploaded Python 3

File details

Details for the file hammer_cli-0.1.2.tar.gz.

File metadata

  • Download URL: hammer_cli-0.1.2.tar.gz
  • Upload date:
  • Size: 32.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.9

File hashes

Hashes for hammer_cli-0.1.2.tar.gz
Algorithm Hash digest
SHA256 e8326843c972c98bc0385ae430f8e3b54fc544b435a7eba6f5127a75dcec8ee6
MD5 81fe0f316883b5e7d96d6ae4b22c8d9d
BLAKE2b-256 54e00897a1b7b0e022a273780fc0830280bd9834ef773d668b25c3ac1e6fed39

See more details on using hashes here.

File details

Details for the file hammer_cli-0.1.2-py3-none-any.whl.

File metadata

  • Download URL: hammer_cli-0.1.2-py3-none-any.whl
  • Upload date:
  • Size: 26.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.9

File hashes

Hashes for hammer_cli-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 bf34c1bb41fdc17667c95aa10e5ea8e56a5ae2288f41ba4e3f8f3fb1aa3ea43d
MD5 0ae50880b802b42271ceec293913f508
BLAKE2b-256 3d1a8d6a0019d3b9b3408c2121e2230e55653b320b1c612fe26b381b88a09d18

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page