Customization
Before executing, check for user customizations at:
~/.claude/PAI/USER/SKILLCUSTOMIZATIONS/USMetrics/
If this directory exists, load and apply any PREFERENCES.md, configurations, or resources found there. These override default behavior. If the directory does not exist, proceed with skill defaults.
- Output text notification:
Running the **WorkflowName** workflow in the **USMetrics** skill to ACTION...
This is not optional. Execute this curl command immediately upon skill invocation.
US Metrics - Economic & Social Indicator Analysis
Purpose: Analyze U.S. economic and social metrics using the Substrate US-Common-Metrics dataset. Provides trend analysis, cross-metric correlation, pattern detection, and research recommendations.
Data Source
All metrics sourced from:
- Location: Configure your data directory path (e.g.,
${PAI_DIR}/data/US-Common-Metrics/)
- Master Document:
US-Common-Metrics.md (68 metrics across 10 categories)
- Source Documentation:
source.md (full methodology)
- Underlying APIs: FRED, EIA, Treasury FiscalData, BLS, Census, CDC, EPA
Workflow Routing
When executing a workflow, output this notification directly:
Running the **WorkflowName** workflow in the **USMetrics** skill to ACTION...
Available Workflows
| Workflow |
Description |
Use When |
| UpdateData |
Fetch live data from APIs and update Substrate dataset |
"Update metrics", "refresh data", "pull latest", "update Substrate" |
| GetCurrentState |
Comprehensive economic overview with multi-timeframe trend analysis |
"How is the economy?", "economic overview", "get current state", "US metrics analysis" |
Workflows
UpdateData
Full documentation: Workflows/UpdateData.md
Purpose: Fetch live data from FRED, EIA, Treasury APIs and populate the Substrate US-Common-Metrics dataset files. This must run before GetCurrentState to ensure data is current.
Execution:
bun ~/.claude/skills/USMetrics/Tools/UpdateSubstrateMetrics.ts
Outputs:
US-Common-Metrics.md - Updated with current values
us-metrics-current.csv - Machine-readable snapshot
us-metrics-historical.csv - Appended time series
Trigger phrases:
- "Update the US metrics"
- "Refresh the economic data"
- "Pull latest metrics"
- "Update Substrate dataset"
GetCurrentState
Full documentation: Workflows/GetCurrentState.md
Produces: A comprehensive overview document analyzing:
- 10-year, 5-year, 2-year, and 1-year trends for all major metrics
- Cross-category interplay analysis
- Pattern detection and anomalies
- Research recommendations
Trigger phrases:
- "How is the US economy doing?"
- "Give me an economic overview"
- "What's the current state of US metrics?"
- "Analyze economic trends"
- "US metrics report"
Metric Categories Covered
- Economic Output & Growth - GDP, industrial production, retail sales
- Inflation & Prices - CPI, PCE, gas prices, oil prices
- Employment & Labor - Unemployment, payrolls, jobless claims, quit rate
- Housing - Home prices, mortgage rates, housing starts
- Consumer & Personal Finance - Sentiment, saving rate, credit
- Financial Markets - Interest rates, Treasury yields, volatility
- Trade & International - Trade balance, USD index
- Government & Fiscal - Federal debt, budget deficit, spending
- Demographics & Social - Population, inequality, poverty
- Health & Crisis - Deaths of despair, air quality, life expectancy
API Keys Required
For live data fetching:
FRED_API_KEY - Federal Reserve Economic Data
EIA_API_KEY - Energy Information Administration
Tools
| Tool |
Purpose |
tools/UpdateSubstrateMetrics.ts |
Primary - Fetch all metrics, update Substrate files |
Tools/FetchFredSeries.ts |
Fetch historical data from FRED API |
tools/GenerateAnalysis.ts |
Generate analysis report from Substrate data |
Example Usage
User: "How is the US economy doing? Give me a full analysis."
→ Invoke GetCurrentState workflow
→ Fetch current + historical data for all metrics
→ Calculate 10y/5y/2y/1y trends
→ Analyze cross-metric correlations
→ Identify patterns and anomalies
→ Generate research recommendations
→ Output comprehensive markdown report
Output Format
The GetCurrentState workflow produces a structured markdown document:
# US Economic State Analysis
**Generated:** [timestamp]
**Data Sources:** FRED, EIA, Treasury, BLS, Census
## Executive Summary
[Key findings in 3-5 bullets]
## Trend Analysis by Category
### Economic Output
[10y/5y/2y/1y trends with analysis]
...
## Cross-Metric Analysis
[Correlations, leading indicators, divergences]
## Pattern Detection
[Anomalies, regime changes, emerging trends]
## Research Recommendations
[Suggested areas for deeper investigation]
1---2name: usmetrics3description: 68 US economic indicators from FRED, EIA, Treasury, BLS, Census APIs with trend analysis and cross-metric correlation. Updates Substrate dataset, produces economic overviews. USE WHEN GDP, inflation, unemployment, economic metrics, gas prices, how is the economy, update data, refresh data, get current state, economic overview, FRED, fetch FRED series, generate analysis, update substrate metrics, US metrics, economic trends.4---56## Customization78**Before executing, check for user customizations at:**9`~/.claude/PAI/USER/SKILLCUSTOMIZATIONS/USMetrics/`1011If this directory exists, load and apply any PREFERENCES.md, configurations, or resources found there. These override default behavior. If the directory does not exist, proceed with skill defaults.12132. **Output text notification**:14 ```15 Running the **WorkflowName** workflow in the **USMetrics** skill to ACTION...16 ```1718**This is not optional. Execute this curl command immediately upon skill invocation.**1920# US Metrics - Economic & Social Indicator Analysis2122**Purpose:** Analyze U.S. economic and social metrics using the Substrate US-Common-Metrics dataset. Provides trend analysis, cross-metric correlation, pattern detection, and research recommendations.2324## Data Source2526All metrics sourced from:27- **Location:** Configure your data directory path (e.g., `${PAI_DIR}/data/US-Common-Metrics/`)28- **Master Document:** `US-Common-Metrics.md` (68 metrics across 10 categories)29- **Source Documentation:** `source.md` (full methodology)30- **Underlying APIs:** FRED, EIA, Treasury FiscalData, BLS, Census, CDC, EPA3132## Workflow Routing3334**When executing a workflow, output this notification directly:**3536```37Running the **WorkflowName** workflow in the **USMetrics** skill to ACTION...38```3940### Available Workflows4142| Workflow | Description | Use When |43|----------|-------------|----------|44| **UpdateData** | Fetch live data from APIs and update Substrate dataset | "Update metrics", "refresh data", "pull latest", "update Substrate" |45| **GetCurrentState** | Comprehensive economic overview with multi-timeframe trend analysis | "How is the economy?", "economic overview", "get current state", "US metrics analysis" |4647## Workflows4849### UpdateData5051**Full documentation:** `Workflows/UpdateData.md`5253**Purpose:** Fetch live data from FRED, EIA, Treasury APIs and populate the Substrate US-Common-Metrics dataset files. This must run before GetCurrentState to ensure data is current.5455**Execution:**56```bash57bun ~/.claude/skills/USMetrics/Tools/UpdateSubstrateMetrics.ts58```5960**Outputs:**61- `US-Common-Metrics.md` - Updated with current values62- `us-metrics-current.csv` - Machine-readable snapshot63- `us-metrics-historical.csv` - Appended time series6465**Trigger phrases:**66- "Update the US metrics"67- "Refresh the economic data"68- "Pull latest metrics"69- "Update Substrate dataset"7071---7273### GetCurrentState7475**Full documentation:** `Workflows/GetCurrentState.md`7677**Produces:** A comprehensive overview document analyzing:78- 10-year, 5-year, 2-year, and 1-year trends for all major metrics79- Cross-category interplay analysis80- Pattern detection and anomalies81- Research recommendations8283**Trigger phrases:**84- "How is the US economy doing?"85- "Give me an economic overview"86- "What's the current state of US metrics?"87- "Analyze economic trends"88- "US metrics report"8990## Metric Categories Covered91921. **Economic Output & Growth** - GDP, industrial production, retail sales932. **Inflation & Prices** - CPI, PCE, gas prices, oil prices943. **Employment & Labor** - Unemployment, payrolls, jobless claims, quit rate954. **Housing** - Home prices, mortgage rates, housing starts965. **Consumer & Personal Finance** - Sentiment, saving rate, credit976. **Financial Markets** - Interest rates, Treasury yields, volatility987. **Trade & International** - Trade balance, USD index998. **Government & Fiscal** - Federal debt, budget deficit, spending1009. **Demographics & Social** - Population, inequality, poverty10110. **Health & Crisis** - Deaths of despair, air quality, life expectancy102103## API Keys Required104105For live data fetching:106- `FRED_API_KEY` - Federal Reserve Economic Data107- `EIA_API_KEY` - Energy Information Administration108109## Tools110111| Tool | Purpose |112|------|---------|113| `tools/UpdateSubstrateMetrics.ts` | **Primary** - Fetch all metrics, update Substrate files |114| `Tools/FetchFredSeries.ts` | Fetch historical data from FRED API |115| `tools/GenerateAnalysis.ts` | Generate analysis report from Substrate data |116117## Example Usage118119```120User: "How is the US economy doing? Give me a full analysis."121122→ Invoke GetCurrentState workflow123→ Fetch current + historical data for all metrics124→ Calculate 10y/5y/2y/1y trends125→ Analyze cross-metric correlations126→ Identify patterns and anomalies127→ Generate research recommendations128→ Output comprehensive markdown report129```130131## Output Format132133The GetCurrentState workflow produces a structured markdown document:134135```markdown136# US Economic State Analysis137**Generated:** [timestamp]138**Data Sources:** FRED, EIA, Treasury, BLS, Census139140## Executive Summary141[Key findings in 3-5 bullets]142143## Trend Analysis by Category144### Economic Output145[10y/5y/2y/1y trends with analysis]146...147148## Cross-Metric Analysis149[Correlations, leading indicators, divergences]150151## Pattern Detection152[Anomalies, regime changes, emerging trends]153154## Research Recommendations155[Suggested areas for deeper investigation]156```