Skip to content

Releases: mamawai/wtfibought

v2.0.7

Choose a tag to compare

@mamawai mamawai released this 17 Sep 04:05

v2.0.7 — trader 交易指令归主人 + 计划与仓位绑定重做 + JSON 统一 Jackson 3

本版跨度 cf75565...52b27dd。三条主线:trader 的交易方法与纪律全部交给主人的交易指令;交易计划与仓位改成按仓位生命期绑定;后端 JSON 统一为 Jackson 3。

AI Trader · 交易指令

  • 平台模板只讲事实:系统提示词只讲环境、开场白内容、工具、仓位规格、护栏拒什么和收尾格式,不带任何交易方法、风格与纪律
  • 交易指令是唯一来源:「自定义提示词」改名为交易指令,删掉「使用平台系统提示词」开关;新建 trader 时预填平台默认指令,可改可删,配置页可一键重置
  • 复盘以指令为尺:reviewer 按主人的交易指令判断对错,下期规则不得与指令冲突,指令没写到的按常识判
  • 老 trader 注意:已有 trader 的指令框不会自动填入默认指令;想继续用原来那套纪律,到配置页点「重置为平台默认指令」再保存

交易计划 · 仓位

  • 一行计划对应一个仓位生命期:旧仓了结就归档;同币同方向还有新仓或挂单的,另起一行;两次唤醒之间开了又平的,也各补一行
  • 结局当轮上报:仓位被止损、同币同方向的加仓单还挂着时,当轮就报结局,不再等挂单成交
  • 平仓先查仓位:close_position 先确认有仓位再下单,留痕统一按币种和方向找计划
  • 护栏:拒掉会当场成交的限价单(买入价不低于现价,或卖出价不高于现价)

模型链路 · 其他

  • Responses 缓存按会话分组prompt_cache_key 加入首条 user 消息,修复 CPA 跨会话回放上一轮输出
  • ReactLoop 容错:模型调用不存在的工具时,回执报错并列出可用工具,不再抛异常打断整轮
  • 复盘价格路径:改为按小时给高 / 低 / 收并标出时刻,替代原来的收盘、高低两行序列
  • 大户持仓分布:以快照价为中心上下各 12 行固定坐标轴,超出范围的名义并入上下两个溢出行
  • JSON 统一 Jackson 3:移除 fastjson2,缓存、落库、SSE、LLM 请求体共用一个 mapper;fastjson2 写的会话上下文照常能读
English

v2.0.7 — Trading instructions belong to the owner + plan/position binding rebuilt + JSON unified on Jackson 3

This release spans cf75565...52b27dd. Three main threads: the trader's method and discipline now live entirely in the owner's trading instructions; plan ↔ position binding is rebuilt around the position lifecycle; backend JSON is unified on Jackson 3.

AI Trader · trading instructions

  • Platform template states facts only: the system prompt covers the environment, what the opening message carries, tools, position spec, what the guard rejects and the closing format — no trading method, style or discipline
  • Instructions are the single source: "custom prompt" is renamed trading instructions and the "use platform system prompt" switch is removed; new traders get the platform default instructions prefilled, editable or deletable, with a one-click reset on the config page
  • Reviews measure against the instructions: the reviewer judges decisions by the owner's instructions, next-period rules must not contradict them, and anything they don't cover is judged by common sense
  • Existing traders: the instruction box is not filled in automatically; to keep the old discipline, click "Reset to platform default" on the config page and save

Trading plans · positions

  • One plan row per position lifecycle: a closed position's plan is archived; if the same symbol and side still has a new position or open order, a new row is started; positions opened and closed between two wake-ups each get their own row
  • Outcomes reported in the same round: when a position is stopped out while an add-on order on the same symbol and side is still pending, the outcome is reported right away instead of waiting for the fill
  • Close checks the position first: close_position confirms the position before placing the order, and records always look up the plan by symbol and side
  • Guard: limit orders that would fill immediately are rejected (a buy at or above the current price, or a sell at or below it)

Model pipeline · misc

  • Responses cache grouped by session: prompt_cache_key now includes the first user message, fixing CPA replaying the previous round's output across sessions
  • ReactLoop tolerance: a call to an unknown tool returns an error listing the available tools instead of throwing and aborting the round
  • Review price paths: hourly high / low / close with timestamps, replacing the separate close and high/low series
  • Whale position distribution: the axis is fixed at 12 rows above and below the snapshot price, with notional outside it folded into top and bottom overflow rows
  • JSON unified on Jackson 3: fastjson2 is removed, and cache, persistence, SSE and LLM request bodies share one mapper; chat contexts written by fastjson2 still load

Full Changelog: v2.0.6...v2.0.7

v2.0.6

Choose a tag to compare

@mamawai mamawai released this 14 Sep 20:44

v2.0.6 — 游客免登录浏览 + 大户持仓与财经日历 + agent 去 langgraph4j

本版跨度 7640834...cf75565。三条主线:游客免登录浏览;新增 Hyperliquid 大户持仓,财经日历换源并做成日历页;wiib-agent 去掉 langgraph4j 改手写 ReactLoop,三家端点补齐提示缓存。

游客浏览

  • 免登录可看:行情、全站成交、榜单、爆仓、竞技场、留言板与快讯 / 财经日历;只读接口放行 GET,写操作与本人账户页仍要登录
  • 登录占位:需要登录的面板(下单、发言、福利)换成去登录占位;游客的 401 不再弹去登录页
  • K 线限制:游客只给最新一屏,翻历史要登录;根路径直接进首页
  • 匿名接口收口:K 线只认上架币种和币安周期,bStock 不再逐只回源,/crypto/price 不放行

