AI Agent Workflow
xlflow is designed so agents can work through stable commands instead of the Excel UI.
Recommended loop:
bash
xlflow doctor --json
xlflow session start --json
xlflow pull --session --json
xlflow push --fast --session --no-save --json
xlflow lint --json
xlflow analyze --json
xlflow test --session --json
xlflow macros --session --json
xlflow run Main.Run --headless --session --json
xlflow save --session --json
xlflow session stop --jsonRules for agents:
- Prefer
--json. - Under WSL, keep projects under
/mnt/<drive>/...; Excel-related commands delegate to Windows xlflow. - Run
doctorbefore changing source for environment failures. - Use
macrosbefore guessing aruntarget. - Replace raw
MsgBox/InputBoxwithXlflowUIand pass--msgbox/--inputboxduring unattendedrunortestflows. - Use
inspectandexport-imageto verify workbook output. - Use
XlflowDebug.Logplusxlflow run --jsonorxlflow test --jsonwhen runtime failures are unclear. - Use
backup listandrollbackwhen apushor workbook mutation leaves the workbook in a bad state. - Avoid headless workflows only for truly human-operated raw dialogs or UserForms; simple confirmation and scalar-input flows should move to
XlflowUIfirst.