TopRank Skills

Official OpenClaw rules 36%

miniqmt

miniQMT Minimalist Quantitative Trading Terminal — Supports external Python for market data retrieval and programmatic trading via the xtquant SDK.

Stars

0

Installs

0

Status

ACTIVE

Visibility

PUBLIC

安装方式

直接复制以下提示词,发送给你的 AI 助手即可完成安装。

请先检查是否已安装 SkillHub 商店,若未安装,请根据 https://skillhub-1388575217.cos.ap-guangzhou.myqcloud.com/install/skillhub.md 安装 SkillHub 商店,然后安装 miniqmt 技能。 若已安装,则直接安装 miniqmt 技能。

Overview

Skill Key
coderwpf/miniqmt
Author
coderwpf
Source Repo
openclaw/skills
Version
1.1.0
Source Path
skills/coderwpf/miniqmt
Latest Commit SHA
97034b6435fb156a10a51f609d58674381e3394e

Extracted Content

SKILL.md excerpt

# miniQMT (XunTou Minimalist Quantitative Terminal)

miniQMT is a lightweight quantitative trading terminal developed by XunTou Technology, designed specifically for external Python integration. It runs as a local Windows service and provides market data and trading capabilities through the [XtQuant](http://dict.thinktrader.net/nativeApi/start_now.html) Python SDK (`xtdata` + `xttrade`).

> ⚠️ **Requires miniQMT permission from your broker**. Contact your securities firm to enable it. Multiple domestic brokers support it (Guojin, Huaxin, Zhongtai, East Money, Guosen, Founder, etc.).

## miniQMT Overview

- **Lightweight QMT client** that runs as a background service on Windows
- Provides a **market data server** + **trading server** for external Python programs
- Python scripts connect via local TCP through the `xtquant` SDK (xtdata for market data, xttrade for trade execution)
- Supports: A-shares, ETFs, convertible bonds, futures, options, margin trading
- Some brokers offer free **Level 2 data** with miniQMT

## Architecture

```
Python script (any IDE: VS Code, PyCharm, Jupyter, etc.)
    ↓ xtquant SDK (pip install xtquant)
    ├── xtdata  ──TCP──→ miniQMT (market data service)
    └── xttrade ──TCP──→ miniQMT (trading service)
                              ↓
                    Broker trading system
```

## How to Get miniQMT

1. Open a securities account with a broker that supports QMT
2. Apply for miniQMT permission (some brokers require minimum assets, e.g., 50k–100k CNY)
3. Download and install the QMT client from your broker
4. Launch in miniQMT mode (minimalist mode) and log in

## Usage Workflow

### 1. Start miniQMT

Launch the QMT client in minimalist mode and log in. The miniQMT interface is very simple — just a login window.

### 2. Install xtquant

```bash
pip install xtquant
```

### 3. Connect to Market Data with Python

```python
from xtquant import xtdata

# Connect to the local miniQMT market data service
xtdata.connect()

# Download historical...

README excerpt

# miniQMT 量化终端 Skill

[![Version](https://img.shields.io/badge/version-1.1.0-blue.svg)](http://dict.thinktrader.net/nativeApi/start_now.html)
[![License](https://img.shields.io/badge/license-Apache--2.0-green.svg)](LICENSE)
[![ClawHub](https://img.shields.io/badge/ClawHub-BossQuant-purple.svg)](https://clawhub.com)

miniQMT 极简量化交易终端,支持外接 Python 获取行情和程序化交易。

## ✨ 特性

- 🐍 **外接 Python** - 独立 Python 环境调用,灵活自由
- 🪶 **轻量级** - 无需完整 QMT 客户端,资源占用少
- 📊 **支持 Level2** - 支持 Level2 逐笔行情数据
- 💹 **实盘交易** - 支持股票、ETF 实盘程序化交易
- 🏦 **多券商支持** - 支持多家券商 miniQMT 接入

## 📥 安装

```bash
pip install xtquant
```

## 🔑 配置

需要券商开通 miniQMT 权限,并启动 miniQMT 客户端。

## 🚀 快速开始

```python
from xtquant import xtdata

# 连接行情服务
xtdata.connect()

# 下载历史数据
xtdata.download_history_data("000001.SZ", "1d", start_time="20240101")

# 获取K线数据
data = xtdata.get_market_data_ex([], ["000001.SZ"], period="1d", start_time="20240101", end_time="20241231")
print(data["000001.SZ"].head())
```

## 📊 支持的功能

| 类别 | 说明 | 示例接口 |
|------|------|----------|
| 行情连接 | 连接行情服务 | `xtdata.connect()` |
| 数据下载 | 下载历史数据 | `xtdata.download_history_data()` |
| K线数据 | 获取K线行情 | `xtdata.get_market_data_ex()` |
| 实时行情 | 订阅实时行情 | `xtdata.subscribe_quote()` |
| 财务数据 | 获取财务数据 | `xtdata.get_financial_data()` |
| 股票交易 | 下单/撤单 | `xt_trader.order_stock()` |
| 持仓查询 | 查询持仓 | `xt_trader.query_stock_positions()` |
| 委托查询 | 查询委托 | `xt_trader.query_stock_orders()` |

## 📖 交易示例

```python
from xtquant import xtdata
from xtquant.xttrader import XtQuantTrader
from xtquant.xttype import StockAccount

# 创建交易实例
trader = XtQuantTrader("path_to_userdata", session_id=123456)
account = StockAccount("your_account_id")
trader.start()

# 买入
trader.order_stock(account, "000001.SZ", xtconstant.STOCK_BUY, 100, xtconstant.FIX_PRICE, 10.5...

Related Claw Skills