rote-cli 0.15.0__tar.gz → 0.16.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (165) hide show
  1. {rote_cli-0.15.0 → rote_cli-0.16.0}/LICENSE +12 -11
  2. {rote_cli-0.15.0 → rote_cli-0.16.0}/PKG-INFO +32 -7
  3. {rote_cli-0.15.0 → rote_cli-0.16.0}/README.md +25 -6
  4. {rote_cli-0.15.0 → rote_cli-0.16.0}/examples/expense-audit/README.md +1 -0
  5. rote_cli-0.16.0/examples/expense-audit/fidelity/cases.yaml +68 -0
  6. rote_cli-0.16.0/examples/expense-audit/fidelity/reference.json +793 -0
  7. {rote_cli-0.15.0 → rote_cli-0.16.0}/examples/expense-audit/runs/2026-10-18-first-agent-run/eval.yaml +1 -1
  8. {rote_cli-0.15.0 → rote_cli-0.16.0}/examples/expense-audit/runs/2026-10-18-first-agent-run/pipeline.yaml +1 -1
  9. rote_cli-0.16.0/examples/expense-audit/skill/sample-input.json +25 -0
  10. {rote_cli-0.15.0 → rote_cli-0.16.0}/pyproject.toml +8 -0
  11. rote_cli-0.16.0/skills/rote-compile/GENERATE.md +168 -0
  12. {rote_cli-0.15.0 → rote_cli-0.16.0}/skills/rote-compile/SKILL.md +92 -35
  13. rote_cli-0.16.0/skills/rote-compile/SYSTEM1.md +105 -0
  14. {rote_cli-0.15.0 → rote_cli-0.16.0}/skills/rote-compile/references/crystallization-heuristics.md +9 -8
  15. {rote_cli-0.15.0 → rote_cli-0.16.0}/skills/rote-compile/references/implementation.md +120 -39
  16. {rote_cli-0.15.0 → rote_cli-0.16.0}/skills/rote-compile/references/ir-schema.md +36 -0
  17. {rote_cli-0.15.0 → rote_cli-0.16.0}/skills/rote-compile/references/llm-judge-extraction.md +23 -6
  18. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/__init__.py +1 -1
  19. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/adapters/_common.py +125 -14
  20. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/adapters/_py_common.py +163 -13
  21. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/adapters/_ts_common.py +409 -85
  22. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/adapters/cloudflare.py +20 -9
  23. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/adapters/dbos.py +71 -12
  24. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/adapters/dbos_ts.py +25 -4
  25. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/adapters/inngest.py +6 -4
  26. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/adapters/python.py +29 -36
  27. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/adapters/temporal.py +15 -0
  28. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/app_registry.py +3 -2
  29. rote_cli-0.16.0/src/rote/bench/__init__.py +13 -0
  30. rote_cli-0.16.0/src/rote/bench/collect.py +375 -0
  31. rote_cli-0.16.0/src/rote/bench/fidelity.py +828 -0
  32. rote_cli-0.16.0/src/rote/bench/fidelity_score.py +632 -0
  33. rote_cli-0.16.0/src/rote/bench/fixture_mcp.py +138 -0
  34. rote_cli-0.16.0/src/rote/bench/http_fixtures.py +186 -0
  35. rote_cli-0.16.0/src/rote/bench/report.py +279 -0
  36. rote_cli-0.16.0/src/rote/bench/runner.py +776 -0
  37. rote_cli-0.16.0/src/rote/bench/score.py +776 -0
  38. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/cli.py +733 -57
  39. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/cloud_auth.py +2 -3
  40. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/compiler/__init__.py +653 -45
  41. rote_cli-0.16.0/src/rote/compiler/_prefix_runner.py +329 -0
  42. rote_cli-0.16.0/src/rote/compiler/api_docs.py +432 -0
  43. rote_cli-0.16.0/src/rote/compiler/backend.py +59 -0
  44. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/compiler/drivers/__init__.py +59 -0
  45. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/compiler/drivers/_fs_tools.py +77 -31
  46. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/compiler/drivers/anthropic_api.py +387 -26
  47. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/compiler/drivers/claude.py +179 -16
  48. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/compiler/drivers/codex.py +105 -3
  49. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/compiler/drivers/openai_api.py +121 -33
  50. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/compiler/events.py +4 -0
  51. rote_cli-0.16.0/src/rote/compiler/grounding.py +740 -0
  52. rote_cli-0.16.0/src/rote/compiler/prefix.py +467 -0
  53. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/compiler/provenance.py +95 -53
  54. rote_cli-0.16.0/src/rote/compiler/report.py +282 -0
  55. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/compiler/sandbox.py +14 -5
  56. rote_cli-0.16.0/src/rote/compiler/system1/__init__.py +411 -0
  57. rote_cli-0.16.0/src/rote/compiler/system1/checker.py +110 -0
  58. rote_cli-0.16.0/src/rote/compiler/system1/decide.py +1127 -0
  59. rote_cli-0.16.0/src/rote/compiler/system1/decision_model.py +500 -0
  60. rote_cli-0.16.0/src/rote/compiler/system1/enforce.py +329 -0
  61. rote_cli-0.16.0/src/rote/compiler/system1/evidence.py +117 -0
  62. rote_cli-0.16.0/src/rote/compiler/system1/generate.py +1786 -0
  63. rote_cli-0.16.0/src/rote/compiler/system1/lane_call.py +238 -0
  64. rote_cli-0.16.0/src/rote/compiler/system1/parse.py +632 -0
  65. rote_cli-0.16.0/src/rote/compiler/system1/skeleton.py +437 -0
  66. rote_cli-0.16.0/src/rote/compiler/system1/structure.py +1886 -0
  67. rote_cli-0.16.0/src/rote/compiler/system1/tiebreak.py +430 -0
  68. rote_cli-0.16.0/src/rote/compiler/tool_grounding.py +792 -0
  69. rote_cli-0.16.0/src/rote/compiler/verify.py +1126 -0
  70. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/config.py +72 -4
  71. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/contracts.py +26 -6
  72. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/eval/baseline.py +11 -3
  73. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/eval/empirical.py +66 -14
  74. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/eval/pricing.py +83 -3
  75. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/inference/__init__.py +8 -0
  76. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/inference/_runtime_helper.py +657 -64
  77. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/init_wizard.py +44 -2
  78. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/ir.py +55 -2
  79. rote_cli-0.16.0/src/rote/isolation.py +75 -0
  80. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/mcp/_runtime_helper.py +158 -18
  81. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/mcp/live_tools.py +11 -9
  82. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/mcp/registry.py +34 -3
  83. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/mcp/tokens.py +2 -3
  84. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/probe.py +29 -6
  85. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/runners/__init__.py +99 -10
  86. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/runners/cloudflare.py +14 -1
  87. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/runners/dbos_ts.py +3 -1
  88. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/serve/backends.py +5 -10
  89. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/serve/registry.py +51 -2
  90. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/serve/server.py +298 -25
  91. rote_cli-0.16.0/src/rote/tool_schema.py +199 -0
  92. rote_cli-0.16.0/src/rote/vendor_specs/__init__.py +23 -0
  93. rote_cli-0.16.0/src/rote/vendor_specs/check.py +995 -0
  94. rote_cli-0.16.0/src/rote/vendor_specs/deps.py +210 -0
  95. rote_cli-0.16.0/src/rote/vendor_specs/docs.py +223 -0
  96. rote_cli-0.16.0/src/rote/vendor_specs/extract.py +1012 -0
  97. rote_cli-0.16.0/src/rote/vendor_specs/fake.py +208 -0
  98. rote_cli-0.16.0/src/rote/vendor_specs/fixture_store.py +91 -0
  99. rote_cli-0.16.0/src/rote/vendor_specs/fixtures.py +127 -0
  100. rote_cli-0.16.0/src/rote/vendor_specs/google.py +249 -0
  101. rote_cli-0.16.0/src/rote/vendor_specs/graphql.py +385 -0
  102. rote_cli-0.16.0/src/rote/vendor_specs/intercept/sitecustomize.py +219 -0
  103. rote_cli-0.16.0/src/rote/vendor_specs/live.py +880 -0
  104. rote_cli-0.16.0/src/rote/vendor_specs/model.py +203 -0
  105. rote_cli-0.16.0/src/rote/vendor_specs/openapi.py +380 -0
  106. rote_cli-0.16.0/src/rote/vendor_specs/psl.py +90 -0
  107. rote_cli-0.16.0/src/rote/vendor_specs/public_suffix_list.dat +16559 -0
  108. rote_cli-0.16.0/src/rote/vendor_specs/schema.py +80 -0
  109. rote_cli-0.16.0/src/rote/vendor_specs/store.py +274 -0
  110. rote_cli-0.16.0/src/rote/xdg.py +39 -0
  111. rote_cli-0.15.0/src/rote/compiler/verify.py +0 -636
  112. {rote_cli-0.15.0 → rote_cli-0.16.0}/.gitignore +0 -0
  113. {rote_cli-0.15.0 → rote_cli-0.16.0}/examples/expense-audit/eval-input.json +0 -0
  114. {rote_cli-0.15.0 → rote_cli-0.16.0}/examples/expense-audit/expected/eval.yaml +0 -0
  115. {rote_cli-0.15.0 → rote_cli-0.16.0}/examples/expense-audit/expected/extracted/audit.py +0 -0
  116. {rote_cli-0.15.0 → rote_cli-0.16.0}/examples/expense-audit/expected/extracted/checks.py +0 -0
  117. {rote_cli-0.15.0 → rote_cli-0.16.0}/examples/expense-audit/expected/extracted/fx.py +0 -0
  118. {rote_cli-0.15.0 → rote_cli-0.16.0}/examples/expense-audit/expected/extracted/report.py +0 -0
  119. {rote_cli-0.15.0 → rote_cli-0.16.0}/examples/expense-audit/expected/pipeline-draft.yaml +0 -0
  120. {rote_cli-0.15.0 → rote_cli-0.16.0}/examples/expense-audit/expected/pipeline.yaml +0 -0
  121. {rote_cli-0.15.0 → rote_cli-0.16.0}/examples/expense-audit/input.json +0 -0
  122. {rote_cli-0.15.0 → rote_cli-0.16.0}/examples/expense-audit/runs/2026-10-18-first-agent-run/compile-metrics.json +0 -0
  123. {rote_cli-0.15.0 → rote_cli-0.16.0}/examples/expense-audit/runs/2026-10-18-first-agent-run/compile-report.md +0 -0
  124. {rote_cli-0.15.0 → rote_cli-0.16.0}/examples/expense-audit/runs/2026-10-18-first-agent-run/extracted/checks.py +0 -0
  125. {rote_cli-0.15.0 → rote_cli-0.16.0}/examples/expense-audit/runs/2026-10-18-first-agent-run/extracted/fx.py +0 -0
  126. {rote_cli-0.15.0 → rote_cli-0.16.0}/examples/expense-audit/runs/2026-10-18-first-agent-run/extracted/policy.py +0 -0
  127. {rote_cli-0.15.0 → rote_cli-0.16.0}/examples/expense-audit/runs/2026-10-18-first-agent-run/extracted/report.py +0 -0
  128. {rote_cli-0.15.0 → rote_cli-0.16.0}/examples/expense-audit/runs/2026-10-18-first-agent-run/extracted/save.py +0 -0
  129. {rote_cli-0.15.0 → rote_cli-0.16.0}/examples/expense-audit/runs/2026-10-18-first-agent-run/provenance.json +0 -0
  130. {rote_cli-0.15.0 → rote_cli-0.16.0}/examples/expense-audit/scorecard.md +0 -0
  131. {rote_cli-0.15.0 → rote_cli-0.16.0}/examples/expense-audit/skill/SKILL.md +0 -0
  132. {rote_cli-0.15.0 → rote_cli-0.16.0}/examples/expense-audit/skill/references/expense-policy.md +0 -0
  133. {rote_cli-0.15.0 → rote_cli-0.16.0}/examples/expense-audit/skill/references/fx-rates.md +0 -0
  134. {rote_cli-0.15.0 → rote_cli-0.16.0}/examples/expense-audit/skill/references/report-format.md +0 -0
  135. {rote_cli-0.15.0 → rote_cli-0.16.0}/skills/rote-compile/references/eval-estimates.md +0 -0
  136. {rote_cli-0.15.0 → rote_cli-0.16.0}/skills/rote-compile/references/node-kinds.md +0 -0
  137. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/__main__.py +0 -0
  138. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/_dbos.py +0 -0
  139. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/adapters/__init__.py +0 -0
  140. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/cloud_compile.py +0 -0
  141. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/compiler/drivers/_heartbeat.py +0 -0
  142. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/compiler/update.py +0 -0
  143. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/deploy.py +0 -0
  144. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/deploy_rote_cloud.py +0 -0
  145. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/eval/__init__.py +0 -0
  146. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/eval/estimate.py +0 -0
  147. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/eval/infra_pricing.py +0 -0
  148. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/eval/priors.py +0 -0
  149. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/eval/scorecard.py +0 -0
  150. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/eval/sidecar.py +0 -0
  151. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/eval/tokens.py +0 -0
  152. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/examples.py +0 -0
  153. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/extras.py +0 -0
  154. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/mcp/__init__.py +0 -0
  155. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/mcp/auth.py +0 -0
  156. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/mcp/client_metadata.json +0 -0
  157. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/mcp/learned.py +0 -0
  158. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/mcp/parked.py +0 -0
  159. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/mcp/release.py +0 -0
  160. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/py.typed +0 -0
  161. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/runners/_node.py +0 -0
  162. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/runners/inngest.py +0 -0
  163. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/runners/temporal.py +0 -0
  164. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/serve/__init__.py +0 -0
  165. {rote_cli-0.15.0 → rote_cli-0.16.0}/src/rote/skill_source.py +0 -0
