diff --git a/docs/deployment_model.zh-CN.md b/docs/deployment_model.zh-CN.md index 984bc3c..b75b1b6 100644 --- a/docs/deployment_model.zh-CN.md +++ b/docs/deployment_model.zh-CN.md @@ -6,11 +6,11 @@ - `InteractiveBrokersPlatform`、`CharlesSchwabPlatform`、`LongBridgePlatform`、`BinancePlatform` 这些仓库才是实际运行单元。 - 策略仓库应该固定依赖某个 Git tag,不要直接依赖 `main`。 -如果要看当前线上真实运行清单,包括仓库、项目、服务、scheduler、runtime identity、secret 名称,见 [`platform_runtime_inventory.zh-CN.md`](./platform_runtime_inventory.zh-CN.md)。 +如果要看公开 runtime 接线清单,包括仓库、项目、服务、scheduler、runtime identity、selector 和 secret 入口,见 [`platform_runtime_inventory.zh-CN.md`](./platform_runtime_inventory.zh-CN.md)。 如果要看 `QuantPlatformKit`、平台运行仓库、未来策略仓库三者的职责边界,见 [`platform_repo_boundaries.zh-CN.md`](./platform_repo_boundaries.zh-CN.md)。 -如果要看当前的平台 / 策略大类 / live profile 对照表,请看 [`platform_strategy_matrix.zh-CN.md`](./platform_strategy_matrix.zh-CN.md)。 +如果要看当前的平台 / 策略大类 / 可配置 profile 对照表,请看 [`platform_strategy_matrix.zh-CN.md`](./platform_strategy_matrix.zh-CN.md)。 ## 仓库职责 diff --git a/docs/platform_repo_boundaries.zh-CN.md b/docs/platform_repo_boundaries.zh-CN.md index 4477ea5..9a88108 100644 --- a/docs/platform_repo_boundaries.zh-CN.md +++ b/docs/platform_repo_boundaries.zh-CN.md @@ -12,7 +12,7 @@ > 哪些东西该放在哪一层,哪些东西不该放? -如果要看当前的平台 / 策略大类 / live profile 对照表,请看 [`platform_strategy_matrix.zh-CN.md`](./platform_strategy_matrix.zh-CN.md)。 +如果要看当前的平台 / 策略大类 / 可配置 profile 对照表,请看 [`platform_strategy_matrix.zh-CN.md`](./platform_strategy_matrix.zh-CN.md)。 ## 1. `QuantPlatformKit` diff --git a/docs/platform_runtime_inventory.md b/docs/platform_runtime_inventory.md index 840884e..2073c74 100644 --- a/docs/platform_runtime_inventory.md +++ b/docs/platform_runtime_inventory.md @@ -2,13 +2,13 @@ _Verified snapshot: 2026-04-18_ -This document records the **current live runtime inventory** across platform repositories and deployment projects. It is meant to answer one question quickly: +This document records the public runtime wiring inventory across platform repositories and deployment projects. It is meant to answer one question quickly: -> which repository, project, service, scheduler, runtime identity, and secret set is actually in use right now? +> which repository, project, service, scheduler, runtime identity, selector, and secret set is wired for each platform? -This is a **current-state runbook**, not a target-state design doc. For target architecture and migration rules, see [`deployment_model.md`](./deployment_model.md). +This is a wiring runbook, not a record of any account's deployed strategy. It intentionally does **not** record mutable deployment state or account-specific allocation choices. -For the current platform / strategy-domain / live-profile matrix, see [`platform_strategy_matrix.md`](./platform_strategy_matrix.md). +For the platform / strategy-domain / configurable-profile matrix, see [`platform_strategy_matrix.md`](./platform_strategy_matrix.md). ## Shared rules @@ -22,14 +22,14 @@ For the current platform / strategy-domain / live-profile matrix, see [`platform - The US equity Cloud Run env-sync workflows use GitHub OIDC + Workload Identity Federation. `GCP_SA_KEY` is not required for those workflows. - GitHub Secrets can remain as temporary runtime fallbacks where migration is not fully finished. -## Current inventory +## Runtime inventory -| Platform | Repo | Strategy domain | Current profile | Runtime model | Project / backend | Current runtime unit | +| Platform | Repo | Strategy domain | Strategy selector | Runtime model | Project / backend | Runtime unit | |---|---|---:|---|---|---|---| -| IBKR | `QuantStrategyLab/InteractiveBrokersPlatform` | `us_equity` | `soxl_soxx_trend_income` | Cloud Run | `interactivebrokersquant` | `interactive-brokers-quant-service` | -| Schwab | `QuantStrategyLab/CharlesSchwabPlatform` | `us_equity` | `tqqq_growth_income` | Cloud Run | `charlesschwabquant` | `charles-schwab-quant-service` | -| LongBridge | `QuantStrategyLab/LongBridgePlatform` | `us_equity` | `HK: tech_communication_pullback_enhancement` / `SG: soxl_soxx_trend_income` | Cloud Run | `longbridgequant` | `longbridge-quant-hk-service`, `longbridge-quant-sg-service` | -| Binance | `QuantStrategyLab/BinancePlatform` | `crypto` | `crypto_leader_rotation` | Oracle Cloud + self-hosted runner | `binancequant` only for Firestore / GCP credentials | GitHub Actions `workflow_dispatch` + self-hosted runner | +| IBKR | `QuantStrategyLab/InteractiveBrokersPlatform` | `us_equity` | `STRATEGY_PROFILE=` | Cloud Run | `interactivebrokersquant` | `interactive-brokers-quant-service` | +| Schwab | `QuantStrategyLab/CharlesSchwabPlatform` | `us_equity` | `STRATEGY_PROFILE=` | Cloud Run | `charlesschwabquant` | `charles-schwab-quant-service` | +| LongBridge | `QuantStrategyLab/LongBridgePlatform` | `us_equity` | `STRATEGY_PROFILE=` per regional service | Cloud Run | `longbridgequant` | `longbridge-quant-hk-service`, `longbridge-quant-sg-service` | +| Binance | `QuantStrategyLab/BinancePlatform` | `crypto` | `STRATEGY_PROFILE=crypto_leader_rotation` | Oracle Cloud + self-hosted runner | `binancequant` only for Firestore / GCP credentials | GitHub Actions `workflow_dispatch` + self-hosted runner | ## Platform details @@ -43,20 +43,19 @@ For the current platform / strategy-domain / live-profile matrix, see [`platform - `interactive-brokers-quant-service` - **Runtime service account** - `ibkr-platform-runtime@interactivebrokersquant.iam.gserviceaccount.com` -- **Current ready revision** - - `interactive-brokers-quant-service-00111-wr5` - **Scheduler** - `interactive-brokers-quant-service-scheduler` - region: `us-central1` - **Core runtime selectors** - - `STRATEGY_PROFILE=soxl_soxx_trend_income` - - `ACCOUNT_GROUP=default` - - `IB_ACCOUNT_GROUP_CONFIG_SECRET_NAME=ibkr-account-groups` + - `STRATEGY_PROFILE=` + - `ACCOUNT_GROUP=` + - `IB_ACCOUNT_GROUP_CONFIG_SECRET_NAME=` - **Runtime secrets** - - `ibkr-account-groups` - - `interactive-brokers-telegram-token` -- **Current notes** - - Transitional envs `IB_GATEWAY_ZONE=us-central1-c` and `IB_GATEWAY_IP_MODE=internal` are still present as service-level fallbacks; the target state is to keep these in the selected account-group payload. + - account-group payload secret selected by `IB_ACCOUNT_GROUP_CONFIG_SECRET_NAME` + - runtime Telegram token secret +- **Runtime notes** + - `ACCOUNT_GROUP` decides which broker/account payload the runtime loads. + - Gateway zone and IP-mode settings should live in the selected account-group payload when the migration is complete. ### Charles Schwab @@ -68,22 +67,19 @@ For the current platform / strategy-domain / live-profile matrix, see [`platform - `charles-schwab-quant-service` - **Runtime service account** - `schwab-platform-runtime@charlesschwabquant.iam.gserviceaccount.com` -- **Current ready revision** - - `charles-schwab-quant-service-00092-8hz` - **Scheduler** - `charles-schwab-quant-service-scheduler` - region: `us-central1` - **Core runtime selectors** - - `STRATEGY_PROFILE=tqqq_growth_income` - - `DUAL_DRIVE_UNLEVERED_SYMBOL=QQQM` + - `STRATEGY_PROFILE=` + - optional strategy-specific envs such as `DUAL_DRIVE_UNLEVERED_SYMBOL` - **Runtime secrets** - - `schwab_token` - - `charles-schwab-api-key` - - `charles-schwab-app-secret` - - `charles-schwab-telegram-token` -- **Current notes** - - Runtime-sensitive envs have already been moved off plain Cloud Run env vars and into Secret Manager refs. - - `crisis_response_shadow` is mounted for `tqqq_growth_income` in `shadow` mode. It is log/notification context only and does not change allocation. + - Schwab token payload secret + - Schwab API key / app secret refs + - runtime Telegram token secret +- **Runtime notes** + - Runtime-sensitive envs should use Secret Manager refs, not plain Cloud Run env values. + - Strategy plugins are sidecars: `shadow` logs and notifies only; `paper`, `advisory`, and `live` semantics are governed by the plugin execution mode contract. - The token refresher lives outside this repo: - `QuantStrategyLab/SchwabTokenAutoRefresher` @@ -98,31 +94,22 @@ For the current platform / strategy-domain / live-profile matrix, see [`platform - SG: `longbridge-quant-sg-service` - **Runtime service account** - `longbridge-platform-runtime@longbridgequant.iam.gserviceaccount.com` -- **Current ready revisions** - - HK: `longbridge-quant-hk-service-00086-slh` - - SG: `longbridge-quant-sg-service-00089-526` - **Schedulers** - `longbridge-quant-hk-service-scheduler` in `asia-east2` - `longbridge-quant-sg-service-scheduler` in `asia-southeast1` - **Core runtime selectors** - - `STRATEGY_PROFILE=tech_communication_pullback_enhancement on HK; STRATEGY_PROFILE=soxl_soxx_trend_income on SG` + - `STRATEGY_PROFILE=` per regional service - `ACCOUNT_REGION=HK|SG` - - `LONGPORT_SECRET_NAME=longport_token_hk|longport_token_sg` + - `LONGPORT_SECRET_NAME=` - **Runtime secrets** - - Secret Manager refs: - - `longbridge-telegram-token` - - `longport-app-key-hk` - - `longport-app-key-sg` - - `longport-app-secret-hk` - - `longport-app-secret-sg` - - region token secrets: - - `longport_token_hk` - - `longport_token_sg` -- **Current notes** + - Secret Manager refs for LongPort app key / app secret + - region token secrets selected by `LONGPORT_SECRET_NAME` + - runtime Telegram token secret +- **Runtime notes** - HK and SG keep two independent Cloud Run services, two triggers, and two GitHub Environments. - - HK uses feature-snapshot envs for `tech_communication_pullback_enhancement`; SG is currently on the direct-runtime `soxl_soxx_trend_income` profile. + - Snapshot-backed profiles require feature snapshot path / manifest envs; direct-runtime profiles do not. - App key / secret are region-specific Secret Manager refs; Telegram token is shared inside the LongBridge project. - - `SERVICE_NAME` is now aligned to the full runtime-facing names above, instead of using the older short `longbridge-quant-hk` / `longbridge-quant-sg` prefixes. + - `SERVICE_NAME` should use the full runtime-facing service names above, not older short prefixes. ### Binance @@ -137,13 +124,13 @@ For the current platform / strategy-domain / live-profile matrix, see [`platform - **What GCP is used for** - Firestore - GCP service-account credentials consumed by the workflow / runtime -- **Current runtime selector** +- **Runtime selector** - `STRATEGY_PROFILE=crypto_leader_rotation` - **Known Firestore backend** - database: `(default)` - mode: `FIRESTORE_NATIVE` - location: `nam5` -- **Current notes** +- **Runtime notes** - Binance is intentionally **not** modeled like the Cloud Run platforms. - Any future cleanup here should keep Oracle runtime concerns separate from GCP backend concerns. @@ -177,9 +164,3 @@ For the current platform / strategy-domain / live-profile matrix, see [`platform - Scheduler OIDC identity is still tied to the default compute service account in the Cloud Run projects. - Real cross-platform strategy implementation sharing has **not** started yet. Only the shared strategy contract and platform-compatibility skeleton are in place. - -## Recommended next steps after this inventory - -1. keep this file current whenever a runtime service, secret name, or runtime service account changes -2. keep repository names, service names, scheduler names, and docs aligned whenever one side changes -3. only after naming and runtime config are stable, start the real strategy-implementation split by domain diff --git a/docs/platform_runtime_inventory.zh-CN.md b/docs/platform_runtime_inventory.zh-CN.md index 48983b8..18cd320 100644 --- a/docs/platform_runtime_inventory.zh-CN.md +++ b/docs/platform_runtime_inventory.zh-CN.md @@ -1,14 +1,14 @@ -# 平台运行清单 +# 平台运行接线清单 _校验快照日期:2026-04-18_ -这份文档记录的是**当前线上真实运行清单**,用来快速回答一个问题: +这份文档记录公开仓库里可以保留的 runtime 接线信息,用来快速回答一个问题: -> 现在到底是哪一个仓库、哪一个项目、哪一个服务、哪一个 scheduler、哪一个 runtime 身份、哪一组 secret 在跑? +> 每个平台对应哪个仓库、项目、服务、scheduler、runtime 身份、selector 和 secret 入口? -这是一份**现状运行手册**,不是目标架构设计稿。目标模型和迁移规则请看 [`deployment_model.zh-CN.md`](./deployment_model.zh-CN.md)。 +这是一份接线手册,不是任何账户的部署策略记录。它刻意不记录可变部署状态或账户级仓位选择。 -如果要看当前的平台 / 策略大类 / live profile 对照表,请看 [`platform_strategy_matrix.zh-CN.md`](./platform_strategy_matrix.zh-CN.md)。 +如果要看平台 / 策略大类 / 可配置 profile 对照表,请看 [`platform_strategy_matrix.zh-CN.md`](./platform_strategy_matrix.zh-CN.md)。 ## 共同规则 @@ -22,14 +22,14 @@ _校验快照日期:2026-04-18_ - 美股 Cloud Run env-sync workflow 使用 GitHub OIDC + Workload Identity Federation,不再需要 `GCP_SA_KEY`。 - GitHub Secrets 可以继续保留给运行时迁移还没完成时的临时 fallback。 -## 当前清单 +## 运行接线清单 -| 平台 | 仓库 | 策略大类 | 当前策略值 | 运行模型 | 项目 / 后端 | 当前运行单元 | +| 平台 | 仓库 | 策略大类 | 策略选择器 | 运行模型 | 项目 / 后端 | 运行单元 | |---|---|---:|---|---|---|---| -| IBKR | `QuantStrategyLab/InteractiveBrokersPlatform` | `us_equity` | `soxl_soxx_trend_income` | Cloud Run | `interactivebrokersquant` | `interactive-brokers-quant-service` | -| Schwab | `QuantStrategyLab/CharlesSchwabPlatform` | `us_equity` | `tqqq_growth_income` | Cloud Run | `charlesschwabquant` | `charles-schwab-quant-service` | -| LongBridge | `QuantStrategyLab/LongBridgePlatform` | `us_equity` | `HK: tech_communication_pullback_enhancement` / `SG: soxl_soxx_trend_income` | Cloud Run | `longbridgequant` | `longbridge-quant-hk-service`、`longbridge-quant-sg-service` | -| Binance | `QuantStrategyLab/BinancePlatform` | `crypto` | `crypto_leader_rotation` | Oracle Cloud + self-hosted runner | `binancequant` 只承担 Firestore / GCP 凭据 | GitHub Actions `workflow_dispatch` + self-hosted runner | +| IBKR | `QuantStrategyLab/InteractiveBrokersPlatform` | `us_equity` | `STRATEGY_PROFILE=` | Cloud Run | `interactivebrokersquant` | `interactive-brokers-quant-service` | +| Schwab | `QuantStrategyLab/CharlesSchwabPlatform` | `us_equity` | `STRATEGY_PROFILE=` | Cloud Run | `charlesschwabquant` | `charles-schwab-quant-service` | +| LongBridge | `QuantStrategyLab/LongBridgePlatform` | `us_equity` | 每个区域服务设置 `STRATEGY_PROFILE=` | Cloud Run | `longbridgequant` | `longbridge-quant-hk-service`、`longbridge-quant-sg-service` | +| Binance | `QuantStrategyLab/BinancePlatform` | `crypto` | `STRATEGY_PROFILE=crypto_leader_rotation` | Oracle Cloud + self-hosted runner | `binancequant` 只承担 Firestore / GCP 凭据 | GitHub Actions `workflow_dispatch` + self-hosted runner | ## 各平台明细 @@ -43,20 +43,19 @@ _校验快照日期:2026-04-18_ - `interactive-brokers-quant-service` - **runtime service account** - `ibkr-platform-runtime@interactivebrokersquant.iam.gserviceaccount.com` -- **当前 ready revision** - - `interactive-brokers-quant-service-00111-wr5` - **Scheduler** - `interactive-brokers-quant-service-scheduler` - region:`us-central1` - **核心运行选择器** - - `STRATEGY_PROFILE=soxl_soxx_trend_income` - - `ACCOUNT_GROUP=default` - - `IB_ACCOUNT_GROUP_CONFIG_SECRET_NAME=ibkr-account-groups` + - `STRATEGY_PROFILE=` + - `ACCOUNT_GROUP=` + - `IB_ACCOUNT_GROUP_CONFIG_SECRET_NAME=` - **运行时 secret** - - `ibkr-account-groups` - - `interactive-brokers-telegram-token` -- **当前说明** - - 过渡 env `IB_GATEWAY_ZONE=us-central1-c`、`IB_GATEWAY_IP_MODE=internal` 目前仍作为服务级 fallback 保留;目标状态仍然是放进选中的 account-group payload。 + - 由 `IB_ACCOUNT_GROUP_CONFIG_SECRET_NAME` 选择的账户组 payload secret + - runtime Telegram token secret +- **运行说明** + - `ACCOUNT_GROUP` 决定 runtime 加载哪组券商 / 账户 payload。 + - Gateway zone 和 IP-mode 设置在迁移完成后应放进选中的 account-group payload。 ### Charles Schwab @@ -68,22 +67,19 @@ _校验快照日期:2026-04-18_ - `charles-schwab-quant-service` - **runtime service account** - `schwab-platform-runtime@charlesschwabquant.iam.gserviceaccount.com` -- **当前 ready revision** - - `charles-schwab-quant-service-00092-8hz` - **Scheduler** - `charles-schwab-quant-service-scheduler` - region:`us-central1` - **核心运行选择器** - - `STRATEGY_PROFILE=tqqq_growth_income` - - `DUAL_DRIVE_UNLEVERED_SYMBOL=QQQM` + - `STRATEGY_PROFILE=` + - 策略专属可选 env,例如 `DUAL_DRIVE_UNLEVERED_SYMBOL` - **运行时 secret** - - `schwab_token` - - `charles-schwab-api-key` - - `charles-schwab-app-secret` - - `charles-schwab-telegram-token` -- **当前说明** - - 运行时敏感配置已经不再走 Cloud Run 明文 env,而是走 Secret Manager 引用。 - - `crisis_response_shadow` 以 `shadow` 模式挂载到 `tqqq_growth_income`;它只进入日志/通知上下文,不改变 allocation。 + - Schwab token payload secret + - Schwab API key / app secret 引用 + - runtime Telegram token secret +- **运行说明** + - 运行时敏感配置应使用 Secret Manager 引用,不应放在 Cloud Run 明文 env。 + - 策略插件是 sidecar:`shadow` 只写日志和通知;`paper`、`advisory`、`live` 的语义由插件执行模式契约统一约束。 - token refresher 不在这个仓库里,而是在: - `QuantStrategyLab/SchwabTokenAutoRefresher` @@ -98,31 +94,22 @@ _校验快照日期:2026-04-18_ - SG:`longbridge-quant-sg-service` - **runtime service account** - `longbridge-platform-runtime@longbridgequant.iam.gserviceaccount.com` -- **当前 ready revision** - - HK:`longbridge-quant-hk-service-00086-slh` - - SG:`longbridge-quant-sg-service-00089-526` - **Scheduler** - `longbridge-quant-hk-service-scheduler`(`asia-east2`) - `longbridge-quant-sg-service-scheduler`(`asia-southeast1`) - **核心运行选择器** - - `STRATEGY_PROFILE=HK 使用 tech_communication_pullback_enhancement;SG 使用 soxl_soxx_trend_income` + - 每个区域服务设置 `STRATEGY_PROFILE=` - `ACCOUNT_REGION=HK|SG` - - `LONGPORT_SECRET_NAME=longport_token_hk|longport_token_sg` + - `LONGPORT_SECRET_NAME=` - **运行时 secret** - - Secret Manager 引用: - - `longbridge-telegram-token` - - `longport-app-key-hk` - - `longport-app-key-sg` - - `longport-app-secret-hk` - - `longport-app-secret-sg` - - 区域 token secret: - - `longport_token_hk` - - `longport_token_sg` -- **当前说明** + - LongPort app key / app secret 的 Secret Manager 引用 + - 由 `LONGPORT_SECRET_NAME` 选择的区域 token secret + - runtime Telegram token secret +- **运行说明** - HK / SG 继续保持两个 Cloud Run 服务、两个 trigger、两个 GitHub Environment。 - - HK 使用 `tech_communication_pullback_enhancement` 的 feature-snapshot env;SG 当前是直接运行输入的 `soxl_soxx_trend_income`。 - - App key / secret 现在使用分区域的 Secret Manager 引用;Telegram token 在 LongBridge 项目内共享。 - - `SERVICE_NAME` 现在也已经对齐到上面的完整运行时名字,不再使用旧的 `longbridge-quant-hk` / `longbridge-quant-sg` 这种短前缀。 + - snapshot 驱动策略需要 feature snapshot path / manifest env;直接运行输入策略不需要。 + - App key / secret 使用分区域的 Secret Manager 引用;Telegram token 在 LongBridge 项目内共享。 + - `SERVICE_NAME` 应使用上面的完整运行时服务名,不再使用旧短前缀。 ### Binance @@ -134,16 +121,16 @@ _校验快照日期:2026-04-18_ - `workflow_dispatch` - **GCP 项目** - `binancequant` -- **GCP 现在承担的职责** +- **GCP 承担的职责** - Firestore - workflow / runtime 使用的 GCP service-account 凭据 -- **当前运行选择器** +- **运行选择器** - `STRATEGY_PROFILE=crypto_leader_rotation` -- **当前 Firestore 后端** +- **Firestore 后端** - database:`(default)` - mode:`FIRESTORE_NATIVE` - location:`nam5` -- **当前说明** +- **运行说明** - Binance 是刻意**不按 Cloud Run 平台**建模的。 - 后续如果继续清理,要把 Oracle 运行面和 GCP 后端职责分开看。 @@ -177,9 +164,3 @@ _校验快照日期:2026-04-18_ - Cloud Run 项目里的 scheduler OIDC 身份还在用默认 compute service account。 - 真正的跨平台策略实现共享还没开始;现在只有共享策略契约和平台兼容骨架。 - -## 这份清单之后的建议 - -1. 以后只要 runtime 服务名、secret 名、runtime service account 变了,就同步更新这份文档 -2. 以后只要 repo 名、service 名、scheduler 名任意一边变了,就把文档一起同步 -3. 等命名和运行配置稳定后,再开始真正按策略大类拆实现 diff --git a/docs/platform_strategy_matrix.md b/docs/platform_strategy_matrix.md index e14d50c..ae8c803 100644 --- a/docs/platform_strategy_matrix.md +++ b/docs/platform_strategy_matrix.md @@ -4,9 +4,9 @@ _Verified snapshot: 2026-04-18_ This page is the short answer to one question: -> which platforms belong to which strategy domain today, what is live right now, and what is only a future extension point? +> which platforms belong to which strategy domain today, which profiles are configurable, and what is only a future extension point? -For live runtime projects, services, schedulers, runtime identities, and secret names, see [`platform_runtime_inventory.md`](./platform_runtime_inventory.md). +For runtime projects, services, schedulers, runtime identities, and selector names, see [`platform_runtime_inventory.md`](./platform_runtime_inventory.md). For repository responsibility boundaries, see [`platform_repo_boundaries.md`](./platform_repo_boundaries.md). @@ -19,17 +19,17 @@ For strategy behavior, research status, and archived backtest evidence, see - `us_equity` - `crypto` - Runtime repositories already expose `STRATEGY_PROFILE`, but this is **not** a full multi-strategy marketplace yet. -- Today, each US equity platform can switch among the live `runtime_enabled` `us_equity` profiles published by `UsEquityStrategies`. +- Today, each US equity platform can switch among the `runtime_enabled` `us_equity` profiles published by `UsEquityStrategies`, subject to each platform's rollout configuration. - Platform runtime adapters are generated from strategy input/target-mode declarations plus platform capabilities, so new in-contract profiles should not need per-platform allowlist edits. - The shared contract is in `QuantPlatformKit`; real `us_equity` strategy implementations now live in `UsEquityStrategies`, while platform repositories own runtime adapters and broker execution. -## Current platform matrix +## Platform matrix -| Platform | Repo | Strategy domain | Current live profile | Runtime model | Real switching today? | +| Platform | Repo | Strategy domain | Configurable profile scope | Runtime model | Real switching today? | |---|---|---|---|---|---| -| IBKR | `QuantStrategyLab/InteractiveBrokersPlatform` | `us_equity` | `soxl_soxx_trend_income` | Cloud Run | Yes - rollout allowlist can switch among supported profiles | -| Charles Schwab | `QuantStrategyLab/CharlesSchwabPlatform` | `us_equity` | `tqqq_growth_income` | Cloud Run | Yes - rollout allowlist can switch among supported profiles | -| LongBridge | `QuantStrategyLab/LongBridgePlatform` | `us_equity` | `tech_communication_pullback_enhancement` on HK / `soxl_soxx_trend_income` on SG | Cloud Run | Yes - rollout allowlist can switch among supported profiles | +| IBKR | `QuantStrategyLab/InteractiveBrokersPlatform` | `us_equity` | `runtime_enabled` US equity profiles | Cloud Run | Yes - rollout allowlist can switch among supported profiles | +| Charles Schwab | `QuantStrategyLab/CharlesSchwabPlatform` | `us_equity` | `runtime_enabled` US equity profiles | Cloud Run | Yes - rollout allowlist can switch among supported profiles | +| LongBridge | `QuantStrategyLab/LongBridgePlatform` | `us_equity` | `runtime_enabled` US equity profiles per regional service | Cloud Run | Yes - rollout allowlist can switch among supported profiles | | Binance | `QuantStrategyLab/BinancePlatform` | `crypto` | `crypto_leader_rotation` | Oracle Cloud + self-hosted runner | No - only this profile is supported today | ## What this means right now @@ -48,7 +48,7 @@ Important limitation: - It means strategies that stay inside the shared input/target-mode contract can be admitted through `UsEquityStrategies` metadata and generated runtime adapters. - If a strategy needs a new input type or broker capability, the shared contract and platform capability matrix must be extended first. -Currently enabled live profiles in `us_equity`: +Configurable runtime-enabled profiles in `us_equity`: - `dynamic_mega_leveraged_pullback` - `global_etf_rotation` @@ -66,7 +66,7 @@ Platforms currently in this domain: - `BinancePlatform` -Current live profile in `crypto`: +Currently supported profile in `crypto`: - `crypto_leader_rotation` diff --git a/docs/platform_strategy_matrix.zh-CN.md b/docs/platform_strategy_matrix.zh-CN.md index 0c586cb..79aec23 100644 --- a/docs/platform_strategy_matrix.zh-CN.md +++ b/docs/platform_strategy_matrix.zh-CN.md @@ -4,9 +4,9 @@ _核对时间:2026-04-18_ 这页只回答一个问题: -> 现在各个平台分别属于哪个策略大类,线上实际在跑什么 profile,哪些只是后续扩展接口? +> 现在各个平台分别属于哪个策略大类,哪些 profile 可以配置,哪些只是后续扩展接口? -如果要看 live 的 GCP 项目、Cloud Run service、scheduler、runtime identity、secret 名,请看 [`platform_runtime_inventory.zh-CN.md`](./platform_runtime_inventory.zh-CN.md)。 +如果要看 runtime 的项目、Cloud Run service、scheduler、runtime identity 和 selector 名,请看 [`platform_runtime_inventory.zh-CN.md`](./platform_runtime_inventory.zh-CN.md)。 如果要看仓库职责边界,请看 [`platform_repo_boundaries.zh-CN.md`](./platform_repo_boundaries.zh-CN.md)。 @@ -19,17 +19,17 @@ _核对时间:2026-04-18_ - `us_equity` - `crypto` - 各个平台仓库现在都已经保留了 `STRATEGY_PROFILE` 入口,但这**还不是**真正的多策略平台。 -- 现在每个美股平台仓库都可以在 `UsEquityStrategies` 发布的 live `runtime_enabled` `us_equity` profile 之间切换。 +- 现在每个美股平台仓库都可以在 `UsEquityStrategies` 发布的 `runtime_enabled` `us_equity` profile 之间切换,前提是对应平台 rollout 配置已经放开。 - 平台 runtime adapter 会根据策略输入、target mode 和平台 capability 自动生成;规范内的新 profile 不应该再需要三个平台分别手写 allowlist。 - 共享契约在 `QuantPlatformKit`;真实的 `us_equity` 策略实现现在放在 `UsEquityStrategies`,平台仓库负责运行时适配和券商执行。 -## 当前平台矩阵 +## 平台矩阵 -| 平台 | 仓库 | 策略大类 | 当前 live profile | 运行模型 | 现在能否真实切换? | +| 平台 | 仓库 | 策略大类 | 可配置 profile 范围 | 运行模型 | 现在能否真实切换? | |---|---|---|---|---|---| -| IBKR | `QuantStrategyLab/InteractiveBrokersPlatform` | `us_equity` | `soxl_soxx_trend_income` | Cloud Run | 可以,rollout allowlist 可在受支持 profile 间切换 | -| Charles Schwab | `QuantStrategyLab/CharlesSchwabPlatform` | `us_equity` | `tqqq_growth_income` | Cloud Run | 可以,rollout allowlist 可在受支持 profile 间切换 | -| LongBridge | `QuantStrategyLab/LongBridgePlatform` | `us_equity` | `HK: tech_communication_pullback_enhancement / SG: soxl_soxx_trend_income` | Cloud Run | 可以,rollout allowlist 可在受支持 profile 间切换 | +| IBKR | `QuantStrategyLab/InteractiveBrokersPlatform` | `us_equity` | `runtime_enabled` 美股 profiles | Cloud Run | 可以,rollout allowlist 可在受支持 profile 间切换 | +| Charles Schwab | `QuantStrategyLab/CharlesSchwabPlatform` | `us_equity` | `runtime_enabled` 美股 profiles | Cloud Run | 可以,rollout allowlist 可在受支持 profile 间切换 | +| LongBridge | `QuantStrategyLab/LongBridgePlatform` | `us_equity` | 每个区域服务可配置 `runtime_enabled` 美股 profiles | Cloud Run | 可以,rollout allowlist 可在受支持 profile 间切换 | | Binance | `QuantStrategyLab/BinancePlatform` | `crypto` | `crypto_leader_rotation` | Oracle Cloud + self-hosted runner | 不能,当前只支持这个 profile | ## 这张表现在该怎么理解 @@ -48,7 +48,7 @@ _核对时间:2026-04-18_ - 它表示只要策略遵守共享输入和 target-mode 契约,就可以通过 `UsEquityStrategies` 元数据和生成式 runtime adapter 接入。 - 如果策略需要新的输入类型或券商能力,要先扩共享契约和平台 capability matrix。 -当前 `us_equity` 域里已经启用的 live profile 有: +当前 `us_equity` 域里已经启用的 runtime profile 有: - `dynamic_mega_leveraged_pullback` - `global_etf_rotation` @@ -66,7 +66,7 @@ _核对时间:2026-04-18_ - `BinancePlatform` -当前 `crypto` 域里线上在跑的 profile: +当前 `crypto` 域里支持的 profile: - `crypto_leader_rotation` diff --git a/docs/us_equity_cross_platform_strategy_spec.md b/docs/us_equity_cross_platform_strategy_spec.md index 05bd026..eab6246 100644 --- a/docs/us_equity_cross_platform_strategy_spec.md +++ b/docs/us_equity_cross_platform_strategy_spec.md @@ -238,7 +238,7 @@ Reviewers should reject a new strategy PR if any of these are true: ## Migration notes for current profiles -Current live profiles can migrate incrementally, but the end state should be: +Current runtime-enabled profiles can migrate incrementally, but the end state should be: - `global_etf_rotation`: portable through normalized history inputs plus weight/value translation diff --git a/docs/us_equity_cross_platform_strategy_spec.zh-CN.md b/docs/us_equity_cross_platform_strategy_spec.zh-CN.md index ae02a99..3d31b42 100644 --- a/docs/us_equity_cross_platform_strategy_spec.zh-CN.md +++ b/docs/us_equity_cross_platform_strategy_spec.zh-CN.md @@ -238,7 +238,7 @@ allowlist 只影响 `enabled`,不要再手写一堆“这个策略天生只能 ## 当前策略的迁移目标 -现有 live profile 可以分步迁移,但目标状态应该是: +现有 runtime-enabled profile 可以分步迁移,但目标状态应该是: - `global_etf_rotation` - 通过标准历史数据输入 + `weight/value` 翻译实现跨平台 diff --git a/docs/us_equity_execution_translation_spec.zh-CN.md b/docs/us_equity_execution_translation_spec.zh-CN.md index 1b930a8..75d9d9d 100644 --- a/docs/us_equity_execution_translation_spec.zh-CN.md +++ b/docs/us_equity_execution_translation_spec.zh-CN.md @@ -133,7 +133,7 @@ 这些原因应该体现在平台诊断或 runtime report 里。 -## 对当前 live profile 的影响 +## 对当前 runtime-enabled profile 的影响 - `global_etf_rotation` - 现在策略契约已经是 `market_history` + `target_mode=weight` diff --git a/docs/us_equity_live_switch_runbook.md b/docs/us_equity_live_switch_runbook.md index 93b6c09..bc25428 100644 --- a/docs/us_equity_live_switch_runbook.md +++ b/docs/us_equity_live_switch_runbook.md @@ -1,6 +1,6 @@ -# US equity live switch and rollback runbook +# US equity strategy switch and rollback runbook -This document is the operational runbook for switching live US equity strategy profiles on the current broker platforms. +This document is the operational runbook for switching US equity strategy profiles on the current broker platforms. Use this after the shared package and platform code is already deployed. @@ -8,7 +8,7 @@ Do **not** use it to justify switching a profile that is not already supported b ## Scope -Current live US equity profiles: +Configurable US equity profiles: - `dynamic_mega_leveraged_pullback` - `global_etf_rotation` @@ -22,17 +22,17 @@ Current live US equity profiles: Note: older deployments may still accept `qqq_tech_enhancement` as a legacy alias for `tech_communication_pullback_enhancement`, but runbooks should use the canonical profile name. -Current runtime platforms: +Runtime platforms: - `ibkr` - `schwab` - `longbridge` -For the current nine-profile scope, all three platforms now report the full matrix as `eligible=true` and `enabled=true`. That means live switching is now an operational change, not a strategy-contract migration. +For the current nine-profile scope, all three platforms now report the full matrix as `eligible=true` and `enabled=true`. That means switching among these supported profiles is an operational change, not a strategy-contract migration. ## Operational profile groups -Treat the live profiles as two operational groups: +Treat the profiles as two operational groups: - **Direct-runtime profiles** - `global_etf_rotation` diff --git a/docs/us_equity_live_switch_runbook.zh-CN.md b/docs/us_equity_live_switch_runbook.zh-CN.md index af65704..b54e297 100644 --- a/docs/us_equity_live_switch_runbook.zh-CN.md +++ b/docs/us_equity_live_switch_runbook.zh-CN.md @@ -1,6 +1,6 @@ -# 美股线上切换与回滚运行手册 +# 美股策略切换与回滚运行手册 -这份文档是当前美股策略在线上切换时的操作手册。 +这份文档是当前美股策略切换时的操作手册。 它默认前提是: @@ -11,7 +11,7 @@ ## 适用范围 -当前美股 live profile: +可配置美股 profile: - `dynamic_mega_leveraged_pullback` - `global_etf_rotation` @@ -25,17 +25,17 @@ 说明:旧部署里 `qqq_tech_enhancement` 仍可能作为 `tech_communication_pullback_enhancement` 的 legacy alias 被接受,但运行手册统一使用 canonical profile 名。 -当前运行平台: +运行平台: - `ibkr` - `schwab` - `longbridge` -对当前这 9 条策略来说,三个平台现在都已经是 `eligible=true` 且 `enabled=true`。也就是说,接下来换线上策略主要是运维切换,不再是契约迁移。 +对当前这 9 条策略来说,三个平台现在都已经是 `eligible=true` 且 `enabled=true`。也就是说,在这些受支持 profile 之间切换主要是运维切换,不再是契约迁移。 ## 运维分组 -现在最好把 live 策略按两组理解: +现在最好把策略按两组理解: - **直接运行输入策略** - `global_etf_rotation` diff --git a/docs/us_equity_release_cutover_plan.md b/docs/us_equity_release_cutover_plan.md index a482e06..755d943 100644 --- a/docs/us_equity_release_cutover_plan.md +++ b/docs/us_equity_release_cutover_plan.md @@ -180,107 +180,61 @@ git push origin HEAD If any repo still has unrelated local edits, split or stash them before creating the release commit. -## Intended live strategy matrix after cutover +## Strategy selector cutover pattern -| Platform service | Intended strategy profile | Notes | -| --- | --- | --- | -| `charles-schwab-quant-service` | `tqqq_growth_income` | TQQQ Growth Income should remain the Schwab live profile | -| `longbridge-quant-hk-service` | `tech_communication_pullback_enhancement` | HK should move to Tech/Communication Pullback Enhancement | -| `longbridge-quant-sg-service` | `soxl_soxx_trend_income` | SG should run SOXL/SOXX Semiconductor Trend Income | -| `interactive-brokers-quant-service` | `soxl_soxx_trend_income` | IBKR should move to SOXL/SOXX Semiconductor Trend Income | - -## Cutover env changes +This public runbook does not pin any account or service to a current strategy profile. Choose the target profile from the supported platform matrix, then apply the matching input mode below. -### CharlesSchwabPlatform +| Service family | Strategy selector | Direct-runtime profile inputs | Snapshot-backed profile inputs | +| --- | --- | --- | --- | +| Schwab Cloud Run service | `STRATEGY_PROFILE=` | market / benchmark history and portfolio snapshot from the runtime | feature snapshot path, manifest path, and optional strategy config path | +| IBKR Cloud Run service | `STRATEGY_PROFILE=` | market / benchmark history and portfolio snapshot from the runtime | feature snapshot path, manifest path, optional strategy config path, and reconciliation output path | +| LongBridge regional service | `STRATEGY_PROFILE=` | market / benchmark history and portfolio snapshot from the runtime | feature snapshot path, manifest path, and optional strategy config path | -Service: +## Cutover env changes -- `charles-schwab-quant-service` +### Direct-runtime profile Set: -- `STRATEGY_PROFILE=tqqq_growth_income` +- `STRATEGY_PROFILE=` -Remove: +Remove stale snapshot envs if present: -- `SCHWAB_DRY_RUN_ONLY` unless a dry-run rollback is explicitly wanted +- `*_FEATURE_SNAPSHOT_PATH` +- `*_FEATURE_SNAPSHOT_MANIFEST_PATH` +- `*_STRATEGY_CONFIG_PATH` +- `*_RECONCILIATION_OUTPUT_PATH` where the platform owns reconciliation output -### LongBridgePlatform HK +Keep execution-mode or dry-run flags unchanged unless the rollout decision explicitly changes them. -Service: - -- `longbridge-quant-hk-service` +### Snapshot-backed profile Set: -- `ACCOUNT_PREFIX=HK` -- `ACCOUNT_REGION=HK` -- `STRATEGY_PROFILE=tech_communication_pullback_enhancement` -- `LONGBRIDGE_FEATURE_SNAPSHOT_PATH` -- `LONGBRIDGE_FEATURE_SNAPSHOT_MANIFEST_PATH` -- `LONGBRIDGE_STRATEGY_CONFIG_PATH` - -Keep unset unless explicitly needed: - -- `LONGBRIDGE_DRY_RUN_ONLY` +- `STRATEGY_PROFILE=` +- `_FEATURE_SNAPSHOT_PATH` +- `_FEATURE_SNAPSHOT_MANIFEST_PATH` +- `_STRATEGY_CONFIG_PATH` if the profile needs an external config file Reason: -- `tech_communication_pullback_enhancement` is a feature snapshot strategy -- HK cutover is not only a profile switch; it also needs snapshot/config inputs - -### LongBridgePlatform SG - -Service: - -- `longbridge-quant-sg-service` - -Set: - -- `ACCOUNT_PREFIX=SG` -- `ACCOUNT_REGION=SG` -- `STRATEGY_PROFILE=soxl_soxx_trend_income` +- snapshot-backed profiles consume a published artifact from `UsEquitySnapshotPipelines` +- direct-runtime profiles do not need the feature snapshot artifact chain -Keep current dry-run choice unless separately changed: +### Regional LongBridge services -- `LONGBRIDGE_DRY_RUN_ONLY` +Set per regional service: -Remove if present: - -- `LONGBRIDGE_FEATURE_SNAPSHOT_PATH` -- `LONGBRIDGE_FEATURE_SNAPSHOT_MANIFEST_PATH` -- `LONGBRIDGE_STRATEGY_CONFIG_PATH` - -### InteractiveBrokersPlatform - -Service: - -- `interactive-brokers-quant-service` - -Set: - -- `STRATEGY_PROFILE=soxl_soxx_trend_income` - -Keep as-is unless the live rollout decision changes: - -- `IBKR_DRY_RUN_ONLY` -- `ACCOUNT_GROUP` - -Remove the tech-specific feature snapshot envs after switching away from `tech_communication_pullback_enhancement`: - -- `IBKR_FEATURE_SNAPSHOT_PATH` -- `IBKR_FEATURE_SNAPSHOT_MANIFEST_PATH` -- `IBKR_STRATEGY_CONFIG_PATH` -- `IBKR_RECONCILIATION_OUTPUT_PATH` - -Reason: +- `ACCOUNT_PREFIX=HK|SG` +- `ACCOUNT_REGION=HK|SG` +- `STRATEGY_PROFILE=` +- `LONGPORT_SECRET_NAME=` -- `soxl_soxx_trend_income` now uses canonical `derived_indicators + portfolio_snapshot` -- it does not need the tech feature snapshot artifact chain +Do not change service names as part of a strategy switch. ## Verification checklist -### Before changing live env +### Before changing env For each platform repo: @@ -289,7 +243,7 @@ For each platform repo: 3. deploy 4. verify the new commit SHA is actually on Cloud Run -### After changing live env +### After changing env Verify with `gcloud run services describe ...`: @@ -300,10 +254,10 @@ Verify with `gcloud run services describe ...`: Then verify the first heartbeat / execution notification: -- Schwab -> `TQQQ Growth Income` -- LongBridge HK -> `Tech/Communication Pullback Enhancement` -- LongBridge SG -> `SOXL/SOXX Semiconductor Trend Income` -- IBKR -> `SOXL/SOXX Semiconductor Trend Income` +- strategy display name matches the selected profile +- input-mode diagnostics match the selected profile type +- stale snapshot envs are absent for direct-runtime profiles +- snapshot-backed profiles can load the expected artifact manifest ## Rollback rules diff --git a/docs/us_equity_release_cutover_plan.zh-CN.md b/docs/us_equity_release_cutover_plan.zh-CN.md index 726cb86..5223d85 100644 --- a/docs/us_equity_release_cutover_plan.zh-CN.md +++ b/docs/us_equity_release_cutover_plan.zh-CN.md @@ -180,107 +180,61 @@ git push origin HEAD 如果某个仓库还有无关本地改动,先拆提交或先 stash,再做这次发版提交。 -## 目标线上策略矩阵 +## 策略选择器切换模式 -| 平台服务 | 目标策略 profile | 说明 | -| --- | --- | --- | -| `charles-schwab-quant-service` | `tqqq_growth_income` | Schwab 继续跑 TQQQ 增长收益 | -| `longbridge-quant-hk-service` | `tech_communication_pullback_enhancement` | HK 切到科技通信回调增强 | -| `longbridge-quant-sg-service` | `soxl_soxx_trend_income` | SG 运行 SOXL/SOXX 半导体趋势收益 | -| `interactive-brokers-quant-service` | `soxl_soxx_trend_income` | IBKR 切到 SOXL/SOXX 半导体趋势收益 | - -## 切换时要改的 env +这份公开 runbook 不绑定任何账户或服务当前应该跑哪条策略。先从受支持平台矩阵里选择目标 profile,再按下面的输入类型切换。 -### CharlesSchwabPlatform +| 服务类型 | 策略选择器 | 直接运行输入 | Snapshot 驱动输入 | +| --- | --- | --- | --- | +| Schwab Cloud Run 服务 | `STRATEGY_PROFILE=` | runtime 提供 market / benchmark history 和 portfolio snapshot | feature snapshot path、manifest path、可选 strategy config path | +| IBKR Cloud Run 服务 | `STRATEGY_PROFILE=` | runtime 提供 market / benchmark history 和 portfolio snapshot | feature snapshot path、manifest path、可选 strategy config path,以及 reconciliation output path | +| LongBridge 区域服务 | `STRATEGY_PROFILE=` | runtime 提供 market / benchmark history 和 portfolio snapshot | feature snapshot path、manifest path、可选 strategy config path | -服务: +## 切换时要改的 env -- `charles-schwab-quant-service` +### 直接运行输入策略 设置: -- `STRATEGY_PROFILE=tqqq_growth_income` +- `STRATEGY_PROFILE=` -删除: +如果残留 snapshot env,要删掉: -- `SCHWAB_DRY_RUN_ONLY`,除非明确要临时回到 dry-run +- `*_FEATURE_SNAPSHOT_PATH` +- `*_FEATURE_SNAPSHOT_MANIFEST_PATH` +- `*_STRATEGY_CONFIG_PATH` +- 平台拥有 reconciliation output 时,删掉 `*_RECONCILIATION_OUTPUT_PATH` -### LongBridgePlatform HK +执行模式或 dry-run 相关变量保持不动,除非这次 rollout 明确要改变。 -服务: - -- `longbridge-quant-hk-service` +### Snapshot 驱动策略 设置: -- `ACCOUNT_PREFIX=HK` -- `ACCOUNT_REGION=HK` -- `STRATEGY_PROFILE=tech_communication_pullback_enhancement` -- `LONGBRIDGE_FEATURE_SNAPSHOT_PATH` -- `LONGBRIDGE_FEATURE_SNAPSHOT_MANIFEST_PATH` -- `LONGBRIDGE_STRATEGY_CONFIG_PATH` - -默认保持不设: - -- `LONGBRIDGE_DRY_RUN_ONLY` +- `STRATEGY_PROFILE=` +- `_FEATURE_SNAPSHOT_PATH` +- `_FEATURE_SNAPSHOT_MANIFEST_PATH` +- profile 需要外部配置时设置 `_STRATEGY_CONFIG_PATH` 原因: -- `tech_communication_pullback_enhancement` 是 feature snapshot 策略 -- HK 这次不只是改 profile,还需要把 snapshot/config 输入一起接上 - -### LongBridgePlatform SG - -服务: - -- `longbridge-quant-sg-service` - -设置: - -- `ACCOUNT_PREFIX=SG` -- `ACCOUNT_REGION=SG` -- `STRATEGY_PROFILE=soxl_soxx_trend_income` +- snapshot 驱动策略消费 `UsEquitySnapshotPipelines` 发布的 artifact +- 直接运行输入策略不需要 feature snapshot artifact 链路 -是否继续 dry-run,保持当前决定: +### LongBridge 区域服务 -- `LONGBRIDGE_DRY_RUN_ONLY` +每个区域服务分别设置: -如果还有这些变量,要删掉: - -- `LONGBRIDGE_FEATURE_SNAPSHOT_PATH` -- `LONGBRIDGE_FEATURE_SNAPSHOT_MANIFEST_PATH` -- `LONGBRIDGE_STRATEGY_CONFIG_PATH` - -### InteractiveBrokersPlatform - -服务: - -- `interactive-brokers-quant-service` - -设置: - -- `STRATEGY_PROFILE=soxl_soxx_trend_income` - -下面这些先保持现状,除非另行决定是否真跑: - -- `IBKR_DRY_RUN_ONLY` -- `ACCOUNT_GROUP` - -从 `tech_communication_pullback_enhancement` 切走后,要把 tech 专用的 feature snapshot env 删掉: - -- `IBKR_FEATURE_SNAPSHOT_PATH` -- `IBKR_FEATURE_SNAPSHOT_MANIFEST_PATH` -- `IBKR_STRATEGY_CONFIG_PATH` -- `IBKR_RECONCILIATION_OUTPUT_PATH` - -原因: +- `ACCOUNT_PREFIX=HK|SG` +- `ACCOUNT_REGION=HK|SG` +- `STRATEGY_PROFILE=` +- `LONGPORT_SECRET_NAME=` -- `soxl_soxx_trend_income` 现在走的是 canonical `derived_indicators + portfolio_snapshot` -- 不再需要科技增强那套 feature snapshot artifact 链路 +切换策略时不要改 service name。 ## 验证清单 -### 改线上 env 之前 +### 改 env 之前 每个平台仓库都要先做: @@ -289,7 +243,7 @@ git push origin HEAD 3. 部署 4. 确认 Cloud Run 上真的已经是新 commit -### 改线上 env 之后 +### 改 env 之后 用 `gcloud run services describe ...` 确认: @@ -300,10 +254,10 @@ git push origin HEAD 再看第一条心跳 / 执行通知: -- Schwab -> `TQQQ Growth Income` -- LongBridge HK -> `Tech/Communication Pullback Enhancement` -- LongBridge SG -> `SOXL/SOXX Semiconductor Trend Income` -- IBKR -> `SOXL/SOXX Semiconductor Trend Income` +- 策略显示名和选择的 profile 一致 +- 输入类型 diagnostics 和选择的 profile 类型一致 +- 直接运行输入策略没有残留 snapshot env +- snapshot 驱动策略能加载目标 artifact manifest ## 回滚原则