Fx Monitor
Use the bundled portable checker instead of relying on host-specific scripts.
Workflow
- 1. Run
python3 /home/xhp/.openclaw/workspace/skills/fx-monitor/scripts/check_boc_fx.py. - Parse the key-value output.
- Handle results by
STATUS:
-
ALERT: send one concise Chinese alert message.
-
NO_ALERT: return
NO_REPLY unless the user explicitly asked for a status report.
-
ERROR: report a short Chinese failure message with
MESSAGE.
Output rules
For alert messages:
- - Start with
【汇率告警】. - Include the Bank of China page publish time.
- Mention all triggered conditions naturally in one sentence.
- Prefer the wording pattern
英镑现汇卖出价下跌 ... / 港币现汇买入价上涨 ... / 日元现汇卖出价下跌 .... - Include comparison values when available.
If the user asks for a normal status report instead of an alert-only run, include:
- - whether an alert triggered
- current GBP spot sell
- current HKD spot buy
- current JPY spot sell
- page publish time
- whether this run wrote a new history snapshot implicitly from the returned data when relevant
Bundled files
- - Checker script: INLINECODE11
- Default history CSV: INLINECODE12
Notes
- - The checker fetches the public Bank of China FX page directly and stores snapshots locally.
- The first successful run usually creates the baseline history row and returns
NO_ALERT; comparison-based alerts begin once at least two snapshots exist. - If the task is about cron management, keep only the FX monitor cron enabled unless the user asks otherwise.
- If a user wants custom thresholds or another history file path, pass CLI flags instead of editing the script first.
Fx Monitor
使用捆绑的可移植检查器,而非依赖特定主机的脚本。
工作流程
- 1. 运行 python3 /home/xhp/.openclaw/workspace/skills/fx-monitor/scripts/checkbocfx.py。
- 解析键值对输出。
- 根据 STATUS 处理结果:
- ALERT:发送一条简洁的中文告警消息。
- NO
ALERT:返回 NOREPLY,除非用户明确要求状态报告。
- ERROR:报告一条简短的中文失败消息,包含 MESSAGE。
输出规则
对于告警消息:
- - 以 【汇率告警】 开头。
- 包含中国银行页面发布时间。
- 用一句话自然提及所有触发条件。
- 优先使用 英镑现汇卖出价下跌 ... / 港币现汇买入价上涨 ... / 日元现汇卖出价下跌 ... 的措辞模式。
- 在可用时包含比较值。
如果用户要求的是普通状态报告而非仅告警运行,则需包含:
- - 是否触发了告警
- 当前英镑现汇卖出价
- 当前港币现汇买入价
- 当前日元现汇卖出价
- 页面发布时间
- 本次运行是否根据返回数据隐式写入了新的历史快照(如相关)
捆绑文件
- - 检查器脚本:/home/xhp/.openclaw/workspace/skills/fx-monitor/scripts/checkbocfx.py
- 默认历史CSV:/home/xhp/.openclaw/workspace/skills/fx-monitor/data/bocfxhistory.csv
注意事项
- - 检查器直接获取中国银行公开外汇页面,并在本地存储快照。
- 首次成功运行通常会创建基准历史行并返回 NO_ALERT;基于比较的告警在至少存在两个快照后才会开始。
- 如果任务涉及cron管理,除非用户另有要求,否则仅保留外汇监控cron。
- 如果用户想要自定义阈值或其他历史文件路径,请优先传递CLI标志,而非直接编辑脚本。