@@ -1,3 +1,4 @@
1
+
1
2
  Apache License
2
3
  Version 2.0, January 2004
3
4
  http://www.apache.org/licenses/
@@ -137,8 +138,8 @@
137
138
 
138
139
  6. Trademarks. This License does not grant permission to use the trade
139
140
  names, trademarks, service marks, or product names of the Licensor,
140
- except as required for describing the origin of the Work and
141
- reproducing the content of the NOTICE file.
141
+ except as required for reasonable and customary use in describing the
142
+ origin of the Work and reproducing the content of the NOTICE file.
142
143
 
143
144
  7. Disclaimer of Warranty. Unless required by applicable law or
144
145
  agreed to in writing, Licensor provides the Work (and each
@@ -163,15 +164,15 @@
163
164
  has been advised of the possibility of such damages.
164
165
 
165
166
  9. Accepting Warranty or Additional Liability. While redistributing
166
- the Work or Derivative Works thereof, You may accept and charge a
167
- fee for acceptance of support, warranty, indemnity, or other liability
168
- obligations and/or rights consistent with this License. However, in
169
- accepting such obligations, You may act only on Your own behalf and on
170
- Your sole responsibility, not on behalf of any other Contributor, and
171
- only if You agree to indemnify, defend, and hold each Contributor
172
- harmless for any liability incurred by, or claims asserted against,
173
- such Contributor by reason of your accepting any such warranty or
174
- additional liability.
167
+ the Work or Derivative Works thereof, You may choose to offer,
168
+ and charge a fee for, acceptance of support, warranty, indemnity,
169
+ or other liability obligations and/or rights consistent with this
170
+ License. However, in accepting such obligations, You may act only
171
+ on Your own behalf and on Your sole responsibility, not on behalf
172
+ of any other Contributor, and only if You agree to indemnify,
173
+ defend, and hold each Contributor harmless for any liability
174
+ incurred by, or claims asserted against, such Contributor by reason
175
+ of your accepting any such warranty or additional liability.
175
176
 
176
177
  END OF TERMS AND CONDITIONS
177
178
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.5
2
2
  Name: rote-cli
3
- Version: 0.15.0
3
+ Version: 0.16.0
4
4
  Summary: Compile AI agent skills into cheap, fast, deterministic pipelines that run without an LLM in the loop
5
5
  Project-URL: Homepage, https://roteskills.com
6
6
  Project-URL: Repository, https://github.com/trevhud/rote
@@ -24,6 +24,7 @@ Classifier: Topic :: Software Development :: Code Generators
24
24
  Classifier: Topic :: Software Development :: Libraries :: Python Modules
25
25
  Classifier: Typing :: Typed
26
26
  Requires-Python: >=3.11
27
+ Requires-Dist: graphql-core<4,>=3.3
27
28
  Requires-Dist: pydantic>=2.7
28
29
  Requires-Dist: pytest<10,>=9.0
29
30
  Requires-Dist: pyyaml>=6.0
@@ -35,10 +36,15 @@ Provides-Extra: dev
35
36
  Requires-Dist: anthropic>=1.15; extra == 'dev'
36
37
  Requires-Dist: dbos<4,>=3.3; extra == 'dev'
37
38
  Requires-Dist: fastmcp<5,>=4.1.1; extra == 'dev'
39
+ Requires-Dist: google-api-python-client>=2.201.0; extra == 'dev'
40
+ Requires-Dist: google-auth-httplib2>=0.4.4; extra == 'dev'
41
+ Requires-Dist: google-auth>=2.62.0; extra == 'dev'
42
+ Requires-Dist: httplib2>=0.32.0; extra == 'dev'
38
43
  Requires-Dist: httpx>=0.28; extra == 'dev'
39
44
  Requires-Dist: mypy>=1.10; extra == 'dev'
40
45
  Requires-Dist: openai>=2.45; extra == 'dev'
41
46
  Requires-Dist: pytest-asyncio>=0.23; extra == 'dev'
47
+ Requires-Dist: requests>=2.34.2; extra == 'dev'
42
48
  Requires-Dist: ruff>=0.6; extra == 'dev'
43
49
  Requires-Dist: temporalio>=1.7; extra == 'dev'
44
50
  Requires-Dist: trustme>=1.2.1; extra == 'dev'
@@ -238,13 +244,27 @@ and want to run a thousand more, unattended.
238
244
 
239
245
  ## How it works
240
246
 
241
- One `rote compile` run does the whole thing. An LLM agent (itself
242
- defined as a skill) reads the source skill, applies a structured
243
- compilation rubric, and emits a runtime-agnostic intermediate
244
- representation (`pipeline.yaml`), extracted Python modules for the
245
- deterministic parts, typed signature stubs for the LLM-judge parts, and
247
+ One `rote compile` run does the whole thing. First rote decides the
248
+ pipeline's structure: which nodes exist and of which kind, how they are
249
+ wired, which run once per item, which are mandatory, where a person must
250
+ approve, and which constants they carry (System-1, see
251
+ [`docs/design/system1-compile.md`](docs/design/system1-compile.md)). One
252
+ Claude Haiku call reads the whole skill and proposes that structure, and
253
+ rote checks every node against the skill's text, its tools' schemas and
254
+ the sample input before accepting it. `--structure rules` decides it with
255
+ rules over the skill's text instead, with no model call.
256
+ Then an LLM agent (itself defined as a skill) writes only the text those
257
+ decisions need: the extracted Python modules for the deterministic
258
+ parts, their tests, and the typed signatures and prompts for the
259
+ LLM-judge parts. rote holds the agent to its decisions, and emits a
260
+ runtime-agnostic intermediate representation (`pipeline.yaml`) plus
246
261
  runnable code for the durable execution engine of your choice.
247
262
 
263
+ `--no-system1` runs the original path instead, where the agent applies
264
+ the full compilation rubric and decides the structure too. `--update`
265
+ always uses that path, because System-1 does not support incremental
266
+ re-compilation yet.
267
+
248
268
  The agent implements the deterministic `pure_function` steps the skill
249
269
  spells out and writes tests for them. Before the compile reports
250
270
  success, rote checks what the agent wrote and runs those tests, and any
@@ -443,7 +463,7 @@ through your API credentials.
443
463
  - **`rote config`**: print every configurable default with its
444
464
  effective value *and the layer that set it*. Resolution everywhere is
445
465
  `flag > ROTE_* env (ROTE_RUNTIME, ROTE_DEPLOY, ROTE_AGENT,
446
- ROTE_MODEL) > project rote.yaml > user config > built-in`. Config
466
+ ROTE_MODEL, ROTE_EFFORT) > project rote.yaml > user config > built-in`. Config
447
467
  files are strict: a typo'd key or value is a loud error, never a
448
468
  silent fallback. `--json` for automation.
449
469
  - **`rote eval <compiled>`**: render the before/after scorecard (wall
@@ -484,6 +504,11 @@ way, prefer the more deterministic kind.
484
504
  Pick with `--runtime`; the same IR drives all of them. Under
485
505
  `--backend api`, none of the emitted code references MCP: the
486
506
  crystallization step replaces tool calls with direct vendor API calls.
507
+ The compiler agent gets web search and fetch tools for that, writes each
508
+ call from the vendor's current reference page, and cites the page as
509
+ `# docs: <url>`; `compile-report.md` lists every cited page beside
510
+ whether the agent fetched it during the compile. The api backend's calls
511
+ are Python, so it needs a Python runtime (`dbos`, `python`, `temporal`).
487
512
  Under the default `--backend mcp`, tool-using nodes emit a working MCP
