{"owner":"shidenggui","repo":"easytrader","hasSkills":true,"totalSkillsCount":1,"totalTokensCount":793,"categories":["copilot-instructions"],"hasMcp":false,"mcpConfig":null,"found":[".github/copilot-instructions.md"],"skills":{".github/copilot-instructions.md":"# Project Guidelines\n\n## Overview\n\neasytrader is a Chinese stock trading automation library. It supports:\n- Windows desktop client brokers via pywinauto GUI automation (同花顺-based)\n- Xueqiu (雪球) web portfolio trading via REST API\n- MiniQMT (迅投) official quant SDK integration\n- Strategy following from JoinQuant / RiceQuant / Xueqiu\n- Remote client-server execution via Flask\n\n## Architecture\n\n**Entry points**: `easytrader.use(broker)` and `easytrader.follower(platform)` — factory functions in `easytrader/api.py`.\n\n**Three parallel branches**:\n\n| Branch | Base class | Purpose |\n|--------|-----------|---------|\n| Desktop GUI | `ClientTrader` → broker subclasses | pywinauto-driven Windows client automation |\n| Web/API | `WebTrader` → `XueQiuTrader`, `MiniqmtTrader` | HTTP/SDK-based trading |\n| Followers | `BaseFollower` → platform subclasses | Mirror strategies from quant platforms |\n\n**Remote**: `server.py` (Flask) + `remoteclient.py` enables controlling a Windows trader remotely.\n\n**Config**: `easytrader/config/client.py` holds broker-specific UI control IDs. JSON configs in `easytrader/config/` store API URLs.\n\n## Code Style\n\n- **Formatter**: `black -l 79` (79-char line limit)\n- **Import sorting**: `isort`\n- **Linter**: `pylint`\n- **Type checking**: `mypy` (with `ignore_missing_imports = True`)\n- **Language**: Comments, error messages, log messages, and docstrings are in **Chinese**. Follow this convention.\n- Type hints are used sparingly (mainly in newer code like `miniqmt/`). Match the style of the surrounding code.\n\n## Build and Test\n\n```bash\n# Install\npipenv install\n\n# Run tests (only xq_follower and xqtrader tests are runnable without Windows + broker)\nmake test                  # or: pipenv run test → pytest -vx --cov=easytrader tests\n\n# Lint & format\npipenv run lint            # pylint\npipenv run format          # black -l 79\npipenv run sort_imports    # isort\npipenv run type_check      # mypy\n```\n\nTests use `unittest` (run via pytest). Desktop client tests require Windows + live broker sessions and are gated by `@unittest.skipUnless` with `EZ_TEST_CLIENTS` env var.\n\n## Conventions\n\n- **Factory dispatch** in `api.py` — broker modules are lazily imported inside `if` branches, not registered via a plugin system.\n- **ABC + strategy pattern**: `IGridStrategy`, `IRefreshStrategy` abstract bases with swappable implementations for grid reading and data refresh.\n- **Logging**: Single shared logger `logging.getLogger(\"easytrader\")` — do not create module-level loggers.\n- **Exceptions**: Use `TradeError` and `NotLoginError` from `easytrader/exceptions.py`.\n- **Perf timing**: `@perf_clock` decorator from `easytrader/utils/perf.py` for performance-critical operations.\n- **Session keepalive**: `WebTrader` uses a daemon heartbeat thread.\n\n## Platform Pitfalls\n\n- `ClientTrader`, `grid_strategies.py`, `refresh_strategies.py`, `pop_dialog_handler.py` require **pywinauto** and Win32 — non-functional on macOS/Linux. Guard platform-specific imports appropriately.\n- `xtquant` (miniqmt dependency) is a proprietary SDK installed from the QMT terminal, not from PyPI.\n- `pywinauto` is pinned to `==0.6.6` — do not upgrade without testing.\n"},"files":{".github/copilot-instructions.md":"# Project Guidelines\n\n## Overview\n\neasytrader is a Chinese stock trading automation library. It supports:\n- Windows desktop client brokers via pywinauto GUI automation (同花顺-based)\n- Xueqiu (雪球) web portfolio trading via REST API\n- MiniQMT (迅投) official quant SDK integration\n- Strategy following from JoinQuant / RiceQuant / Xueqiu\n- Remote client-server execution via Flask\n\n## Architecture\n\n**Entry points**: `easytrader.use(broker)` and `easytrader.follower(platform)` — factory functions in `easytrader/api.py`.\n\n**Three parallel branches**:\n\n| Branch | Base class | Purpose |\n|--------|-----------|---------|\n| Desktop GUI | `ClientTrader` → broker subclasses | pywinauto-driven Windows client automation |\n| Web/API | `WebTrader` → `XueQiuTrader`, `MiniqmtTrader` | HTTP/SDK-based trading |\n| Followers | `BaseFollower` → platform subclasses | Mirror strategies from quant platforms |\n\n**Remote**: `server.py` (Flask) + `remoteclient.py` enables controlling a Windows trader remotely.\n\n**Config**: `easytrader/config/client.py` holds broker-specific UI control IDs. JSON configs in `easytrader/config/` store API URLs.\n\n## Code Style\n\n- **Formatter**: `black -l 79` (79-char line limit)\n- **Import sorting**: `isort`\n- **Linter**: `pylint`\n- **Type checking**: `mypy` (with `ignore_missing_imports = True`)\n- **Language**: Comments, error messages, log messages, and docstrings are in **Chinese**. Follow this convention.\n- Type hints are used sparingly (mainly in newer code like `miniqmt/`). Match the style of the surrounding code.\n\n## Build and Test\n\n```bash\n# Install\npipenv install\n\n# Run tests (only xq_follower and xqtrader tests are runnable without Windows + broker)\nmake test                  # or: pipenv run test → pytest -vx --cov=easytrader tests\n\n# Lint & format\npipenv run lint            # pylint\npipenv run format          # black -l 79\npipenv run sort_imports    # isort\npipenv run type_check      # mypy\n```\n\nTests use `unittest` (run via pytest). Desktop client tests require Windows + live broker sessions and are gated by `@unittest.skipUnless` with `EZ_TEST_CLIENTS` env var.\n\n## Conventions\n\n- **Factory dispatch** in `api.py` — broker modules are lazily imported inside `if` branches, not registered via a plugin system.\n- **ABC + strategy pattern**: `IGridStrategy`, `IRefreshStrategy` abstract bases with swappable implementations for grid reading and data refresh.\n- **Logging**: Single shared logger `logging.getLogger(\"easytrader\")` — do not create module-level loggers.\n- **Exceptions**: Use `TradeError` and `NotLoginError` from `easytrader/exceptions.py`.\n- **Perf timing**: `@perf_clock` decorator from `easytrader/utils/perf.py` for performance-critical operations.\n- **Session keepalive**: `WebTrader` uses a daemon heartbeat thread.\n\n## Platform Pitfalls\n\n- `ClientTrader`, `grid_strategies.py`, `refresh_strategies.py`, `pop_dialog_handler.py` require **pywinauto** and Win32 — non-functional on macOS/Linux. Guard platform-specific imports appropriately.\n- `xtquant` (miniqmt dependency) is a proprietary SDK installed from the QMT terminal, not from PyPI.\n- `pywinauto` is pinned to `==0.6.6` — do not upgrade without testing.\n"},"items":[{"name":"copilot-instructions.md","path":".github/copilot-instructions.md","rawUrl":"https://raw.githubusercontent.com/shidenggui/easytrader/HEAD/.github/copilot-instructions.md","title":"GitHub Copilot Instructions","category":"copilot-instructions","format":"markdown","content":"# Project Guidelines\n\n## Overview\n\neasytrader is a Chinese stock trading automation library. It supports:\n- Windows desktop client brokers via pywinauto GUI automation (同花顺-based)\n- Xueqiu (雪球) web portfolio trading via REST API\n- MiniQMT (迅投) official quant SDK integration\n- Strategy following from JoinQuant / RiceQuant / Xueqiu\n- Remote client-server execution via Flask\n\n## Architecture\n\n**Entry points**: `easytrader.use(broker)` and `easytrader.follower(platform)` — factory functions in `easytrader/api.py`.\n\n**Three parallel branches**:\n\n| Branch | Base class | Purpose |\n|--------|-----------|---------|\n| Desktop GUI | `ClientTrader` → broker subclasses | pywinauto-driven Windows client automation |\n| Web/API | `WebTrader` → `XueQiuTrader`, `MiniqmtTrader` | HTTP/SDK-based trading |\n| Followers | `BaseFollower` → platform subclasses | Mirror strategies from quant platforms |\n\n**Remote**: `server.py` (Flask) + `remoteclient.py` enables controlling a Windows trader remotely.\n\n**Config**: `easytrader/config/client.py` holds broker-specific UI control IDs. JSON configs in `easytrader/config/` store API URLs.\n\n## Code Style\n\n- **Formatter**: `black -l 79` (79-char line limit)\n- **Import sorting**: `isort`\n- **Linter**: `pylint`\n- **Type checking**: `mypy` (with `ignore_missing_imports = True`)\n- **Language**: Comments, error messages, log messages, and docstrings are in **Chinese**. Follow this convention.\n- Type hints are used sparingly (mainly in newer code like `miniqmt/`). Match the style of the surrounding code.\n\n## Build and Test\n\n```bash\n# Install\npipenv install\n\n# Run tests (only xq_follower and xqtrader tests are runnable without Windows + broker)\nmake test                  # or: pipenv run test → pytest -vx --cov=easytrader tests\n\n# Lint & format\npipenv run lint            # pylint\npipenv run format          # black -l 79\npipenv run sort_imports    # isort\npipenv run type_check      # mypy\n```\n\nTests use `unittest` (run via pytest). Desktop client tests require Windows + live broker sessions and are gated by `@unittest.skipUnless` with `EZ_TEST_CLIENTS` env var.\n\n## Conventions\n\n- **Factory dispatch** in `api.py` — broker modules are lazily imported inside `if` branches, not registered via a plugin system.\n- **ABC + strategy pattern**: `IGridStrategy`, `IRefreshStrategy` abstract bases with swappable implementations for grid reading and data refresh.\n- **Logging**: Single shared logger `logging.getLogger(\"easytrader\")` — do not create module-level loggers.\n- **Exceptions**: Use `TradeError` and `NotLoginError` from `easytrader/exceptions.py`.\n- **Perf timing**: `@perf_clock` decorator from `easytrader/utils/perf.py` for performance-critical operations.\n- **Session keepalive**: `WebTrader` uses a daemon heartbeat thread.\n\n## Platform Pitfalls\n\n- `ClientTrader`, `grid_strategies.py`, `refresh_strategies.py`, `pop_dialog_handler.py` require **pywinauto** and Win32 — non-functional on macOS/Linux. Guard platform-specific imports appropriately.\n- `xtquant` (miniqmt dependency) is a proprietary SDK installed from the QMT terminal, not from PyPI.\n- `pywinauto` is pinned to `==0.6.6` — do not upgrade without testing.\n","isInternal":false,"tokens":793,"sizeBytes":3207}],"systemPromptSnippet":"<yakaai_skills repo=\"shidenggui/easytrader\">\n<!-- File: .github/copilot-instructions.md (Tokens: ~793 | Category: copilot-instructions) -->\n# Project Guidelines\n\n## Overview\n\neasytrader is a Chinese stock trading automation library. It supports:\n- Windows desktop client brokers via pywinauto GUI automation (同花顺-based)\n- Xueqiu (雪球) web portfolio trading via REST API\n- MiniQMT (迅投) official quant SDK integration\n- Strategy following from JoinQuant / RiceQuant / Xueqiu\n- Remote client-server execution via Flask\n\n## Architecture\n\n**Entry points**: `easytrader.use(broker)` and `easytrader.follower(platform)` — factory functions in `easytrader/api.py`.\n\n**Three parallel branches**:\n\n| Branch | Base class | Purpose |\n|--------|-----------|---------|\n| Desktop GUI | `ClientTrader` → broker subclasses | pywinauto-driven Windows client automation |\n| Web/API | `WebTrader` → `XueQiuTrader`, `MiniqmtTrader` | HTTP/SDK-based trading |\n| Followers | `BaseFollower` → platform subclasses | Mirror strategies from quant platforms |\n\n**Remote**: `server.py` (Flask) + `remoteclient.py` enables controlling a Windows trader remotely.\n\n**Config**: `easytrader/config/client.py` holds broker-specific UI control IDs. JSON configs in `easytrader/config/` store API URLs.\n\n## Code Style\n\n- **Formatter**: `black -l 79` (79-char line limit)\n- **Import sorting**: `isort`\n- **Linter**: `pylint`\n- **Type checking**: `mypy` (with `ignore_missing_imports = True`)\n- **Language**: Comments, error messages, log messages, and docstrings are in **Chinese**. Follow this convention.\n- Type hints are used sparingly (mainly in newer code like `miniqmt/`). Match the style of the surrounding code.\n\n## Build and Test\n\n```bash\n# Install\npipenv install\n\n# Run tests (only xq_follower and xqtrader tests are runnable without Windows + broker)\nmake test                  # or: pipenv run test → pytest -vx --cov=easytrader tests\n\n# Lint & format\npipenv run lint            # pylint\npipenv run format          # black -l 79\npipenv run sort_imports    # isort\npipenv run type_check      # mypy\n```\n\nTests use `unittest` (run via pytest). Desktop client tests require Windows + live broker sessions and are gated by `@unittest.skipUnless` with `EZ_TEST_CLIENTS` env var.\n\n## Conventions\n\n- **Factory dispatch** in `api.py` — broker modules are lazily imported inside `if` branches, not registered via a plugin system.\n- **ABC + strategy pattern**: `IGridStrategy`, `IRefreshStrategy` abstract bases with swappable implementations for grid reading and data refresh.\n- **Logging**: Single shared logger `logging.getLogger(\"easytrader\")` — do not create module-level loggers.\n- **Exceptions**: Use `TradeError` and `NotLoginError` from `easytrader/exceptions.py`.\n- **Perf timing**: `@perf_clock` decorator from `easytrader/utils/perf.py` for performance-critical operations.\n- **Session keepalive**: `WebTrader` uses a daemon heartbeat thread.\n\n## Platform Pitfalls\n\n- `ClientTrader`, `grid_strategies.py`, `refresh_strategies.py`, `pop_dialog_handler.py` require **pywinauto** and Win32 — non-functional on macOS/Linux. Guard platform-specific imports appropriately.\n- `xtquant` (miniqmt dependency) is a proprietary SDK installed from the QMT terminal, not from PyPI.\n- `pywinauto` is pinned to `==0.6.6` — do not upgrade without testing.\n</yakaai_skills>"}