VeighNa (formerly vnpy) is a mature, open-source quantitative trading framework written in Python. It provides a complete ecosystem for developing, backtesting, and executing algorithmic trading strategies across multiple asset classes including Chinese futures, stocks, options, and global markets via interfaces like CTP, XTP, Interactive Brokers, and more. The system is built on an event-driven architecture with a central MainEngine that orchestrates gateways (exchange connections), apps (strategy modules), and engines (services such as order management, logging, email, and WeChat notifications). It offers both a full-featured PySide6 desktop GUI and headless/scriptable operation, making it suitable for both manual and automated trading. The framework includes a dedicated alpha research module (vnpy.alpha) for factor-based strategy development, featuring built-in factor datasets (Alpha101, Alpha158), machine learning models (Lasso, LightGBM, MLP), and a backtesting engine. This gives the repository a hybrid character: primarily an application framework for trading, but with significant data/research capabilities for quantitative analysis. The codebase demonstrates strong engineering practices with plugin-based design, abstract interfaces for databases and datafeeds, and reusable utility classes like BarGenerator, ArrayManager, and OffsetConverter. However, some modules are monolithic and tightly coupled, and the large ecosystem of external gateway packages introduces version compatibility risks.
This repository contains the open-source book 'XQuant: δΊΊδΊΊι½ζ―ιεδΊ€ζε' (XQuant: Everyone Can Be a Quantitative Trader), which serves as an educational resource for learning quantitative trading methodologies. Rather than being a functional trading application, it provides a structured curriculum teaching readers how to develop, test, execute, and monitor quantitative strategies using AI coding assistants. The book walks through a complete workflow: from selecting investment instruments (ETFs), determining position sizing, creating trading rules, validating strategy performance, avoiding overfitting, modeling execution costs, to monitoring and iterating on live strategies. Its unique value lies in teaching a spec-driven development approach where users write clear strategy specifications that AI coding assistants can translate into executable code, making quantitative research accessible to non-programmers.