财经日历 · 快讯

  • 换源 TradingView:只收 High 级,按事件 id 更新,带实际值
  • 等实际值再唤醒:trader 唤醒撞上数据公布时刻,先等实际值出来(最多 30s);注入改为刚公布 / 过去 3 天 / 今天剩余三段
  • 新增日历页:2022 年起的历史按周翻、按国家筛,点开看指标解读与历次走势
  • 日历标记:日历行加国旗、实际值与预期对比标签;K 线标记换成财经日历事件,只挂 BTC、只挂美国事件
  • 快讯只留译文:停止打标,功能位 news-tagging 改名 news-translation

Hyperliquid 大户持仓

  • 地址池与轮询:每日认证大户地址池(净值 ≥ 100 万或盯盘币仓位 ≥ 10 万,最多 1000 个),每 10 分钟轮询持仓,按币聚合快照落库
  • Coin 页:新增大户持仓块,多空名义、均价、覆盖率,开仓价 / 强平价按价位分布
  • 首页:新增大户持仓卡,各币多空名义、人数与现价 5% 内强平名义
  • 只做展示:不进 trader 决策,whale.enabled 可关

币种与界面

  • 新币种:接入 ZEC(现货 + 合约)与 HYPE(纯合约)
  • 选币列表:币种图标换官方 SVG,列表改极简行,点行带过渡动画
  • 顶栏:sticky,往下滚折叠
  • 交互:控件反馈统一,排行榜改版,AI 面板开合改成收放浮动球
  • 手机端交易页:副图不挤主图,止盈止损默认收起

模型链路 · agent

  • trader 模板:去掉「先看大周期定方向」「盈亏比 ≥ 2:1」「HOLD 是常态」三处门槛,交给模型自己权衡
  • ReactLoop:叶子 agent 改手写 ReactLoop,删除 langgraph4j 依赖;会话上下文改裸 JSON 落库,兼容老格式
  • 提示缓存:Anthropic 的 system 挂 1h、末条消息挂 5 分钟断点,Responses 带 prompt_cache_key,三家都记缓存命中
  • 推理回放:Responses 在工具循环里原样回放 reasoning,接得上上一步的推理
  • 非正常收尾:拒绝、截断、上下文写满时显式报错,不再把半截回答当结论
English

v2.0.6 — Guest browsing + whale positions & economic calendar + agent off langgraph4j

This release spans 7640834...cf75565. Three main threads: guests can browse without logging in; Hyperliquid whale positions are added, and the economic calendar moves to a new source and gets its own page; wiib-agent drops langgraph4j for a hand-written ReactLoop, with prompt caching added across all three endpoint protocols.

Guest browsing

  • No login needed: markets, all-site trades, rankings, liquidations, the arena, comments, and news / the economic calendar; read-only endpoints are opened for GET, while writes and your own account pages still require login
  • Login placeholders: panels that need login (ordering, posting, buffs) show a log-in placeholder instead; a guest's 401 no longer bounces to the login page
  • Candle limits: guests see only the latest screen, and paging back through history requires login; the root path opens straight to the home page
  • Anonymous endpoints tightened: candles accept only listed symbols and Binance intervals, bStock no longer hits the upstream stock by stock, and /crypto/price stays closed

Economic calendar and news

  • Switched to TradingView: High impact only, updated by event id, with actual values
  • Wait for actuals before waking: when a trader wake-up lands on a release time, it waits for the actual value first (up to 30s); injection is now split into just released / past 3 days / rest of today
  • New calendar page: history since 2022, paged by week and filtered by country, with an explainer and past releases for each indicator
  • Calendar markers: rows gained flags, actual values and vs-forecast tags; chart markers now come from calendar events, on BTC only and US events only
  • News keeps translations only: tagging is gone, and the news-tagging slot is renamed news-translation

Hyperliquid whale positions

  • Pool and polling: a whale address pool is certified daily (account value ≥ 1M or a watched-coin position ≥ 100k, up to 1000 accounts), positions are polled every 10 minutes, and per-coin snapshots are stored
  • Coin page: a new whale block with long/short notional, average entry, coverage, and entry / liquidation price distribution by level
  • Home page: a new whale card with long/short notional, headcount, and liquidation notional within 5% of the price for each coin
  • Display only: never fed into trader decisions; whale.enabled turns it off

Coins and UI

  • New coins: ZEC (spot + futures) and HYPE (futures only)
  • Coin lists: official SVG icons, minimal rows, and a transition when a row is clicked
  • Top bar: sticky, collapses on scroll
  • Interaction: unified control feedback, a redesigned leaderboard, and the AI panel now opens and closes by morphing from the floating ball
  • Mobile trading page: sub-charts no longer squeeze the main chart, and take profit / stop loss are collapsed by default

Model pipeline and agent

  • Trader template: drops three gates — "read the higher timeframe for direction first", "risk-reward ≥ 2:1" and "HOLD is the norm" — and leaves those trade-offs to the model
  • ReactLoop: leaf agents now run a hand-written ReactLoop and the langgraph4j dependencies are removed; session context is stored as plain JSON and still reads the old format
  • Prompt caching: Anthropic sets a 1h breakpoint on the system prompt and a 5-minute one on the last message, Responses sends prompt_cache_key, and all three protocols record cache hits
  • Reasoning replay: Responses replays reasoning verbatim inside the tool loop, so the model can continue its previous reasoning
  • Abnormal endings: refusal, truncation and a full context window now raise errors instead of saving a partial answer as the conclusion

Full Changelog: v2.0.5...v2.0.6