488
513
  client call (with durable park-on-auth on every MCP-capable runtime);
489
514
  see [`docs/mcp-client.md`](docs/mcp-client.md).
@@ -181,13 +181,27 @@ and want to run a thousand more, unattended.
181
181
 
182
182
  ## How it works
183
183
 
184
- One `rote compile` run does the whole thing. An LLM agent (itself
185
- defined as a skill) reads the source skill, applies a structured
186
- compilation rubric, and emits a runtime-agnostic intermediate
187
- representation (`pipeline.yaml`), extracted Python modules for the
188
- deterministic parts, typed signature stubs for the LLM-judge parts, and
184
+ One `rote compile` run does the whole thing. First rote decides the
185
+ pipeline's structure: which nodes exist and of which kind, how they are
186
+ wired, which run once per item, which are mandatory, where a person must
187
+ approve, and which constants they carry (System-1, see
188
+ [`docs/design/system1-compile.md`](docs/design/system1-compile.md)). One
189
+ Claude Haiku call reads the whole skill and proposes that structure, and
190
+ rote checks every node against the skill's text, its tools' schemas and
191
+ the sample input before accepting it. `--structure rules` decides it with
192
+ rules over the skill's text instead, with no model call.
193
+ Then an LLM agent (itself defined as a skill) writes only the text those
194
+ decisions need: the extracted Python modules for the deterministic
195
+ parts, their tests, and the typed signatures and prompts for the
196
+ LLM-judge parts. rote holds the agent to its decisions, and emits a
197
+ runtime-agnostic intermediate representation (`pipeline.yaml`) plus
189
198
  runnable code for the durable execution engine of your choice.
