通达信TQ

通达信TQ is a skill for Claude Code, Codex from adambbhe/TDX-finance-mcp-plugin-v3. It costs 56 tokens per session (24,991 once invoked), scanned A, original, MIT.

A connection between Python strategy files and TdxQuant, TongdaXin's platform for securities data analysis and quantitative investment research. It uses the platform's tqcenter.py module to interact with the TongdaXin client.

In plain words
What is it for?
Use it to work with TongdaXin market data, analysis, strategy research, investment decisions, or automated trading from Python.
Why use it?
It gives Python strategies a documented way to use the TongdaXin client's quantitative research interface instead of handling that connection manually.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it to work with TongdaXin market data, analysis, strategy research, investment decisions, or automated trading from Python.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/adambbhe/tdx-finance-mcp-plugin-v3/tdx-quant
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add adambbhe/TDX-finance-mcp-plugin-v3 --skill tdx-quant
Clone the repo
git clone --depth 1 https://github.com/adambbhe/TDX-finance-mcp-plugin-v3

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for 通达信TQ

README.md
[![agentmods](https://agentmods.dev/badge/skills/adambbhe/tdx-finance-mcp-plugin-v3/tdx-quant/github.svg)](https://agentmods.dev/skills/adambbhe/tdx-finance-mcp-plugin-v3/tdx-quant)
Your own site
<a href="https://agentmods.dev/skills/adambbhe/tdx-finance-mcp-plugin-v3/tdx-quant"><img src="https://agentmods.dev/badge/skills/adambbhe/tdx-finance-mcp-plugin-v3/tdx-quant/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for 通达信TQ

Your own site · 80×15
<a href="https://agentmods.dev/skills/adambbhe/tdx-finance-mcp-plugin-v3/tdx-quant"><img src="https://agentmods.dev/badge/skills/adambbhe/tdx-finance-mcp-plugin-v3/tdx-quant.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 56 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 24,991 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00056 $0.24991
Opus 5 $0.00028 $0.12495
Sonnet 5 $0.00011 $0.04998
Haiku 4.5 $0.00006 $0.02499

Measured 11d ago against content hash aa5b40121072, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-11, from the pricing page.

Security

Grade A, and why

通达信TQ scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 11d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/tdx-quant/SKILL.md · 2,599 lines

How it starts

The opening of the file, as written. The whole thing — 2,599 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Tdx Quant Skill

本文档基于 tqcenter.py Version 1.0.6(2026-03-27) 官方文档:https://help.tdx.com.cn/quant/docs/markdown/mindoc-1cfsjkbf8f3is/

TdxQuant 是由深圳市财富趋势科技股份有限公司研发的专业量化投研平台,本 Skill 通过 tqcenter.py 模块的 tq 类提供与通达信客户端交互的完整接口。


重要:Python 文件路径配置

文件目录结构

通达信安装目录\
├── Tdxw.exe                 # 主程序
├── PYPlugins\               # 插件目录
│   ├── TPyth.dll            # 通达信Python通信DLL
│   ├── TPythClient.dll      # 通达信Python通信DLL
│   ├── user\                # 用户策略目录
│   │   └── tqcenter.py      # TdxQuant核心模块
│   ├── data\                # 下载数据目录
│   └── file\                # 发送文件目录

Python 策略文件可以放在任意位置。

导入 tqcenter 前,必须将通达信安装目录的 PYPlugins\user 路径添加到 sys.path使用 sys.path.insert(0, ...) 确保加载正确的 tqcenter.py

获取通达信安装目录

通达信Tdxw的安装目录存储在 Windows 注册表中:

  • 注册表路径HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\通达信金融终端64
  • 键名InstallLocation

可通过以下 Python 代码自动读取安装目录:

import winreg

def get_tdx_install_path():
    """从注册表获取通达信安装目录"""
    key_path = r"SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\通达信金融终端64"
    try:
        with winreg.OpenKey(winreg.HKEY_LOCAL_MACHINE, key_path) as key:
            install_path, _ = winreg.QueryValueEx(key, "InstallLocation")
            return install_path
    except FileNotFoundError:
        print(f"未找到注册表项: HKLM\\{key_path}")
        return None

tdx_root = get_tdx_install_path()
# tdx_root 示例: "D:\\new_tdx" 或 "E:\\App\\new_tdx_test64"
  • 本技能必须检测到进程中有运行的TdxW.exe进程。
  • 进程路径所在的程序目录即为通达信安装目录。
  • python 文件示例中,请将 tdx_root 替换为通达信安装目录。
  • 如果检测不到tdxw.exe进程,请提示用户先运行通达信客户端。
  • 通达信安装目录下面指定位置如果不存在tqcenter.py 文件,提示用户当前的客户端不支持TQ策略,需升级。
  • 如果有多个TdxW.exe进程,请依次寻找,直到找到第一个含有tqcenter.py 文件的进程。
  • 找到之后,请记住这个位置,作为 tdx_root,不用每次都查找,除非这个位置失效。

初始化示例(动态获取安装目录)

import sys, winreg, os

# 从注册表获取安装目录
key_path = r"SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\通达信金融终端64"
with winreg.OpenKey(winreg.HKEY_LOCAL_MACHINE, key_path) as key:
    tdx_root, _ = winreg.QueryValueEx(key, "InstallLocation")

# 添加 PYPlugins/user 到 sys.path
sys.path.insert(0, os.path.join(tdx_root, 'PYPlugins', 'user'))

from tqcenter import tq

tq.initialize(__file__)

Read the full file on GitHub · 2,599 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 11d ago First seen · 2,599 lines · 56 tokens per session scan A aa5b40121072

Subscribe to this mod's changes

通达信TQ is a skill published in the GitHub repository adambbhe/TDX-finance-mcp-plugin-v3 (35 stars, last pushed 2mo ago), licensed MIT. It adds 56 tokens to every session and 24,991 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.