A first plan
A team wants its monthly sales report. Read the plan in words and then as the file. It is the same plan.
VisionExecutionProof
In words
The wishThe monthly sales report, sent to the team
Step 1 · numbers
What to doExport last month's sales to report/sales.csv.
Who does itAn algorithm runs
export-sales --month last --out report/sales.csvWhat proves itThe command ends without an error.If the command fails, an agent fixes what stands in the way, and the command runs again as the proof.
Step 2 · report
What to doWrite report/report.md from report/sales.csv: the total, the three best products and what changed since the month before.
Who does itAn agent
What proves it
- These must be there:
report/report.md - Another agent must find this true: “Every number in the report is the same as in report/sales.csv.”
- The person answers yes to: “Is this report ready to send?”
Step 3 · send
What to doSend report/report.md to the team.
Who does itAn algorithm runs
send-mail --to team --file report/report.mdWhat proves itThe command ends without an error.
The file
json
{
"$schema": "vpf/1",
"wish": "The monthly sales report, sent to the team",
"limits": {
"repeats": 2
},
"steps": [
{
"id": "numbers",
"do": "Export last month's sales to report/sales.csv.",
"by": "algorithm",
"run": "export-sales --month last --out report/sales.csv",
"on_fail": "agent"
},
{
"id": "report",
"do": "Write report/report.md from report/sales.csv: the total, the three best products and what changed since the month before.",
"by": "agent",
"tools": [
"read",
"write"
],
"proof": [
{
"by": "algorithm",
"needs": [
{
"need": "files",
"path": "report/report.md"
}
]
},
{
"by": "agent",
"check": "Every number in the report is the same as in report/sales.csv."
},
{
"by": "person",
"ask": "Is this report ready to send?"
}
]
},
{
"id": "send",
"do": "Send report/report.md to the team.",
"by": "algorithm",
"run": "send-mail --to team --file report/report.md"
}
]
}What happens when it runs
- A command exports last month's sales. If it fails, an agent fixes what stands in its way, and the command runs again as the proof.
- An agent writes the report. Three proofs stand between its work and the next step: the file must be there, another agent must find every number the same as in the sales, and a person must say it is ready.
- A command sends the report to the team.
If a proof refuses the report, it goes back to the agent with the reasons, and every proof is asked again. After two refused attempts, set by limits.repeats, the person is asked whether to go on.
Next
- Learn the principle behind every plan.
- Write a plan of your own.
- See more examples of everyday work.