跳到正文
cccskills
免费在 GitHub 公开

a-share-runtime-data-access

Retrieve locally stored Chinese A-share prices, financial statements, and valuation context through the project's shared interfaces. Look up technical indicators, inspect available data fields, and check data dates when results disagree.

中文简介正在准备中。当前显示英语简介。

原文查看原文说明

Use when the task requires reading A-share stock data, financial data, valuation context, or querying local stock collections through core.skill_runtime runtime interfaces.

查看安装方法

适用场景

  • Checking a stock's prices and valuation context
  • Retrieving financial data across reporting periods
  • Looking up technical indicators and their data dates
  • Inspecting available local data fields

包含的文件(1)

  • SKILL.md6.0 KB

SKILL.md(原文)

安装前可以查看交给 AI 代理的指令内容。

A-share Runtime Data Access

Use this skill when the user asks for A-share local data retrieval, quote lookup, financial period lookup, valuation context building, technical indicator lookup, or schema inspection through the project's public runtime interfaces and local tools.

Scope

  • Only handle A-share data in this workflow.
  • Do not switch to multi-market logic unless the user explicitly changes scope.
  • Prefer the project's public runtime interfaces over direct database access.

First Read

Before fetching data, read these documents in order:

  1. docs/design/runtime-interfaces/skill-runtime-overview.md
  2. docs/design/runtime-interfaces/local-data-access-design.md
  3. docs/design/runtime-interfaces/project-access-and-governance.md

If you need concrete function signatures or allowed collections, then read:

  1. core/skill_runtime/data_access.py
  2. core/skill_runtime/project_access.py
  3. core/skill_runtime/catalog.py

Runtime Rules

  • Prefer core.skill_runtime.data_access for business-semantic data access.
  • Use core.skill_runtime.project_access only when helper functions are insufficient or when inspecting schema / field coverage.
  • Do not create MongoClient or import pymongo directly.
  • Do not bypass core.skill_runtime by reading lower-level provider or database modules unless the user explicitly asks for code archaeology.
  • For technical analysis, prefer the project's local technical tools and materialized snapshots over ad hoc indicator calculation.

Preferred Helpers

For common A-share tasks, prefer these helpers first:

  1. get_stock_basic_info(symbol)
  2. get_market_quotes(symbol)
  3. get_latest_stock_price(symbol)
  4. get_stock_daily_quotes(symbol, start_date, end_date)
  5. get_stock_financial_periods(symbol)
  6. get_stock_financial_data(symbol)
  7. get_stock_valuation_context(symbol)
  8. get_stock_news(symbol)
  9. query_stock_collection(collection, ...)
  10. inspect_stock_collection_schema(collection, ...)

For technical-analysis tasks, prefer these entry points first:

  1. core.tools.implementations.market.technical_factor_bundle_tool.get_technical_factor_bundle_tool
  2. core.tools.implementations.market.technical_indicators.get_technical_indicators

Use the factor bundle first when the user needs structured MA20, RSI14, KDJ, or MACD values. Use get_technical_indicators only when the user wants a readable technical-analysis report rather than a structured factor payload.

When checking freshness or explaining discrepancies, inspect these components in order:

  1. stock_technical_indicators latest trade_date
  2. market_quotes latest trade_date
  3. app/services/technical_indicator_materialization_service.py
  4. app/main.py technical indicator materialization job configuration

How To Execute In Embedded Nanobot

The embedded nanobot runtime does not expose core.skill_runtime as a first-class tool yet. When you need actual data, do this:

  1. Read the design docs and target runtime module.
  2. If the goal is only validation, inspection, or one-time probing, write a short temporary Python script under temp/.
  3. Run the script with C:\TradingAgentsCN\env\Scripts\python.exe using the exec tool.
  4. Summarize the returned data clearly for the user.

