Commit Graph
123 Commits
Author SHA1 Message Date
mohe ef4ead6a03 fix: ocg_router proc_guard API适配——_LockResult无pid属性,g.pid→g.message(修复502 Bad Gateway根因:启动检查AttributeError导致服务不稳定) 2026-08-14 09:46:51 +08:00
mohe 75026c9b7a feat: ocg_router空输出自动换key——_forward_request检测content为空→返回empty_content→_proxy_chat自动换下一个key重试(不冷却) 2026-08-14 09:31:07 +08:00
mohe 6a5c08a5df feat: ocg_router 并发模式——X-OCG-Mode: concurrent 时 round-robin 锁 key 轮询(每次请求轮着用key,避免并发压同一key触发429/401), 非并发模式保持按用量选最空闲; 测试验证key1→key4→key5→key6轮询 2026-08-14 04:06:26 +08:00
hmo 936925c74f revert: Windows now static IP 192.168.1.16 (was .248 DHCP) — restore .16 in configs 2026-08-12 21:51:08 +08:00
hmo f19f93931a fix: wechat login status — logged in / message activity takes priority over stale QR text in docker logs 2026-08-12 16:14:05 +08:00
hmo a83ae177cb fix: ocg_router error classification — 400 client error no retry, 5xx/Router.Unavailable no longer kill keys into cooldown, client disconnect handled, max parallel 16 2026-08-12 16:08:14 +08:00
hmo 44b77be525 fix: Windows IP changed 192.168.1.16 -> 192.168.1.248 — update dashboard bridge URL, health checks, agents.yaml 2026-08-12 16:07:46 +08:00
hmo 4b838b5a6b fix: ocg_router single-threaded HTTPServer blocks all requests on large body — switch to ThreadingHTTPServer 2026-08-10 12:56:01 +08:00
mohe c6d7d8b92d fix: 微信状态检测登录成功优先(logged in/Message), 消除历史日志干扰 2026-08-08 01:36:57 +08:00
mohe 6f9161cd93 fix: dashboard 微信状态检测识别等待扫码/会话失效, 不再误报已登录 2026-08-08 01:30:19 +08:00
mohe 8feed0092b fix: health_check 识别微信登录失效(loginCheck错误), 防止误报已登录 2026-08-08 01:03:13 +08:00
hmo a8b46178e3 fix: spec audit — align specs with reality (xmpp_bot 5807, dashboard missing endpoints, article_processor X-Lines, api_proxy capability, health_check JSON escape); fix 5802->5807 across dashboard/health_check/watchdog consumers 2026-08-06 16:48:16 +08:00
hmo 1dd3f9aad5 fix: watchdog revival — port 5807 in registry, skip remote/self-managed services, add to start.bat
- service_registry: xmpp_bot port 5802 -> 5807 (matches xmpp_agent_core), fix health_url/log
- xmpp_watchdog: skip services without script or pid_file (dashboard self-managed, gateway_* remote) — previously crashed on open(None)
- start.bat: launch watchdog after xxm bot so crash auto-recovery runs on boot
2026-08-05 09:57:51 +08:00
hmo afcce956f0 fix: chat_bridge missing import sys -> xmpp_bot crash on startup; RDP/EasyTier bridge offline 2026-08-05 02:22:20 +08:00
hmo 745daaa1a2 fix: Router.Unavailable -> all keys short-cooldown 30s + cooldown error shows cause/expiry 2026-08-04 11:09:27 +08:00
hmo a83660ebd3 feat: enable/disable OCG keys via Dashboard — disabled keys removed from router pool instantly 2026-08-03 11:45:16 +08:00
hmo f25a15f3bf fix: usage collection error no longer kills keys; 401/403 treated as key failure; key3 (renewal cancelled) skipped via accounts.json 2026-08-03 11:21:12 +08:00
mohe be2b194b71 feat: WeChat QR code + status inline in Platform tab
wechat_bridge entry now shows:
- status text (已登录Xh / 已掉线Xh) via s.message
- inline QR code with 5min expiry + refresh button when logged out
- refreshWechatQR() fetches latest QR on demand (no polling)
2026-08-02 04:43:16 +08:00
mohe b0ad75b88e fix: detect system_event_logout for real WeChat status
Previously only looked for WeChat send OK/error in last 200 log lines.
system_event_logout was missed, so dashboard showed 正常 when session
was actually dead. Now:
- Greps full webhook log for system_event_login/logout
- Logout after login => logged_out status
- WeChat send timeout (Hermes error) also counts as failure
2026-08-02 04:32:37 +08:00
hmo bd87a341dc fix: strip Transfer-Encoding from proxy response (buffered, not chunked) 2026-08-02 04:25:44 +08:00
hmo ad40956f33 docs: ocg_router spec file (human help + AI spec) 2026-08-01 14:39:32 +08:00
hmo e8111a3a59 merge: resolve dashboard.html conflict (keep proxy section) 2026-08-01 12:40:47 +08:00
hmo 79a9264cbd feat: OCG router proxy — quota-aware 6-key routing 2026-08-01 12:39:35 +08:00
mohe 7581bccda5 fix: cross-platform config path in chat_bridge.py
_load_providers and _SERVE_DB had hardcoded C:\\\\Users\\\\hmo paths.
Now uses os.path.expanduser(" ~\) as primary path, with Windows
fallback. Supports OPENCODE_CONFIG_PATH env override.
2026-07-31 10:37:07 +08:00
mohe fd6ea76f54 feat: WeChat status + QR on Dashboard, proactive login notifier
- /api/wechat/status: real login detection via webhook log + docker logs
- /api/platform: wechat_bridge now returns login_ok, message, qr_url
- Platform tab: inline QR code with 5min expiry + refresh button
- wechat_qr_notifier.py: 40h session-age WeChat warning + XMPP logout alert
- agents_health_check.py: login_check via docker logs
- wechat_webhook.py: timeout 180→600s
2026-07-31 03:22:35 +08:00
hmo 3e2a74d4d9 fix: SenseNova卡片不再混入OpenCode Go组
- accounts.json移除key8/9/10(它们是同一SenseNova账户的3个模型视角,非OCG账号)
  否则OCG采集器会把它们当OCG账户采集,前端归到OpenCode Go组
- /api/keys: 注册表外的用量条目(sensenova)以独立provider追加,不进OCG
- 前端provider名映射补sensenova
2026-07-23 22:52:53 +08:00
hmo 0a3986238e feat: SenseNova Token Plan余量监控(参考OCG/Kimi CDP模式)
- usage_collector_sensenova.py: CDP刮platform.sensenova.cn/console三模型余量
  (锚定'模型名+换行+数字%剩余'防图例区误匹配)
- dashboard: /api/usage和/api/keys合并sensenova数据; refresh流程加SSH采集+scp回传
- accounts.json注册key8/9/10(同一SenseNova key三模型视角)
2026-07-23 18:23:16 +08:00
hmo e59c1bcc53 fix: 移除afw-proxy(已废弃试验)+ocg-key顺序由/api/keys配额动态决定
- afw-proxy是早期试验代理,老爸确认已废弃,不入链
- ocg-key*按AgentsMeeting/api/keys健康度排序,session_expired跳过
2026-07-23 16:47:28 +08:00
hmo eddbee968c fix: provider链白名单与实际config脱节导致模型无响应
- 原allowed仅4个provider(deepseek/volcengine/opencode-go*), config里只有deepseek(402欠费)→全链死
- 现按存活度排序: sense-nova(实测可用+tools支持)→deepseek→afw-proxy→ocg-key*
- 模型名: options.model优先, 否则取provider models字典第一个key
2026-07-23 15:54:38 +08:00
mohe 42a55f03c2 chore: 移除小果(agent-003)——已全线退役(dashboard默认agents/agents.yaml/auto_heal服务映射) 2026-07-21 22:46:42 +08:00
hmo 74496bacd9 chore: set executable bit on cron wrapper scripts 2026-07-21 01:02:50 +08:00
hmo 37bfbad921 feat: add cron wrapper scripts for OCG and Kimi local collectors
- ocg_collect.sh: local OCG collection via HTTP+cookies
- kimi_collect_local.sh: local Kimi collection via Playwright CDP
- Replaces kimi_collect.sh (SSH-to-Windows approach)
2026-07-21 01:00:58 +08:00
hmo c11222e55c feat: local Kimi collection via Playwright + headless Chrome on 246
- usage_collector_kimi_local.py: Playwright connect_over_cdp to local Chrome
- kimi_login.py: interactive login helper for headless Chrome
- Replaces SSH-to-Windows approach, removes single point of failure
- Chrome CDP service: chrome-kimi-cdp.service (systemd)
2026-07-21 00:56:00 +08:00
hmo 2598b286eb fix: kimi collector crash on CDP error + auto-start CDP proxy + dashboard renewal badge
- usage_collector_kimi: guard /targets dict response, auto-start CDP proxy if down
- usage_collector: add subscribed/renewal fields to HTTP+CDP collection
- dashboard: show UNSUBSCRIBED red badge / renewal-cancelled orange badge
2026-07-20 23:18:40 +08:00
hmo dc3b3d1868 fix: Kimi collector always reloads page for fresh data 2026-07-19 22:17:12 +08:00
hmo 9a6ff4a3bd fix: refresh endpoint triggers Kimi collector via SSH to Windows + scp result back 2026-07-19 22:12:46 +08:00
hmo 84423565f8 fix: Kimi collector targets correct membership/subscription tab, parses 3 usage metrics with dates 2026-07-19 21:26:40 +08:00
hmo c1232ed382 fix: OCG output includes provider field + Kimi collector uses membership/subscription page 2026-07-19 21:09:01 +08:00
hmo bfb6bfba59 fix: OCG collector skips non-opencode_go provider accounts (key7 Kimi was leaking into OCG section) 2026-07-19 20:22:04 +08:00
hmo e509334ff4 fix: /api/keys reads Kimi usage_stats_kimi.json for key7 data 2026-07-19 19:47:46 +08:00
hmo 7a43fec2b1 feat: multi-provider usage — Kimi collector via CDP, unified /api/usage, frontend grouping 2026-07-19 19:46:08 +08:00
hmo 94f5f9ec92 feat: add /api/keys endpoint — masked API keys with usage data (rolling/weekly/monthly) 2026-07-19 10:53:32 +08:00
hmo 94250e9dda fix: match crontab entries by script filename (underscore) not task name (hyphen) 2026-07-19 09:25:25 +08:00
hmo 0ed048c327 fix: dashboard monitor checks local crontab + dev-spec adds Linux-first deployment rule 2026-07-19 09:24:03 +08:00
hmo d6950b0982 rewrite: health check, daily health, todo executor for Linux 246 deployment (native tools, no Windows deps) 2026-07-19 09:21:26 +08:00
hmo 1d4f083b10 fix: use 10s timeout for remote service HTTP checks 2026-07-19 09:12:15 +08:00
hmo b248fc62c5 fix: auto_heal extract service_key from composite key (agent-XXX:name) for SERVICE_UNIT_MAP lookup 2026-07-19 09:10:39 +08:00
hmo b56b1b3b47 fix: health check PID now advisory-only, remote services skip local port, add ?§ to task entries 2026-07-19 09:05:16 +08:00
hmo 4bba29965f fix: handle GBK encoding from Windows schtasks output via SSH 2026-07-19 08:20:08 +08:00
hmo 9fca8185a5 fix: monitor endpoint checks Windows schtasks via SSH instead of Linux systemd/crontab 2026-07-19 08:18:54 +08:00