v2.0.5

Choose a tag to compare

@mamawai mamawai released this 08 Sep 09:22

本版跨度 52fa890...7640834。三条主线:AI Trader 的主导权交回主人手里(留言提权、可忽略的交易、仓位绑定计划),全站界面照海报重做,以及 wiib-agent 从 quant 里拆成独立进程

  • 修好"留言总被拒绝":根因是模型拿平台纪律当否决依据。现在留言拼进唤醒开场白末尾(user 消息、最近因位置),并把举证责任倒过来——执行不需要理由,不执行只有两种理由算数:撞硬性护栏(杠杆区间/保证金占比/止损方向),或你对着当前行情引具体数字的独立判断;拿"纪律不允许 / 退出只有几条路 / 还没到目标位 / 盈亏比不够 / HOLD 是常态"推掉留言=根本没评估
  • 留言指定的开仓/加仓不受盈亏比门槛约束(止损、失效条件、论点标签仍要自己补齐);真要否决必须给替代方案;结论里单起一行对账「已执行+做了什么 / 未执行+什么数字让你这么判断」
  • 已了结交易可标记 stale:教材层(复盘素材、决策时间线、唤醒"最近决策"回注、chat 的 decisions/plans、论点战绩统计)一律绕开被忽略的交易,公开记录、钱账、权益曲线与排行榜一点不动。仅本人、仅 CLOSED 可标记,开关只有主人看得见
  • 仓位↔计划绑定:ai_trader_plan 加 position_id,开仓/加仓从下单响应直接落盘,限价单成交后按 (symbol|side) 补绑;pairAll 成为唯一配对入口,复盘/竞技场/统计/同侪四个消费端全换过来——同一笔交易在不同地方配到不同计划的问题从根上消除
  • 决策收尾改「总评 + 按币分段」:[SYMBOL] 段头独占一行,纯观望的币也要写;解析层按段切分,旧格式整块归 WHOLE 兼容。时间线的观望合并跟着改按币段,一个币条件变了不再冲断别的币的连续段
  • 观望不再白烧钱:纯观望且各币窗口振幅全 <2% 就跳过复盘,留 SKIPPED 注明缘由(K 线缺数据不算平静);<6h 的碎观望收进一行汇总,≥6h 升格成对账块(段头 + 等待条件全文 + 段起点结构快照);复盘提示词要求好观望一句带过、错失必须写进教训
  • 同侪学习只数在场的同侪(未暂停 + 有持仓或 24h 内有了结),门槛改为除自己外 ≥2 人
  • 重置开新局可选不带入复盘/学习笔记(缺省仍带入);新增本局论点战绩统计块,注入位置在最近决策之后、笔记之前

唤醒链路

  • 观察包重构:事件、账户状态、上一轮结论、决策轨迹全部挪进唤醒开场白,system 提示词只留身份与规则
  • 财经日历:ForexFactory 周历采集落库,唤醒注入过去 12h 已公布 + 未来 24h 即将公布,只给事实——事件临近不构成方向动作的理由。首页也有一张卡,本周已公布 / 即将公布各 6 条
  • 唤醒过程 SSE 实时展示与历史回看:现场块看得到工具调用、预算条与打字光标,跑完落成可回看的轨迹。现场只给主人看,非主人连 live 与 trace 一律拒,竞技场列表的实时流退役
  • 止盈从软约束改硬规则:开仓必填止盈——它就是计划的目标位,盈亏比与"到目标位落袋"都按它算;想让利润奔跑,开仓后往远移即可
  • 拆掉加减仓审批链路,模型始终自主调仓;工具失败改回给模型自己处理;单轮可交易币种上限 3、模型调用上限 12、预算见底给收尾提示
  • 支持删除 trader:决策、计划与每局的 sim 子账户全清

界面照海报重做

  • 数字设计基底:index.css 换成 token + 原子类 + reveal/stagger 动效,Archivo 变宽字体,圆角全归 0,卡片背景与页面同色,新增 countUp / useStagger 两个 hook
  • 顶栏与行情副条:文字 logo、导航橙方块滑动、2px 墨线、副条 80s 无缝滚动;「更多」下拉摊开,用户名改纯文字 + 退出按钮;手机顶栏与底部 Tab 同步换风格
  • 首页:开屏 6/3/3(总资产大数 + 净值线基线分色 | 我的 Trader 墨块 | 月度盈亏格)、入口七格、市场四类各两只、快讯 8/4 成交、爆仓多空比条、新手教学三列;快讯支持按天翻看
  • 交易页:K 线工具三层分工——顶栏管周期 / 图型 / 指标 / 全屏,左侧画线竖栏,图内三行读数 + VOL/MACD/RSI;成交标记只标 B/S,点开列该根全部成交;开仓止损止盈输入框常显,留空即不设
  • 持仓页:总资产大数 + 钱包 kv + 今日收益五类拆分 + 资产分布条,合约 / 币种 / 股票 / 预测四块统一表格
  • 竞技场:记分牌行(名次、收益率、状态 chip + 原因)+ 三步引导;详情页记分头 + 六格 strip、SVG 净值曲线(改平滑样条、标签越界钳在图内)、现场块、决策时间线每条一格
  • 交易页页头显示资金费率:改成结算点(0/8/16)拉一次全量写缓存,扣费与查询都只读缓存,不再每次直连 Binance
  • 新增 wiib-intro 介绍站与 agent 流程图页