Do not treat a temp/*.py script as the final artifact when the logic is clearly reusable. If the requested logic is parameterizable and should work for other stocks or other future runs, use the temp script only as a short validation probe and then promote the implementation into a reusable skill.

For technical-analysis tasks in embedded nanobot, use this execution pattern:

  1. If the user wants structured technical values, call get_technical_factor_bundle_tool from a temp script.
  2. If the user wants a textual technical interpretation, call get_technical_indicators from a temp script.
  3. If the tool result conflicts with price data, compare stock_technical_indicators.trade_date against market_quotes.trade_date before concluding there is a bug.

For embedded runtime work, apply this boundary:

  1. use temp scripts for fast verification and data access that the runtime does not yet expose directly
  2. if the output is becoming a named reusable capability, convert it into a skill instead of leaving it in temp/
  3. if the task is still exploratory and the reusable shape is not yet confirmed, say that explicitly

Windows Execution Rule

On Windows, do not rely on inline python -c snippets for runtime verification. Prefer writing a temporary .py file and then executing it. This avoids quoting and shell-expansion issues.

Minimal Script Pattern

from pathlib import Path
import sys

repo = Path(r"C:\TradingAgentsCN")
sys.path.insert(0, str(repo))

from core.skill_runtime.data_access import get_stock_basic_info

data = get_stock_basic_info("600519")
print(data)

Helper Selection Guide

  • If the user asks for one stock's snapshot, start with get_stock_basic_info or get_stock_valuation_context.
  • If the user asks for multi-period fundamentals, start with get_stock_financial_periods.
  • If the user asks for technical indicators, start with get_technical_factor_bundle_tool.
  • If the user asks for a prose-style technical reading, use get_technical_indicators after confirming the requested date range.
  • If the user asks for local collection availability or fields, start with inspect_stock_collection_schema.
  • If the user asks for a direct collection sample, use query_stock_collection only after confirming the collection is publicly exposed in catalog.py.

Response Expectations

  • State which runtime interface you used.
  • If data is empty, state whether the helper returned no records or the collection/helper is not exposed.
  • When validation fails, report whether the problem is instruction gap, interface usage error, or missing underlying data.

评价

还没有评价。欢迎分享你的使用感受。

评论

无需登录即可发表。欢迎分享使用感受、提问,或说明在哪些环境下无法运行。

还没有评论。来写第一条吧。

提交后会立即公开。请勿填写邮箱、电话等个人信息。URL 最多 2 个。

0 / 1000 字

此表单受 reCAPTCHA 保护,适用 Google 的隐私权政策和服务条款。

同一仓库的技能

Retrieve financial data through natural language queries, including Chinese A-share stocks, funds, futures, company financials, and economic indicators. The skill calls a Python script and presents key results as concise summaries and tables.

中文简介正在准备中。当前显示英语简介。

  • Checking stock prices and daily market data
  • Retrieving recently disclosed revenue and profit
  • Comparing prices across stocks
hsliuping/TradingAgents-CN3.2万2026年9月22日 更新

Search financial news, industry developments, and company sentiment using natural-language questions. Retrieve related headlines, summaries, sources, and article links through a Python script, with optional date ranges to focus the search on a specific period.

中文简介正在准备中。当前显示英语简介。

  • Finding financial news related to a question
  • Researching market and industry developments
  • Checking news and public sentiment about a company
hsliuping/TradingAgents-CN3.2万2026年9月22日 更新

Design and generate agents in Nanobot by finding reusable tools, skills, prompts, and existing agent configurations. Guide requirements and confirmation, create focused agent assets, and follow recorded real-data testing and evaluation before publication.

中文简介正在准备中。当前显示英语简介。

  • Designing an agent around existing project resources
  • Adapting existing agent configurations and prompts
  • Identifying missing tools and calculation capabilities
hsliuping/TradingAgents-CN3.2万2026年9月22日 更新

Investigate and fix agent behavior in TradingAgentsCN by checking active database prompt templates, prompt assembly code, and output processing. Apply targeted changes and verify them with focused tests, template checks, and workflow logs.

中文简介正在准备中。当前显示英语简介。

  • Investigating prompt changes that do not affect runtime behavior
  • Synchronizing database templates with prompt assembly code
  • Tracing incorrect dates or price references in position analysis
hsliuping/TradingAgents-CN3.2万2026年9月22日 更新

Estimate the distribution of stockholders' purchase costs for Chinese A-share stocks using price and volume data. A triangular model produces cost concentration metrics, the estimated share below the current price, and visualization charts.

中文简介正在准备中。当前显示英语简介。

  • Examining estimated purchase cost distributions for Chinese A-share stocks
  • Checking the estimated share of holdings below the current price
  • Identifying price ranges with concentrated holdings
hsliuping/TradingAgents-CN3.2万2026年9月22日 更新

查看 hsliuping 的全部技能

报告此技能的问题