190
199
 
200
+ `--no-system1` runs the original path instead, where the agent applies
201
+ the full compilation rubric and decides the structure too. `--update`
202
+ always uses that path, because System-1 does not support incremental
203
+ re-compilation yet.
204
+
191
205
  The agent implements the deterministic `pure_function` steps the skill
192
206
  spells out and writes tests for them. Before the compile reports
193
207
  success, rote checks what the agent wrote and runs those tests, and any
@@ -386,7 +400,7 @@ through your API credentials.
386
400
  - **`rote config`**: print every configurable default with its
387
401
  effective value *and the layer that set it*. Resolution everywhere is
388
402
  `flag > ROTE_* env (ROTE_RUNTIME, ROTE_DEPLOY, ROTE_AGENT,
389
- ROTE_MODEL) > project rote.yaml > user config > built-in`. Config
403
+ ROTE_MODEL, ROTE_EFFORT) > project rote.yaml > user config > built-in`. Config
390
404
  files are strict: a typo'd key or value is a loud error, never a
391
405
  silent fallback. `--json` for automation.
392
406
  - **`rote eval <compiled>`**: render the before/after scorecard (wall
@@ -427,6 +441,11 @@ way, prefer the more deterministic kind.
427
441
  Pick with `--runtime`; the same IR drives all of them. Under
428
442
  `--backend api`, none of the emitted code references MCP: the
429
443
  crystallization step replaces tool calls with direct vendor API calls.
444
+ The compiler agent gets web search and fetch tools for that, writes each
445
+ call from the vendor's current reference page, and cites the page as
446
+ `# docs: <url>`; `compile-report.md` lists every cited page beside
447
+ whether the agent fetched it during the compile. The api backend's calls
448
+ are Python, so it needs a Python runtime (`dbos`, `python`, `temporal`).
430
449
  Under the default `--backend mcp`, tool-using nodes emit a working MCP