模型链路 · 研判对话

  • 端点协议写全四种:新增 Anthropic Messages 与 Gemini,SseChatModel 抽出自研 SSE 骨架,三个子类只管协议形状
  • 服务端搜索跨协议打通:勾了搜索就声明该协议的搜索工具,上游拒收自动退回不搜;过程轨显示"正在搜索 / 搜索了 N 个网站",来源随 done 下发并落库
  • chat 联网搜索改显式 opt-in:端点上勾 web_search,只授权 summarizer,带 usage 观测
  • 界面语言与 agent 提示词语言拆成两套开关;快讯中英两套一起下发,切语言不重拉
  • 研判对话改 ChatGPT 版式,加清空全部会话;一轮对话的执行从 Controller 拆到 ChatTurnStreamer,重新生成的上下文回退抽成 ChatTurnRewinder
  • 中断能掐断在途模型流、token 账本按轮换新;openai 协议超时逐请求下发
  • 升级 langgraph4j 1.8.26 / Spring AI 2.0.1,spring-ai 走 BOM 钉死版本

架构 · 清理

  • wiib-quant 拆分:新增 wiib-agent 进程模块,agent/** 迁到 com.mawai.wiibagent,quant 去掉 boot 插件降级为普通库由 agent 依赖扫描;界面词表劈成 agent.yml / quant.yml,8082 端口不变、前端代理零改
  • LIQFADE 策略整体下架(含文档面),LiquidationCascadeLeg 作为全部策略共用的 live 信号确认腿保留;新增 PromptParityTest 钉死 zh/en key 集合与占位符对齐
  • 词表收尾:BYOK 端点校验、SSRF 拒因、会话无标题接入 MessageCatalog,喂模型的硬编码中文外置双语,英文界面不再冒中文
  • SSE 断连不再进系统异常兜底,token 合计空行判空
English

This release spans 52fa890...7640834. Three main threads: control of the AI Trader handed back to its owner (owner messages carry real weight, trades can be ignored, positions are bound to plans), the whole UI rebuilt from the poster designs, and wiib-agent split out of quant into its own process

  • Fixed "owner messages always get rejected": the root cause was the model treating platform discipline as grounds for refusal. The message is now appended to the wake-up opener (a user message, in the most recent position) and the burden of proof is reversed — executing needs no justification, and only two reasons count for not executing: it hits a hard guardrail (leverage band, margin ratio, stop-loss direction), or your own read of the current market backed by concrete numbers. Waving a message away with "discipline forbids it / there are only so many exits / the target isn't reached / the risk-reward is short / HOLD is the norm" means it was never evaluated
  • Entries or add-ons the owner asks for are exempt from the risk-reward gate (stop loss, invalidation conditions and thesis tags are still yours to fill in); a genuine refusal must offer an alternative; and the conclusion carries a dedicated line — "owner message: executed + what was done / not executed + which numbers led you there"
  • Closed trades can be marked stale: everything in the teaching layer (review material, decision timeline, the "recent decisions" replay in the wake-up, chat's decisions/plans, thesis scorecard) skips ignored trades, while public records, the ledger, the equity curve and the leaderboard are untouched. Only the owner, only CLOSED trades, and the toggle is owner-only
  • Position ↔ plan binding: ai_trader_plan gained position_id, written straight from the order response on entry/add-on and back-filled by (symbol|side) once a limit order fills; pairAll is now the single pairing entry point and all four consumers (review, arena, stats, peer learning) use it — the same trade can no longer be paired to different plans in different places
  • Decision endings restructured as "overall + per-symbol sections": the [SYMBOL] header takes its own line and symbols merely on the sidelines get a section too; the parser splits by section and old-format blocks fall back to a WHOLE pseudo-key. Timeline wait-merging follows the same per-symbol split, so one symbol's condition change no longer breaks another symbol's streak
  • Waiting rounds no longer burn budget for nothing: a pure wait round where every symbol's window amplitude is <2% skips the review and leaves a SKIPPED row with the reason (missing candles do not count as calm); wait stretches under 6h collapse into one summary line, while 6h or longer are promoted to a reconciliation block (section header + full wait conditions + structure snapshot at the section start). The reviewer prompt now asks for good waits in one line and missed moves written up as a lesson
  • Peer learning only counts peers who are actually present (not paused, and either holding or closed something in the last 24h), with the threshold raised to 2 or more besides yourself
  • Resetting for a new run can optionally leave review and learning notes behind (they carry over by default); a per-run thesis scorecard block was added, injected after recent decisions and before the notes

Wake-up pipeline

  • Observation package rebuilt: events, account state, last round's conclusion and the decision trace all moved into the wake-up opener, leaving the system prompt with identity and rules only
  • Economic calendar: the ForexFactory weekly calendar is collected and persisted, and the wake-up gets what was released in the past 12h plus what is due in the next 24h — facts only, an upcoming event is not a reason for a directional move. The home page carries a card too, six released and six upcoming for the week
  • Live SSE view of the wake-up plus history replay: the live block shows tool calls, the budget bar and a typing cursor, and settles into a replayable trace when the round ends. The live view is owner-only — non-owners are refused on both live and trace — and the realtime stream on the arena list is retired
  • Take profit went from soft guidance to a hard rule: it is required on entry, because it is the plan's target — both the risk-reward check and "take it at the target" are computed from it; to let profits run, move it further out after entry
  • The add/reduce approval chain is gone, the model always sizes its own positions; tool failures are handed back to the model to deal with; a round is capped at 3 tradable symbols and 12 model calls, with a wrap-up notice when the budget runs low
  • Traders can be deleted: decisions, plans and every run's sim sub-account are cleared

UI rebuilt from the posters

  • Design foundation: index.css moved to tokens + utility classes + reveal/stagger animations, the Archivo variable font, all corner radii to zero, card background identical to the page, and two new hooks (countUp / useStagger)
  • Top bar and ticker: text logo, an orange block sliding under the nav, 2px ink rules, and an 80s seamless ticker; the More dropdown is laid out, the user name is plain text with a sign-out button, and the mobile top bar and bottom tabs follow the same style
  • Home: a 6/3/3 opening screen (total assets in large figures + an equity line colored around its baseline | my Trader ink block | monthly P&L grid), a seven-cell entry grid, two symbols for each of four markets, an 8/4 news-and-trades row, a liquidation long/short bar and a three-column beginner guide; news flashes can be paged by day
  • Trading page: chart tools split across three layers — the top bar owns interval / chart type / indicators / fullscreen, a vertical drawing rail sits on the left, and three readout lines plus VOL/MACD/RSI live inside the chart; trade markers show only B/S and expand to list every fill on that candle; stop-loss and take-profit inputs are always visible and simply unset when left blank
  • Portfolio page: total assets in large figures + a wallet kv block + today's P&L broken into five kinds + an allocation bar, with futures / crypto / stocks / predictions on one consistent table style
  • Arena: a scoreboard row (rank, return, status chip with reason) plus a three-step guide; the detail page gained a scorecard header, a six-cell strip, an SVG equity curve (smoothed spline, out-of-range labels clamped inside the plot), the live block and a decision timeline with one cell per entry
  • The trading page header shows the funding rate: it is now fetched in full once per settlement point (0/8/16) into the cache, with both charging and queries reading the cache instead of hitting Binance every time
  • New wiib-intro marketing site and an agent flow diagram page

Model pipeline and research chat

  • All four endpoint protocols are implemented: Anthropic Messages and Gemini join the set, with SseChatModel factored out as the in-hou...
Read more

v2.0.4

Choose a tag to compare

@mamawai mamawai released this 25 Aug 04:04

本版跨度 74cec08...52fa890。三条主线:界面与 AI 产出全面中英双语,行为分析从平台功能位搬进对话轨

  • 前端全量 i18n:13 个命名空间 2017 条词条。首次进门弹语言选择,顶栏 / 登录页 / 我的页都能切
  • AI 产出跟随用户语言:提示词外置 prompts/{lang}.yml,21 个工具的描述按语言下发。trader 决策、复盘、学习笔记、研判对话、AI 教练开场白全链路跟着走
  • 后端界面文案与护栏拒因全部入词表(sim / trader / quant 三侧):拒因不再带中文,改带错误码或词表 key,由调用方按自己那门语言成文
  • 快讯翻译落库:打标同批产出译文,取用侧按语言取一份,不在渲染期临时翻
  • 对话行、了结方式、回测深层拒因改认语言无关码
  • 英文界面布局收口:顶栏加 More 下拉、断点抬到 lg——11 项平铺的英文顶栏要 1321px,1280 差 41px;竞技场补手机入口

行为分析进对话

  • 原来是 /ai 页一个按钮 + 平台买单的功能位,现在是对话轨的工具,跑在你自己的 BYOK 深模型上,报告以卡片落在对话流里
  • userId 在建叶子时烤死、不做成参数——做成参数就等于允许模型分析别人的账户
  • 按钮直发意图,跳过派发直奔工具

AI Trader 竞技场 · 对话

  • 补答轮改为前端发起的正常轮:让位后后端只排队不偷跑,接回后与普通轮一致——可补派专家、流式作答、可弹卡、可中断、可再被让位
  • 竞技场详情页重排减噪,曲线加区间选择、时间线按天查询;配置页加相关 skills 卡
  • 主人留言提权:合理就尽量履行、不许忽视,开场白末尾再钉一次
  • 模型产出落库不再截断;复盘 / 学习笔记超限改按句读收笔,不再拦腰断句
  • 挂死判据从字节级改为整体时长——block 超时判瞬时进重试,路由捎 90s 快速失败
  • 四处建图点收口到统一入口:消息去重 schema 与状态序列化器写死在入口里,系统提示必填且空值当场抛。行为零变化
  • 公开错误行归类文案、删会话拒运行中、消息上限、默认端点唯一索引
English

This release spans 74cec08...52fa890. Three main threads: the UI and everything the AI writes are now bilingual, behavior analysis moved out of a platform feature slot into the chat track
Bilingual

  • Full frontend i18n: 13 namespaces, 2017 entries. First visit prompts for a language; you can switch from the top bar, the login page or the Me page
  • AI output follows your language: prompts moved into prompts/{lang}.yml and all 21 tool descriptions are served per language. Trader decisions, reviews, learning notes, research chat and the AI coach opener all follow
  • Backend UI copy and guardrail rejections are fully catalogued across sim / trader / quant: a rejection no longer carries Chinese text but an error code or a catalog key, and the caller renders it in its own language
  • News-flash translations are persisted: produced in the same batch as tagging, readers pick the one matching their language instead of translating at render time
  • Chat rows, close-reason labels and deep backtest rejections now travel as language-neutral codes
  • English layout fixes: a More dropdown in the top bar and the breakpoint raised to lg — eleven items laid flat in English need 1321px, and 1280 falls 41px short; the Arena gained a mobile entry point

Behavior analysis moved into chat

  • It used to be a button on the /ai page backed by a platform-funded feature slot. It is now a tool on the chat track, running on your own BYOK deep model, with the report landing in the conversation as a card
  • userId is baked in when the leaf is built rather than exposed as a parameter — making it a parameter would let the model analyze someone else's account
  • The button now sends the intent directly, skipping dispatch and going straight to the tool

AI Trader Arena and chat

  • The deferred-answer round is now a normal round the frontend starts: after yielding, the backend only queues and never runs ahead, and once resumed it behaves like any other round — more experts can be dispatched, answers stream, cards can pop, it can be interrupted, and it can yield again
  • Arena detail page reorganized for less noise, with a range selector on the curve and per-day timeline queries; the config page gained a related-skills card
  • Owner messages carry more weight: honor them where reasonable, never ignore them, and the instruction is repeated at the end of the opener
  • Model output is no longer truncated on write; over-length review and learning notes stop at a sentence boundary instead of being cut mid-sentence
  • The hang detector switched from byte-level to overall duration: a block timeout is treated as transient and retried, and routing carries a 90s fast-fail
  • All four graph-construction sites funnel through one entry point, where the dedup schema and state serializer are fixed and the system prompt is required and throws on empty. No behavior change
  • Public error rows are categorized, deleting a running session is rejected, message counts are capped, and the default endpoint gained a unique index

v2.0.3

Choose a tag to compare

@mamawai mamawai released this 19 Aug 09:03

本版跨度 6d886a9...d8cde28。三条主线:研判工作台的对话页整个重做,AI Trader 把三个动作从"模型代执行"改成"用户按按钮"并加上唤醒时段,以及一批模拟盘账本与结算的正确性修复。

研判工作台 · 对话

  • 对话页重构:ChatPanel 拆成壳 / 消息 / 输入区 / 历史四块,回答改无框正文,工作过程轨默认展开
  • 支持中断当前轮与重新生成最后一条回答;重新生成会回退模型侧上下文到本轮提问之前,新答案落库后才顶掉旧答案
  • 每轮落库读数:端点 · 模型名、调用次数、token、耗时;有别轮在途专家仍在记账时只报耗时不报用量(写 NULL 而非 0)
  • 悬浮球可拖动、松手吸边,未读脉冲环与研判中雷达扫描纯 CSS;PC 全屏铺满浏览器视口而非原生 Fullscreen(那个连地址栏一起吃掉),左侧常驻历史会话栏
  • 快捷提问改可编辑可删;trader 三项动作从头部下拉移到输入框上方横向滑出
  • 删掉跨会话记忆(chat 侧 recall / remember 全链路 + workbench_memory 表)——召回段对答案质量没有可观测贡献

AI Trader 竞技场

  • 动作面板:留言 / 手动唤醒 / 点播复盘改表单驱动,执行入口只剩一条 REST。对话轨的工具只把表单推给用户,模型碰不到执行路径,所以它说不出"我已经唤醒了";只有当场烧钱的 run_deep_analysis 仍走 HITL
  • 留言支持多轮注入(1~24 轮,15m 档 ≈6 小时),每注入一次递减,减到 0 连正文清空
  • 唤醒时段:北京时间 HH:mm-HH:mm,可跨午夜。只管例行唤醒与波动警报,手动不拦,复盘 / 学习照常;提示词节奏行按时段说真话,末次唤醒带休眠提示并明说休眠不是平仓或抢开一笔的理由
  • 已了结交易卡:sim 已平仓位 ⟵配对⟶ 交易计划 ⟵关联⟶ 开 / 平仓那一轮的决策全文,配对算法与复盘、同侪学习共用同一套
  • 下单加幂等键:sim 侧 SETNX 只成交一次,同键重发问结果,仍未知回 UNKNOWN 让模型先核对持仓——原来读超时被当失败,模型重下就是双仓
  • 复盘超时 180s → 600s,点播改异步;等待条件按段提取、观望轮合并

合约交易

  • 反手:市价全平并立刻反向开等量新仓(双向持仓下只开反向仓会变成对冲)。开仓失败不回滚不外抛,带着已平仓信息返回让前端交代半成功;余额不足时只完成平仓
  • 反手入口移入持仓卡卡头,平时一格图标,确认态就地展开

BYOK 与模型链路

  • 思考档位放开自由填写:各家档位名字自己定(xhigh / minimal…),写死白名单会挡住
  • tool_choice 被上游拒收改为降级重发:开思考档位时上游直接 400,首轮必炸整轮作废;key 无效当场暂停 trader
  • Responses SSE 畸形事件不再炸整轮(不规范网关把 event: 行原样当 data 发),但全程无可解析事件会当场报错,不退化成静默空回答

模拟盘账本与结算

  • 预测回合结算失败不再永久 LOCKED 冻结本金:改按事件窗口结算 + 缺价回源 Polymarket REST + 巡检重跑,实在没价的作废退本金
  • 限价单触发索引改为 DB 落定后再摘,不再悬空;撤单挪到提交后,加每小时索引对账兜 Redis 丢键
  • 三个游戏"进行中的那一局"从 Redis 搬进库表,TTL 过期后本金不退、局接不上的问题消失
  • 账户重置清表前锁 user 行;sim 启动补漏按真实停机时长回看 1m K 线(上限 1000 根),不再漏掉重启期间的限价与强平穿越
  • 一批"报告与实际不符":单已成交却报失败、抢锁失败被当成结果未知、SSE 断连仍告诉模型表单已弹出、结果未知的下单在竞技场长得跟成交一样
  • 回测最大回撤改逐点算比例取最大(原口径把 100→50→1000→900 算成 10%)

安全 · 清理

  • WebSocket 登录 token 从 SockJS URL 挪到 STOMP CONNECT 头(URL 上的 token 会进 nginx 日志和浏览器历史)
  • 清理死代码

v2.0.2

Choose a tag to compare

@mamawai mamawai released this 17 Aug 07:21

v2.0.2 — AI Trader 竞技场 + 研判工作台全员开放 + 可视化回测

本版跨度 6fddcc8...6d886a9。主线三件事:AI Trader 竞技场从零落地(交易 / 复盘 / 学习三套装置),研判工作台改成 BYOK 后向全体用户开放,以及新增可视化回测页与手动复盘。

AI Trader 竞技场

每个用户一个 AI 交易员,接自己的模型与 key 在模拟盘自主交易,净值曲线与决策日志全程公开。

  • 交易核心:ai_trader / ai_trader_decision 表,提示词组装 → ReactAgent 唤醒回路 → 调度器按 K 线级别对齐边界;数据工具(K 线 / 结构 / 指标 / 快照 / IV / 资金费 / 盘口 / 快讯)+ 交易工具(开平仓 / 止损止盈 / 计划)+ TradeGuard 硬校验护栏,越界拒绝不截断
  • 仓位规格由主人设定(杠杆区间 / 保证金占比 / 单仓 / 双开 / 自主加减仓),加减仓走审批;token 用量统计;手动唤醒决策行标 MANUAL
  • 计划即承诺:开仓必须给论点标签、数据引用、失效条件,落 ai_trader_plan 每次唤醒回注;计划归档带生命期不删
  • 波动哨兵:持仓币种 5 分钟振幅超阈值临时唤醒(每币 180 天校准阈值、5 分钟冷静期),档位收编 5m / 15m / 1h / 4h
  • 竞技场三页:排行榜 / 详情决策时间线(推理全文、工具轨迹、论点与修订史、复盘与学习卡片)/ 我的 trader 配置;按局查看 R1/R2/Rx,重置只清本局;轮次保留窗口 R10,出窗局三表清除 + sim 子账户销户
  • 提示词三层重构:单问题框架 / 检验旧论点 / 固定收尾格式 / 成本数字化 / 截断保尾
  • 真跑一晚修的边角:空 symbol 挡在行情查询前、保证金提示数量照抄可过、SDK 读响应盲区单次重试、同轮重开不误判加仓、审批回执解析异常致动作双计

复盘与学习

  • reviewer workflow:日线边界读自己一天的交易,ReviewMaterialAssembler 算齐四块硬事实(战绩 / 论点→结局配对 / 决策摘编 / 价格路径),单次调用两段产出——【本期复盘】进 REVIEW 行、【记忆更新】覆盖 memory;缺分隔符降级不污染记忆;复盘用本地行情库并滚动承接上一期
  • learning agent:peer_insights 只读同侪(排行榜 + 单 trader 复盘 / 学习笔记 / 论点结局),产出学习笔记 learning_notes + LEARN 决策行公开上时间线;【不学什么】必填、每条带证据与差距数字
  • 日线交接三阶段:先交易 → 全体复盘 → 屏障 → 全体学习,停工窗口挡住例行 / 警报 / 手动 / 点播四个唤醒入口
  • review_enabled / learning_enabled 两个开关进配置管线;同侪学习互看以 learning_enabled 勾选为准

研判工作台

  • 对全体用户开放,模型走用户自己的 BYOK;入口三道准入(配置 / 建图 / 并发闸门:全局 10 轮 + 每用户 1 轮),LLM 错误归类成一句能照着做的话,前端按错误码分流引导去配置
  • 编排去图化:父 StateGraph 退役,ChatTurnRunner 平铺循环接管,叶子 ReactAgent 独立编译;会话上下文自建 workbench_chat_context 存储;专家结论带出处标注,修"取到数据仍答没有"
  • HITL 闸门上移到工具执行边,授权键 =(会话,工具,标的)三元组,点旧卡片不会误授权给新请求
  • chat 与 trader 联动:trader_agent 只读专家 + wake_trader / review_trader_now / run_deep_analysis 三个动作过 HITL
  • 专家取数期用户可插话让位,欠的答案转补答轮;研判鼓励方向表态;新增 kline_structure 工具;对话改全站悬浮 ChatDock,AI 页重构为 Tab,市场研判 tab 下线;面板文案 Polaris
  • 修复:续聊上下文读不出来(BYTEA 映射)导致每轮失忆;summarizer 调用上限与历史压缩从未生效;openai 协议路挂工具 options 类型不对致路由必炸零派发,ToolChoice 统一两协议 tool_choice

BYOK 端点库

  • 全站 BYOK 总配置收进 AI 页「模型配置」:一人多条端点(协议 + URL + key + 模型 + 思考档位),按用途绑定(对话主 / 轻、交易员),没绑的用途落到默认端点;卡片上标出哪些地方在用它
  • 交易员、复盘教练不再各填一套 key,只从下拉里选;只配一条就是全局默认
  • 连通性探测走生产建模路径;思考档位可配;SSRF 防线补 100.64.0.0/10 与 NAT64 等嵌 v4 形态;日志切面字段级脱敏,key / 密码 / 邀请码不再明文进日志

可视化回测与手动复盘

  • 回测页:策略回测异步任务链(工作记录事件流 + 图表回放),K 线周期 5m~1d 切换
  • 手动复盘:按周期逐根揭示 K 线、按收盘价开多开空,多空双开、加减仓、杠杆随时调,全仓口径爆仓;随机盲测隐藏真实日期,时长 3 / 7 / 14 / 28 天;成交标记、量能副图、权益曲线与结算统计
  • AI 教练:局中「AI 提示」读盘面结构 / 量能 / 持仓风险,结算后一键评估整局操作行为;模型从端点库里选
  • 画线工具补齐:射线 / 垂直线 / 平行通道 / 矩形 / 多空仓位区间 / 价格区间;触屏改十字虚线相对拖动 + 轻点固定
  • K 线新闻轨:快讯按时间桶挂到对应 K 线上方(画布图元随蜡烛同帧渲染),点击看详情

快讯与行情底座

  • 快讯采集打标:news_event 落库 + news-tagging 平台功能位,封闭词表轻模型批量打标
  • Binance REST 限流熔断(429/418 冷却期)+ serve-stale 年龄上限(资金费 8h / 标记价 15min);行情组装 single-flight;资金费历史与盘口纳入 TTL 缓存;盘口改走 WS 源;采集线程死于 Error 不再留僵尸等待者
  • 交易护栏三处漏洞修复,审批链路加 CAS;止损止盈改全仓;哨兵窗口加锁

体验

  • 现货买入支持 USDT 金额输入(crypto / bStock 双面板单位切换,预算与仓位 % 同口径)
  • 开屏改噪点场像素块随机点亮拼字,登录页背景换烟雾 shader;时间线徽章换 Lucide 图标

清理

  • 下线旧预测管线:预测工具箱 / fragility / 记分卡 / 宏观引擎 / vol 对账线全链路,MCP 不再暴露预测工具;删 quant / quant-light / chat 三个平台模型位(对话全量 BYOK);去图化清尾删 PostgresSaver 残余

Full Changelog: v2.0.1...v2.0.2

v2.0.1

Choose a tag to compare

@mamawai mamawai released this 04 Aug 06:06

v2.0.1 — 专业 K 线工具链 + 全仓强平安全带

本版跨度 d1428d1...6fddcc8。主线两件事:K 线从看图工具升级为带画线、仓位标注的专业图表,以及给全仓强平建起一条免检安全带。

K 线图表

从零建起画线与标注体系,看图和复盘不再需要切去别家。

  • 全屏模式:优先原生 Fullscreen API,iPhone Safari 降级 fixed 铺满;周期切换组内嵌工具条,切周期不退全屏
  • 画线工具:趋势线 / 水平线 / 斐波那契 / 文字标注;锚点存绝对 bar time + 价格,翻历史不飘线、跨周期共用;按 symbol 持久化,支持磁吸 OHLC、拖拽编辑
  • 仓位参考线:入场 / 止盈 / 止损 / 强平线,多空色系区分,信息写在线尾小签不占 y 轴
  • 历史成交标记:按 K 线聚合成 B/S 上标角标,点击弹出逐笔买卖价
  • 最新价轴标签换成「价格 + 收盘倒计时」合体框,MACD / RSI 副图各自可开关
  • 修复移动端展示问题

全仓风控与性能

  • 全仓强平安全带:为账户算出安全价格带,带内 tick 零 DB 免检直接放行;插针价钉住判定与结算;杠杆与仓位变更走纪元失效,加仓两条路径同步刷新用户索引
  • 全仓 tick 巡检优化:snapshot 三查合一、巡检池 10→15

首页与体验

  • 月度盈亏网格替换 AI 波动画像卡:按月逐日盈亏格子,点击看当日五分类拆解
  • 现货卖出即时到账
  • 排版优化:快捷入口收进总资产卡、快讯与成交 2:1 分栏、小字号全站放大一档

AI 行为分析

  • 股票维度换轨 bstock:GBM 股票/期权残留全删,crypto 统计剔除 bstock 混入,新增 bstock 全链路统计
  • 合约维度分品类:crypto / 大宗 / tradfi 按五分类同源符号集归桶,未知符号入 crypto 默认桶
  • LLM 失败负缓存 2 分钟,钝化失败后的重试风暴,信号量拒绝不入负缓存

基建

  • JDK 21 升级到 25

Full Changelog: v2.0.0...v2.0.1

v2.0.0

Choose a tag to compare

@mamawai mamawai released this 28 Jul 17:35

v2.0.0 — 框架大版本升级 + 资金账本

本版跨度 4ba31a0...f14e7e1。主线两件事:整站迁到 Spring Boot 4 / Spring AI 2.0 / langgraph4j,以及从零建起一套完整的资金账本。

框架升级

大版本号的由来。common / feed / sim / quant 四个模块分两阶段迁到 Spring Boot 4,AI 侧换成 Spring AI 2.0 + langgraph4j 编排,对话链路重新打通。

资金账本

新增 ledger 表与全链路记账,每一笔资金变动都有据可查。

  • 余额写入收口:资金方法统一改 RETURNING 拿变动后余额,并禁止 user 资金字段随实体更新,堵住 updateById 整行覆写余额的路径
  • 记账切面全量兜底落账,覆盖开仓平仓、爆仓、资金费、初始资金与账户重置
  • 新增账单查询接口 GET /api/ledger 与前端资金账单页
  • 删除 wallet_transfer 双轨表

交易与行情

  • 合约仓位历史
  • 排行榜重构:分页、多维排序与用户详情页
  • K 线新增 4h / 1d 周期,支持左拖翻历史
  • 全站匿名成交页
  • 支持双端登录

性能

  • bStock 行情接实时流,去掉 /bstock/list 的 8 秒轮询
  • 爆仓卡免 COUNT 全表扫、orderflow 按窗口读

关键修复

  • 策略冷 seed 移出 computeIfAbsent,此前虚拟线程 pinning 会导致进程假死
  • 修复 Spring Boot 4 迁移回归:futures 触发索引强转抛 CCE
  • 深研判确认轮直通汇总不再重派专家,触发条件收紧为显式请求

Full Changelog: https://github.com/mamawai/wtfibought/commits/v2.0.0