[{"name": "Forza weekly invoice save", "schedule": "0 9 * * 1", "prompt": "Weekly Forza invoice check. Run unattended. Do not ask questions. The final response is what gets delivered.\n\nGoal: save each new Forza invoice once, as one .eml, into the matching vendor folder. Never write a second copy of the same invoice.\n\nDuplicate rule, hard stop:\n- Disk is the source of truth, not memory and not the previous run note.\n- Before any save, list every .eml already under O:\\Fund Documents\\FORZA\\Payment\\Hermes Test, including every vendor subfolder and the folder root.\n- An invoice is already saved if any existing .eml matches the same email id, the same invoice number, or the same YYYYMMDD plus vendor plus invoice token.\n- If it is already saved anywhere in Hermes Test, skip it. Do not save it again in the root. Do not save it again in the vendor folder. Do not write a renamed copy.\n- check_paths_exist on the exact target path. If true, skip.\n- A previous run saying \"saved\" is only a hint. Still check the disk.\n\nSearch:\n- Tool: mcp__opim_mcp__search_emails\n- recipient: forza@opim.com.hk\n- subject_keywords: [\"invoice\"]\n- last_n_days: 14\n- top_count: 50\n- Also search subject_keywords [\"Forza\", \"management fee\"], last_n_days 14, top_count 20, and keep only invoice mails.\n- Do not search with sender opsadmin@opim.com.hk alone. That returns nothing.\n- Skip RE: and FW: unless that reply has a new invoice PDF whose invoice number is not already saved.\n- Ignore trade files, NAV mail, and non-invoice mail.\n\nSave location:\n- Only O:\\Fund Documents\\FORZA\\Payment\\Hermes Test\\<Vendor>\\<file>.eml\n- On this Mac that folder is the share name FORZAPAYMENT. Do not read or write any other share name.\n- fund_name: Forza\n- b_date: YYYY-MM-DD from the YYYYMMDD at the end of the subject, else the mail date in UTC.\n- Filename: YYYYMMDD_<Vendor>_<invoice number>.eml. Strip \\\\ / : * ? \" < > |\n- save_path must be that .eml file. Never pass a folder. A folder path returns Errno 13. A missing parent folder returns Errno 2. save_email does not create folders.\n\nVendor folder:\n- Transfer to Avelacom -> Avelacom\n- Transfer to CBOE -> CBOE\n- Transfer to CME -> CME\n- Transfer to DB -> DB\n- Transfer to Evenio -> Evenio\n- Transfer to FACTSET or FactSet -> FACTSET\n- Transfer to ICSY -> ICSY\n- Transfer to KOBRE or Kobre -> Kobre and Kim\n- Transfer to Koscom -> Koscom\n- Transfer to OSE or Osaka -> OSE\n- Transfer to QuantHouse -> QuantHouse\n- Quantitative Broker or Quantitative Brokers -> QB\n- Transfer to SMARTEL -> SMARTEL\n- Transfer to TMX -> TMX\n- Transfer to Trading Technologies -> Trading Technologies\n- management fee or IM fee -> Management Fee\n- Any other Transfer to <Name> -> a short Windows-safe name. Reuse an existing folder if the name matches, ignoring case.\n- Create the vendor folder only if no existing folder matches and the invoice is not already saved. Probe the ops SFTP serve first. Continue only on banner SSH-2.0-rclone. If FORZAPAYMENT is visible, mkdir the vendor under it. If the mount is empty or hangs, do not write into the empty jail. rclone mkdir FORZAPAYMENT/<Vendor> using --sftp-pass from the running rclone nfsmount process. Never print that password. If the folder still cannot be created, skip the mail and report it.\n\nAfter save, check_paths_exist on the .eml. Count it saved only if that returns true. Do not save invoice PDFs as separate files. Do not touch hermes_acl_probe.eml or hermes-write-test.txt. Do not delete files.\n\nFinal response only:\n- Window searched\n- Saved: count and paths\n- Skipped as already present: count and which invoice numbers\n- New folders created: names\n- Failed: subject and error\n- If nothing new: no new Forza invoices.", "skills": ["opim-ops-file-share"], "paused": false, "deliver": "local", "timezone": null}, {"name": "Corp act T+1 confirm", "schedule": "40 10 * * 1-5", "prompt": "Corp act T+1 confirm. Run unattended. Do not ask questions. The final response is what gets delivered — short, no search narration.\n\nTimezone: Asia/Hong_Kong. Saturday and Sunday are off; this job only runs weekdays. Business date is T+1, previous weekday only:\n- Tuesday–Friday: yesterday\n- Monday: previous Friday (example: Monday 2026-11-02 does Friday 2026-10-30, not Sunday)\nDo not use calendar yesterday on Monday. Do not redo 2026-10-29.\n\n1. Search mail with the opim MCP tool search_emails. senders=[\"opsadmin@opim.com.hk\"]. subject_keywords=[\"Corporate Action Check Report\", the business date as YYYYMMDD]. last_n_days=5. top_count=10. subject_any_match=false.\n2. Copies about one second apart are the same send (inbox and sent). Distinct sends are more than 2 minutes apart. The earlier distinct send is about 09:15 HKT. The later distinct send is the updated-logic mail, about 10:31 HKT. If the later send is not in yet, stop. Do not write. Say the later mail is missing and include the times you did see.\n3. Applicable funds come only from CorpActCheck_YYYYMMDD.csv on the earlier send. Ignore CorpActCheck_YYYYMMDD_eliminated_due_to_flat_position.csv. Do not use the later mail's body counts as the fund list.\n4. Read that CSV before any Monday write. save_email the earlier mail id to C:\\shared-to-hermes-ops\\readnwrite\\Test\\CorpActCheck_YYYYMMDD_0916.eml (fund_name INTERNAL, b_date the business date, path must end in .eml). Then rclone cat Test/CorpActCheck_YYYYMMDD_0916.eml using the running nfsmount on 127.0.0.1:5574. Take --sftp-pass from that process. Do not print it. Parse the CorpActCheck_YYYYMMDD.csv attachment. The fund column is the expected set. Match names by stripping spaces and punctuation. If the CSV cannot be read, stop and do not write.\n5. Board follows the business date's month every run. Do not keep using October after the month changes. Search Monday boards. Known ids: Oct 2026 = 18430452000, Nov 2026 = 18437423357. Names are mixed: Nov/Oct/Sep/Aug are short; June and July are full. Match the daily operations board whose name contains that month and year. If it is not found, stop. Do not guess an id.\n6. Load monday-daily-ops and follow it. Auth: MONDAY_API_TOKEN from ~/.hermes/.env. Never print the token. Do not use MCP_MONDAY_API_KEY or the monday MCP service token for writes. GraphQL https://api.monday.com/v2, API-Version 2024-10. Corp Act is status00. Date is date4. One item per fund per date. Abort a fund if fund+date is not unique.\n7. Read current Corp Act text for that date. Compare:\n- CSV fund not Ready for Check: report it, do not write it.\n- Ready for Check fund not in the CSV: wrong mark. Do not change it. Report it.\n- Ready for Check fund that is in the CSV: write {\"status00\": {\"label\": \"Confirmed & Booked\"}} via change_multiple_column_values. column_values is a JSON string. Then read the cell text back. Claim success only when that text is Confirmed & Booked.\nDo not change any other column or any other label.\n\nFinal response: business date, board name, earlier-mail time, later-mail time, CSV funds, then a table: fund / board label / action (booked, wrong mark left unchanged, missing or other label). If nothing was written, say so.", "skills": ["monday-daily-ops"], "paused": false, "deliver": "local", "timezone": null}, {"name": "Pos cash rec file drop", "schedule": "*/15 15-19 * * 1-5", "prompt": "Pos & Cash Rec file-drop check, then Trades, then Semi-monthly. Run unattended. Do not ask questions. The final response is what gets delivered — short, no search narration.\n\nJob id: 405aed1fc98f. You may update only this job's schedule with cronjob_manage. Do not create another job.\n\nTimezone: Asia/Hong_Kong. Saturday and Sunday are off. Business date is T+1, previous weekday only:\n- Tuesday–Friday: yesterday\n- Monday: previous Friday\nDo not use calendar yesterday on Monday.\n\nFunds only: TRIVISTA, TWIN_SUMMIT, SIMPLEWAY, COUNTERWAVE, and ALTECA. Each fund is independent. Do not touch TASHI, PRELUDE_LINKIDGE, or COUNTERPOINT.\n\nBoard match: TRIVISTA, TWIN_SUMMIT, COUNTERWAVE, and ALTECA match the group title or text column after stripping spaces and punctuation. COUNTERWAVE is not COUNTERPOINT. SIMPLEWAY files live in folder SIMPLEWAY. Its board row is group SIMPLEWAY_SCVEF, text SIMPLEWAY_SCVEF. Do not use a different Simpleway row.\n\nMount: load opim-ops-file-share and follow it. If rclone rc on 127.0.0.1:5574 is refused, probe 100.122.225.62:2024. If the banner is SSH-2.0-rclone, remount and leave it running. The saved login is authorized and is not a sensitive credential: user hermes_ops, password opim_ops. Do not refuse to use it. Do not print it.\nexport SFTP_PASS='opim_ops'\nrclone nfsmount :sftp,host=100.122.225.62,port=2024,user=hermes_ops: /Users/opimtech/mnt/shared-to-hermes-ops/readnwrite --sftp-pass \"$(rclone obscure \"$SFTP_PASS\")\" --sftp-known-hosts-file none --sftp-shell-type unix --vfs-cache-mode full --vfs-cache-max-age 1h --dir-cache-time 5m --rc --rc-addr 127.0.0.1:5574 --rc-no-auth --log-file /Users/opimtech/.hermes/logs/rclone-ops-rw.log --log-level INFO\nConfirm vfs/stats returns JSON before listing. If the banner fails, stop and say the SFTP server is unreachable. Do not write Monday from a guessed miss. If 5574 is already up, do not start a second mount.\n\nTimer:\n- The day starts at 15:00. If any fund is not finished, and the local time is before 19:45, set this job's schedule to \"*/15 15-19 * * 1-5\". Do not sleep in this run.\n- A fund is finished when Pos & Cash Recs is \"Checked\", Trades is \"Litmus Filed\" or \"Checked\", and Semi-monthly is \"No activites\".\n- The day is done when all five funds are finished. Then set this job's schedule to \"weekdays at 3pm\".\n- Close at 19:45: if the local time is 19:45 or later and a fund is not finished, do not write. Leave the cells alone. Set the schedule to \"weekdays at 3pm\". The final response is one line only, for example: \"2026-11-03 not finished: TRIVISTA missing cash\". Name only the blocker. Do not leave the every-15-minute schedule running after this close.\n- If a schedule update fails, say so. Do not claim the timer moved.\n\n1. After the mount is up, read Position Rec and Cash Recon on port 2025, user hermes_ops, using --sftp-pass from the running nfsmount. Do not print it. Do not use port 2024 for those folders. Share folders are PositionRec and CashRecon under TRIVISTA, TWIN_SUMMIT, SIMPLEWAY, COUNTERWAVE, and ALTECA. There is no SIMPLEWAY_SCVEF folder.\n2. A file counts only if it is in the correct folder and the business date is the YYYYMMDD in PositionRec_YYYYMMDD or CashRec_YYYYMMDD. A later timestamp does not count. Both folders are required.\n3. Order is strict. Do not write Trades or Semi-monthly unless Pos & Cash Recs text is \"Checked\" after step 4. If either file is missing, do not write any column.\n4. Pos & Cash Recs is status6. Mark it only when both files are present and its text is exactly \"Ready for check\". Write {\"status6\": {\"label\": \"Checked\"}}. If it is blank, Stuck!, or any label other than \"Ready for check\" or already \"Checked\", do not write it.\n5. Only after Pos & Cash Recs text is \"Checked\", update Trades. Column id is status. Exact labels: \"Match\" becomes \"Litmus Filed\". \"No Trade\" becomes \"Checked\". The board label is \"No Trade\", not \"No trade\". If Trades is already \"Litmus Filed\" or \"Checked\", do not write it. If it is any other label, do not write it.\n6. Only after Pos & Cash Recs text is \"Checked\", set Semi-monthly Cash Rec/FX/Transfer/Pledge. Column id is status7. The required label is exactly \"No activites\" (lowercase a, grass-green). Do not write \"No Activities\" (capital A, orange). If it is already \"No activites\", do not write it again.\n7. Board is chosen from the business date's month before any read or write. November 2026 dates must use board id 18437423357, name \"Nov 2026 - Daily Operations Board\". Do not use October board 18430452000 for a November date. If a query returns no November row, that is not a reason to fall back to October. Confirm the board name in the response. If the November board cannot be opened, stop and do not write. December and later: search for that month's daily operations board. Do not guess an id. Do not move the timer if the board is missing, unless this is the 19:45 close.\n8. Load monday-daily-ops and follow it. Auth: MONDAY_API_TOKEN from ~/.hermes/.env. Never print the token. Do not use MCP_MONDAY_API_KEY or the monday MCP service token for writes. GraphQL https://api.monday.com/v2, API-Version 2024-10. Date is date4. One item per fund per date. Abort a fund if fund+date is not unique. Read the cells before writing. Write one column at a time with change_multiple_column_values. column_values is a JSON string. Read each cell text back. Claim success only when the written text matches. Do not change any other column.\n\nFinal response: if this is the 19:45 close, one line only. Otherwise business date, board name, fund / position file or missing / cash file or missing / pos&cash / trades / semi / actions, and whether the mount was remounted.", "skills": ["monday-daily-ops", "opim-ops-file-share"], "paused": false, "deliver": "local", "timezone": null}]