"Vibe-Trading: Your Personal Trading Agent"
Python ai-agentalgorithmic-tradingbacktestingfintechllmmcpmulti-agentpythonquantitative-financetrading
docs: add IM channel README coverage (#343)
Haozhe Wu2d08b9550cc5
diff --git a/README.md b/README.mdindex b8683af68..734c9f391 100644--- a/README.md+++ b/README.md@@ -50,13 +50,15 @@## 📰 News+- **2026-06-30** 💬 **IM channel runtime for research delivery**: Vibe-Trading can now attach the same agent session runtime to 16 built-in message adapters — WebSocket, Telegram, Slack, Discord, Matrix, WhatsApp, Signal, QQ/NapCat, WeChat/WeCom, Feishu/Lark, DingTalk, Teams, email, and Mochat. CLI (`vibe-trading channels status/start/stop/login/pairing`), REST (`/channels/status`, `/channels/start`, `/channels/stop`, `/channels/pairing/command`), and the Web UI Settings panel expose status, recovery hints, start/stop, and sender pairing; SDK-backed adapters stay behind extras such as `vibe-trading-ai[telegram]` or `vibe-trading-ai[channels]` ([#341](https://github.com/HKUDS/Vibe-Trading/pull/341)).+- **2026-06-29** 🛡️ **Live advisory safety + Trading 212 read-only connector + Windows/Gemini fixes**: live order guards now have an opt-in, broker-agnostic `PreTradeAdvisoryInterface` that records advisory reviews without bypassing the mandate gate, kill switch, or audit trail ([#328](https://github.com/HKUDS/Vibe-Trading/pull/328), closes [#317](https://github.com/HKUDS/Vibe-Trading/issues/317), thanks @shadowinlife). Trading 212 joins the connector layer with read-only account, positions, orders, history, and instrument-metadata support; `place_order` / `cancel_order` still hard-refuse until a structural paper/live boundary exists ([#321](https://github.com/HKUDS/Vibe-Trading/pull/321), closes [#309](https://github.com/HKUDS/Vibe-Trading/issues/309), thanks @mvanhorn). Windows startup avoids the pandas 3.0 `Timestamp` crash via the `<3.0.0` constraint ([#329](https://github.com/HKUDS/Vibe-Trading/pull/329), closes [#324](https://github.com/HKUDS/Vibe-Trading/issues/324), thanks @hannibal-lee); Gemini `thought_signature` dict-history replay was verified/fixed on `main` ([#318](https://github.com/HKUDS/Vibe-Trading/issues/318)); `.US` financial statements now route to SEC EDGAR instead of Eastmoney ([#325](https://github.com/HKUDS/Vibe-Trading/issues/325)); and the Alpha Library landing page got cache/date/selector/noscript/DNS-prefetch hardening while heavier CSP and social-card follow-ups stay tracked ([#323](https://github.com/HKUDS/Vibe-Trading/issues/323)).- **2026-06-28** 🧰 **Cross-platform setup/dev + runtime and file-tool hardening**: `vibe-trading setup` and `vibe-trading dev` now handle Windows TypeScript builds, launch the backend from the right cwd, use the Vite 5899 port, and shut child processes down cleanly ([#292](https://github.com/HKUDS/Vibe-Trading/pull/292), thanks @digger-yu). Runtime status polling now degrades instead of crashing ([#322](https://github.com/HKUDS/Vibe-Trading/issues/322)); MCP OAuth cache keys are sanitized ([#313](https://github.com/HKUDS/Vibe-Trading/issues/313)); OpenAI defaults and Robinhood `agent.json` validation were tightened ([#319](https://github.com/HKUDS/Vibe-Trading/pull/319), [#320](https://github.com/HKUDS/Vibe-Trading/pull/320), thanks @mvanhorn); and file tools got isolated read/write roots plus broader sandbox tests ([#299](https://github.com/HKUDS/Vibe-Trading/pull/299), thanks @skloxo).-- **2026-06-27** 🧯 **Content-filter resilience + Shadow Account feature contract cleanup**: event-driven and swarm runs now skip individual LLM content-moderation hits, warn in run cards when filter rates are high, and recognize Gemini safety finish reasons instead of aborting an entire analysis ([#308](https://github.com/HKUDS/Vibe-Trading/pull/308), closes [#307](https://github.com/HKUDS/Vibe-Trading/issues/307), thanks @shadowinlife). Shadow Account extraction/codegen now share one `PRICE_FEATURES` contract and keep four-decimal return bounds, preventing rule/codegen drift and precision loss on `prior_5d_return` ([#316](https://github.com/HKUDS/Vibe-Trading/pull/316), thanks @Robin1987China).<details><summary>Earlier news</summary>+- **2026-06-27** 🧯 **Content-filter resilience + Shadow Account feature contract cleanup**: event-driven and swarm runs now skip individual LLM content-moderation hits, warn in run cards when filter rates are high, and recognize Gemini safety finish reasons instead of aborting an entire analysis ([#308](https://github.com/HKUDS/Vibe-Trading/pull/308), closes [#307](https://github.com/HKUDS/Vibe-Trading/issues/307), thanks @shadowinlife). Shadow Account extraction/codegen now share one `PRICE_FEATURES` contract and keep four-decimal return bounds, preventing rule/codegen drift and precision loss on `prior_5d_return` ([#316](https://github.com/HKUDS/Vibe-Trading/pull/316), thanks @Robin1987China).- **2026-06-26** 🎯 **Shadow Account conditional entry + tushare ETF/index/HK routing**: extracted Shadow Account rules now carry RSI / prior-return bounds, so the generated SignalEngine enters on real conditions (RSI in range, prior-return in range) instead of blindly replaying the holding cadence ([#314](https://github.com/HKUDS/Vibe-Trading/pull/314), follows [#302](https://github.com/HKUDS/Vibe-Trading/pull/302), thanks @Robin1987China). The tushare loader also routes ETF/LOF → `fund_daily()`, indices → `index_daily()`, and HK equities → `hk_daily()` instead of always calling `daily()` (which silently returns empty for non-stocks), with per-symbol empty-result + partial-fetch warnings ([#315](https://github.com/HKUDS/Vibe-Trading/pull/315), closes [#310](https://github.com/HKUDS/Vibe-Trading/issues/310), thanks @shadowinlife).- **2026-06-25** 🧪 **Strict validation JSON + calmer agent context**: standalone backtest validation now normalizes nested `NaN` / `Infinity` values before writing `artifacts/validation.json` or CLI stdout, so strict JSON parsers no longer choke on validation payloads ([#306](https://github.com/HKUDS/Vibe-Trading/pull/306), thanks @gyx09212214-prog). The agent prompt also derives the current data-source count from the loader registry, and `_microcompact()` now waits for real token pressure instead of clearing older tool results during short runs ([#296](https://github.com/HKUDS/Vibe-Trading/pull/296), closes [#282](https://github.com/HKUDS/Vibe-Trading/issues/282), thanks @MarkfuGod).- **2026-06-24** 🎯 **Shadow Account price context + reactive Chinese UI + LAN auth fix**: Shadow Account rule extraction now sees PIT-safe entry context — `entry_rsi14` and `prior_5d_return` fetched through the loader registry as of `buy_dt`, with graceful offline/no-data degradation ([#302](https://github.com/HKUDS/Vibe-Trading/pull/302), follows [#295](https://github.com/HKUDS/Vibe-Trading/issues/295), thanks @Robin1987China). The main Web UI panels now use reactive English / zh-CN translations across charts, chat, Alpha Library, Correlation, and Run Detail ([#301](https://github.com/HKUDS/Vibe-Trading/pull/301), thanks @skloxo). Remote same-origin Web UI deployments with `API_AUTH_KEY` can post and upload again after the CSRF hardening, while mismatched cross-site origins remain blocked ([#304](https://github.com/HKUDS/Vibe-Trading/pull/304), thanks @Hinotoi-agent).@@ -205,6 +207,7 @@ It is designed for research, simulation, and backtesting — and, when you choos| **Review your own trades** | Broker-journal parsing, behavior diagnostics, rule extraction, and Shadow Account comparisons. || **Improve repeated research** | Persistent memory and editable skills turn useful routines into reusable workflows. || **Run analyst teams** | Multi-agent research reviews for investment, quant, crypto, macro, and risk workflows. |+| **Put research into IM channels** | Run the same session runtime through WebSocket, Telegram, Slack, Discord, Matrix, WhatsApp, Signal, QQ/NapCat, WeChat/WeCom, Feishu/Lark, DingTalk, Teams, email, and Mochat with CLI, REST, and Web UI controls. || **Ship usable artifacts** | Reports, TradingView Pine Script, TDX, MetaTrader 5, MCP tools, and later research sessions. || **Bench a pre-built alpha zoo** | One-line IC + alive/reversed/dead categorisation across 456 alphas (Qlib 158 + Kakushadze 101 + GTJA 191 + FF5 + Carhart) on your universe. |@@ -602,6 +605,7 @@ vibe-trading # interactive TUIvibe-trading run -p "..." # single runvibe-trading serve # API servervibe-trading alpha list # browse 456 pre-built alphas; show / bench / compare / export-manifest sub-commands available+vibe-trading channels status --local # inspect IM channel config and install hintsvibe-trading provider doctor # print redacted provider/proxy/package diagnostics```@@ -662,6 +666,24 @@ vibe-trading alpha bench --zoo gtja191 --universe csi300 --period 2018-2025 --to</details>+<details>+<summary><b>IM channels</b></summary>++IM channel adapters connect outside chat apps to the same session runtime used by the Web UI and CLI. Configure enabled adapters under `channels` in `~/.vibe-trading/agent.json`; SDK-backed adapters are optional extras, and missing SDKs report recovery hints instead of crashing the runtime.++```bash+vibe-trading channels status --local # inspect config and missing SDK hints without API+vibe-trading channels status # query the running API runtime+vibe-trading channels start # start enabled adapters through the API+vibe-trading channels stop # stop enabled adapters through the API+vibe-trading channels login weixin # run an adapter login hook when needed+vibe-trading channels pairing --channel telegram list+```++The built-in adapters cover `websocket`, `telegram`, `slack`, `discord`, `matrix`, `whatsapp`, `signal`, `qq`, `napcat`, `weixin`, `wecom`, `feishu`, `dingtalk`, `msteams`, `email`, and `mochat`. Use narrow extras such as `pip install "vibe-trading-ai[telegram]"`, or install the full channel set with `pip install "vibe-trading-ai[channels]"`.++</details>+---## 💡 Examples@@ -779,6 +801,10 @@ vibe-trading serve --port 8899| `PUT` | `/settings/llm` | Update local LLM settings || `GET` | `/settings/data-sources` | Read local data source settings || `PUT` | `/settings/data-sources` | Update local data source settings |+| `GET` | `/channels/status` | Read IM channel runtime and adapter status |+| `POST` | `/channels/start` | Start configured IM channel adapters |+| `POST` | `/channels/stop` | Stop configured IM channel adapters |+| `POST` | `/channels/pairing/command` | Run a sender-pairing command against the shared store || `POST` | `/scheduled-runs` | Create a scheduled research job (interval-ms or cron) || `GET` | `/scheduled-runs` | List scheduled jobs || `DELETE` | `/scheduled-runs/{job_id}` | Cancel a scheduled job |@@ -797,6 +823,8 @@ The Web UI Settings page lets local users update the LLM provider/model, base URSettings reads are side-effect free: `GET /settings/llm` and `GET /settings/data-sources` never create `agent/.env`, and they only return project-relative paths. Settings reads and writes can expose credential state or update credentials/runtime environment, so they require `API_AUTH_KEY` when configured. If `API_AUTH_KEY` is unset for dev mode, settings access is accepted only from loopback clients.+The same Settings page includes an **IM Channels** panel for local operators. It polls `/channels/status`, shows configured/enabled/available/loaded/running states, surfaces adapter recovery hints, and can start or stop the configured channel runtime without going back to the terminal.+### Scheduled researchRun a research prompt or backtest on a repeating schedule. The background executor is **off by default** — start the server with `VIBE_TRADING_ENABLE_SCHEDULER=1` to enable it:@@ -1207,7 +1235,7 @@ Vibe-Trading is part of the **[HKUDS](https://github.com/HKUDS)** agent ecosyste| **Options Lab** | Vol surface, Greeks dashboard, payoff/scenario explorer | Planned || **Portfolio Studio** | Risk x-ray, constraints, turnover-aware optimizer, rebalance notes | Planned || **Alpha Zoo** | 452 pre-built alphas (Qlib 158 + Kakushadze 101 + GTJA 191 + FF5 + Carhart) with one-line bench, agent integration, and Web UI | **Shipped 0.1.8** |-| **Research Delivery** | Scheduled briefs to Slack / Telegram / email-style channels | Scheduler Shipped |+| **Research Delivery** | Scheduled briefs and live research sessions through Slack / Telegram / email-style IM channels | Scheduler + IM Runtime Shipped || **Community** | Shareable skills, presets, and strategy cards | Exploring |---diff --git a/README_ar.md b/README_ar.mdindex a4b59bf3e..e3392f3f3 100644--- a/README_ar.md+++ b/README_ar.md@@ -50,13 +50,15 @@## 📰 الأخبار+- **2026-06-30** 💬 **بيئة تشغيل قنوات IM لتسليم الأبحاث**: يستطيع Vibe-Trading الآن وصل بيئة تشغيل جلسة agent نفسها بـ 16 محوّلاً مدمجاً للرسائل — WebSocket وTelegram وSlack وDiscord وMatrix وWhatsApp وSignal وQQ/NapCat وWeChat/WeCom وFeishu/Lark وDingTalk وTeams وemail وMochat. تغطي CLI (`vibe-trading channels status/start/stop/login/pairing`) وREST (`/channels/status` و`/channels/start` و`/channels/stop` و`/channels/pairing/command`) ولوحة Web UI Settings الحالة وتلميحات الاسترداد والبدء/الإيقاف وsender pairing؛ وتبقى المحولات المعتمدة على SDK خلف extras مثل `vibe-trading-ai[telegram]` أو `vibe-trading-ai[channels]` ([#341](https://github.com/HKUDS/Vibe-Trading/pull/341)).+- **2026-06-29** 🛡️ **Live advisory safety + Trading 212 read-only connector + Windows/Gemini fixes**: live order guards now have an opt-in, broker-agnostic `PreTradeAdvisoryInterface` that records advisory reviews without bypassing the mandate gate, kill switch, or audit trail ([#328](https://github.com/HKUDS/Vibe-Trading/pull/328), closes [#317](https://github.com/HKUDS/Vibe-Trading/issues/317), thanks @shadowinlife). Trading 212 joins the connector layer with read-only account, positions, orders, history, and instrument-metadata support; `place_order` / `cancel_order` still hard-refuse until a structural paper/live boundary exists ([#321](https://github.com/HKUDS/Vibe-Trading/pull/321), closes [#309](https://github.com/HKUDS/Vibe-Trading/issues/309), thanks @mvanhorn). Windows startup avoids the pandas 3.0 `Timestamp` crash via the `<3.0.0` constraint ([#329](https://github.com/HKUDS/Vibe-Trading/pull/329), closes [#324](https://github.com/HKUDS/Vibe-Trading/issues/324), thanks @hannibal-lee); Gemini `thought_signature` dict-history replay was verified/fixed on `main` ([#318](https://github.com/HKUDS/Vibe-Trading/issues/318)); `.US` financial statements now route to SEC EDGAR instead of Eastmoney ([#325](https://github.com/HKUDS/Vibe-Trading/issues/325)); and the Alpha Library landing page got cache/date/selector/noscript/DNS-prefetch hardening while heavier CSP and social-card follow-ups stay tracked ([#323](https://github.com/HKUDS/Vibe-Trading/issues/323)).- **2026-06-28** 🧰 **أوامر setup/dev عبر المنصات + تقوية runtime وأدوات الملفات**: يتعامل `vibe-trading setup` و`vibe-trading dev` الآن مع بناء TypeScript على Windows، وتشغيل backend من cwd الصحيح، واستخدام منفذ Vite 5899، وإغلاق العمليات الفرعية بنظافة عند الخروج ([#292](https://github.com/HKUDS/Vibe-Trading/pull/292)، شكراً @digger-yu). كما أصبح polling لحالة Runtime يتدهور بأمان بدل الانهيار ([#322](https://github.com/HKUDS/Vibe-Trading/issues/322))، وتُنظَّف مفاتيح cache الخاصة بـ MCP OAuth ([#313](https://github.com/HKUDS/Vibe-Trading/issues/313))، وشُدِّدت defaults الخاصة بـ OpenAI والتحقق من Robinhood `agent.json` ([#319](https://github.com/HKUDS/Vibe-Trading/pull/319)، [#320](https://github.com/HKUDS/Vibe-Trading/pull/320)، شكراً @mvanhorn)، وحصلت أدوات الملفات على read/write roots منفصلة واختبارات sandbox أوسع ([#299](https://github.com/HKUDS/Vibe-Trading/pull/299)، شكراً @skloxo).-- **2026-06-27** 🧯 **مرونة content-filter + تنظيف عقد features في Shadow Account**: أصبحت تشغيلات event-driven وswarm تتجاوز إصابات content-moderation الفردية من LLM، وتعرض تحذيراً في run cards عندما ترتفع معدلات الفلترة، وتتعرف على أسباب Gemini safety finish بدلاً من إيقاف التحليل كاملاً ([#308](https://github.com/HKUDS/Vibe-Trading/pull/308)، يغلق [#307](https://github.com/HKUDS/Vibe-Trading/issues/307)، شكراً @shadowinlife). كما تشترك مراحل استخراج Shadow Account وتوليد الكود في عقد `PRICE_FEATURES` واحد وتحافظ على حدود العوائد بأربع منازل عشرية، ما يمنع drift بين القاعدة والكود وفقدان دقة `prior_5d_return` ([#316](https://github.com/HKUDS/Vibe-Trading/pull/316)، شكراً @Robin1987China).<details><summary>أخبار سابقة</summary>+- **2026-06-27** 🧯 **مرونة content-filter + تنظيف عقد features في Shadow Account**: أصبحت تشغيلات event-driven وswarm تتجاوز إصابات content-moderation الفردية من LLM، وتعرض تحذيراً في run cards عندما ترتفع معدلات الفلترة، وتتعرف على أسباب Gemini safety finish بدلاً من إيقاف التحليل كاملاً ([#308](https://github.com/HKUDS/Vibe-Trading/pull/308)، يغلق [#307](https://github.com/HKUDS/Vibe-Trading/issues/307)، شكراً @shadowinlife). كما تشترك مراحل استخراج Shadow Account وتوليد الكود في عقد `PRICE_FEATURES` واحد وتحافظ على حدود العوائد بأربع منازل عشرية، ما يمنع drift بين القاعدة والكود وفقدان دقة `prior_5d_return` ([#316](https://github.com/HKUDS/Vibe-Trading/pull/316)، شكراً @Robin1987China).- **2026-06-26** 🎯 **دخول مشروط لـ Shadow Account + توجيه tushare لـ ETF/المؤشرات/هونغ كونغ**: أصبحت قواعد Shadow Account المستخرجة تحمل نطاقات RSI / العائد السابق، فيدخل SignalEngine المُولَّد بناءً على شروط حقيقية (RSI ضمن النطاق، والعائد السابق ضمن النطاق) بدلاً من تكرار وتيرة الاحتفاظ بشكل أعمى ([#314](https://github.com/HKUDS/Vibe-Trading/pull/314)، متابعة لـ [#302](https://github.com/HKUDS/Vibe-Trading/pull/302)، شكراً @Robin1987China). كما يوجّه loader الخاص بـ tushare صناديق ETF/LOF إلى `fund_daily()`، والمؤشرات إلى `index_daily()`، وأسهم هونغ كونغ إلى `hk_daily()` بدلاً من استدعاء `daily()` الذي يعيد فراغاً بصمت لغير الأسهم، مع تحذيرات لكل رمز عن النتائج الفارغة والجلب الجزئي ([#315](https://github.com/HKUDS/Vibe-Trading/pull/315)، يغلق [#310](https://github.com/HKUDS/Vibe-Trading/issues/310)، شكراً @shadowinlife).- **2026-06-25** 🧪 **JSON صارم للتحقق + سياق agent أهدأ**: أصبح مسار التحقق المستقل للاختبار الخلفي يطبّع قيم `NaN` / `Infinity` المتداخلة قبل كتابة `artifacts/validation.json` أو stdout في CLI، فلا تتعطل parsers الصارمة أمام payload التحقق ([#306](https://github.com/HKUDS/Vibe-Trading/pull/306)، شكراً @gyx09212214-prog). كما صار prompt الخاص بالـ agent يستنتج عدد مصادر البيانات الحالي من loader registry، ولا تعمل `_microcompact()` إلا عند وجود ضغط tokens حقيقي، فلا تُمسح نتائج الأدوات القديمة مبكرًا في التشغيلات القصيرة ([#296](https://github.com/HKUDS/Vibe-Trading/pull/296)، يغلق [#282](https://github.com/HKUDS/Vibe-Trading/issues/282)، شكراً @MarkfuGod).- **2026-06-24** 🎯 **سياق سعري لـ Shadow Account + واجهة صينية تفاعلية + إصلاح auth على LAN**: أصبح استخراج قواعد Shadow Account يرى سياق الدخول الآمن point-in-time — `entry_rsi14` و`prior_5d_return` عبر loader registry عند `buy_dt` — مع تدهور graceful عند عدم توفر الشبكة أو البيانات ([#302](https://github.com/HKUDS/Vibe-Trading/pull/302)، متابعة لـ [#295](https://github.com/HKUDS/Vibe-Trading/issues/295)، شكراً @Robin1987China). كما انتقلت اللوحات الرئيسية في Web UI إلى ترجمات English / zh-CN تفاعلية عبر charts وchat وAlpha Library وCorrelation وRun Detail ([#301](https://github.com/HKUDS/Vibe-Trading/pull/301)، شكراً @skloxo). وبعد تحصين CSRF، عادت deployments البعيدة same-origin التي تضبط `API_AUTH_KEY` إلى دعم POST / upload، بينما تبقى origins المتقاطعة غير المطابقة محظورة ([#304](https://github.com/HKUDS/Vibe-Trading/pull/304)، شكراً @Hinotoi-agent).@@ -206,6 +208,7 @@ Vibe-Trading مساحة عمل بحثية مفتوحة المصدر تحول ا| **مراجعة صفقاتك الخاصة** | قراءة سجلات الوسطاء، وتشخيص السلوك، واستخراج القواعد، ومقارنات Shadow Account. || **تحسين الأبحاث المتكررة** | الذاكرة الدائمة والمهارات القابلة للتحرير تحول الروتينات المفيدة إلى تدفقات قابلة لإعادة الاستخدام. || **تشغيل فرق محللين** | مراجعات بحث متعددة الوكلاء لتدفقات الاستثمار والكم والكريبتو والماكرو والمخاطر. |+| **وصل الأبحاث بقنوات IM** | إدارة بيئة جلسة واحدة عبر WebSocket وTelegram وSlack وDiscord وMatrix وWhatsApp وSignal وQQ/NapCat وWeChat/WeCom وFeishu/Lark وDingTalk وTeams وemail وMochat من CLI وREST وWeb UI. || **إنتاج مخرجات قابلة للاستخدام** | تقارير، وTradingView Pine Script، وTDX، وMetaTrader 5، وأدوات MCP، وجلسات بحث لاحقة. || **bench ألفا zoo جاهزة** | تشغيل IC + IR + تصنيف alive/reversed/dead عبر 456 ألفا (Qlib 158 + Kakushadze 101 + GTJA 191 + FF5 + Carhart) بسطر أوامر واحد على universe الخاص بك. |@@ -593,6 +596,7 @@ vibe-trading # interactive TUIvibe-trading run -p "..." # single runvibe-trading serve # API servervibe-trading alpha list # استعرض 456 ألفا جاهز؛ متاح show / bench / compare / export-manifest+vibe-trading channels status --local # فحص إعدادات قنوات IM وتلميحات التثبيت```<details>@@ -652,6 +656,24 @@ vibe-trading alpha bench --zoo gtja191 --universe csi300 --period 2018-2025 --to</details>+<details>+<summary><b>قنوات IM</b></summary>++تصل محولات IM تطبيقات الدردشة الخارجية ببيئة الجلسة نفسها التي يستخدمها Web UI وCLI. اضبط المحولات المفعّلة تحت `channels` في `~/.vibe-trading/agent.json`. المحولات المعتمدة على SDK اختيارية عبر extras، وعند غياب SDK تعرض تلميحات استرداد بدلاً من إسقاط runtime.++```bash+vibe-trading channels status --local # فحص config وتلميحات SDK الناقصة دون API+vibe-trading channels status # الاستعلام عن API runtime الجاري+vibe-trading channels start # بدء المحولات المفعّلة عبر API+vibe-trading channels stop # إيقاف المحولات المفعّلة عبر API+vibe-trading channels login weixin # تشغيل hook تسجيل الدخول عند الحاجة+vibe-trading channels pairing --channel telegram list+```++تشمل المحولات المدمجة `websocket` و`telegram` و`slack` و`discord` و`matrix` و`whatsapp` و`signal` و`qq` و`napcat` و`weixin` و`wecom` و`feishu` و`dingtalk` و`msteams` و`email` و`mochat`. يمكنك تثبيت منصة محددة مثل `pip install "vibe-trading-ai[telegram]"` أو تثبيت المجموعة كاملة عبر `pip install "vibe-trading-ai[channels]"`.++</details>+---## 💡 أمثلة@@ -769,6 +791,10 @@ vibe-trading serve --port 8899| `PUT` | `/settings/llm` | تحديث إعدادات LLM المحلية || `GET` | `/settings/data-sources` | قراءة إعدادات مصادر البيانات المحلية || `PUT` | `/settings/data-sources` | تحديث إعدادات مصادر البيانات المحلية |+| `GET` | `/channels/status` | قراءة حالة IM channel runtime والمحولات |+| `POST` | `/channels/start` | بدء محولات IM configured |+| `POST` | `/channels/stop` | إيقاف محولات IM configured |+| `POST` | `/channels/pairing/command` | تنفيذ أمر sender-pairing على shared store || `POST` | `/scheduled-runs` | إنشاء مهمة بحث مجدولة (interval-ms أو cron) || `GET` | `/scheduled-runs` | سرد المهام المجدولة || `DELETE` | `/scheduled-runs/{job_id}` | إلغاء مهمة مجدولة |@@ -787,6 +813,8 @@ vibe-trading serve --port 8899قراءات Settings بلا آثار جانبية: لا تنشئ `GET /settings/llm` ولا `GET /settings/data-sources` ملف `agent/.env`، ولا تعيدان إلا مسارات نسبية للمشروع. قد تكشف قراءات وكتابات Settings حالة بيانات الاعتماد أو تحدث بيانات الاعتماد/بيئة التشغيل، لذلك تتطلب `API_AUTH_KEY` عند ضبطه. إذا كان `API_AUTH_KEY` غير مضبوط في وضع التطوير، فلا يقبل الوصول إلى Settings إلا من عملاء loopback.+تحتوي صفحة Settings نفسها على لوحة **قنوات IM** للمشغل المحلي. تستطلع `/channels/status`، وتعرض حالات configured/enabled/available/loaded/running وتلميحات استرداد المحولات، ويمكنها بدء أو إيقاف channel runtime configured دون العودة إلى الطرفية.+### البحث المجدول (Scheduled research)شغّل prompt بحثي أو backtest وفق جدول متكرر. المنفّذ الخلفي **معطّل افتراضياً** — شغّل الخادم بـ `VIBE_TRADING_ENABLE_SCHEDULER=1` لتفعيله:@@ -1022,7 +1050,7 @@ Vibe-Trading جزء من نظام وكلاء **[HKUDS](https://github.com/HKUDS)| **Options Lab** | سطح تقلب، ولوحة Greeks، ومستكشف payoff/scenario | مخطط || **Portfolio Studio** | أشعة مخاطر، وقيود، ومحسن يراعي الدوران، وملاحظات إعادة توازن | مخطط || **Alpha Zoo** | 452 ألفا كمّي جاهز عبر 4 zoos (Qlib 158 + Kakushadze 101 + GTJA 191 + FF5 + Carhart)، سطر أوامر واحد للـ bench، تكامل agent، وواجهة Web | **تم الإطلاق 0.1.8** |-| **Research Delivery** | موجزات مجدولة إلى Slack / Telegram / قنوات شبيهة بالبريد | المُجدوِل شُحن |+| **Research Delivery** | موجزات مجدولة وجلسات بحث حي عبر Slack / Telegram / قنوات IM شبيهة بالبريد | المُجدوِل + IM Runtime شُحنا || **Community** | مهارات وإعدادات مسبقة وبطاقات استراتيجية قابلة للمشاركة | قيد الاستكشاف |---diff --git a/README_ja.md b/README_ja.mdindex 86c6f26cb..329045816 100644--- a/README_ja.md+++ b/README_ja.md@@ -50,13 +50,15 @@## 📰 ニュース+- **2026-06-30** 💬 **研究配信用の IM チャンネルランタイム**:Vibe-Trading は同じ agent session runtime を 16 の組み込み message adapter に接続できるようになりました——WebSocket、Telegram、Slack、Discord、Matrix、WhatsApp、Signal、QQ/NapCat、WeChat/WeCom、Feishu/Lark、DingTalk、Teams、email、Mochat。CLI(`vibe-trading channels status/start/stop/login/pairing`)、REST(`/channels/status`、`/channels/start`、`/channels/stop`、`/channels/pairing/command`)、Web UI Settings panel が status、recovery hints、start/stop、sender pairing を扱い、SDK-backed adapters は `vibe-trading-ai[telegram]` や `vibe-trading-ai[channels]` などの extras の背後に残ります([#341](https://github.com/HKUDS/Vibe-Trading/pull/341))。+- **2026-06-29** 🛡️ **Live advisory safety + Trading 212 read-only connector + Windows/Gemini fixes**: live order guards now have an opt-in, broker-agnostic `PreTradeAdvisoryInterface` that records advisory reviews without bypassing the mandate gate, kill switch, or audit trail ([#328](https://github.com/HKUDS/Vibe-Trading/pull/328), closes [#317](https://github.com/HKUDS/Vibe-Trading/issues/317), thanks @shadowinlife). Trading 212 joins the connector layer with read-only account, positions, orders, history, and instrument-metadata support; `place_order` / `cancel_order` still hard-refuse until a structural paper/live boundary exists ([#321](https://github.com/HKUDS/Vibe-Trading/pull/321), closes [#309](https://github.com/HKUDS/Vibe-Trading/issues/309), thanks @mvanhorn). Windows startup avoids the pandas 3.0 `Timestamp` crash via the `<3.0.0` constraint ([#329](https://github.com/HKUDS/Vibe-Trading/pull/329), closes [#324](https://github.com/HKUDS/Vibe-Trading/issues/324), thanks @hannibal-lee); Gemini `thought_signature` dict-history replay was verified/fixed on `main` ([#318](https://github.com/HKUDS/Vibe-Trading/issues/318)); `.US` financial statements now route to SEC EDGAR instead of Eastmoney ([#325](https://github.com/HKUDS/Vibe-Trading/issues/325)); and the Alpha Library landing page got cache/date/selector/noscript/DNS-prefetch hardening while heavier CSP and social-card follow-ups stay tracked ([#323](https://github.com/HKUDS/Vibe-Trading/issues/323)).- **2026-06-28** 🧰 **クロスプラットフォーム setup/dev + runtime と file tool の強化**:`vibe-trading setup` と `vibe-trading dev` は、Windows の TypeScript build、正しい cwd からの backend 起動、Vite の 5899 port、終了時の子プロセス cleanup を正しく扱うようになりました([#292](https://github.com/HKUDS/Vibe-Trading/pull/292)、@digger-yu さんに感謝)。Runtime status polling はクラッシュせず graceful に degrade し([#322](https://github.com/HKUDS/Vibe-Trading/issues/322))、MCP OAuth cache key は sanitize され([#313](https://github.com/HKUDS/Vibe-Trading/issues/313))、OpenAI default と Robinhood `agent.json` validation も強化されました([#319](https://github.com/HKUDS/Vibe-Trading/pull/319)、[#320](https://github.com/HKUDS/Vibe-Trading/pull/320)、@mvanhorn さんに感謝)。File tools には独立した read/write roots と sandbox tests の拡充も入りました([#299](https://github.com/HKUDS/Vibe-Trading/pull/299)、@skloxo さんに感謝)。-- **2026-06-27** 🧯 **Content-filter resilience + Shadow Account feature contract cleanup**:event-driven / swarm run は、個別の LLM content-moderation hit をスキップし、filter rate が高い場合は run card で警告し、Gemini safety finish reason を認識して analysis 全体を abort しないようになりました([#308](https://github.com/HKUDS/Vibe-Trading/pull/308)、[#307](https://github.com/HKUDS/Vibe-Trading/issues/307) をクローズ、@shadowinlife さんに感謝)。Shadow Account の extraction/codegen は同じ `PRICE_FEATURES` contract を共有し、4 桁小数の return bounds を保つことで、rule/codegen drift と `prior_5d_return` の精度落ちを防ぎます([#316](https://github.com/HKUDS/Vibe-Trading/pull/316)、@Robin1987China さんに感謝)。<details><summary>過去のニュース</summary>+- **2026-06-27** 🧯 **Content-filter resilience + Shadow Account feature contract cleanup**:event-driven / swarm run は、個別の LLM content-moderation hit をスキップし、filter rate が高い場合は run card で警告し、Gemini safety finish reason を認識して analysis 全体を abort しないようになりました([#308](https://github.com/HKUDS/Vibe-Trading/pull/308)、[#307](https://github.com/HKUDS/Vibe-Trading/issues/307) をクローズ、@shadowinlife さんに感謝)。Shadow Account の extraction/codegen は同じ `PRICE_FEATURES` contract を共有し、4 桁小数の return bounds を保つことで、rule/codegen drift と `prior_5d_return` の精度落ちを防ぎます([#316](https://github.com/HKUDS/Vibe-Trading/pull/316)、@Robin1987China さんに感謝)。- **2026-06-26** 🎯 **Shadow Account の条件付きエントリー + tushare ETF/指数/HK ルーティング**:抽出された Shadow Account ルールが RSI / prior-return のレンジを持つようになり、生成される SignalEngine は保有サイクルを盲目的に再生せず、実際の条件(RSI がレンジ内、prior-return がレンジ内)でエントリーします([#314](https://github.com/HKUDS/Vibe-Trading/pull/314)、[#302](https://github.com/HKUDS/Vibe-Trading/pull/302) の follow-up、@Robin1987China さんに感謝)。tushare loader も ETF/LOF を `fund_daily()`、指数を `index_daily()`、香港株を `hk_daily()` にルーティングし、非株式に対して静かに空を返す `daily()` を常に呼ぶのをやめ、銘柄ごとの空結果 + 部分取得の警告を追加しました([#315](https://github.com/HKUDS/Vibe-Trading/pull/315)、[#310](https://github.com/HKUDS/Vibe-Trading/issues/310) をクローズ、@shadowinlife さんに感謝)。- **2026-06-25** 🧪 **strict validation JSON + 落ち着いた agent context**:単独のバックテスト validation は、`artifacts/validation.json` や CLI stdout に書き出す前に入れ子の `NaN` / `Infinity` を正規化するようになり、strict JSON parser が validation payload で詰まらなくなりました([#306](https://github.com/HKUDS/Vibe-Trading/pull/306)、@gyx09212214-prog さんに感謝)。Agent prompt も loader registry から現在の data-source 数を動的に導出し、`_microcompact()` は本当に token pressure がある時だけ動くため、短い実行で古い tool result が早すぎるタイミングで消されません([#296](https://github.com/HKUDS/Vibe-Trading/pull/296)、[#282](https://github.com/HKUDS/Vibe-Trading/issues/282) をクローズ、@MarkfuGod さんに感謝)。- **2026-06-24** 🎯 **Shadow Account の価格コンテキスト + reactive Chinese UI + LAN auth 修正**:Shadow Account のルール抽出は、`buy_dt` 時点の point-in-time-safe な entry context(`entry_rsi14` と `prior_5d_return`)を loader registry 経由で読めるようになり、offline / no-data では従来どおり graceful に落ちます([#302](https://github.com/HKUDS/Vibe-Trading/pull/302)、[#295](https://github.com/HKUDS/Vibe-Trading/issues/295) の follow-up、@Robin1987China さんに感謝)。Web UI の主要パネルは charts、chat、Alpha Library、Correlation、Run Detail まで reactive English / zh-CN translation に寄せました([#301](https://github.com/HKUDS/Vibe-Trading/pull/301)、@skloxo さんに感謝)。CSRF hardening 後も、`API_AUTH_KEY` を設定した remote same-origin Web UI deployment は POST / upload が通る一方、mismatch した cross-site origin は引き続き拒否されます([#304](https://github.com/HKUDS/Vibe-Trading/pull/304)、@Hinotoi-agent さんに感謝)。@@ -206,6 +208,7 @@ Vibe-Trading は、金融に関する問いを実行可能な分析へ変換す| **自分の取引をレビューする** | ブローカー取引日誌の解析、行動診断、ルール抽出、Shadow Account 比較。 || **反復リサーチを改善する** | 永続メモリと編集可能な skills により、有用な手順を再利用可能なワークフローへ変換。 || **アナリストチームを走らせる** | 投資、クオンツ、暗号資産、マクロ、リスクのワークフロー向けマルチエージェント・リサーチレビュー。 |+| **リサーチを IM チャンネルへ接続する** | WebSocket、Telegram、Slack、Discord、Matrix、WhatsApp、Signal、QQ/NapCat、WeChat/WeCom、Feishu/Lark、DingTalk、Teams、email、Mochat から同じ session runtime を CLI、REST、Web UI で管理。 || **使える artifacts を出力する** | レポート、TradingView Pine Script、TDX、MetaTrader 5、MCP tools、後続リサーチセッション。 || **事前構築 alpha zoo をベンチ** | 456 個の alpha 因子(Qlib 158 + Kakushadze 101 + GTJA 191 + FF5 + Carhart)に対し、1 行 CLI で IC + IR + alive/reversed/dead 分類を実行 |@@ -593,6 +596,7 @@ vibe-trading # interactive TUIvibe-trading run -p "..." # single runvibe-trading serve # API servervibe-trading alpha list # 456 個の事前構築 alpha を閲覧;show / bench / compare / export-manifest サブコマンド利用可+vibe-trading channels status --local # IM チャンネル設定と install hints を確認```<details>@@ -649,6 +653,24 @@ vibe-trading alpha bench --zoo gtja191 --universe csi300 --period 2018-2025 --to</details>+<details>+<summary><b>IM チャンネル</b></summary>++IM channel adapters は外部チャットアプリを Web UI / CLI と同じ session runtime へ接続します。有効化する adapter は `~/.vibe-trading/agent.json` の `channels` 配下に設定します。SDK-backed adapters は optional extras で、SDK が足りない場合も runtime を落とさず recovery hints を返します。++```bash+vibe-trading channels status --local # API なしで config と missing SDK hints を確認+vibe-trading channels status # 稼働中の API runtime を問い合わせ+vibe-trading channels start # API 経由で enabled adapters を開始+vibe-trading channels stop # API 経由で enabled adapters を停止+vibe-trading channels login weixin # 必要な adapter login hook を実行+vibe-trading channels pairing --channel telegram list+```++Built-in adapters は `websocket`、`telegram`、`slack`、`discord`、`matrix`、`whatsapp`、`signal`、`qq`、`napcat`、`weixin`、`wecom`、`feishu`、`dingtalk`、`msteams`、`email`、`mochat` です。個別に `pip install "vibe-trading-ai[telegram]"` を使うか、全チャンネル分を `pip install "vibe-trading-ai[channels]"` で入れられます。++</details>+---## 💡 例@@ -766,6 +788,10 @@ vibe-trading serve --port 8899| `PUT` | `/settings/llm` | local LLM settings を更新 || `GET` | `/settings/data-sources` | local data source settings を読み取り || `PUT` | `/settings/data-sources` | local data source settings を更新 |+| `GET` | `/channels/status` | IM channel runtime と adapter status を読み取り |+| `POST` | `/channels/start` | 設定済み IM channel adapters を開始 |+| `POST` | `/channels/stop` | 設定済み IM channel adapters を停止 |+| `POST` | `/channels/pairing/command` | shared store に対して sender-pairing command を実行 || `POST` | `/scheduled-runs` | 定期リサーチジョブを作成(interval-ms または cron) || `GET` | `/scheduled-runs` | スケジュール済みジョブを一覧 || `DELETE` | `/scheduled-runs/{job_id}` | スケジュール済みジョブをキャンセル |@@ -784,6 +810,8 @@ Web UI Settings page では、local users が LLM provider/model、base URL、geSettings reads は side-effect free です。`GET /settings/llm` と `GET /settings/data-sources` は `agent/.env` を作成せず、project-relative paths だけを返します。Settings の読み書きは credential state の公開や credentials/runtime environment の更新を伴うため、設定済みの場合は `API_AUTH_KEY` が必要です。dev mode で `API_AUTH_KEY` が未設定の場合、settings access は loopback clients からのみ受け付けます。+同じ Settings page には local operator 向けの **IM チャンネル**パネルもあります。`/channels/status` を polling し、configured/enabled/available/loaded/running 状態、adapter recovery hints、runtime の start/stop 操作を terminal に戻らず扱えます。+### Scheduled research(定期リサーチ)リサーチ prompt や backtest を繰り返しスケジュールで実行します。バックグラウンド executor は**既定でオフ**です。`VIBE_TRADING_ENABLE_SCHEDULER=1` を付けて server を起動すると有効になります:@@ -1019,7 +1047,7 @@ Vibe-Trading は **[HKUDS](https://github.com/HKUDS)** agent ecosystem の一部| **Options Lab** | Vol surface, Greeks dashboard, payoff/scenario explorer | Planned || **Portfolio Studio** | Risk x-ray, constraints, turnover-aware optimizer, rebalance notes | Planned || **Alpha Zoo** | 452 個の事前構築 alpha 因子(Qlib 158 + Kakushadze 101 + GTJA 191 + FF5 + Carhart)、1 行 CLI でベンチ、agent 統合、Web UI | **0.1.8 でリリース済み** |-| **Research Delivery** | Scheduled briefs to Slack / Telegram / email-style channels | スケジューラ出荷済み |+| **Research Delivery** | Slack / Telegram / email-style IM channels 経由の scheduled briefs と live research sessions | スケジューラ + IM Runtime 出荷済み || **Community** | Shareable skills, presets, and strategy cards | Exploring |---diff --git a/README_ko.md b/README_ko.mdindex 671f91e7d..1c931d1eb 100644--- a/README_ko.md+++ b/README_ko.md@@ -50,13 +50,15 @@## 📰 뉴스+- **2026-06-30** 💬 **리서치 전달을 위한 IM 채널 런타임**: Vibe-Trading은 이제 같은 agent session runtime을 16개 내장 메시지 어댑터에 연결할 수 있습니다 — WebSocket, Telegram, Slack, Discord, Matrix, WhatsApp, Signal, QQ/NapCat, WeChat/WeCom, Feishu/Lark, DingTalk, Teams, email, Mochat. CLI(`vibe-trading channels status/start/stop/login/pairing`), REST(`/channels/status`, `/channels/start`, `/channels/stop`, `/channels/pairing/command`), Web UI Settings 패널이 상태, 복구 힌트, 시작/중지, sender pairing을 제공하며, SDK 기반 어댑터는 `vibe-trading-ai[telegram]` 또는 `vibe-trading-ai[channels]` 같은 extras 뒤에 둡니다([#341](https://github.com/HKUDS/Vibe-Trading/pull/341)).+- **2026-06-29** 🛡️ **Live advisory safety + Trading 212 read-only connector + Windows/Gemini fixes**: live order guards now have an opt-in, broker-agnostic `PreTradeAdvisoryInterface` that records advisory reviews without bypassing the mandate gate, kill switch, or audit trail ([#328](https://github.com/HKUDS/Vibe-Trading/pull/328), closes [#317](https://github.com/HKUDS/Vibe-Trading/issues/317), thanks @shadowinlife). Trading 212 joins the connector layer with read-only account, positions, orders, history, and instrument-metadata support; `place_order` / `cancel_order` still hard-refuse until a structural paper/live boundary exists ([#321](https://github.com/HKUDS/Vibe-Trading/pull/321), closes [#309](https://github.com/HKUDS/Vibe-Trading/issues/309), thanks @mvanhorn). Windows startup avoids the pandas 3.0 `Timestamp` crash via the `<3.0.0` constraint ([#329](https://github.com/HKUDS/Vibe-Trading/pull/329), closes [#324](https://github.com/HKUDS/Vibe-Trading/issues/324), thanks @hannibal-lee); Gemini `thought_signature` dict-history replay was verified/fixed on `main` ([#318](https://github.com/HKUDS/Vibe-Trading/issues/318)); `.US` financial statements now route to SEC EDGAR instead of Eastmoney ([#325](https://github.com/HKUDS/Vibe-Trading/issues/325)); and the Alpha Library landing page got cache/date/selector/noscript/DNS-prefetch hardening while heavier CSP and social-card follow-ups stay tracked ([#323](https://github.com/HKUDS/Vibe-Trading/issues/323)).- **2026-06-28** 🧰 **크로스 플랫폼 setup/dev + 런타임 및 파일 도구 강화**: `vibe-trading setup` 과 `vibe-trading dev` 가 Windows TypeScript build, 올바른 cwd 에서의 backend 실행, Vite 5899 포트, 종료 시 child process 정리를 제대로 처리합니다([#292](https://github.com/HKUDS/Vibe-Trading/pull/292), @digger-yu 님 감사합니다). Runtime status polling 은 이제 crash 대신 graceful 하게 degrade 하고([#322](https://github.com/HKUDS/Vibe-Trading/issues/322)), MCP OAuth cache key 는 sanitize 되며([#313](https://github.com/HKUDS/Vibe-Trading/issues/313)), OpenAI default 와 Robinhood `agent.json` validation 도 더 엄격해졌습니다([#319](https://github.com/HKUDS/Vibe-Trading/pull/319), [#320](https://github.com/HKUDS/Vibe-Trading/pull/320), @mvanhorn 님 감사합니다). File tools 는 독립 read/write roots 와 확장된 sandbox tests 를 갖췄습니다([#299](https://github.com/HKUDS/Vibe-Trading/pull/299), @skloxo 님 감사합니다).-- **2026-06-27** 🧯 **콘텐츠 필터 복원력 + Shadow Account feature contract 정리**: event-driven / swarm 실행은 이제 개별 LLM content-moderation hit 를 건너뛰고, filter rate 가 높으면 run card 에 경고하며, Gemini safety finish reason 을 인식해 전체 analysis 를 abort 하지 않습니다([#308](https://github.com/HKUDS/Vibe-Trading/pull/308), [#307](https://github.com/HKUDS/Vibe-Trading/issues/307) 종료, @shadowinlife 님 감사합니다). Shadow Account extraction/codegen 은 하나의 `PRICE_FEATURES` contract 를 공유하고 네 자리 소수 return bounds 를 유지해 rule/codegen drift 와 `prior_5d_return` 정밀도 손실을 막습니다([#316](https://github.com/HKUDS/Vibe-Trading/pull/316), @Robin1987China 님 감사합니다).<details><summary>이전 뉴스</summary>+- **2026-06-27** 🧯 **콘텐츠 필터 복원력 + Shadow Account feature contract 정리**: event-driven / swarm 실행은 이제 개별 LLM content-moderation hit 를 건너뛰고, filter rate 가 높으면 run card 에 경고하며, Gemini safety finish reason 을 인식해 전체 analysis 를 abort 하지 않습니다([#308](https://github.com/HKUDS/Vibe-Trading/pull/308), [#307](https://github.com/HKUDS/Vibe-Trading/issues/307) 종료, @shadowinlife 님 감사합니다). Shadow Account extraction/codegen 은 하나의 `PRICE_FEATURES` contract 를 공유하고 네 자리 소수 return bounds 를 유지해 rule/codegen drift 와 `prior_5d_return` 정밀도 손실을 막습니다([#316](https://github.com/HKUDS/Vibe-Trading/pull/316), @Robin1987China 님 감사합니다).- **2026-06-26** 🎯 **Shadow Account 조건부 진입 + tushare ETF/지수/HK 라우팅**: 추출된 Shadow Account 규칙이 이제 RSI / prior-return 범위를 담아, 생성된 SignalEngine 이 보유 주기를 맹목적으로 반복하지 않고 실제 조건(RSI 가 범위 내, prior-return 이 범위 내)에서 진입합니다([#314](https://github.com/HKUDS/Vibe-Trading/pull/314), [#302](https://github.com/HKUDS/Vibe-Trading/pull/302) follow-up, @Robin1987China 님 감사합니다). tushare loader 도 ETF/LOF 를 `fund_daily()`, 지수를 `index_daily()`, 홍콩 주식을 `hk_daily()` 로 라우팅하며, 비주식에 대해 조용히 빈 값을 반환하는 `daily()` 를 항상 호출하던 동작을 멈추고, 심볼별 빈 결과 + 부분 수집 경고를 추가했습니다([#315](https://github.com/HKUDS/Vibe-Trading/pull/315), [#310](https://github.com/HKUDS/Vibe-Trading/issues/310) 종료, @shadowinlife 님 감사합니다).- **2026-06-25** 🧪 **엄격한 validation JSON + 더 안정적인 agent context**: 독립 backtest validation 이 `artifacts/validation.json` 또는 CLI stdout 을 쓰기 전에 중첩된 `NaN` / `Infinity` 값을 정규화해, strict JSON parser 가 validation payload 에서 막히지 않습니다([#306](https://github.com/HKUDS/Vibe-Trading/pull/306), @gyx09212214-prog 님 감사합니다). Agent prompt 도 loader registry 에서 현재 data-source 수를 동적으로 계산하고, `_microcompact()` 는 실제 token pressure 가 있을 때만 실행되어 짧은 실행에서 오래된 tool result 를 너무 일찍 비우지 않습니다([#296](https://github.com/HKUDS/Vibe-Trading/pull/296), [#282](https://github.com/HKUDS/Vibe-Trading/issues/282) 종료, @MarkfuGod 님 감사합니다).- **2026-06-24** 🎯 **Shadow Account 가격 context + 반응형 중국어 UI + LAN auth 수정**: Shadow Account 규칙 추출은 이제 `buy_dt` 기준 point-in-time-safe entry context 인 `entry_rsi14` 와 `prior_5d_return` 을 loader registry 로 가져오며, offline / no-data 상황에서는 기존처럼 graceful 하게 feature 를 제외합니다([#302](https://github.com/HKUDS/Vibe-Trading/pull/302), [#295](https://github.com/HKUDS/Vibe-Trading/issues/295) follow-up, @Robin1987China 님 감사합니다). 주요 Web UI 패널은 charts, chat, Alpha Library, Correlation, Run Detail 까지 반응형 English / zh-CN translation 을 사용합니다([#301](https://github.com/HKUDS/Vibe-Trading/pull/301), @skloxo 님 감사합니다). CSRF hardening 이후에도 `API_AUTH_KEY` 가 설정된 remote same-origin Web UI deployment 는 POST / upload 가 다시 통과하고, mismatch 된 cross-site origin 은 계속 차단됩니다([#304](https://github.com/HKUDS/Vibe-Trading/pull/304), @Hinotoi-agent 님 감사합니다).@@ -206,6 +208,7 @@ Vibe-Trading은 금융 질문을 실행 가능한 분석으로 바꾸는 오픈| **내 거래 검토하기** | 브로커 일지 파싱, 행동 진단, 규칙 추출, Shadow Account 비교. || **반복 리서치 개선하기** | 영구 메모리와 편집 가능한 스킬로 유용한 루틴을 재사용 가능한 워크플로로 전환. || **애널리스트 팀 실행하기** | 투자, 퀀트, 크립토, 매크로, 리스크 워크플로를 위한 멀티 에이전트 리서치 리뷰. |+| **리서치를 IM 채널에 연결하기** | WebSocket, Telegram, Slack, Discord, Matrix, WhatsApp, Signal, QQ/NapCat, WeChat/WeCom, Feishu/Lark, DingTalk, Teams, email, Mochat에서 같은 session runtime을 CLI, REST, Web UI로 관리. || **사용 가능한 artifacts 만들기** | 리포트, TradingView Pine Script, TDX, MetaTrader 5, MCP tools, 이후 리서치 세션. || **사전 빌드된 alpha zoo 벤치** | 456개의 alpha 인자(Qlib 158 + Kakushadze 101 + GTJA 191 + FF5 + Carhart)에 대해 한 줄 CLI로 IC + IR + alive/reversed/dead 분류 수행 |@@ -593,6 +596,7 @@ vibe-trading # interactive TUIvibe-trading run -p "..." # single runvibe-trading serve # API servervibe-trading alpha list # 사전 빌드된 456개 alpha 탐색; show / bench / compare / export-manifest 서브커맨드 사용 가능+vibe-trading channels status --local # IM 채널 설정과 설치 힌트 확인```<details>@@ -652,6 +656,24 @@ vibe-trading alpha bench --zoo gtja191 --universe csi300 --period 2018-2025 --to</details>+<details>+<summary><b>IM 채널</b></summary>++IM channel adapter는 외부 채팅 앱을 Web UI와 CLI가 쓰는 같은 session runtime에 연결합니다. 활성화할 어댑터는 `~/.vibe-trading/agent.json`의 `channels` 아래에 설정합니다. SDK 기반 어댑터는 optional extras이며, SDK가 없으면 런타임을 중단하지 않고 recovery hints를 표시합니다.++```bash+vibe-trading channels status --local # API 없이 config와 missing SDK hints 확인+vibe-trading channels status # 실행 중인 API runtime 조회+vibe-trading channels start # API를 통해 enabled adapters 시작+vibe-trading channels stop # API를 통해 enabled adapters 중지+vibe-trading channels login weixin # 필요한 adapter login hook 실행+vibe-trading channels pairing --channel telegram list+```++Built-in adapters는 `websocket`, `telegram`, `slack`, `discord`, `matrix`, `whatsapp`, `signal`, `qq`, `napcat`, `weixin`, `wecom`, `feishu`, `dingtalk`, `msteams`, `email`, `mochat`입니다. 개별 플랫폼은 `pip install "vibe-trading-ai[telegram]"`처럼 설치하거나, 전체 채널 세트는 `pip install "vibe-trading-ai[channels]"`로 설치할 수 있습니다.++</details>+---## 💡 예제@@ -769,6 +791,10 @@ vibe-trading serve --port 8899| `PUT` | `/settings/llm` | local LLM settings 업데이트 || `GET` | `/settings/data-sources` | local data source settings 읽기 || `PUT` | `/settings/data-sources` | local data source settings 업데이트 |+| `GET` | `/channels/status` | IM channel runtime과 adapter status 읽기 |+| `POST` | `/channels/start` | 설정된 IM channel adapters 시작 |+| `POST` | `/channels/stop` | 설정된 IM channel adapters 중지 |+| `POST` | `/channels/pairing/command` | shared store에 sender-pairing command 실행 || `POST` | `/scheduled-runs` | 예약 리서치 작업 생성 (interval-ms 또는 cron) || `GET` | `/scheduled-runs` | 예약된 작업 목록 || `DELETE` | `/scheduled-runs/{job_id}` | 예약 작업 취소 |@@ -787,6 +813,8 @@ Web UI Settings page에서는 local user가 LLM provider/model, base URL, generaSettings read는 side effect가 없습니다. `GET /settings/llm`과 `GET /settings/data-sources`는 `agent/.env`를 만들지 않으며 project-relative path만 반환합니다. Settings read/write는 credential state를 노출하거나 credential/runtime environment를 업데이트할 수 있으므로 `API_AUTH_KEY`가 설정되어 있으면 인증이 필요합니다. dev mode에서 `API_AUTH_KEY`가 설정되지 않은 경우 settings access는 loopback client에서만 허용됩니다.+같은 Settings page에는 local operator용 **IM 채널** 패널도 있습니다. `/channels/status`를 polling하고 configured/enabled/available/loaded/running 상태와 adapter recovery hints를 표시하며, 터미널로 돌아가지 않고 configured channel runtime을 시작하거나 중지할 수 있습니다.+### Scheduled research (예약 리서치)리서치 prompt나 backtest를 반복 일정으로 실행합니다. 백그라운드 executor는 **기본적으로 꺼져 있습니다** — `VIBE_TRADING_ENABLE_SCHEDULER=1`로 server를 시작하면 활성화됩니다:@@ -1022,7 +1050,7 @@ Vibe-Trading은 **[HKUDS](https://github.com/HKUDS)** agent ecosystem의 일부| **Options Lab** | Vol surface, Greeks dashboard, payoff/scenario explorer | Planned || **Portfolio Studio** | Risk x-ray, constraints, turnover-aware optimizer, rebalance notes | Planned || **Alpha Zoo** | 4개 zoo에 걸친 452개의 사전 빌드된 alpha 인자(Qlib 158 + Kakushadze 101 + GTJA 191 + FF5 + Carhart), 한 줄 CLI 벤치, agent 통합, Web UI | **0.1.8 출시 완료** |-| **Research Delivery** | Slack / Telegram / email-style channels로 예약 brief 전달 | 스케줄러 출시 |+| **Research Delivery** | Slack / Telegram / email-style IM channels를 통한 예약 brief와 live research sessions | 스케줄러 + IM Runtime 출시 || **Community** | 공유 가능한 skills, presets, strategy cards | Exploring |---diff --git a/README_zh.md b/README_zh.mdindex 2701eb10a..b7624ec44 100644--- a/README_zh.md+++ b/README_zh.md@@ -50,13 +50,15 @@## 📰 News+- **2026-06-30** 💬 **IM 通道运行时接入研究交付**:Vibe-Trading 现在可把同一套 agent session runtime 接到 16 个内置消息适配器:WebSocket、Telegram、Slack、Discord、Matrix、WhatsApp、Signal、QQ/NapCat、微信/企业微信、飞书/Lark、钉钉、Teams、email、Mochat。CLI(`vibe-trading channels status/start/stop/login/pairing`)、REST(`/channels/status`、`/channels/start`、`/channels/stop`、`/channels/pairing/command`)和 Web UI Settings 面板已覆盖状态、恢复提示、启停与 sender pairing;SDK 型适配器继续通过 `vibe-trading-ai[telegram]` 或 `vibe-trading-ai[channels]` 等 extras 按需安装([#341](https://github.com/HKUDS/Vibe-Trading/pull/341))。+- **2026-06-29** 🛡️ **实盘交易安全顾问 + Trading 212 只读连接器 + Windows/Gemini 修复**:实盘下单守卫现在提供可选的、券商无关的 `PreTradeAdvisoryInterface`,在记录顾问审查的同时不绕过 mandate gate、kill switch 或审计追踪([#328](https://github.com/HKUDS/Vibe-Trading/pull/328),关闭 [#317](https://github.com/HKUDS/Vibe-Trading/issues/317),感谢 @shadowinlife)。Trading 212 加入连接器层,支持只读账户、持仓、订单、历史和合约元数据;`place_order` / `cancel_order` 在有结构性 paper/live 边界之前仍硬拒绝([#321](https://github.com/HKUDS/Vibe-Trading/pull/321),关闭 [#309](https://github.com/HKUDS/Vibe-Trading/issues/309),感谢 @mvanhorn)。Windows 启动通过 `<3.0.0` 约束避免 pandas 3.0 `Timestamp` 崩溃([#329](https://github.com/HKUDS/Vibe-Trading/pull/329),关闭 [#324](https://github.com/HKUDS/Vibe-Trading/issues/324),感谢 @hannibal-lee);Gemini `thought_signature` dict-history 重放已在 `main` 验证修复([#318](https://github.com/HKUDS/Vibe-Trading/issues/318));`.US` 财务报表现在路由到 SEC EDGAR 而非东方财富([#325](https://github.com/HKUDS/Vibe-Trading/issues/325));Alpha Library 着陆页获得 cache/date/selector/noscript/DNS-prefetch 加固,更重的 CSP 和社交卡片跟进工作仍在追踪中([#323](https://github.com/HKUDS/Vibe-Trading/issues/323))。- **2026-06-28** 🧰 **跨平台 setup/dev + 运行态与文件工具加固**:`vibe-trading setup` 和 `vibe-trading dev` 现在能正确处理 Windows TypeScript 构建、从正确 cwd 启动后端、使用 Vite 的 5899 端口,并在退出时干净关闭子进程([#292](https://github.com/HKUDS/Vibe-Trading/pull/292),感谢 @digger-yu)。Runtime 状态轮询现在会优雅降级而不是崩溃([#322](https://github.com/HKUDS/Vibe-Trading/issues/322));MCP OAuth cache key 已做脱敏规范化([#313](https://github.com/HKUDS/Vibe-Trading/issues/313));OpenAI 默认模型与 Robinhood `agent.json` 校验进一步收紧([#319](https://github.com/HKUDS/Vibe-Trading/pull/319)、[#320](https://github.com/HKUDS/Vibe-Trading/pull/320),感谢 @mvanhorn);文件工具也补上了独立读/写 roots 与更完整的 sandbox 测试([#299](https://github.com/HKUDS/Vibe-Trading/pull/299),感谢 @skloxo)。-- **2026-06-27** 🧯 **内容过滤韧性 + Shadow Account 特征契约清理**:事件驱动与 swarm 运行现在会跳过单个 LLM 内容审核命中,在 run card 中提示较高过滤率,并识别 Gemini safety finish reason,而不是让整次分析直接失败([#308](https://github.com/HKUDS/Vibe-Trading/pull/308),关闭 [#307](https://github.com/HKUDS/Vibe-Trading/issues/307),感谢 @shadowinlife)。Shadow Account 抽取与代码生成现在共用同一个 `PRICE_FEATURES` 契约,并保留四位小数的收益边界,避免规则/codegen 漂移以及 `prior_5d_return` 精度损失([#316](https://github.com/HKUDS/Vibe-Trading/pull/316),感谢 @Robin1987China)。<details><summary>更早的更新</summary>+- **2026-06-27** 🧯 **内容过滤韧性 + Shadow Account 特征契约清理**:事件驱动与 swarm 运行现在会跳过单个 LLM 内容审核命中,在 run card 中提示较高过滤率,并识别 Gemini safety finish reason,而不是让整次分析直接失败([#308](https://github.com/HKUDS/Vibe-Trading/pull/308),关闭 [#307](https://github.com/HKUDS/Vibe-Trading/issues/307),感谢 @shadowinlife)。Shadow Account 抽取与代码生成现在共用同一个 `PRICE_FEATURES` 契约,并保留四位小数的收益边界,避免规则/codegen 漂移以及 `prior_5d_return` 精度损失([#316](https://github.com/HKUDS/Vibe-Trading/pull/316),感谢 @Robin1987China)。- **2026-06-26** 🎯 **Shadow Account 条件入场 + tushare ETF/指数/港股路由**:抽取出的 Shadow Account 规则现在会带上 RSI / 前期收益的区间,生成的 SignalEngine 据此按真实条件入场(RSI 落在区间内、前期收益落在区间内),不再盲目复现持仓节奏([#314](https://github.com/HKUDS/Vibe-Trading/pull/314),承接 [#302](https://github.com/HKUDS/Vibe-Trading/pull/302),感谢 @Robin1987China)。tushare loader 也会把 ETF/LOF 路由到 `fund_daily()`、指数到 `index_daily()`、港股到 `hk_daily()`,不再一律调用对非股票静默返回空的 `daily()`,并加上每只标的的空结果与部分缺失告警([#315](https://github.com/HKUDS/Vibe-Trading/pull/315),关闭 [#310](https://github.com/HKUDS/Vibe-Trading/issues/310),感谢 @shadowinlife)。- **2026-06-25** 🧪 **严格 validation JSON + 更稳的 agent 上下文**:独立回测 validation 现在会在写出 `artifacts/validation.json` 或 CLI stdout 前归一化嵌套的 `NaN` / `Infinity`,严格 JSON 解析器不再被验证载荷卡住([#306](https://github.com/HKUDS/Vibe-Trading/pull/306),感谢 @gyx09212214-prog)。Agent prompt 的数据源数量也改为从 loader registry 动态推导,`_microcompact()` 只有在真实 token 压力下才会触发,短运行不会再过早清掉旧工具结果([#296](https://github.com/HKUDS/Vibe-Trading/pull/296),关闭 [#282](https://github.com/HKUDS/Vibe-Trading/issues/282),感谢 @MarkfuGod)。- **2026-06-24** 🎯 **Shadow Account 入场价格上下文 + 中文 UI 响应式本地化 + 局域网鉴权修复**:Shadow Account 规则抽取现在能看到 point-in-time 安全的入场上下文——按 `buy_dt` 经 loader registry 读取 `entry_rsi14` 与 `prior_5d_return`,离线/无数据时优雅降级([#302](https://github.com/HKUDS/Vibe-Trading/pull/302),承接 [#295](https://github.com/HKUDS/Vibe-Trading/issues/295),感谢 @Robin1987China)。Web UI 主面板进一步接入响应式英文 / zh-CN 翻译,覆盖图表、聊天、Alpha 因子库、Correlation 与 Run Detail([#301](https://github.com/HKUDS/Vibe-Trading/pull/301),感谢 @skloxo)。CSRF 加固后,配置了 `API_AUTH_KEY` 的远程同源 Web UI 部署现在又能正常 POST / upload,而跨站 mismatch origin 仍会被拦截([#304](https://github.com/HKUDS/Vibe-Trading/pull/304),感谢 @Hinotoi-agent)。@@ -205,6 +207,7 @@ Vibe-Trading 是一个开源研究工作台,用于把金融问题转化为可| **复盘自己的交易** | 券商日志解析、行为诊断、规则提取和 Shadow Account 对比。 || **改进重复研究** | 持久记忆和可编辑 skills 将有用流程变成可复用工作流。 || **运行分析师团队** | 面向投资、量化、加密、宏观和风控工作流的多智能体研究评审。 |+| **把研究接入 IM 通道** | 通过 WebSocket、Telegram、Slack、Discord、Matrix、WhatsApp、Signal、QQ/NapCat、微信/企业微信、飞书/Lark、钉钉、Teams、email、Mochat,在 CLI、REST 和 Web UI 中管理同一套 session runtime。 || **交付可用成果** | 报告、TradingView Pine Script、TDX、MetaTrader 5、MCP tools,以及可延续的研究 sessions。 || **跑预置 alpha zoo 横评** | 456 个 alpha 因子(Qlib 158 + Kakushadze 101 + GTJA 191 + FF5 + Carhart),一行 CLI 在你选的 universe 上算 IC + IR + alive/reversed/dead 分类 |@@ -590,6 +593,7 @@ vibe-trading # interactive TUIvibe-trading run -p "..." # single runvibe-trading serve # API servervibe-trading alpha list # 浏览 456 个预置 alpha;支持 show / bench / compare / export-manifest 子命令+vibe-trading channels status --local # 检查 IM 通道配置和依赖安装提示```<details>@@ -646,6 +650,24 @@ vibe-trading alpha bench --zoo gtja191 --universe csi300 --period 2018-2025 --to</details>+<details>+<summary><b>IM 通道</b></summary>++IM 通道适配器会把外部聊天应用接到 Web UI 和 CLI 共用的 session runtime。把要启用的平台写到 `~/.vibe-trading/agent.json` 的 `channels` 段;SDK 型适配器是可选 extras,缺依赖时会给出恢复提示,而不是拖垮运行时。++```bash+vibe-trading channels status --local # 不连 API,检查配置和缺失 SDK 提示+vibe-trading channels status # 查询正在运行的 API runtime+vibe-trading channels start # 通过 API 启动已启用的适配器+vibe-trading channels stop # 通过 API 停止已启用的适配器+vibe-trading channels login weixin # 需要时执行适配器登录流程+vibe-trading channels pairing --channel telegram list+```++内置适配器包括 `websocket`、`telegram`、`slack`、`discord`、`matrix`、`whatsapp`、`signal`、`qq`、`napcat`、`weixin`、`wecom`、`feishu`、`dingtalk`、`msteams`、`email` 和 `mochat`。可按需安装单个平台,例如 `pip install "vibe-trading-ai[telegram]"`,也可以一次安装全量通道依赖:`pip install "vibe-trading-ai[channels]"`。++</details>+---## 💡 Examples@@ -763,6 +785,10 @@ vibe-trading serve --port 8899| `PUT` | `/settings/llm` | 更新本地 LLM settings || `GET` | `/settings/data-sources` | 读取本地数据源 settings || `PUT` | `/settings/data-sources` | 更新本地数据源 settings |+| `GET` | `/channels/status` | 读取 IM 通道运行时与适配器状态 |+| `POST` | `/channels/start` | 启动已配置的 IM 通道适配器 |+| `POST` | `/channels/stop` | 停止已配置的 IM 通道适配器 |+| `POST` | `/channels/pairing/command` | 针对共享存储执行 sender pairing 命令 || `POST` | `/scheduled-runs` | 创建定时研究任务(间隔毫秒或 cron) || `GET` | `/scheduled-runs` | 列出定时任务 || `DELETE` | `/scheduled-runs/{job_id}` | 取消定时任务 |@@ -781,6 +807,8 @@ Web UI Settings 页面允许本地用户更新 LLM provider/model、base URL、gSettings 读取无副作用:`GET /settings/llm` 和 `GET /settings/data-sources` 永远不会创建 `agent/.env`,并且只返回项目相对路径。Settings 读写可能暴露凭据状态或更新凭据/运行时环境,因此在配置了 `API_AUTH_KEY` 时会要求认证。如果 dev mode 下未设置 `API_AUTH_KEY`,settings 访问只接受 loopback clients。+同一个 Settings 页面也包含 **IM 通道**面板,面向本地 operator。它会轮询 `/channels/status`,展示 configured/enabled/available/loaded/running 状态,暴露适配器恢复提示,并可直接启动或停止已配置的通道 runtime。+### 定时研究(Scheduled research)让研究 prompt 或回测按固定周期重复运行。后台执行器**默认关闭**——启动服务时设置 `VIBE_TRADING_ENABLE_SCHEDULER=1` 才会开启:@@ -1016,7 +1044,7 @@ Vibe-Trading 是 **[HKUDS](https://github.com/HKUDS)** 智能体生态的一部| **Options Lab** | Vol surface、Greeks dashboard、payoff/scenario explorer | Planned || **Portfolio Studio** | Risk x-ray、constraints、turnover-aware optimizer、rebalance notes | Planned || **Alpha Zoo** | 452 个预置 alpha 因子(Qlib 158 + Kakushadze 101 + GTJA 191 + FF5 + Carhart),一行 CLI 跑横评,agent 集成,Web UI 浏览 | **已发布 0.1.8** |-| **Research Delivery** | 定时 briefs 到 Slack / Telegram / email-style channels | 调度器已发布 |+| **Research Delivery** | 通过 Slack / Telegram / email-style IM channels 发送定时 briefs 与实时研究 sessions | 调度器 + IM Runtime 已发布 || **Community** | 可分享的 skills、presets 和 strategy cards | Exploring |---