431
450
  client call (with durable park-on-auth on every MCP-capable runtime);
432
451
  see [`docs/mcp-client.md`](docs/mcp-client.md).
@@ -104,6 +104,7 @@ examples/expense-audit/
104
104
  ├── scorecard.md # measured before/after (rote eval --run)
105
105
  ├── skill/
106
106
  │ ├── SKILL.md # the source skill, as an agent would run it
107
+ │ ├── sample-input.json # the sample run `rote compile` grounds its contracts in
107
108
  │ └── references/
108
109
  │ ├── expense-policy.md # caps, receipts, severities
109
110
  │ ├── fx-rates.md # finance month-end rates
@@ -0,0 +1,68 @@
1
+ # Behavioral fidelity cases for `rote bench` (docs/compile-bench.md).
2
+ #
3
+ # The skill runs as an agent on each case (the committed reference.json),
4
+ # and each compiled pipeline runs on the same cases. Every case has more
5
+ # than one employee and more than one finding, so a fan-out or a check that
6
+ # silently does nothing cannot pass. The controller's decisions are fixed.
7
+
8
+ output_fields:
9
+ period: the reporting period, YYYY-MM
10
+ batch_total_usd: the whole batch total in USD, a number
11
+ auto_approved_employees: list of the names of the employees whose reports were auto-approved
12
+ duplicate_ids: list of the expense ids flagged as duplicates
13
+ late_ids: list of the expense ids flagged as late
14
+ blocked_ids: list of the expense ids with at least one block finding
15
+ review_queue: >-
16
+ the review queue, a list with one object per finding, each with
17
+ `expense_id`, `employee` and `severity` (block or review)
18
+ reimbursable_usd: the reimbursable total in USD after the controller's decisions, a number
19
+ returned_usd: the total returned to employees in USD, a number
20
+ pending_usd: the total still pending a decision in USD, a number
21
+ report_status: the status the filed report is marked with (final or draft)
22
+ report_filename: the file name the audit report is saved as
23
+
24
+ cases:
25
+ - id: base
26
+ description: the bundled September batch; the controller approves three review items and rejects one
27
+ input_file: ../input.json
28
+ gates:
29
+ - reviewer: Priya Shah
30
+ approved_ids: [EXP-2403, EXP-2413, EXP-2420]
31
+ rejected_ids: [EXP-2410]
32
+
33
+ - id: second_batch
34
+ description: >-
35
+ the same batch with a missing receipt (block), a line dated after the
36
+ period closed (late), a category the policy does not list (block), and
37
+ an entertainment line that now carries its pre-approval; the controller
38
+ approves two review items and rejects two
39
+ input_file: ../input.json
40
+ input_patches:
41
+ - {set: submissions.13.receipt, value: false}
42
+ - {set: submissions.14.date, value: "2026-10-02"}
43
+ - {set: submissions.8.preapproval_id, value: PA-118}
44
+ - append: submissions
45
+ value:
46
+ id: EXP-2442
47
+ employee: Emi Tanaka
48
+ department: Design
49
+ date: "2026-09-27"
50
+ category: gifts
51
+ merchant: Tokyu Hands
52
+ amount: 4500
53
+ currency: JPY
54
+ receipt: true
55
+ gates:
56
+ - reviewer: Priya Shah
57
+ approved_ids: [EXP-2410, EXP-2440]
58
+ rejected_ids: [EXP-2403, EXP-2413]
59
+
60
+ - id: unknown_currency
61
+ description: a line in a currency the rate table does not list, so the skill must stop before auditing
62
+ input_file: ../input.json
63
+ input_patches:
64
+ - {set: submissions.10.currency, value: CHF}
65
+ gates:
66
+ - reviewer: Priya Shah
67
+ approved_ids: [EXP-2403, EXP-2413, EXP-2420]
68
+ rejected_ids: [EXP-2410]