@intentsolutionsio/openbb-terminal 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.claude-plugin/plugin.json +29 -0
- package/LICENSE +21 -0
- package/README.md +1162 -0
- package/agents/crypto-analyst.md +165 -0
- package/agents/equity-analyst.md +148 -0
- package/agents/macro-economist.md +228 -0
- package/agents/portfolio-manager.md +163 -0
- package/commands/openbb-crypto.md +347 -0
- package/commands/openbb-equity.md +266 -0
- package/commands/openbb-macro.md +91 -0
- package/commands/openbb-options.md +87 -0
- package/commands/openbb-portfolio.md +154 -0
- package/commands/openbb-research.md +173 -0
- package/package.json +51 -0
- package/skills/skill-adapter/assets/README.md +7 -0
- package/skills/skill-adapter/assets/config-template.json +32 -0
- package/skills/skill-adapter/assets/skill-schema.json +28 -0
- package/skills/skill-adapter/assets/test-data.json +27 -0
- package/skills/skill-adapter/references/README.md +4 -0
- package/skills/skill-adapter/references/best-practices.md +69 -0
- package/skills/skill-adapter/references/examples.md +73 -0
- package/skills/skill-adapter/scripts/README.md +7 -0
- package/skills/skill-adapter/scripts/helper-template.sh +42 -0
- package/skills/skill-adapter/scripts/validation.sh +32 -0
package/README.md
ADDED
|
@@ -0,0 +1,1162 @@
|
|
|
1
|
+
# 📊 OpenBB Terminal - AI-Powered Investment Research
|
|
2
|
+
|
|
3
|
+
**Professional-grade financial analysis powered by OpenBB Platform** - Comprehensive equity research, cryptocurrency analysis, macroeconomic insights, and portfolio management, all integrated with Claude's AI capabilities.
|
|
4
|
+
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
## 🎯 What This Plugin Does
|
|
8
|
+
|
|
9
|
+
Transform Claude Code into a powerful investment research terminal using OpenBB's open-source financial data platform.
|
|
10
|
+
|
|
11
|
+
**Features**:
|
|
12
|
+
- 📈 **Equity Analysis** - Stocks, fundamentals, technicals, analyst ratings
|
|
13
|
+
- 💰 **Crypto Analysis** - On-chain metrics, DeFi, whale tracking, sentiment
|
|
14
|
+
- 🌍 **Macro Economics** - GDP, inflation, rates, employment data
|
|
15
|
+
- 💼 **Portfolio Management** - Performance tracking, optimization, rebalancing
|
|
16
|
+
- 📊 **Options Analysis** - Chains, Greeks, strategies, unusual activity
|
|
17
|
+
- 🤖 **AI Research** - Automated investment thesis generation
|
|
18
|
+
|
|
19
|
+
---
|
|
20
|
+
|
|
21
|
+
## 🚀 Quick Start
|
|
22
|
+
|
|
23
|
+
### Installation
|
|
24
|
+
|
|
25
|
+
```bash
|
|
26
|
+
# Add marketplace
|
|
27
|
+
/plugin marketplace add jeremylongshore/claude-code-plugins
|
|
28
|
+
|
|
29
|
+
# Install OpenBB Terminal plugin
|
|
30
|
+
/plugin install openbb-terminal@claude-code-plugins-plus
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
### Prerequisites
|
|
34
|
+
|
|
35
|
+
```bash
|
|
36
|
+
# Install OpenBB Platform (Python 3.9.21 - 3.12)
|
|
37
|
+
pip install openbb
|
|
38
|
+
|
|
39
|
+
# Optional: Install with specific data providers
|
|
40
|
+
pip install openbb[all] # All providers
|
|
41
|
+
pip install openbb[yfinance] # Just Yahoo Finance
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
### Basic Usage
|
|
45
|
+
|
|
46
|
+
```bash
|
|
47
|
+
# Analyze a stock
|
|
48
|
+
/openbb-equity AAPL
|
|
49
|
+
|
|
50
|
+
# Check crypto market
|
|
51
|
+
/openbb-crypto BTC
|
|
52
|
+
|
|
53
|
+
# Review portfolio
|
|
54
|
+
/openbb-portfolio --analyze
|
|
55
|
+
|
|
56
|
+
# Macro overview
|
|
57
|
+
/openbb-macro --country=US
|
|
58
|
+
|
|
59
|
+
# Options analysis
|
|
60
|
+
/openbb-options SPY
|
|
61
|
+
|
|
62
|
+
# AI research report
|
|
63
|
+
/openbb-research TSLA --depth=deep
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
---
|
|
67
|
+
|
|
68
|
+
## FREE Data Sources: No Paid Subscriptions Required
|
|
69
|
+
|
|
70
|
+
**Use OpenBB Terminal with 100% free data providers** - no Bloomberg, Refinitiv, or premium API costs.
|
|
71
|
+
|
|
72
|
+
### Quick Comparison
|
|
73
|
+
|
|
74
|
+
| Data Type | Paid Providers | FREE Providers |
|
|
75
|
+
|-----------|---------------|----------------|
|
|
76
|
+
| **Stock Data** | Bloomberg ($20K+/year) | Yahoo Finance: **$0** |
|
|
77
|
+
| **Crypto Data** | CoinMetrics ($500+/mo) | CoinGecko API: **$0** |
|
|
78
|
+
| **Options Data** | Intrinio ($200+/mo) | CBOE/NASDAQ (free): **$0** |
|
|
79
|
+
| **Macro Data** | Refinitiv ($1K+/mo) | FRED (Federal Reserve): **$0** |
|
|
80
|
+
| **Fundamentals** | FactSet ($12K+/year) | Alpha Vantage (free tier): **$0** |
|
|
81
|
+
|
|
82
|
+
**Annual Savings: $25,000-50,000** for professional-grade data.
|
|
83
|
+
|
|
84
|
+
### Why Free Data Providers?
|
|
85
|
+
|
|
86
|
+
**Benefits:**
|
|
87
|
+
- **Zero Cost:** No subscription fees or API charges
|
|
88
|
+
- **Professional Quality:** Same data hedge funds use
|
|
89
|
+
- **No Rate Limits:** (with Yahoo Finance and FRED)
|
|
90
|
+
- **Real-Time Data:** 15-min delay for stocks, real-time for crypto
|
|
91
|
+
- **Global Coverage:** 50K+ stocks, 10K+ cryptos, 180+ countries
|
|
92
|
+
|
|
93
|
+
**Free Provider Ecosystem:**
|
|
94
|
+
- **Yahoo Finance** - Stocks, ETFs, indices, historical data
|
|
95
|
+
- **Alpha Vantage** - Fundamentals, technicals, forex (500 calls/day free)
|
|
96
|
+
- **FRED (Federal Reserve)** - 817K economic time series
|
|
97
|
+
- **CoinGecko** - 10K+ cryptos, free API
|
|
98
|
+
- **CBOE/NASDAQ** - Options chains (15-min delay)
|
|
99
|
+
- **SEC EDGAR** - 10-K, 10-Q, insider trades
|
|
100
|
+
- **Census Bureau** - US economic data
|
|
101
|
+
- **World Bank** - Global development indicators
|
|
102
|
+
|
|
103
|
+
### Setup Guide (Free Tier Only)
|
|
104
|
+
|
|
105
|
+
#### 1. Install OpenBB with Free Providers
|
|
106
|
+
|
|
107
|
+
```bash
|
|
108
|
+
# Install OpenBB Platform
|
|
109
|
+
pip install openbb
|
|
110
|
+
|
|
111
|
+
# Install ONLY free provider packages
|
|
112
|
+
pip install openbb[yfinance] # Yahoo Finance (FREE)
|
|
113
|
+
|
|
114
|
+
# No need for paid providers!
|
|
115
|
+
```
|
|
116
|
+
|
|
117
|
+
#### 2. Configure Free API Keys (Optional)
|
|
118
|
+
|
|
119
|
+
```python
|
|
120
|
+
from openbb import obb
|
|
121
|
+
|
|
122
|
+
# Alpha Vantage (FREE tier: 500 calls/day)
|
|
123
|
+
# Get free key at: https://www.alphavantage.co/support/#api-key
|
|
124
|
+
obb.user.credentials.alpha_vantage_api_key = "YOUR_FREE_KEY"
|
|
125
|
+
|
|
126
|
+
# FRED (FREE, unlimited)
|
|
127
|
+
# Get free key at: https://fred.stlouisfed.org/docs/api/api_key.html
|
|
128
|
+
obb.user.credentials.fred_api_key = "YOUR_FREE_KEY"
|
|
129
|
+
|
|
130
|
+
# Save configuration
|
|
131
|
+
obb.user.save()
|
|
132
|
+
```
|
|
133
|
+
|
|
134
|
+
**No credit card required for any of these keys.**
|
|
135
|
+
|
|
136
|
+
#### 3. Use Free Data Sources
|
|
137
|
+
|
|
138
|
+
```python
|
|
139
|
+
from openbb import obb
|
|
140
|
+
|
|
141
|
+
# Stock data (Yahoo Finance - FREE)
|
|
142
|
+
stock_data = obb.equity.price.historical(
|
|
143
|
+
symbol="AAPL",
|
|
144
|
+
provider="yfinance" # FREE
|
|
145
|
+
)
|
|
146
|
+
|
|
147
|
+
# Crypto data (CoinGecko - FREE)
|
|
148
|
+
crypto_data = obb.crypto.price.historical(
|
|
149
|
+
symbol="BTC",
|
|
150
|
+
provider="coingecko" # FREE
|
|
151
|
+
)
|
|
152
|
+
|
|
153
|
+
# Macro data (FRED - FREE)
|
|
154
|
+
gdp_data = obb.economy.gdp(
|
|
155
|
+
country="US",
|
|
156
|
+
provider="fred" # FREE
|
|
157
|
+
)
|
|
158
|
+
|
|
159
|
+
# Options data (CBOE - FREE)
|
|
160
|
+
options_chains = obb.derivatives.options.chains(
|
|
161
|
+
symbol="SPY",
|
|
162
|
+
provider="cboe" # FREE
|
|
163
|
+
)
|
|
164
|
+
```
|
|
165
|
+
|
|
166
|
+
### Cost Comparison
|
|
167
|
+
|
|
168
|
+
#### Premium Approach (Paid)
|
|
169
|
+
|
|
170
|
+
**Annual Subscriptions:**
|
|
171
|
+
- Bloomberg Terminal: $24,000/year
|
|
172
|
+
- Refinitiv Eikon: $12,000/year
|
|
173
|
+
- FactSet: $12,000/year
|
|
174
|
+
- Intrinio: $2,400/year
|
|
175
|
+
- CoinMetrics Pro: $6,000/year
|
|
176
|
+
- **Total: $56,400/year**
|
|
177
|
+
|
|
178
|
+
#### Free Approach (This Plugin)
|
|
179
|
+
|
|
180
|
+
**Annual Subscriptions:**
|
|
181
|
+
- Yahoo Finance: $0
|
|
182
|
+
- Alpha Vantage (free tier): $0
|
|
183
|
+
- FRED: $0
|
|
184
|
+
- CoinGecko: $0
|
|
185
|
+
- SEC EDGAR: $0
|
|
186
|
+
- **Total: $0/year**
|
|
187
|
+
|
|
188
|
+
**Savings: $56,400/year** with comparable data quality.
|
|
189
|
+
|
|
190
|
+
### Free vs Paid: Data Quality Comparison
|
|
191
|
+
|
|
192
|
+
| Metric | Paid (Bloomberg) | FREE (Yahoo + FRED) |
|
|
193
|
+
|--------|------------------|---------------------|
|
|
194
|
+
| **Stock Prices** | Real-time | 15-min delay ⚠️ |
|
|
195
|
+
| **Historical Data** | 30+ years | 20+ years ✅ |
|
|
196
|
+
| **Fundamentals** | Instant updates | Daily updates ✅ |
|
|
197
|
+
| **Macro Data** | Proprietary | Official (Fed, Census) ✅ |
|
|
198
|
+
| **Options Chains** | Real-time | 15-min delay ⚠️ |
|
|
199
|
+
| **Crypto Data** | Premium exchanges | CoinGecko aggregate ✅ |
|
|
200
|
+
| **Cost** | $24K/year | $0/year ✅ |
|
|
201
|
+
|
|
202
|
+
**15-min delay is acceptable for 99% of investors** (day traders excluded).
|
|
203
|
+
|
|
204
|
+
### Migration Examples
|
|
205
|
+
|
|
206
|
+
#### Before (Paid Premium)
|
|
207
|
+
|
|
208
|
+
```python
|
|
209
|
+
# Using Bloomberg (requires $24K/year subscription)
|
|
210
|
+
import blpapi
|
|
211
|
+
|
|
212
|
+
session = blpapi.Session()
|
|
213
|
+
session.start()
|
|
214
|
+
# ... Bloomberg API calls
|
|
215
|
+
```
|
|
216
|
+
|
|
217
|
+
**Annual Cost:** $24,000
|
|
218
|
+
|
|
219
|
+
#### After (Free Providers)
|
|
220
|
+
|
|
221
|
+
```python
|
|
222
|
+
# Using Yahoo Finance (FREE)
|
|
223
|
+
from openbb import obb
|
|
224
|
+
|
|
225
|
+
data = obb.equity.price.historical(
|
|
226
|
+
symbol="AAPL",
|
|
227
|
+
provider="yfinance"
|
|
228
|
+
)
|
|
229
|
+
```
|
|
230
|
+
|
|
231
|
+
**Annual Cost:** $0
|
|
232
|
+
|
|
233
|
+
**Same historical data, zero cost.**
|
|
234
|
+
|
|
235
|
+
### Real Use Cases with Free Data
|
|
236
|
+
|
|
237
|
+
#### 1. Stock Portfolio Analysis
|
|
238
|
+
|
|
239
|
+
```python
|
|
240
|
+
from openbb import obb
|
|
241
|
+
|
|
242
|
+
# Get stock data (Yahoo Finance - FREE)
|
|
243
|
+
aapl = obb.equity.price.historical("AAPL", provider="yfinance")
|
|
244
|
+
msft = obb.equity.price.historical("MSFT", provider="yfinance")
|
|
245
|
+
googl = obb.equity.price.historical("GOOGL", provider="yfinance")
|
|
246
|
+
|
|
247
|
+
# Fundamentals (Alpha Vantage - FREE)
|
|
248
|
+
aapl_fundamentals = obb.equity.fundamental.overview(
|
|
249
|
+
"AAPL",
|
|
250
|
+
provider="alpha_vantage"
|
|
251
|
+
)
|
|
252
|
+
```
|
|
253
|
+
|
|
254
|
+
**Cost:** $0 (vs Bloomberg: $24K/year)
|
|
255
|
+
|
|
256
|
+
#### 2. Crypto Market Analysis
|
|
257
|
+
|
|
258
|
+
```python
|
|
259
|
+
# Crypto prices (CoinGecko - FREE)
|
|
260
|
+
btc = obb.crypto.price.historical("BTC", provider="coingecko")
|
|
261
|
+
eth = obb.crypto.price.historical("ETH", provider="coingecko")
|
|
262
|
+
|
|
263
|
+
# Market cap, volume, 24h change - all FREE
|
|
264
|
+
```
|
|
265
|
+
|
|
266
|
+
**Cost:** $0 (vs CoinMetrics: $6K/year)
|
|
267
|
+
|
|
268
|
+
#### 3. Macroeconomic Research
|
|
269
|
+
|
|
270
|
+
```python
|
|
271
|
+
# US GDP (FRED - FREE)
|
|
272
|
+
gdp = obb.economy.gdp(country="US", provider="fred")
|
|
273
|
+
|
|
274
|
+
# Inflation (FRED - FREE)
|
|
275
|
+
cpi = obb.economy.cpi(country="US", provider="fred")
|
|
276
|
+
|
|
277
|
+
# Unemployment (FRED - FREE)
|
|
278
|
+
unemployment = obb.economy.unemployment(country="US", provider="fred")
|
|
279
|
+
```
|
|
280
|
+
|
|
281
|
+
**Cost:** $0 (vs Refinitiv: $12K/year)
|
|
282
|
+
|
|
283
|
+
### Free Tier Limitations
|
|
284
|
+
|
|
285
|
+
**Alpha Vantage Free Tier:**
|
|
286
|
+
- 500 API calls/day (enough for most users)
|
|
287
|
+
- 5 API calls/minute
|
|
288
|
+
- Solution: Cache data locally
|
|
289
|
+
|
|
290
|
+
**Yahoo Finance:**
|
|
291
|
+
- No official rate limits (generous)
|
|
292
|
+
- 15-minute delay on real-time data
|
|
293
|
+
- Solution: Perfect for investors (not day traders)
|
|
294
|
+
|
|
295
|
+
**CoinGecko:**
|
|
296
|
+
- 10-50 calls/minute (free)
|
|
297
|
+
- Solution: More than enough for crypto analysis
|
|
298
|
+
|
|
299
|
+
### When Free Data Is NOT Enough
|
|
300
|
+
|
|
301
|
+
**Use paid providers if:**
|
|
302
|
+
- You're a day trader (need real-time data)
|
|
303
|
+
- You trade options actively (need instant chains)
|
|
304
|
+
- You need proprietary alternative data
|
|
305
|
+
- Your firm requires Bloomberg for compliance
|
|
306
|
+
- You manage $10M+ AUM professionally
|
|
307
|
+
|
|
308
|
+
**For everyone else:** Free data providers are sufficient.
|
|
309
|
+
|
|
310
|
+
### Hybrid Approach: Mostly Free
|
|
311
|
+
|
|
312
|
+
**Best of both worlds:** Use free data 95% of the time, paid for critical needs.
|
|
313
|
+
|
|
314
|
+
```python
|
|
315
|
+
from openbb import obb
|
|
316
|
+
|
|
317
|
+
# Default to FREE providers
|
|
318
|
+
obb.user.preferences.data_source = "yfinance" # FREE
|
|
319
|
+
|
|
320
|
+
# Only use paid when specifically needed
|
|
321
|
+
critical_data = obb.equity.price.historical(
|
|
322
|
+
symbol="AAPL",
|
|
323
|
+
provider="polygon" # Paid (only when required)
|
|
324
|
+
)
|
|
325
|
+
```
|
|
326
|
+
|
|
327
|
+
**Cost Reduction:** 95% savings ($1,200/year vs $24K/year)
|
|
328
|
+
|
|
329
|
+
### Resources
|
|
330
|
+
|
|
331
|
+
- **Yahoo Finance:** [finance.yahoo.com](https://finance.yahoo.com) (FREE forever)
|
|
332
|
+
- **Alpha Vantage:** [alphavantage.co](https://www.alphavantage.co) (FREE tier)
|
|
333
|
+
- **FRED API:** [fred.stlouisfed.org/docs/api](https://fred.stlouisfed.org/docs/api) (FREE)
|
|
334
|
+
- **CoinGecko:** [coingecko.com/api](https://www.coingecko.com/api) (FREE tier)
|
|
335
|
+
- **OpenBB Docs:** [docs.openbb.co](https://docs.openbb.co/platform)
|
|
336
|
+
|
|
337
|
+
**Bottom Line:** For 99% of investors, free data providers offer Bloomberg-quality data at $0/year.
|
|
338
|
+
|
|
339
|
+
---
|
|
340
|
+
|
|
341
|
+
## ⚠️ Rate Limits & API Requirements
|
|
342
|
+
|
|
343
|
+
**IMPORTANT:** Tom (@TomLucidor) asked us to document the REAL constraints. Here they are - no marketing, just facts.
|
|
344
|
+
|
|
345
|
+
### Free API Comparison Table
|
|
346
|
+
|
|
347
|
+
| Provider | Daily Limit | Per-Minute | Registration | API Key | IP Tracking | Best For |
|
|
348
|
+
|----------|-------------|------------|--------------|---------|-------------|----------|
|
|
349
|
+
| **Yahoo Finance** | ~2,000/hour | ~100/min | ❌ No | ❌ No | ⚠️ Soft bans | Stock quotes, historical data |
|
|
350
|
+
| **Alpha Vantage** | **25/day** | **5/min** | ✅ Email | ✅ Required | ✅ Yes | Fundamentals, technicals |
|
|
351
|
+
| **FRED** | Unlimited | 120/min | ✅ Email | ✅ Required | ❌ No | Economic data |
|
|
352
|
+
| **SEC EDGAR** | Unlimited | **10/sec** | ❌ No | ❌ No | ⚠️ User-Agent | Company filings |
|
|
353
|
+
| **CoinGecko** | Unlimited | **50/min** | ❌ Optional | ❌ Optional | ⚠️ Soft limits | Crypto data |
|
|
354
|
+
| **IEX Cloud** | 50K/month | 100/sec | ✅ Email | ✅ Required | ❌ No | Stock data (free tier) |
|
|
355
|
+
|
|
356
|
+
### Detailed Limits by Provider
|
|
357
|
+
|
|
358
|
+
#### 1. Alpha Vantage (Fundamentals & Technicals)
|
|
359
|
+
|
|
360
|
+
**FREE TIER REALITY:**
|
|
361
|
+
- ❌ **NOT 500/day** (that's outdated info from 2018)
|
|
362
|
+
- ✅ **Actually 25 API calls/day** (since 2022)
|
|
363
|
+
- ✅ **5 calls/minute max**
|
|
364
|
+
- ✅ **Email signup required** (no credit card)
|
|
365
|
+
- ✅ **Single IP per API key**
|
|
366
|
+
|
|
367
|
+
**Registration Steps:**
|
|
368
|
+
1. Go to: https://www.alphavantage.co/support/#api-key
|
|
369
|
+
2. Enter email (no verification link, instant key)
|
|
370
|
+
3. Copy API key (starts with uppercase letters)
|
|
371
|
+
4. Add to OpenBB: `obb.user.credentials.alpha_vantage_api_key = "KEY"`
|
|
372
|
+
|
|
373
|
+
**Agent Strategy for 25/day Limit:**
|
|
374
|
+
```python
|
|
375
|
+
# Strategy 1: Cache aggressively (24-hour TTL)
|
|
376
|
+
from functools import lru_cache
|
|
377
|
+
import time
|
|
378
|
+
|
|
379
|
+
@lru_cache(maxsize=100)
|
|
380
|
+
def get_fundamentals(symbol):
|
|
381
|
+
# Cached for full day
|
|
382
|
+
return obb.equity.fundamental.overview(
|
|
383
|
+
symbol=symbol,
|
|
384
|
+
provider="alpha_vantage"
|
|
385
|
+
)
|
|
386
|
+
|
|
387
|
+
# Strategy 2: Batch symbols intelligently
|
|
388
|
+
symbols_to_analyze = ["AAPL", "GOOGL", "MSFT", "TSLA", "NVDA"]
|
|
389
|
+
|
|
390
|
+
# Don't use all 25 calls on 25 stocks!
|
|
391
|
+
# Use 1 call for overview, then cache
|
|
392
|
+
for symbol in symbols_to_analyze[:25]: # Max 25
|
|
393
|
+
data = get_fundamentals(symbol) # Only fetches once per symbol
|
|
394
|
+
|
|
395
|
+
# Strategy 3: Fallback chain
|
|
396
|
+
def get_stock_data(symbol):
|
|
397
|
+
try:
|
|
398
|
+
# Try Alpha Vantage first (most detailed)
|
|
399
|
+
return obb.equity.price.historical(symbol, provider="alpha_vantage")
|
|
400
|
+
except RateLimitError:
|
|
401
|
+
# Fallback to Yahoo Finance (unlimited)
|
|
402
|
+
return obb.equity.price.historical(symbol, provider="yfinance")
|
|
403
|
+
```
|
|
404
|
+
|
|
405
|
+
**When You Hit the Limit:**
|
|
406
|
+
- Error: `"Thank you for using Alpha Vantage! Our standard API call frequency is 5 calls per minute and 25 calls per day."`
|
|
407
|
+
- Wait time: 24 hours until reset (resets at midnight UTC)
|
|
408
|
+
- Workaround: Use Yahoo Finance for price data, only use Alpha Vantage for fundamentals
|
|
409
|
+
|
|
410
|
+
**Upgrade Path:**
|
|
411
|
+
- $49.99/month: 75 calls/minute, 100K calls/month
|
|
412
|
+
- Probably not worth it - use Yahoo Finance instead
|
|
413
|
+
|
|
414
|
+
#### 2. Yahoo Finance (Stock Quotes & Historical Data)
|
|
415
|
+
|
|
416
|
+
**FREE TIER REALITY:**
|
|
417
|
+
- ✅ **~2,000 requests/hour** (undocumented soft limit)
|
|
418
|
+
- ✅ **~100 requests/minute**
|
|
419
|
+
- ✅ **No registration** (truly anonymous)
|
|
420
|
+
- ✅ **No API key** (uses Python library yfinance)
|
|
421
|
+
- ⚠️ **IP tracking** (can get soft-banned for aggressive scraping)
|
|
422
|
+
|
|
423
|
+
**How It Actually Works:**
|
|
424
|
+
```python
|
|
425
|
+
# Yahoo Finance doesn't have "official" API
|
|
426
|
+
# Uses yfinance library which scrapes website
|
|
427
|
+
|
|
428
|
+
import yfinance as yf
|
|
429
|
+
|
|
430
|
+
# This doesn't count against Alpha Vantage limit
|
|
431
|
+
ticker = yf.Ticker("AAPL")
|
|
432
|
+
hist = ticker.history(period="1y") # FREE, unlimited (sort of)
|
|
433
|
+
```
|
|
434
|
+
|
|
435
|
+
**Agent Strategy for IP-Based Limits:**
|
|
436
|
+
```python
|
|
437
|
+
# Strategy 1: Respect rate limits (self-impose)
|
|
438
|
+
import time
|
|
439
|
+
|
|
440
|
+
class YFinanceCoordinator:
|
|
441
|
+
def __init__(self):
|
|
442
|
+
self.last_request = 0
|
|
443
|
+
self.min_interval = 0.1 # 100ms between requests
|
|
444
|
+
|
|
445
|
+
def get_data(self, symbol):
|
|
446
|
+
# Wait if needed
|
|
447
|
+
elapsed = time.time() - self.last_request
|
|
448
|
+
if elapsed < self.min_interval:
|
|
449
|
+
time.sleep(self.min_interval - elapsed)
|
|
450
|
+
|
|
451
|
+
# Make request
|
|
452
|
+
data = yf.Ticker(symbol).history(period="1d")
|
|
453
|
+
self.last_request = time.time()
|
|
454
|
+
return data
|
|
455
|
+
|
|
456
|
+
# Strategy 2: Batch downloads (yfinance supports this!)
|
|
457
|
+
symbols = ["AAPL", "GOOGL", "MSFT", "TSLA", "NVDA"]
|
|
458
|
+
data = yf.download(
|
|
459
|
+
tickers=symbols,
|
|
460
|
+
period="1mo",
|
|
461
|
+
group_by='ticker',
|
|
462
|
+
threads=True # Parallel downloads (faster but more aggressive)
|
|
463
|
+
)
|
|
464
|
+
|
|
465
|
+
# Strategy 3: Cache locally
|
|
466
|
+
import pandas as pd
|
|
467
|
+
from datetime import datetime, timedelta
|
|
468
|
+
|
|
469
|
+
def get_cached_data(symbol, cache_hours=6):
|
|
470
|
+
cache_file = f"/tmp/yf_{symbol}.csv"
|
|
471
|
+
|
|
472
|
+
# Check cache age
|
|
473
|
+
if os.path.exists(cache_file):
|
|
474
|
+
age = time.time() - os.path.getmtime(cache_file)
|
|
475
|
+
if age < cache_hours * 3600:
|
|
476
|
+
return pd.read_csv(cache_file)
|
|
477
|
+
|
|
478
|
+
# Fetch fresh data
|
|
479
|
+
data = yf.Ticker(symbol).history(period="1y")
|
|
480
|
+
data.to_csv(cache_file)
|
|
481
|
+
return data
|
|
482
|
+
```
|
|
483
|
+
|
|
484
|
+
**When You Get Soft-Banned:**
|
|
485
|
+
- Symptom: Empty DataFrames or 404 errors
|
|
486
|
+
- Duration: Usually 1 hour
|
|
487
|
+
- Workaround: Use residential proxy or wait
|
|
488
|
+
- Prevention: Add 100ms delay between requests
|
|
489
|
+
|
|
490
|
+
#### 3. SEC EDGAR (Company Filings)
|
|
491
|
+
|
|
492
|
+
**FREE TIER REALITY:**
|
|
493
|
+
- ✅ **Unlimited requests** (government data, public domain)
|
|
494
|
+
- ⚠️ **10 requests/second limit** (hard limit since 2021)
|
|
495
|
+
- ⚠️ **User-Agent header REQUIRED** (must include email or get 403)
|
|
496
|
+
- ✅ **No registration**
|
|
497
|
+
- ✅ **No API key**
|
|
498
|
+
|
|
499
|
+
**Registration Requirements:**
|
|
500
|
+
None! But you MUST set a User-Agent header with your email:
|
|
501
|
+
|
|
502
|
+
```python
|
|
503
|
+
import requests
|
|
504
|
+
|
|
505
|
+
headers = {
|
|
506
|
+
'User-Agent': 'YourCompany yourname@email.com' # REQUIRED
|
|
507
|
+
}
|
|
508
|
+
|
|
509
|
+
# This works
|
|
510
|
+
response = requests.get(
|
|
511
|
+
'https://www.sec.gov/cgi-bin/browse-edgar',
|
|
512
|
+
headers=headers
|
|
513
|
+
)
|
|
514
|
+
|
|
515
|
+
# This gets 403 Forbidden
|
|
516
|
+
response = requests.get(
|
|
517
|
+
'https://www.sec.gov/cgi-bin/browse-edgar' # Missing User-Agent
|
|
518
|
+
)
|
|
519
|
+
```
|
|
520
|
+
|
|
521
|
+
**Agent Strategy for 10/sec Limit:**
|
|
522
|
+
```python
|
|
523
|
+
import time
|
|
524
|
+
from collections import deque
|
|
525
|
+
|
|
526
|
+
class EDGARRateLimiter:
|
|
527
|
+
def __init__(self):
|
|
528
|
+
self.requests = deque(maxlen=10) # Track last 10 requests
|
|
529
|
+
|
|
530
|
+
def make_request(self, url):
|
|
531
|
+
# Wait if we've made 10 requests in last second
|
|
532
|
+
if len(self.requests) == 10:
|
|
533
|
+
elapsed = time.time() - self.requests[0]
|
|
534
|
+
if elapsed < 1.0:
|
|
535
|
+
time.sleep(1.0 - elapsed)
|
|
536
|
+
|
|
537
|
+
# Make request
|
|
538
|
+
self.requests.append(time.time())
|
|
539
|
+
return requests.get(url, headers={
|
|
540
|
+
'User-Agent': 'OpenBB Terminal research@example.com'
|
|
541
|
+
})
|
|
542
|
+
|
|
543
|
+
# Use with OpenBB
|
|
544
|
+
edgar = EDGARRateLimiter()
|
|
545
|
+
filings = edgar.make_request(
|
|
546
|
+
f'https://www.sec.gov/cgi-bin/browse-edgar?action=getcompany&CIK=AAPL'
|
|
547
|
+
)
|
|
548
|
+
```
|
|
549
|
+
|
|
550
|
+
#### 4. CoinGecko (Cryptocurrency Data)
|
|
551
|
+
|
|
552
|
+
**FREE TIER REALITY:**
|
|
553
|
+
- ✅ **Unlimited requests/day** (generous free tier)
|
|
554
|
+
- ⚠️ **50 calls/minute** (soft limit)
|
|
555
|
+
- ✅ **No registration** (optional for higher limits)
|
|
556
|
+
- ✅ **No API key** (optional)
|
|
557
|
+
|
|
558
|
+
**With Free API Key (Optional):**
|
|
559
|
+
- 30-50 calls/minute (still free)
|
|
560
|
+
- More stable rate limits
|
|
561
|
+
- Get key at: https://www.coingecko.com/en/api
|
|
562
|
+
|
|
563
|
+
**Agent Strategy:**
|
|
564
|
+
```python
|
|
565
|
+
# CoinGecko is actually generous - just add small delay
|
|
566
|
+
import time
|
|
567
|
+
|
|
568
|
+
def get_crypto_data(coin_id):
|
|
569
|
+
time.sleep(1.2) # 50/min = 1.2s per request
|
|
570
|
+
return obb.crypto.price.historical(
|
|
571
|
+
symbol=coin_id,
|
|
572
|
+
provider="coingecko"
|
|
573
|
+
)
|
|
574
|
+
```
|
|
575
|
+
|
|
576
|
+
### Multi-Agent Resource Management (Single IP)
|
|
577
|
+
|
|
578
|
+
**Scenario: 5 AI Agents Analyzing 100 Stocks**
|
|
579
|
+
|
|
580
|
+
```python
|
|
581
|
+
# DON'T: Each agent hammers APIs independently
|
|
582
|
+
# BAD - Will hit all rate limits in minutes!
|
|
583
|
+
for agent in agents:
|
|
584
|
+
for stock in stocks:
|
|
585
|
+
data = agent.fetch_data(stock) # 500 API calls!
|
|
586
|
+
|
|
587
|
+
# DO: Centralized quota coordinator
|
|
588
|
+
class FinancialDataCoordinator:
|
|
589
|
+
def __init__(self):
|
|
590
|
+
self.alpha_vantage_calls_today = 0
|
|
591
|
+
self.alpha_vantage_max = 25
|
|
592
|
+
self.yfinance_last_request = 0
|
|
593
|
+
self.cache = {}
|
|
594
|
+
|
|
595
|
+
def get_data(self, symbol, agent_id):
|
|
596
|
+
# Check cache first
|
|
597
|
+
if symbol in self.cache:
|
|
598
|
+
return self.cache[symbol]
|
|
599
|
+
|
|
600
|
+
# Try Yahoo Finance (unlimited-ish)
|
|
601
|
+
try:
|
|
602
|
+
data = self.fetch_yfinance(symbol)
|
|
603
|
+
self.cache[symbol] = data
|
|
604
|
+
return data
|
|
605
|
+
except RateLimitError:
|
|
606
|
+
pass
|
|
607
|
+
|
|
608
|
+
# Fallback to Alpha Vantage (use quota wisely)
|
|
609
|
+
if self.alpha_vantage_calls_today < self.alpha_vantage_max:
|
|
610
|
+
data = self.fetch_alpha_vantage(symbol)
|
|
611
|
+
self.alpha_vantage_calls_today += 1
|
|
612
|
+
self.cache[symbol] = data
|
|
613
|
+
return data
|
|
614
|
+
|
|
615
|
+
# Out of quota - return cached or error
|
|
616
|
+
raise QuotaExceededError(f"Out of API calls. Used {self.alpha_vantage_calls_today}/25 Alpha Vantage calls today")
|
|
617
|
+
|
|
618
|
+
# All 5 agents share the same coordinator
|
|
619
|
+
coordinator = FinancialDataCoordinator()
|
|
620
|
+
for agent in agents:
|
|
621
|
+
agent.data_source = coordinator
|
|
622
|
+
```
|
|
623
|
+
|
|
624
|
+
### Upgrade Paths (When Free Tier Isn't Enough)
|
|
625
|
+
|
|
626
|
+
| Your Problem | Solution | Cost |
|
|
627
|
+
|--------------|----------|------|
|
|
628
|
+
| Alpha Vantage 25/day too low | Upgrade to $49.99/mo | $600/year (still way cheaper than Bloomberg) |
|
|
629
|
+
| Yahoo Finance soft bans | Use IEX Cloud 50K/month free | $0 |
|
|
630
|
+
| Need real-time data | Upgrade to IEX Cloud $9/mo | $108/year |
|
|
631
|
+
| Need 100% uptime | Use Polygon.io $29/mo | $348/year |
|
|
632
|
+
| Bloomberg-level features | Still 10x cheaper | $600-3,000/year vs $24K+ |
|
|
633
|
+
|
|
634
|
+
### Summary: Can You Run 10 Agents on One IP?
|
|
635
|
+
|
|
636
|
+
**✅ YES** - if you're smart about it:
|
|
637
|
+
|
|
638
|
+
| Provider | Single IP Strategy | Max Agents Supported |
|
|
639
|
+
|----------|-------------------|---------------------|
|
|
640
|
+
| Yahoo Finance | Shared cache, 100ms delays | 10-20 agents |
|
|
641
|
+
| Alpha Vantage | Centralized quota (25/day total) | Unlimited agents (shared quota) |
|
|
642
|
+
| FRED | No limits! | Unlimited |
|
|
643
|
+
| SEC EDGAR | 10/sec shared limit | 5-10 agents |
|
|
644
|
+
| CoinGecko | 50/min shared | 10+ agents |
|
|
645
|
+
|
|
646
|
+
**Key: Agents must coordinate, not compete for quota.**
|
|
647
|
+
|
|
648
|
+
---
|
|
649
|
+
|
|
650
|
+
## 💡 Core Commands (6)
|
|
651
|
+
|
|
652
|
+
### 1. `/openbb-equity` - Stock Analysis
|
|
653
|
+
|
|
654
|
+
Complete equity analysis with fundamentals, technicals, and AI insights.
|
|
655
|
+
|
|
656
|
+
```bash
|
|
657
|
+
# Basic analysis
|
|
658
|
+
/openbb-equity AAPL
|
|
659
|
+
|
|
660
|
+
# Fundamental focus
|
|
661
|
+
/openbb-equity MSFT --analysis=fundamental
|
|
662
|
+
|
|
663
|
+
# Technical with custom period
|
|
664
|
+
/openbb-equity NVDA --analysis=technical --period=6m
|
|
665
|
+
|
|
666
|
+
# Complete deep-dive
|
|
667
|
+
/openbb-equity GOOGL --analysis=all --period=1y
|
|
668
|
+
```
|
|
669
|
+
|
|
670
|
+
**Provides**:
|
|
671
|
+
- Historical price data (OHLCV)
|
|
672
|
+
- Company fundamentals (P/E, EPS, ROE, margins)
|
|
673
|
+
- Analyst ratings and price targets
|
|
674
|
+
- Technical indicators (SMA, RSI, volume)
|
|
675
|
+
- AI-powered investment insights
|
|
676
|
+
|
|
677
|
+
---
|
|
678
|
+
|
|
679
|
+
### 2. `/openbb-crypto` - Cryptocurrency Analysis
|
|
680
|
+
|
|
681
|
+
Comprehensive crypto market analysis with on-chain data.
|
|
682
|
+
|
|
683
|
+
```bash
|
|
684
|
+
# Bitcoin analysis
|
|
685
|
+
/openbb-crypto BTC
|
|
686
|
+
|
|
687
|
+
# Ethereum DeFi metrics
|
|
688
|
+
/openbb-crypto ETH --metrics=defi
|
|
689
|
+
|
|
690
|
+
# Altcoin vs Bitcoin
|
|
691
|
+
/openbb-crypto LINK --vs=BTC --period=90d
|
|
692
|
+
|
|
693
|
+
# Social sentiment check
|
|
694
|
+
/openbb-crypto DOGE --metrics=social
|
|
695
|
+
```
|
|
696
|
+
|
|
697
|
+
**Provides**:
|
|
698
|
+
- Real-time price and volume data
|
|
699
|
+
- On-chain metrics (active addresses, hash rate, holders)
|
|
700
|
+
- DeFi analytics (TVL, staking, protocols)
|
|
701
|
+
- Social sentiment (Twitter, Reddit, news)
|
|
702
|
+
- Whale activity tracking
|
|
703
|
+
- AI market analysis
|
|
704
|
+
|
|
705
|
+
---
|
|
706
|
+
|
|
707
|
+
### 3. `/openbb-macro` - Macroeconomic Analysis
|
|
708
|
+
|
|
709
|
+
Global economic indicators and market implications.
|
|
710
|
+
|
|
711
|
+
```bash
|
|
712
|
+
# US macro overview
|
|
713
|
+
/openbb-macro --country=US --indicators=all
|
|
714
|
+
|
|
715
|
+
# UK inflation focus
|
|
716
|
+
/openbb-macro --country=UK --indicators=inflation
|
|
717
|
+
|
|
718
|
+
# China GDP analysis
|
|
719
|
+
/openbb-macro --country=CN --indicators=gdp
|
|
720
|
+
```
|
|
721
|
+
|
|
722
|
+
**Provides**:
|
|
723
|
+
- GDP growth rates and forecasts
|
|
724
|
+
- Inflation metrics (CPI, PPI, PCE)
|
|
725
|
+
- Interest rates and central bank policy
|
|
726
|
+
- Employment data (unemployment, NFP)
|
|
727
|
+
- Market impact analysis
|
|
728
|
+
|
|
729
|
+
---
|
|
730
|
+
|
|
731
|
+
### 4. `/openbb-portfolio` - Portfolio Management
|
|
732
|
+
|
|
733
|
+
Performance tracking, risk analysis, and optimization.
|
|
734
|
+
|
|
735
|
+
```bash
|
|
736
|
+
# Analyze current portfolio
|
|
737
|
+
/openbb-portfolio --analyze
|
|
738
|
+
|
|
739
|
+
# Optimize allocation
|
|
740
|
+
/openbb-portfolio --optimize
|
|
741
|
+
|
|
742
|
+
# Compare to benchmark
|
|
743
|
+
/openbb-portfolio --benchmark=SPY
|
|
744
|
+
```
|
|
745
|
+
|
|
746
|
+
**Provides**:
|
|
747
|
+
- Total return and performance metrics
|
|
748
|
+
- Risk analysis (volatility, Sharpe, max drawdown)
|
|
749
|
+
- Asset allocation breakdown
|
|
750
|
+
- Rebalancing recommendations
|
|
751
|
+
- Position-level P/L tracking
|
|
752
|
+
|
|
753
|
+
---
|
|
754
|
+
|
|
755
|
+
### 5. `/openbb-options` - Options Analysis
|
|
756
|
+
|
|
757
|
+
Options chains, Greeks, and strategy analysis.
|
|
758
|
+
|
|
759
|
+
```bash
|
|
760
|
+
# Options chain analysis
|
|
761
|
+
/openbb-options AAPL
|
|
762
|
+
|
|
763
|
+
# Covered call strategy
|
|
764
|
+
/openbb-options SPY --strategy=covered-call
|
|
765
|
+
|
|
766
|
+
# Custom expiry
|
|
767
|
+
/openbb-options TSLA --expiry=30d
|
|
768
|
+
|
|
769
|
+
# Unusual activity scanner
|
|
770
|
+
/openbb-options NVDA --unusual-activity
|
|
771
|
+
```
|
|
772
|
+
|
|
773
|
+
**Provides**:
|
|
774
|
+
- Call/put options chains
|
|
775
|
+
- Greeks (Delta, Gamma, Theta, Vega)
|
|
776
|
+
- Implied volatility analysis
|
|
777
|
+
- Strategy recommendations
|
|
778
|
+
- Unusual options activity alerts
|
|
779
|
+
|
|
780
|
+
---
|
|
781
|
+
|
|
782
|
+
### 6. `/openbb-research` - AI Investment Research
|
|
783
|
+
|
|
784
|
+
Comprehensive AI-powered research reports.
|
|
785
|
+
|
|
786
|
+
```bash
|
|
787
|
+
# Deep research report
|
|
788
|
+
/openbb-research AAPL --depth=deep
|
|
789
|
+
|
|
790
|
+
# Quick thesis
|
|
791
|
+
/openbb-research MSFT --depth=quick --focus=thesis
|
|
792
|
+
|
|
793
|
+
# Risk analysis
|
|
794
|
+
/openbb-research TSLA --focus=risks
|
|
795
|
+
|
|
796
|
+
# Opportunity scanner
|
|
797
|
+
/openbb-research AMD --focus=opportunities
|
|
798
|
+
```
|
|
799
|
+
|
|
800
|
+
**Generates**:
|
|
801
|
+
- Executive summary
|
|
802
|
+
- Investment thesis
|
|
803
|
+
- Financial analysis
|
|
804
|
+
- Valuation assessment
|
|
805
|
+
- Risk factors
|
|
806
|
+
- Catalysts and price targets
|
|
807
|
+
- Actionable recommendations
|
|
808
|
+
|
|
809
|
+
---
|
|
810
|
+
|
|
811
|
+
## 🤖 AI Agents (4)
|
|
812
|
+
|
|
813
|
+
### 1. `equity-analyst`
|
|
814
|
+
|
|
815
|
+
Expert stock analyst specializing in fundamental and technical analysis.
|
|
816
|
+
|
|
817
|
+
**Expertise**:
|
|
818
|
+
- Financial statement analysis
|
|
819
|
+
- DCF and relative valuation models
|
|
820
|
+
- Technical indicators and chart patterns
|
|
821
|
+
- Investment thesis generation
|
|
822
|
+
- Risk assessment
|
|
823
|
+
|
|
824
|
+
**Use with**: `/openbb-equity`, `/openbb-research`
|
|
825
|
+
|
|
826
|
+
---
|
|
827
|
+
|
|
828
|
+
### 2. `crypto-analyst`
|
|
829
|
+
|
|
830
|
+
Cryptocurrency and digital asset specialist.
|
|
831
|
+
|
|
832
|
+
**Expertise**:
|
|
833
|
+
- On-chain analysis (network metrics, whale tracking)
|
|
834
|
+
- Tokenomics evaluation
|
|
835
|
+
- DeFi protocol assessment
|
|
836
|
+
- Market cycle analysis
|
|
837
|
+
- Crypto-specific technical analysis
|
|
838
|
+
|
|
839
|
+
**Use with**: `/openbb-crypto`, `/openbb-research`
|
|
840
|
+
|
|
841
|
+
---
|
|
842
|
+
|
|
843
|
+
### 3. `portfolio-manager`
|
|
844
|
+
|
|
845
|
+
Portfolio construction and risk management expert.
|
|
846
|
+
|
|
847
|
+
**Expertise**:
|
|
848
|
+
- Asset allocation optimization
|
|
849
|
+
- Risk-adjusted return maximization
|
|
850
|
+
- Rebalancing strategies
|
|
851
|
+
- Position sizing
|
|
852
|
+
- Performance attribution
|
|
853
|
+
|
|
854
|
+
**Use with**: `/openbb-portfolio`, all analysis commands
|
|
855
|
+
|
|
856
|
+
---
|
|
857
|
+
|
|
858
|
+
### 4. `macro-economist`
|
|
859
|
+
|
|
860
|
+
Macroeconomic analysis and policy expert.
|
|
861
|
+
|
|
862
|
+
**Expertise**:
|
|
863
|
+
- Business cycle analysis
|
|
864
|
+
- Central bank policy interpretation
|
|
865
|
+
- Inflation and growth dynamics
|
|
866
|
+
- Asset class implications
|
|
867
|
+
- Geopolitical risk assessment
|
|
868
|
+
|
|
869
|
+
**Use with**: `/openbb-macro`, `/openbb-research`
|
|
870
|
+
|
|
871
|
+
---
|
|
872
|
+
|
|
873
|
+
## 📚 Real-World Examples
|
|
874
|
+
|
|
875
|
+
### Example 1: Stock Deep-Dive
|
|
876
|
+
|
|
877
|
+
```bash
|
|
878
|
+
# Step 1: Fundamental + technical analysis
|
|
879
|
+
/openbb-equity AAPL --analysis=all --period=1y
|
|
880
|
+
|
|
881
|
+
# Step 2: Get AI agent insights
|
|
882
|
+
Ask equity-analyst: "Analyze AAPL based on the data above. What's your investment recommendation?"
|
|
883
|
+
|
|
884
|
+
# Step 3: Check macro context
|
|
885
|
+
/openbb-macro --country=US --indicators=all
|
|
886
|
+
|
|
887
|
+
# Step 4: Generate comprehensive report
|
|
888
|
+
/openbb-research AAPL --depth=deep
|
|
889
|
+
```
|
|
890
|
+
|
|
891
|
+
**Output**: Complete investment case with buy/hold/sell recommendation and price targets.
|
|
892
|
+
|
|
893
|
+
---
|
|
894
|
+
|
|
895
|
+
### Example 2: Crypto Portfolio Optimization
|
|
896
|
+
|
|
897
|
+
```bash
|
|
898
|
+
# Analyze holdings
|
|
899
|
+
/openbb-crypto BTC
|
|
900
|
+
/openbb-crypto ETH --metrics=defi
|
|
901
|
+
/openbb-crypto SOL --metrics=on-chain
|
|
902
|
+
|
|
903
|
+
# Get agent recommendations
|
|
904
|
+
Ask crypto-analyst: "I hold BTC (50%), ETH (30%), SOL (20%). Should I rebalance?"
|
|
905
|
+
|
|
906
|
+
# Check macro impact
|
|
907
|
+
/openbb-macro --indicators=inflation # Crypto as inflation hedge?
|
|
908
|
+
|
|
909
|
+
# Portfolio integration
|
|
910
|
+
/openbb-portfolio --analyze # See crypto in broader context
|
|
911
|
+
```
|
|
912
|
+
|
|
913
|
+
---
|
|
914
|
+
|
|
915
|
+
### Example 3: Options Income Strategy
|
|
916
|
+
|
|
917
|
+
```bash
|
|
918
|
+
# Find covered call opportunity
|
|
919
|
+
/openbb-equity SPY --analysis=technical
|
|
920
|
+
|
|
921
|
+
# Check options chain
|
|
922
|
+
/openbb-options SPY --strategy=covered-call
|
|
923
|
+
|
|
924
|
+
# Analyze risk/reward
|
|
925
|
+
Ask equity-analyst: "SPY at $450. Is selling $470 calls for $2 premium a good covered call?"
|
|
926
|
+
|
|
927
|
+
# Monitor position
|
|
928
|
+
/openbb-portfolio --analyze
|
|
929
|
+
```
|
|
930
|
+
|
|
931
|
+
---
|
|
932
|
+
|
|
933
|
+
### Example 4: Macro-Driven Portfolio Positioning
|
|
934
|
+
|
|
935
|
+
```bash
|
|
936
|
+
# Assess economic regime
|
|
937
|
+
/openbb-macro --country=US --indicators=all
|
|
938
|
+
|
|
939
|
+
# Get macro interpretation
|
|
940
|
+
Ask macro-economist: "Based on this data, are we early/mid/late cycle? What's the recession risk?"
|
|
941
|
+
|
|
942
|
+
# Adjust portfolio
|
|
943
|
+
Ask portfolio-manager: "Given this macro outlook, how should I position? What sectors to overweight?"
|
|
944
|
+
|
|
945
|
+
# Execute changes
|
|
946
|
+
/openbb-equity XLK # Tech sector
|
|
947
|
+
/openbb-equity XLE # Energy sector
|
|
948
|
+
/openbb-portfolio --optimize
|
|
949
|
+
```
|
|
950
|
+
|
|
951
|
+
---
|
|
952
|
+
|
|
953
|
+
## 🔧 Configuration
|
|
954
|
+
|
|
955
|
+
### OpenBB API Keys (Optional)
|
|
956
|
+
|
|
957
|
+
For premium data, configure API keys:
|
|
958
|
+
|
|
959
|
+
```python
|
|
960
|
+
from openbb import obb
|
|
961
|
+
|
|
962
|
+
# Set credentials
|
|
963
|
+
obb.user.credentials.fmp_api_key = "YOUR_KEY" # Financial Modeling Prep
|
|
964
|
+
obb.user.credentials.polygon_api_key = "YOUR_KEY" # Polygon.io
|
|
965
|
+
obb.user.credentials.alpha_vantage_api_key = "YOUR_KEY" # Alpha Vantage
|
|
966
|
+
|
|
967
|
+
# Save configuration
|
|
968
|
+
obb.user.save()
|
|
969
|
+
```
|
|
970
|
+
|
|
971
|
+
### Data Providers
|
|
972
|
+
|
|
973
|
+
OpenBB supports 100+ data providers:
|
|
974
|
+
- **Free**: Yahoo Finance, Alpha Vantage (limited)
|
|
975
|
+
- **Freemium**: Polygon, FMP, Intrinio
|
|
976
|
+
- **Premium**: Bloomberg, Refinitiv, FactSet
|
|
977
|
+
|
|
978
|
+
See [OpenBB docs](https://docs.openbb.co/platform/reference) for full list.
|
|
979
|
+
|
|
980
|
+
---
|
|
981
|
+
|
|
982
|
+
## 📊 Data Coverage
|
|
983
|
+
|
|
984
|
+
### Equity Data
|
|
985
|
+
- **Stocks**: 50,000+ global equities
|
|
986
|
+
- **Indices**: S&P 500, Nasdaq, Dow, international indices
|
|
987
|
+
- **ETFs**: 3,000+ ETFs and sector funds
|
|
988
|
+
- **Historical**: Up to 20+ years of data
|
|
989
|
+
|
|
990
|
+
### Cryptocurrency
|
|
991
|
+
- **Assets**: 10,000+ cryptocurrencies
|
|
992
|
+
- **Exchanges**: Binance, Coinbase, Kraken, 20+ more
|
|
993
|
+
- **DeFi**: 1,000+ protocols on Ethereum, BSC, Polygon
|
|
994
|
+
- **On-Chain**: BTC, ETH, and major L1s
|
|
995
|
+
|
|
996
|
+
### Macroeconomic
|
|
997
|
+
- **Countries**: 180+ countries
|
|
998
|
+
- **Indicators**: 200+ economic data series
|
|
999
|
+
- **Central Banks**: Fed, ECB, BOJ, BOE, PBOC
|
|
1000
|
+
- **Frequency**: Daily, monthly, quarterly
|
|
1001
|
+
|
|
1002
|
+
### Options
|
|
1003
|
+
- **Equities**: All optionable US stocks
|
|
1004
|
+
- **Indices**: SPX, NDX, RUT
|
|
1005
|
+
- **ETFs**: SPY, QQQ, IWM, sector ETFs
|
|
1006
|
+
- **Expirations**: All available dates
|
|
1007
|
+
|
|
1008
|
+
---
|
|
1009
|
+
|
|
1010
|
+
## 🎯 Use Cases
|
|
1011
|
+
|
|
1012
|
+
### For Individual Investors
|
|
1013
|
+
- **Stock Screening**: Find undervalued stocks with `/openbb-equity`
|
|
1014
|
+
- **Crypto Trading**: Track market sentiment with `/openbb-crypto`
|
|
1015
|
+
- **Portfolio Tracking**: Monitor performance with `/openbb-portfolio`
|
|
1016
|
+
- **Options Income**: Generate income with `/openbb-options`
|
|
1017
|
+
|
|
1018
|
+
### For Financial Analysts
|
|
1019
|
+
- **Research Reports**: Auto-generate with `/openbb-research`
|
|
1020
|
+
- **Earnings Analysis**: Deep-dive fundamentals
|
|
1021
|
+
- **Macro Forecasting**: Economic scenario planning
|
|
1022
|
+
- **Comp Analysis**: Compare valuation multiples
|
|
1023
|
+
|
|
1024
|
+
### For Quants
|
|
1025
|
+
- **Factor Analysis**: Extract data for backtests
|
|
1026
|
+
- **Risk Modeling**: Calculate portfolio VaR
|
|
1027
|
+
- **Algo Development**: API integration for strategies
|
|
1028
|
+
- **Performance Attribution**: Decompose returns
|
|
1029
|
+
|
|
1030
|
+
### For Portfolio Managers
|
|
1031
|
+
- **Asset Allocation**: Optimize with `/openbb-portfolio`
|
|
1032
|
+
- **Rebalancing**: Systematic rebalance triggers
|
|
1033
|
+
- **Risk Management**: Monitor drawdowns
|
|
1034
|
+
- **Client Reporting**: Automated performance reports
|
|
1035
|
+
|
|
1036
|
+
---
|
|
1037
|
+
|
|
1038
|
+
## 🔗 Integration
|
|
1039
|
+
|
|
1040
|
+
### With Other Plugins
|
|
1041
|
+
|
|
1042
|
+
```bash
|
|
1043
|
+
# With ai-commit-gen (track research as commits)
|
|
1044
|
+
/openbb-research AAPL --depth=deep
|
|
1045
|
+
/commit # Commit research notes
|
|
1046
|
+
|
|
1047
|
+
# With overnight-dev (run backtests overnight)
|
|
1048
|
+
/overnight-dev "Backtest AAPL trading strategy using OpenBB data"
|
|
1049
|
+
|
|
1050
|
+
# With git-commit-smart (version research)
|
|
1051
|
+
/gc # Smart commit research findings
|
|
1052
|
+
```
|
|
1053
|
+
|
|
1054
|
+
### With External Tools
|
|
1055
|
+
|
|
1056
|
+
- **Excel/Sheets**: Export data via pandas `.to_csv()`
|
|
1057
|
+
- **Jupyter Notebooks**: Run OpenBB commands in notebooks
|
|
1058
|
+
- **Trading Platforms**: Use data for order execution
|
|
1059
|
+
- **Portfolio Trackers**: Import holdings and performance
|
|
1060
|
+
|
|
1061
|
+
---
|
|
1062
|
+
|
|
1063
|
+
## ⚙️ Advanced Features
|
|
1064
|
+
|
|
1065
|
+
### Custom Analysis Workflows
|
|
1066
|
+
|
|
1067
|
+
Create custom research pipelines:
|
|
1068
|
+
|
|
1069
|
+
```python
|
|
1070
|
+
# Multi-stock comparison
|
|
1071
|
+
for ticker in ["AAPL", "MSFT", "GOOGL"]:
|
|
1072
|
+
/openbb-equity {ticker} --analysis=all
|
|
1073
|
+
Ask equity-analyst: "Quick assessment of {ticker}"
|
|
1074
|
+
|
|
1075
|
+
# Sector rotation analysis
|
|
1076
|
+
sectors = ["XLK", "XLE", "XLF", "XLV", "XLI"]
|
|
1077
|
+
for sector in sectors:
|
|
1078
|
+
/openbb-equity {sector}
|
|
1079
|
+
/openbb-macro --impact=sector
|
|
1080
|
+
|
|
1081
|
+
# Crypto basket strategy
|
|
1082
|
+
cryptos = ["BTC", "ETH", "SOL", "AVAX"]
|
|
1083
|
+
for crypto in cryptos:
|
|
1084
|
+
/openbb-crypto {crypto} --metrics=all
|
|
1085
|
+
```
|
|
1086
|
+
|
|
1087
|
+
### Automated Alerts
|
|
1088
|
+
|
|
1089
|
+
Set up monitoring:
|
|
1090
|
+
|
|
1091
|
+
```python
|
|
1092
|
+
# Price alerts
|
|
1093
|
+
if current_price < sma_200:
|
|
1094
|
+
print(f"🚨 {ticker} below 200-day SMA - potential buy")
|
|
1095
|
+
|
|
1096
|
+
# Volatility alerts
|
|
1097
|
+
if portfolio_vol > target_vol * 1.5:
|
|
1098
|
+
print("⚠️ Portfolio risk elevated - rebalance needed")
|
|
1099
|
+
|
|
1100
|
+
# Macro alerts
|
|
1101
|
+
if inflation_yoy > 4.0:
|
|
1102
|
+
print("🔥 High inflation - consider inflation hedges")
|
|
1103
|
+
```
|
|
1104
|
+
|
|
1105
|
+
---
|
|
1106
|
+
|
|
1107
|
+
## 📖 Documentation
|
|
1108
|
+
|
|
1109
|
+
- **OpenBB Platform Docs**: https://docs.openbb.co/platform
|
|
1110
|
+
- **API Reference**: https://docs.openbb.co/platform/reference
|
|
1111
|
+
- **Data Providers**: https://docs.openbb.co/platform/data_providers
|
|
1112
|
+
- **GitHub**: https://github.com/OpenBB-finance/OpenBB
|
|
1113
|
+
|
|
1114
|
+
---
|
|
1115
|
+
|
|
1116
|
+
## 🚨 Important Notes
|
|
1117
|
+
|
|
1118
|
+
### Disclaimers
|
|
1119
|
+
|
|
1120
|
+
- **Not Financial Advice**: All analysis is for informational purposes only
|
|
1121
|
+
- **Do Your Own Research**: Always verify data and consult professionals
|
|
1122
|
+
- **Risk Disclosure**: Past performance doesn't guarantee future results
|
|
1123
|
+
- **Data Accuracy**: Verify critical data from multiple sources
|
|
1124
|
+
|
|
1125
|
+
### Data Limitations
|
|
1126
|
+
|
|
1127
|
+
- **Free Tier**: 15-20 minute delays on some data
|
|
1128
|
+
- **API Limits**: Rate limits apply (varies by provider)
|
|
1129
|
+
- **Coverage**: Not all assets have complete data
|
|
1130
|
+
- **Historical**: Survivorship bias in long-term data
|
|
1131
|
+
|
|
1132
|
+
---
|
|
1133
|
+
|
|
1134
|
+
## 🤝 Contributing
|
|
1135
|
+
|
|
1136
|
+
Help improve this plugin:
|
|
1137
|
+
|
|
1138
|
+
1. Report issues with specific commands
|
|
1139
|
+
2. Suggest new analysis workflows
|
|
1140
|
+
3. Share custom agent configurations
|
|
1141
|
+
4. Contribute example use cases
|
|
1142
|
+
|
|
1143
|
+
---
|
|
1144
|
+
|
|
1145
|
+
## 📜 License
|
|
1146
|
+
|
|
1147
|
+
MIT License - See [LICENSE](LICENSE) file for details.
|
|
1148
|
+
|
|
1149
|
+
**OpenBB Platform**: Apache 2.0 License
|
|
1150
|
+
|
|
1151
|
+
---
|
|
1152
|
+
|
|
1153
|
+
## 🙋 Support
|
|
1154
|
+
|
|
1155
|
+
- **Plugin Issues**: https://github.com/jeremylongshore/claude-code-plugins/issues
|
|
1156
|
+
- **OpenBB Issues**: https://github.com/OpenBB-finance/OpenBB/issues
|
|
1157
|
+
- **Discord**: https://discord.gg/openbb (OpenBB community)
|
|
1158
|
+
- **Discussions**: https://github.com/jeremylongshore/claude-code-plugins/discussions
|
|
1159
|
+
|
|
1160
|
+
---
|
|
1161
|
+
|
|
1162
|
+
**Transform Claude Code into a professional investment research terminal. Install now and start analyzing!** 📊🚀
|