Documentation Index Fetch the complete documentation index at: https://docs.llmquantdata.com/llms.txt
Use this file to discover all available pages before exploring further.
已暴露为 MCP 工具 :macro_indicator_search + macro_indicator_history —— 在 Claude / Cursor / 任意 MCP 客户端中直接调用。详见 MCP Server 60 秒配置。
已上线
1 credit · history
免费 · search
它为 Agent 做什么
macro_indicator_history 返回单个支持的美国宏观指标(CPI、UNRATE、Fed Funds、10Y 收益率、GDP 等)的 latest-vintage 历史时间序列 —— 一组 { date, value, realtime_start, realtime_end } observation。它是 agent 的 宏观时间序列拉取器 :要把过去 5 年通胀画图、要算收益率曲线斜率、要把 observation 喂下游模型时调它。
canonical 的 agent 流程是两步:先调 macro_indicator_search(免费)找到正确的 indicator alias,再调 macro_indicator_history 拉序列。两种查询模式:
Recent 模式 —— 传 limit(默认 60)取最近 N 个 observation。
Range 模式 —— 传 start_date + end_date 取一个固定窗口。
Agent flow
返回值
指标元信息 + observations 数组。 回显的平台稳定 alias(如 us.cpi.headline)。
上游 FRED series ID(如 CPIAUCSL)。
原生发布频率:Daily、Weekly、Monthly、Quarterly、Annual。
单位字符串(如 Index 1982-1984=100、Percent)。
observations
MacroObservation[]
required
时间升序的 observation(旧 → 新)。 该值首次发布日(YYYY-MM-DD)。用来识别 revision。
该值的有效结束日。当前 latest vintage 通常等于 realtime_start。
200 OK · macro_indicator_history
{
"data" : {
"indicator" : "us.cpi.headline" ,
"series_id" : "CPIAUCSL" ,
"title" : "Consumer Price Index for All Urban Consumers: All Items in U.S. City Average" ,
"frequency" : "Monthly" ,
"units" : "Index 1982-1984=100" ,
"observations" : [
{
"date" : "2026-01-01" ,
"value" : 318.412 ,
"realtime_start" : "2026-02-12" ,
"realtime_end" : "2026-02-12"
},
{
"date" : "2026-02-01" ,
"value" : 319.082 ,
"realtime_start" : "2026-03-12" ,
"realtime_end" : "2026-03-12"
},
{
"date" : "2026-03-01" ,
"value" : 319.799 ,
"realtime_start" : "2026-04-10" ,
"realtime_end" : "2026-04-10"
}
],
"attribution" : "Source: U.S. Bureau of Labor Statistics via FRED"
},
"meta" : {
"count" : 3 ,
"stale" : false ,
"creditsUsed" : 1 ,
"remainingCredits" : 99 ,
"sourceNotice" : "This product uses the FRED® API but is not endorsed or certified by the Federal Reserve Bank of St. Louis."
}
}
See all 37 lines
Revision-aware :宏观 observation 会被修订。我们返回的是当前 latest vintage —— FRED 今天发布的值,不一定是当初首发的值。用 realtime_start / realtime_end 判断你是不是看到了修订后的版本。MVP 不支持 ALFRED 风格的 as-of 历史回放。
默认 limit=60 大致覆盖月频 5 年、周频 1 年、日频 3 个月。需要更长就提到 500 或改用 Range 模式。缓存跨用户共享,热门指标基本秒回。
Recent 与 Range 模式互斥。 要么单传 limit,要么同时传 start_date + end_date。只传一个 date 返回 400。
仅 allowlist 内。 约 50 个精选美国指标,allowlist 之外返回 404。用 macro_indicator_search 浏览可用列表。
直接调用
MCP (Claude / Cursor)
Python (HTTP)
cURL
// 1) 找 alias
{
"method" : "tools/call" ,
"params" : {
"name" : "macro_indicator_search" ,
"arguments" : { "q" : "cpi" , "category" : "Inflation" }
}
}
// 2) 取最近的 history(默认 60)
{
"method" : "tools/call" ,
"params" : {
"name" : "macro_indicator_history" ,
"arguments" : { "indicator" : "us.cpi.headline" , "limit" : 60 }
}
}
// 2b) 或取一个明确的日期范围
{
"method" : "tools/call" ,
"params" : {
"name" : "macro_indicator_history" ,
"arguments" : {
"indicator" : "us.cpi.headline" ,
"start_date" : "2020-01-01" ,
"end_date" : "2026-03-01"
}
}
}
完整参数参考
macro_indicator_search — 请求参数
自由文本关键词,匹配 indicator alias、FRED 标题、series_id。
按主题过滤(Inflation、Rates、Labor、Growth、Housing、Liquidity、Conditions、FX、Credit、Sentiment、Energy、Inflation Expectations、Consumption)。
按发布频率过滤(Daily、Weekly、Monthly、Quarterly、Annual)。
macro_indicator_history — 请求参数
平台 alias(如 us.cpi.headline、us.rates.fed_funds)。与 series_id 二选一 。
FRED series ID(如 CPIAUCSL)。与 indicator 二选一 。必须在 allowlist 内。
Range 模式。ISO 日期 YYYY-MM-DD。必须与 end_date 同时使用。
Range 模式。ISO 日期 YYYY-MM-DD。必须与 start_date 同时使用。
Recent 模式返回条数。范围 1–500。Range 模式下被忽略。
相关接口
宏观指标目录 浏览约 50 个精选指标 allowlist(免费)。
宏观指标快照 只看最新值 + 涨跌(不返回完整序列)。