跳到正文
Skillpedia
分析与电子表格37k · #7552

sec-edgar

它能做什么

这项技能从美国证券交易委员会(SEC)获取美国公司的官方申报文件和财务数据。适合需要美国上市公司原始文件的投资者和分析师。

适用场景

  • ✓当你想获取某家美国上市公司最新的 10-K 或 10-Q 报告的时候。
  • ✓当你需要从官方申报文件中获取某家公司披露的营收或盈利历史的时候。
  • ✓当你想查找某家美国公司提交的 8-K 公告的时候。

技能链接

https://github.com/HKUDS/Vibe-Trading/blob/main/agent/src/skills/sec-edgar/SKILL.md

复制后粘贴给你的 AI(Claude、ChatGPT 或 Cursor),让它按照说明操作。

使用方法

最简单的方法:复制下面的消息,粘贴给你的 AI。它会读取这个技能并按说明操作。

可直接粘贴的消息

请用这个技能帮我:https://github.com/HKUDS/Vibe-Trading/blob/main/agent/src/skills/sec-edgar/SKILL.md 阅读该链接中的 SKILL.md 文件,并在我的任务中按照它的说明来做。
想让你的 AI 自己找到这样的技能吗?安装免费的 Skillpedia MCP:只需一行,每次任务前它都会在 15,000+ 个技能中搜索。1 分钟完成安装 →

可以这样问 AI

“请找到苹果公司最新的 10-K 申报文件,并从 SEC 数据中获取其营收历史。”

每周 5 个新技能,1 分钟读完。

工作原理

它会根据股票代码查找公司的 SEC 标识符,然后列出最近的申报文件及文件链接。它还会获取公司以 XBRL 格式披露的财务数据。

技术内容(原始 SKILL.md)

作者在 GitHub 上的英文原文。

SEC EDGAR

Overview

The U.S. Securities and Exchange Commission (SEC) publishes free, no-auth JSON endpoints for every reporting company on its EDGAR system: a ticker-to-CIK directory, a recent-filings index, and the full set of XBRL ("companyfacts") financial concepts a company has reported. This skill documents how Vibe-Trading fetches that data through the bundled sec_edgar_client transport and the get_sec_filings agent tool.

This is the fetch skill — it covers how to get filing-index rows, document URLs, and us-gaap metric series out of EDGAR. The separate edgar-sec-filings skill is the methodology layer (how to read a 10-K, score insider activity, interpret 8-K items); for any actual data retrieval it delegates here.

Scope is the United States only. EDGAR has no coverage of A-shares, HK, or other non-U.S. markets — route those through tushare / yfinance / akshare instead.

Link convention: every link below that points into references/ is written relative to this document (references/...) — the form GitHub resolves when someone opens the file in a browser. The read_file tool resolves the same string against the skill that owns it, so the agent and a human reader reach one file. Keep the relative form when adding new docs, and keep reference paths unique across skills: a path two skills both carry is reported as ambiguous rather than guessed.

Quick Start

Preferred path — the get_sec_filings tool (read-only, throttled, returns strict JSON):

{ "ticker": "AAPL", "form": "10-K", "limit": 5 }
{ "ticker": "MSFT", "metric": "Revenues", "limit": 8 }

The tool resolves the ticker to a CIK, fetches the filing index (optionally filtered by form), and — when metric is set — also pulls the XBRL series for that us-gaap concept. See sec-edgar/references/get_sec_filings_tool.md for the full parameter and envelope contract.

Script path — call the sec_edgar_client transport directly when you need raw JSON the tool does not surface (e.g. company address, all units of a concept):

from backtest.loaders.sec_edgar_client import cik_for, get_submissions, get_company_facts

cik = cik_for("AAPL")            # "0000320193", or None if not in the SEC table
submissions = get_submissions(cik)   # recent-filings index + company metadata
facts = get_company_facts(cik)       # all reported XBRL concepts

A runnable end-to-end example lives at sec-edgar/scripts/sec_filings_example.py.

Parameter & Format Notes

  • Ticker: U.S. equity symbol, case-insensitive (AAPL, msft). Resolved to a CIK via the SEC company-tickers table; an unlisted ticker returns an error envelope (tool) or None (cik_for).
  • CIK: the SEC Central Index Key, normalized to a zero-padded 10-digit string (320193 → "0000320193"). The submissions and companyfacts endpoints require the padded form; document URLs use the un-padded form.
  • Form: SEC form type, case-insensitive (10-K, 10-Q, 8-K, DEF 14A, 4). Omit to return all recent forms.
  • Metric: an XBRL us-gaap concept name (Revenues, NetIncomeLoss, Assets, StockholdersEquity). Case-sensitive — these are exact taxonomy element names.
  • Dates: SEC returns ISO YYYY-MM-DD strings (e.g. 2023-09-30).
  • Return shape: the tool returns a JSON-string envelope; the client returns decoded JSON (dict).

Reference Docs

Scripts

Notes

  • Free, no API key: EDGAR is public. The only requirement is a descriptive User-Agent carrying a contact address; the client ships a compliant default and honors the VIBE_TRADING_SEC_UA override.
  • Rate-limited by IP: the SEC throttles per source IP and temporarily blocks clients that burst without a contact UA. Every request routes
常见问题

它涵盖美国以外的公司吗?

不涵盖。SEC EDGAR 只覆盖美国的申报公司,因此其他市场需要其他数据源。

我需要 API 密钥吗?

不需要。SEC 接口无需密钥,但请求会按 IP 进行频率限制,因此技能会对请求进行节流。

什么是 XBRL?

XBRL 是公司用来标记财务数据的标准格式,计算机可以读取。

详情

作者的原始描述

U.S. SEC EDGAR fetch interface — resolve a ticker to its CIK, list recent filings (10-K / 10-Q / 8-K and friends) with primary-document URLs, and pull XBRL companyfacts financial series. Free, no API key; rate-limited by IP so every request is throttled and carries a contact User-Agent. United States only.

repo: HKUDS/Vibe-Trading

热度

GitHub 星标
37k
排名
#7552
许可证
MIT
更新时间
2026/11/1

这个技能有用吗?

0

登录 后即可投票。

评论

  • …

同一仓库的更多技能

相似技能