stock_indicators_hk
Retrieve key financial indicators from Hong Kong stock market reports 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:189-194 (handler)The handler function that fetches financial analysis indicators for HK stocks using akshare, caches the result, and returns the top 15 rows as CSV.def stock_indicators_hk( symbol: str = field_symbol, ): dfs = ak_cache(ak.stock_financial_hk_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:185-188 (registration)Registers the stock_indicators_hk tool with the MCP server using the @mcp.tool decorator, specifying its title and description.@mcp.tool( title="港股关键指标", description="获取港股市场的股票财务报告关键指标", )
- mcp_aktools/__init__.py:20-20 (schema)Shared Pydantic Field schema definition for the 'symbol' input parameter used across stock tools, including stock_indicators_hk.field_symbol = Field(description="股票代码")