stock_indicators_us
Retrieve key financial indicators for US stocks to analyze company performance and make informed investment decisions.
Instructions
获取美股市场的股票财务报告关键指标
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| symbol | Yes | 股票代码 |
Implementation Reference
- mcp_aktools/__init__.py:201-206 (handler)The handler function for the 'stock_indicators_us' tool. It fetches financial analysis indicators for a US stock using the akshare library, applies caching via ak_cache, formats the DataFrame as CSV, and returns the first 15 rows.def stock_indicators_us( symbol: str = field_symbol, ): dfs = ak_cache(ak.stock_financial_us_analysis_indicator_em, symbol=symbol, indicator="单季报") keys = dfs.to_csv(index=False, float_format="%.3f").strip().split("\n") return "\n".join(keys[0:15])
- mcp_aktools/__init__.py:197-200 (registration)The @mcp.tool decorator registers the 'stock_indicators_us' function as an MCP tool with title and description in Chinese.@mcp.tool( title="美股关键指标", description="获取美股市场的股票财务报告关键指标", )
- mcp_aktools/__init__.py:20-20 (schema)Pydantic Field definition for the 'symbol' parameter used in the tool's input schema, shared across multiple stock tools.field_symbol = Field(description="股票代码")