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 🙏

© 2026 – Pkg Stats / Ryan Hefner

fed-policy-cli

v1.0.2

Published

Macro trading intelligence from Fed policy analysis. Transform economic data into actionable trading insights by analyzing historical Fed policy analogues.

Readme

Fed Policy CLI

Macro trading intelligence from Fed policy analysis

Transform economic data into actionable trading insights by analyzing historical Federal Reserve policy analogues. Built for macro traders, hedge funds, and financial analysts.

Features

  • 📊 Historical Analogue Analysis - Find similar Fed policy periods using weighted economic indicators
  • 💹 Market vs Fed Expectations - Analyze yield curve inversions and rate divergences
  • 🌍 Cross-Asset Fed Playbook - Multi-asset performance during Fed cycles (bonds, equities, commodities, currencies)
  • 🎮 Policy Simulator - What-if scenario modeling for Fed policy changes
  • 📈 Trading Signals - AI-generated signals with confidence scores and risk analysis

Installation

npm install -g fed-policy-cli

Quick Start

# Show welcome screen and commands
fed-policy-cli

# Fetch latest economic data (required first step)
fed-policy-cli update-data --api-key YOUR_FRED_API_KEY

# Analyze current market conditions
fed-policy-cli analyze --template balanced-economic

# Market expectations analysis
fed-policy-cli market-expectations

# Cross-asset analysis during Fed cycles
fed-policy-cli cross-asset-analysis

API Keys Required

Store in .env file:

FRED_API_KEY=your_fred_api_key_here
ALPHA_VANTAGE_API_KEY=your_alpha_vantage_key_here

Commands

Data Management

  • update-data - Fetch latest economic data from FRED API
  • list-templates - Show available economic analysis templates

Analysis

  • analyze - Find historical Fed policy analogues
  • correlate - Calculate correlation matrices for economic indicators
  • market-expectations - Analyze market vs Fed rate expectations
  • cross-asset-analysis - Multi-asset performance during Fed cycles
  • simulate - Interactive Fed policy scenario simulator

Examples

# Stagflation analysis
fed-policy-cli analyze --template stagflation-hunt --months 12

# Custom indicator analysis
fed-policy-cli analyze --indicator UNRATE:0.5 --indicator CPIAUCSL:0.5

# Correlation analysis
fed-policy-cli correlate --indicators UNRATE CPIAUCSL GDPC1

# Cross-asset analysis with Alpha Vantage data
fed-policy-cli cross-asset-analysis --alpha-vantage-key YOUR_KEY

Data Sources

  • FRED (Federal Reserve Economic Data) - 100+ economic indicators
  • FOMC Projections - Fed dot plot data
  • Alpha Vantage - ETF and cross-asset data
  • Treasury Yield Curves - Daily yield data

Use Cases

  • Macro Trading - Position sizing and asset allocation during Fed cycles
  • Risk Management - Historical drawdown analysis and scenario planning
  • Research - Economic cycle analysis and policy impact studies
  • Portfolio Management - Cross-asset rotation strategies

Available Templates

| Template | Focus | Key Indicators | |----------|-------|----------------| | stagflation-hunt | High inflation + unemployment | UNRATE, CPIAUCSL, DFF | | financial-crisis | Financial stress periods | UNRATE, T10Y2Y, DFF, ICSA | | policy-tightening | Fed tightening cycles | DFF, CPIAUCSL, UNRATE | | recession-early-warning | Recession precursors | T10Y2Y, ICSA, GDPC1 | | inflation-regime | Inflationary periods | CPIAUCSL, PCEPI, DFF | | balanced-economic | Equal weight analysis | All indicators |

Supported Indicators

Economic Data (FRED)

  • UNRATE - Unemployment Rate
  • CPIAUCSL - CPI Inflation
  • DFF - Federal Funds Rate
  • PCEPI - PCE Core Inflation
  • GDPC1 - Real GDP Growth
  • T10Y2Y - 10-2 Year Treasury Spread
  • ICSA - Initial Jobless Claims

Cross-Asset Data

  • DCOILWTICO - WTI Crude Oil
  • POILBREUSDM - Brent Crude Oil
  • DTWEXBGS - USD Index
  • PCOPPUSDM - Copper Price

ETF Data (Alpha Vantage)

  • TLT - 20+ Year Treasury Bonds
  • SPY - S&P 500
  • XLF - Financial Sector
  • HYG - High Yield Bonds
  • GLD - Gold

Example Output

 ═══════════════ MARKET EXPECTATIONS ANALYSIS ═══════════════

 ════════════════════ EXECUTIVE SUMMARY ═════════════════════
 🎯 Market positioning 46bp hawkish vs Fed guidance

 Key Takeaways:
   • Significant hawkish divergence creates trading opportunity
   • Yield curve inversion signals recession risk (-4bp 2s10s)
   • Fed targets 3.40% by 2027

 ──── Yield Curve Snapshot ────
 3M: 4.42%   2Y: 3.86%   10Y: 4.35%   30Y: 4.86%
 2s10s: +0.49bp ⚠️ INVERTED

 ──── Trading Signals ────
 1. YIELD CURVE PLAY
    Yield curve inverted. Consider recession protection trades.
    Confidence: ████░░░░░░ 45%

License

MIT

Support