@interf/compiler 0.3.0 → 0.3.2

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 (151) hide show
  1. package/README.md +120 -83
  2. package/dist/bin.js +3 -3
  3. package/dist/bin.js.map +1 -1
  4. package/dist/commands/compile.d.ts +11 -0
  5. package/dist/commands/compile.d.ts.map +1 -1
  6. package/dist/commands/compile.js +216 -70
  7. package/dist/commands/compile.js.map +1 -1
  8. package/dist/commands/create-workflow-wizard.d.ts.map +1 -1
  9. package/dist/commands/create-workflow-wizard.js +17 -8
  10. package/dist/commands/create-workflow-wizard.js.map +1 -1
  11. package/dist/commands/create.d.ts.map +1 -1
  12. package/dist/commands/create.js +44 -45
  13. package/dist/commands/create.js.map +1 -1
  14. package/dist/commands/default.d.ts.map +1 -1
  15. package/dist/commands/default.js +27 -31
  16. package/dist/commands/default.js.map +1 -1
  17. package/dist/commands/doctor.js +2 -2
  18. package/dist/commands/doctor.js.map +1 -1
  19. package/dist/commands/executor-flow.d.ts +11 -0
  20. package/dist/commands/executor-flow.d.ts.map +1 -0
  21. package/dist/commands/executor-flow.js +104 -0
  22. package/dist/commands/executor-flow.js.map +1 -0
  23. package/dist/commands/init.d.ts +1 -0
  24. package/dist/commands/init.d.ts.map +1 -1
  25. package/dist/commands/init.js +374 -64
  26. package/dist/commands/init.js.map +1 -1
  27. package/dist/commands/list.js +1 -1
  28. package/dist/commands/list.js.map +1 -1
  29. package/dist/commands/reset.d.ts.map +1 -1
  30. package/dist/commands/reset.js +2 -18
  31. package/dist/commands/reset.js.map +1 -1
  32. package/dist/commands/source-config-wizard.d.ts +6 -7
  33. package/dist/commands/source-config-wizard.d.ts.map +1 -1
  34. package/dist/commands/source-config-wizard.js +151 -78
  35. package/dist/commands/source-config-wizard.js.map +1 -1
  36. package/dist/commands/test-flow.d.ts +22 -0
  37. package/dist/commands/test-flow.d.ts.map +1 -0
  38. package/dist/commands/test-flow.js +129 -0
  39. package/dist/commands/test-flow.js.map +1 -0
  40. package/dist/commands/test.d.ts +4 -0
  41. package/dist/commands/test.d.ts.map +1 -0
  42. package/dist/commands/test.js +133 -0
  43. package/dist/commands/test.js.map +1 -0
  44. package/dist/commands/verify.d.ts.map +1 -1
  45. package/dist/commands/verify.js +7 -3
  46. package/dist/commands/verify.js.map +1 -1
  47. package/dist/commands/workspace-flow.d.ts +21 -0
  48. package/dist/commands/workspace-flow.d.ts.map +1 -0
  49. package/dist/commands/workspace-flow.js +90 -0
  50. package/dist/commands/workspace-flow.js.map +1 -0
  51. package/dist/index.d.ts +1 -1
  52. package/dist/index.d.ts.map +1 -1
  53. package/dist/index.js +1 -1
  54. package/dist/index.js.map +1 -1
  55. package/dist/lib/agent-detection.js +4 -4
  56. package/dist/lib/agent-detection.js.map +1 -1
  57. package/dist/lib/agent-skills.js +6 -6
  58. package/dist/lib/agent-skills.js.map +1 -1
  59. package/dist/lib/benchmark-execution.d.ts.map +1 -1
  60. package/dist/lib/benchmark-execution.js +39 -17
  61. package/dist/lib/benchmark-execution.js.map +1 -1
  62. package/dist/lib/benchmark-sandbox.d.ts +10 -0
  63. package/dist/lib/benchmark-sandbox.d.ts.map +1 -0
  64. package/dist/lib/benchmark-sandbox.js +75 -0
  65. package/dist/lib/benchmark-sandbox.js.map +1 -0
  66. package/dist/lib/benchmark-targets.d.ts +1 -0
  67. package/dist/lib/benchmark-targets.d.ts.map +1 -1
  68. package/dist/lib/benchmark-targets.js +12 -0
  69. package/dist/lib/benchmark-targets.js.map +1 -1
  70. package/dist/lib/benchmark-types.d.ts +1 -1
  71. package/dist/lib/benchmark-types.d.ts.map +1 -1
  72. package/dist/lib/benchmark.d.ts +1 -1
  73. package/dist/lib/benchmark.d.ts.map +1 -1
  74. package/dist/lib/benchmark.js +1 -1
  75. package/dist/lib/benchmark.js.map +1 -1
  76. package/dist/lib/interf-scaffold.d.ts.map +1 -1
  77. package/dist/lib/interf-scaffold.js +2 -1
  78. package/dist/lib/interf-scaffold.js.map +1 -1
  79. package/dist/lib/interf-workflow-package.d.ts.map +1 -1
  80. package/dist/lib/interf-workflow-package.js +7 -2
  81. package/dist/lib/interf-workflow-package.js.map +1 -1
  82. package/dist/lib/local-workflows.d.ts.map +1 -1
  83. package/dist/lib/local-workflows.js +24 -8
  84. package/dist/lib/local-workflows.js.map +1 -1
  85. package/dist/lib/runtime-contracts.d.ts +3 -1
  86. package/dist/lib/runtime-contracts.d.ts.map +1 -1
  87. package/dist/lib/runtime-contracts.js +115 -0
  88. package/dist/lib/runtime-contracts.js.map +1 -1
  89. package/dist/lib/runtime-reconcile.d.ts +2 -1
  90. package/dist/lib/runtime-reconcile.d.ts.map +1 -1
  91. package/dist/lib/runtime-reconcile.js +71 -15
  92. package/dist/lib/runtime-reconcile.js.map +1 -1
  93. package/dist/lib/runtime-runs.js +12 -3
  94. package/dist/lib/runtime-runs.js.map +1 -1
  95. package/dist/lib/runtime-types.d.ts +11 -0
  96. package/dist/lib/runtime-types.d.ts.map +1 -1
  97. package/dist/lib/runtime.d.ts +1 -1
  98. package/dist/lib/runtime.d.ts.map +1 -1
  99. package/dist/lib/runtime.js +1 -1
  100. package/dist/lib/runtime.js.map +1 -1
  101. package/dist/lib/schema.d.ts +36 -9
  102. package/dist/lib/schema.d.ts.map +1 -1
  103. package/dist/lib/schema.js +29 -7
  104. package/dist/lib/schema.js.map +1 -1
  105. package/dist/lib/source-config.d.ts +4 -1
  106. package/dist/lib/source-config.d.ts.map +1 -1
  107. package/dist/lib/source-config.js +23 -4
  108. package/dist/lib/source-config.js.map +1 -1
  109. package/dist/lib/state-health.d.ts +2 -2
  110. package/dist/lib/state-health.d.ts.map +1 -1
  111. package/dist/lib/state-health.js +34 -19
  112. package/dist/lib/state-health.js.map +1 -1
  113. package/dist/lib/state-io.d.ts.map +1 -1
  114. package/dist/lib/state-io.js +6 -0
  115. package/dist/lib/state-io.js.map +1 -1
  116. package/dist/lib/validate-workspace.d.ts +41 -0
  117. package/dist/lib/validate-workspace.d.ts.map +1 -1
  118. package/dist/lib/validate-workspace.js +152 -4
  119. package/dist/lib/validate-workspace.js.map +1 -1
  120. package/dist/lib/validate.d.ts +2 -2
  121. package/dist/lib/validate.d.ts.map +1 -1
  122. package/dist/lib/validate.js +17 -2
  123. package/dist/lib/validate.js.map +1 -1
  124. package/dist/lib/workflow-definitions.d.ts.map +1 -1
  125. package/dist/lib/workflow-definitions.js +42 -20
  126. package/dist/lib/workflow-definitions.js.map +1 -1
  127. package/dist/lib/workflow-helpers.d.ts.map +1 -1
  128. package/dist/lib/workflow-helpers.js +4 -2
  129. package/dist/lib/workflow-helpers.js.map +1 -1
  130. package/dist/lib/workflows.d.ts +2 -2
  131. package/dist/lib/workflows.d.ts.map +1 -1
  132. package/dist/lib/workflows.js +3 -1
  133. package/dist/lib/workflows.js.map +1 -1
  134. package/dist/lib/workspace-compile.d.ts +4 -3
  135. package/dist/lib/workspace-compile.d.ts.map +1 -1
  136. package/dist/lib/workspace-compile.js +199 -100
  137. package/dist/lib/workspace-compile.js.map +1 -1
  138. package/dist/lib/workspace-reset.d.ts +2 -0
  139. package/dist/lib/workspace-reset.d.ts.map +1 -0
  140. package/dist/lib/workspace-reset.js +21 -0
  141. package/dist/lib/workspace-reset.js.map +1 -0
  142. package/package.json +1 -1
  143. package/skills/benchmark/SKILL.md +4 -3
  144. package/skills/workflow/create/SKILL.md +4 -1
  145. package/skills/workspace/shape/SKILL.md +15 -0
  146. package/skills/workspace/structure/SKILL.md +15 -0
  147. package/skills/workspace/summarize/SKILL.md +15 -0
  148. package/dist/commands/benchmark.d.ts +0 -3
  149. package/dist/commands/benchmark.d.ts.map +0 -1
  150. package/dist/commands/benchmark.js +0 -83
  151. package/dist/commands/benchmark.js.map +0 -1
package/README.md CHANGED
@@ -1,19 +1,21 @@
1
1
  # Interf
2
2
 
3
- Open-source knowledge compiler for your files.
3
+ Open-source knowledge compiler for local agents.
4
4
 
5
5
  Interf measures and improves how accurately local agents answer questions from your files.
6
6
 
7
7
  If you use Claude Code, Codex, OpenClaw, Hermes, or your own local agent setup on folders full of PDFs, docs, spreadsheets, and notes, the failure often shows up late: missed evidence, shallow analysis, bad comparisons, or answers that sound confident but are wrong.
8
8
 
9
- Interf lets you write a few questions and expected answers about your files, build a compiled workspace on top of those files, and see whether the result actually passes.
9
+ Interf lets you define a few checks over your files, measure the raw baseline first if you want it, compile a workspace on top of those files, and see whether the result actually passes.
10
10
 
11
11
  - your files stay on your machine
12
12
  - you choose the local agent
13
13
  - your raw files stay the source of truth
14
14
  - Interf adds a file-based layer on top
15
15
 
16
- It runs local data-processing pipelines with your agents as executors and produces a compiled workspace: a file-based layer on top of your raw files that agents can navigate, inspect, and work from.
16
+ `interf compile` runs a local data-processing pipeline with your agents as executors and produces a compiled workspace: a file-based layer on top of your raw files that agents can navigate, inspect, and work from.
17
+
18
+ In the advanced looped mode, Interf can keep rerunning that pipeline, testing the result, and trying improved preparation attempts until it finds the best-performing workspace within the attempt budget.
17
19
 
18
20
  ## Quick Start
19
21
 
@@ -28,7 +30,14 @@ Install:
28
30
  npm install -g @interf/compiler
29
31
  ```
30
32
 
31
- Start by writing a few questions and expected answers in `interf.config.json`:
33
+ The quickest start is the wizard:
34
+
35
+ ```bash
36
+ cd ~/my-folder
37
+ interf
38
+ ```
39
+
40
+ If you want to see the config shape first, this is what Interf writes:
32
41
 
33
42
  ```json
34
43
  {
@@ -36,6 +45,9 @@ Start by writing a few questions and expected answers in `interf.config.json`:
36
45
  {
37
46
  "name": "default",
38
47
  "about": "General compiled workspace for the quarterly results folder.",
48
+ "retry_policy": {
49
+ "max_attempts": 3
50
+ },
39
51
  "checks": [
40
52
  {
41
53
  "question": "What full-year revenue range did the company maintain?",
@@ -51,23 +63,36 @@ Start by writing a few questions and expected answers in `interf.config.json`:
51
63
  }
52
64
  ```
53
65
 
54
- Then run Interf in that folder:
66
+ The root-level flow is:
55
67
 
56
68
  ```bash
57
- cd ~/my-folder
58
- interf init
59
- interf create workspace
69
+ interf
60
70
  interf compile
61
- interf benchmark
71
+ interf test
62
72
  ```
63
73
 
64
- That first run gives you three concrete things:
74
+ The first guided run can:
75
+
76
+ - save a few questions and expected answers for this folder
77
+ - run a baseline test on the raw files
78
+ - compile the workspace
79
+ - optionally keep compiling and retesting until it passes or reaches the attempt limit
80
+ - run the same test against the compiled workspace
81
+
82
+ That gives you three concrete things:
65
83
 
66
84
  - `interf/workspaces/default/` with the compiled workspace for your files
67
- - `interf/benchmarks/runs/...` with the saved benchmark result
85
+ - `interf/benchmarks/runs/...` with the saved test result
68
86
  - a pass/fail score on the same questions and expected answers you wrote
69
87
 
70
- If `interf.config.json` is missing, `interf init` can draft it with you before the first compile. If Interf cannot find your local agent or compile setup, run:
88
+ Saved test runs keep the details you need later:
89
+
90
+ - whether the run tested `raw`, `workspace`, or both
91
+ - per-question pass/fail results
92
+ - the saved run path under `interf/benchmarks/runs/...`
93
+ - executor metadata such as agent, command, model, effort, and profile when available
94
+
95
+ If `interf.config.json` is missing, `interf` or `interf init` can draft it with you before the first compile. If Interf cannot find your local agent or compile setup, run:
71
96
 
72
97
  ```bash
73
98
  interf doctor
@@ -76,10 +101,11 @@ interf doctor
76
101
  The first flow is:
77
102
 
78
103
  - write down a few questions your agent should be able to answer from your files
79
- - let `interf init` save those checks in `interf.config.json`
80
- - run `interf create workspace` and `interf compile` to build the compiled workspace
81
- - run `interf benchmark` to see whether that compiled workspace passes the checks
82
- - add another workspace only when one recurring context needs a narrower setup
104
+ - let `interf` or `interf init` save those checks in `interf.config.json`
105
+ - optionally run a baseline test on the raw files
106
+ - run `interf compile` to build the compiled workspace
107
+ - run `interf test` to test the raw files, the compiled workspace, or both
108
+ - only create another workspace if you want a separate compiled setup with its own checks
83
109
  - if needed, rerun compile or use the advanced retry path until it is good enough
84
110
 
85
111
  ## Why This Approach
@@ -98,27 +124,26 @@ Sample flow:
98
124
  ```bash
99
125
  cp -r examples/benchmark-demo /tmp/interf-demo
100
126
  cd /tmp/interf-demo
101
- interf init
102
- interf create workspace
127
+ interf
103
128
  interf compile
104
- interf benchmark
129
+ interf test
105
130
  ```
106
131
 
107
- ## Start With A Few Questions
132
+ ## Start With Your Own Checks
133
+
134
+ Start with your own checks over the files: questions where you already know the correct answer from the dataset.
108
135
 
109
- `interf.config.json` is where you write the questions and expected answers for a folder.
136
+ `interf.config.json` is where you save those checks for a folder.
110
137
 
111
138
  That file uses one `workspaces` array:
112
139
 
113
- - the first workspace is the default compiled workspace for the folder
114
- - later workspaces are optional and only exist when one recurring context needs a narrower setup
140
+ - most folders only need one workspace
141
+ - add another workspace only if you want a separate compiled setup with different checks
115
142
  - each workspace carries its own `checks`
143
+ - each workspace can optionally carry `retry_policy.max_attempts` for the self-improving compile loop
116
144
 
117
145
  If the file is missing, `interf init` can draft it with you before the first compile. You can edit it any time.
118
146
 
119
- That example is just `interf.config.json`.
120
- Advanced retry settings do not live there.
121
-
122
147
  Good first checks are small and practical:
123
148
 
124
149
  - one exact number from a chart, table, or filing
@@ -128,26 +153,34 @@ Good first checks are small and practical:
128
153
  Then run:
129
154
 
130
155
  ```bash
131
- interf create workspace
132
156
  interf compile
133
- interf benchmark
157
+ interf test
134
158
  ```
135
159
 
136
- ## What `interf benchmark` Compares
160
+ ## What `interf test` Does
137
161
 
138
- `interf benchmark` compares compiled workspaces, not raw chat sessions.
162
+ `interf test` scores either the raw files, a compiled workspace, or both on the same saved checks.
139
163
 
140
164
  It lets you answer a simple question:
141
165
 
142
- - does this compiled workspace pass the checks?
166
+ - what is the current baseline on the raw files?
167
+ - does this compiled workspace improve on that baseline?
143
168
  - which compiled workspace or workflow performs better on the same folder?
144
- - does another workspace help more on a narrower recurring context?
169
+ - does a separate workspace with different checks work better for that job?
170
+
171
+ By default it loads checks from `interf.config.json`, can run a raw baseline in an isolated raw-files sandbox, can test eligible compiled workspaces under `interf/workspaces/`, and saves the run under `interf/benchmarks/runs/`.
172
+
173
+ Each saved run includes:
145
174
 
146
- By default it loads checks from `interf.config.json`, discovers eligible compiled workspaces under `interf/workspaces/`, and saves the run under `interf/benchmarks/runs/`.
175
+ - the benchmark target and mode
176
+ - per-question results and traces
177
+ - the executor metadata for that run
147
178
 
148
- If you run `interf benchmark` from inside a workspace, it uses that workspace's checks. If you run it from the source folder, it uses the default workspace checks.
179
+ If you run `interf test` from inside a workspace, it uses that workspace's checks and tests that workspace. If you run it from the source folder, it lets you choose a saved workspace and then choose raw files, the compiled workspace, or both.
149
180
 
150
- If you need raw-file probes too, use the advanced eval-pack runner in [docs/eval-loop.md](./docs/eval-loop.md).
181
+ Live test runs use an isolated sandbox. For raw baselines, Interf gives the agent sanitized raw files only. For compiled-workspace tests, it gives the agent a copied workspace plus sanitized raw files. The source-folder control plane, `interf.config.json`, and saved test runs are not part of those sandboxes.
182
+
183
+ If you need repeated isolated experiments across workflows or models, use the advanced eval-pack runner in [docs/eval-loop.md](./docs/eval-loop.md).
151
184
 
152
185
  ## What `interf compile` Does
153
186
 
@@ -155,30 +188,35 @@ If you need raw-file probes too, use the advanced eval-pack runner in [docs/eval
155
188
 
156
189
  By default, that means:
157
190
 
158
- - read the files
159
- - write summaries and navigation docs
160
- - organize cross-file knowledge
161
- - build the compiled workspace for the folder
162
- - optionally build additional workspaces for recurring contexts you care about
191
+ - summarize the source files into per-file evidence notes
192
+ - structure the cross-file knowledge layer into entities, claims, and indexes
193
+ - shape the final workspace around its saved focus and questions
194
+
195
+ In other words, the built-in workflow is:
196
+
197
+ 1. `summarize`
198
+ 2. `structure`
199
+ 3. `shape`
163
200
 
164
201
  In public docs, `pipeline` is the thing Interf runs. `workflow` is the saved method that defines or customizes that pipeline.
165
202
 
166
203
  The default workflow is built in. If you want a different method, you can define your own workflow package and benchmark it on the same folder.
167
204
 
205
+ If a workspace has `retry_policy.max_attempts`, or if you run `interf compile --max-attempts <n>`, Interf can keep compiling, testing, and retrying until that workspace passes or reaches the attempt limit. If several attempts fail, Interf keeps the best-performing compiled workspace from that run.
206
+
168
207
  ## What Gets Created
169
208
 
170
209
  After compile, Interf writes into `./interf/` beside your source files.
171
210
 
172
211
  - `interf/workspaces/<name>/` is a compiled workspace over the folder
173
- - `interf/benchmarks/runs/...` stores saved benchmark runs
212
+ - `interf/benchmarks/runs/...` stores saved test runs
174
213
 
175
214
  Inside those workspaces you will see things like:
176
215
 
177
216
  - summaries of source files
178
217
  - navigation notes and entrypoints for agents
179
218
  - cross-file knowledge notes
180
- - workspace-specific outputs for one recurring context
181
- - benchmark artifacts you can inspect later
219
+ - workspace-specific outputs when you define a separate job-focused workspace
182
220
 
183
221
  The compiled workspace is just a normal folder. Open it in your editor, in your agent, or in Obsidian if you want the graph view.
184
222
 
@@ -191,59 +229,56 @@ Public terms:
191
229
  - `your files` = the source folder Interf reads from
192
230
  - `questions and expected answers` = the checks you want your agent to pass
193
231
  - `checks` = the pass/fail questions each workspace should satisfy
194
- - `benchmark` = score compiled workspaces on the same checks
232
+ - `test` = run the saved questions and get a score
195
233
  - `compiled workspace` = the output Interf produces on top of a folder
196
- - `workspace` = an optional additional compiled workspace for one recurring context
234
+ - `workspace` = one compiled setup with its own checks
197
235
 
198
236
  Technical terms:
199
237
 
200
238
  - `source folder` = the raw files Interf reads from
239
+ - `benchmark` = the technical alias and saved-run layer behind `interf test`
201
240
  - `workflow` = the saved method that defines or customizes the pipeline
202
241
  - `.interf/` = runtime state, proofs, and health artifacts
203
242
 
204
- ## Advanced: Additional Workspaces
205
-
206
- Start with the default compiled workspace first.
207
-
208
- Most folders only need one compiled workspace.
209
-
210
- Create another workspace only when one recurring context needs a narrower setup.
211
-
212
- Use the default compiled workspace for broad questions such as:
243
+ ## Advanced: Separate Workspaces
213
244
 
214
- - what is in this folder?
215
- - what changed?
216
- - where is the source evidence?
245
+ Most folders only need one workspace.
217
246
 
218
- Create another workspace when that broad layer is no longer enough and the work becomes a repeatable context, for example:
247
+ Create another only when you want a different compiled setup with different checks, for example:
219
248
 
220
- - operator briefings
221
- - board prep
249
+ - general folder understanding
222
250
  - finance reporting
251
+ - board prep
223
252
  - diligence review
224
- - chart extraction for a report set
225
- - one recurring research set
226
253
 
227
- Why create one:
254
+ Why create another one:
228
255
 
229
- - it narrows what the agent should retrieve for that context
230
- - it prepares guidance and structure on top of the raw folder for that recurring context
231
- - it lets you benchmark that context separately
232
-
233
- If the default compiled workspace is already enough, do not create another workspace yet.
256
+ - it keeps a separate set of questions and expected answers
257
+ - it gives that job its own compiled output under `interf/workspaces/<name>/`
258
+ - it lets you test that job separately
234
259
 
235
260
  ## Advanced: Keep Improving Until It Passes
236
261
 
237
- Interf also supports an advanced experiment path above the normal build + benchmark flow.
262
+ Interf also supports a deeper loop above the normal compile + test flow.
263
+
264
+ The normal workspace flow already supports `retry_policy.max_attempts` inside `interf.config.json` or `interf compile --max-attempts <n>`.
238
265
 
239
- Give it the same folder and the same checks. Interf can keep rerunning compile + benchmark attempts until the benchmark passes or the attempt budget runs out.
266
+ Give it the same folder and the same checks. Interf can keep rerunning compile + test attempts until the test passes or the attempt budget runs out.
267
+
268
+ That loop is the self-improving part of the product:
269
+
270
+ - it reruns the local data-processing pipeline over the same files
271
+ - it keeps the checks fixed, so the target does not move
272
+ - it can vary the compile profile and follow-up diagnostics
273
+ - it records which attempt performed best on the same saved test
240
274
 
241
275
  In practice:
242
276
 
243
- - `retry_policy.max_attempts_per_profile` controls how many attempts each compile profile gets
277
+ - `retry_policy.max_attempts` controls how many total attempts a normal workspace compile gets
278
+ - `retry_policy.max_attempts_per_profile` controls how many attempts each compile profile gets in eval packs
244
279
  - stronger diagnostic profiles can be used only after the default ones fail
245
280
  - the checks stay the same across every attempt
246
- - each attempt records what changed
281
+ - each attempt records what changed and which attempt performed best
247
282
 
248
283
  Example eval-pack shape:
249
284
 
@@ -252,6 +287,9 @@ Example eval-pack shape:
252
287
  "workspaces": [
253
288
  {
254
289
  "name": "default",
290
+ "retry_policy": {
291
+ "max_attempts": 3
292
+ },
255
293
  "checks": [
256
294
  {
257
295
  "question": "What full-year revenue range did the company maintain?",
@@ -260,16 +298,13 @@ Example eval-pack shape:
260
298
  ]
261
299
  }
262
300
  ],
263
- // Advanced only: retry settings live in eval packs, not in interf.config.json.
264
301
  "retry_policy": {
265
302
  "max_attempts_per_profile": 3
266
303
  }
267
304
  }
268
305
  ```
269
306
 
270
- Today this lives in the advanced eval-pack runner, not in `interf.config.json` and not in a top-level `interf compile --max-retries` flag.
271
-
272
- Use the normal benchmark flow first. Use this advanced path when you want Interf to keep improving the local preparation workflow until the workspace is good enough for your task or the attempt budget runs out. It spends more tokens, so use it when that extra spend is worth the accuracy target.
307
+ Use the normal workspace retry loop first. Use the eval-pack path when you want Interf to compare multiple compile profiles, add diagnostics, or keep iterating in a more controlled experiment loop. It spends more tokens, so use it when that extra spend is worth the accuracy target.
273
308
 
274
309
  ## Use It With Your Agent
275
310
 
@@ -278,11 +313,11 @@ If you already work through Claude Code, Codex, OpenClaw, or Hermes, the agent c
278
313
  Paste something like this into your agent:
279
314
 
280
315
  ```text
281
- Install @interf/compiler, run `interf init` in this folder, and use the local agent executor.
316
+ Install @interf/compiler, run `interf` in this folder, and use the local agent executor.
282
317
 
283
- If `interf.config.json` is missing, draft a default workspace with a few checks this agent should be able to answer from these files and add the expected answers for me to confirm.
318
+ If `interf.config.json` is missing, draft one workspace with a few checks this agent should be able to answer from these files and add the expected answers for me to confirm.
284
319
 
285
- Then run `interf create workspace`, `interf compile`, and `interf benchmark`.
320
+ Then run a raw baseline if helpful, compile the workspace, and run `interf test`.
286
321
 
287
322
  Tell me whether the compiled workspace passes the checks, and only recommend it if it does.
288
323
  ```
@@ -304,11 +339,13 @@ Workflow package docs live in [docs/workflow-spec.md](./docs/workflow-spec.md).
304
339
 
305
340
  ## Core Commands
306
341
 
307
- - `interf init` = choose your local executor and draft checks
308
- - `interf create workspace` = create a compiled workspace for this folder
342
+ - `interf` = open the root-folder wizard
343
+ - `interf init` = alias for the root-folder wizard
344
+ - `interf create workspace` = create another compiled workspace when you need one
309
345
  - `interf create workflow` = create a reusable local workflow package
310
- - `interf compile` = build the current compiled workspace
311
- - `interf benchmark` = score compiled workspaces on your checks
346
+ - `interf compile` = build a selected workspace for the current folder
347
+ - `interf test` = test the raw files, a compiled workspace, or both on saved checks
348
+ - `interf benchmark` = alias for `interf test`
312
349
  - `interf doctor` = check local executor setup
313
350
  - `interf verify <check>` = run deterministic checks on major workflow steps
314
351
  - `interf reset <scope>` = remove generated state while keeping source files
package/dist/bin.js CHANGED
@@ -4,7 +4,7 @@ import { hideBin } from "yargs/helpers";
4
4
  import { initCommand } from "./commands/init.js";
5
5
  import { createCommand } from "./commands/create.js";
6
6
  import { compileCommand } from "./commands/compile.js";
7
- import { benchmarkCommand } from "./commands/benchmark.js";
7
+ import { testCommand } from "./commands/test.js";
8
8
  import { doctorCommand } from "./commands/doctor.js";
9
9
  import { listCommand } from "./commands/list.js";
10
10
  import { statusCommand } from "./commands/status.js";
@@ -15,9 +15,9 @@ yargs(hideBin(process.argv))
15
15
  .scriptName("interf")
16
16
  .command(defaultCommand)
17
17
  .command(initCommand)
18
- .command(createCommand)
19
18
  .command(compileCommand)
20
- .command(benchmarkCommand)
19
+ .command(testCommand)
20
+ .command(createCommand)
21
21
  .command(doctorCommand)
22
22
  .command(listCommand)
23
23
  .command(statusCommand)
package/dist/bin.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"bin.js","sourceRoot":"","sources":["../src/bin.ts"],"names":[],"mappings":";AACA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,OAAO,EAAE,MAAM,eAAe,CAAC;AACxC,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AACjD,OAAO,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AACrD,OAAO,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AACvD,OAAO,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAC3D,OAAO,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AACrD,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AACjD,OAAO,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AACrD,OAAO,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AACnD,OAAO,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AACvD,OAAO,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AAErD,KAAK,CAAC,OAAO,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC;KACzB,UAAU,CAAC,QAAQ,CAAC;KACpB,OAAO,CAAC,cAAc,CAAC;KACvB,OAAO,CAAC,WAAW,CAAC;KACpB,OAAO,CAAC,aAAa,CAAC;KACtB,OAAO,CAAC,cAAc,CAAC;KACvB,OAAO,CAAC,gBAAgB,CAAC;KACzB,OAAO,CAAC,aAAa,CAAC;KACtB,OAAO,CAAC,WAAW,CAAC;KACpB,OAAO,CAAC,aAAa,CAAC;KACtB,OAAO,CAAC,aAAa,CAAC;KACtB,OAAO,CAAC,YAAY,CAAC;KACrB,MAAM,EAAE;KACR,IAAI,EAAE;KACN,OAAO,EAAE;KACT,KAAK,EAAE,CAAC"}
1
+ {"version":3,"file":"bin.js","sourceRoot":"","sources":["../src/bin.ts"],"names":[],"mappings":";AACA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,OAAO,EAAE,MAAM,eAAe,CAAC;AACxC,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AACjD,OAAO,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AACrD,OAAO,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AACvD,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AACjD,OAAO,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AACrD,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AACjD,OAAO,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AACrD,OAAO,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AACnD,OAAO,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AACvD,OAAO,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AAErD,KAAK,CAAC,OAAO,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC;KACzB,UAAU,CAAC,QAAQ,CAAC;KACpB,OAAO,CAAC,cAAc,CAAC;KACvB,OAAO,CAAC,WAAW,CAAC;KACpB,OAAO,CAAC,cAAc,CAAC;KACvB,OAAO,CAAC,WAAW,CAAC;KACpB,OAAO,CAAC,aAAa,CAAC;KACtB,OAAO,CAAC,aAAa,CAAC;KACtB,OAAO,CAAC,WAAW,CAAC;KACpB,OAAO,CAAC,aAAa,CAAC;KACtB,OAAO,CAAC,aAAa,CAAC;KACtB,OAAO,CAAC,YAAY,CAAC;KACrB,MAAM,EAAE;KACR,IAAI,EAAE;KACN,OAAO,EAAE;KACT,KAAK,EAAE,CAAC"}
@@ -1,3 +1,14 @@
1
+ import type { WorkflowExecutionProfile, WorkflowExecutor } from "../lib/executors.js";
2
+ import type { SourceWorkspaceConfig } from "../lib/schema.js";
1
3
  import type { CommandModule } from "yargs";
2
4
  export declare const compileCommand: CommandModule;
5
+ export declare function runCompileCommand(argv?: Record<string, unknown>): Promise<void>;
6
+ export declare function runConfiguredWorkspaceCompile(options: {
7
+ executor: WorkflowExecutor;
8
+ workspacePath: string;
9
+ sourcePath: string;
10
+ workspaceConfig: SourceWorkspaceConfig | null;
11
+ executionProfile?: WorkflowExecutionProfile;
12
+ maxAttemptsOverride: number | null;
13
+ }): Promise<boolean>;
3
14
  //# sourceMappingURL=compile.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"compile.d.ts","sourceRoot":"","sources":["../../src/commands/compile.ts"],"names":[],"mappings":"AAqBA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,OAAO,CAAC;AAoB3C,eAAO,MAAM,cAAc,EAAE,aAuC5B,CAAC"}
1
+ {"version":3,"file":"compile.d.ts","sourceRoot":"","sources":["../../src/commands/compile.ts"],"names":[],"mappings":"AAUA,OAAO,KAAK,EAAE,wBAAwB,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AAMtF,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,kBAAkB,CAAC;AAM9D,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,OAAO,CAAC;AAa3C,eAAO,MAAM,cAAc,EAAE,aAa5B,CAAC;AAEF,wBAAsB,iBAAiB,CAAC,IAAI,GAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CA+EzF;AA6CD,wBAAsB,6BAA6B,CACjD,OAAO,EAAE;IACP,QAAQ,EAAE,gBAAgB,CAAC;IAC3B,aAAa,EAAE,MAAM,CAAC;IACtB,UAAU,EAAE,MAAM,CAAC;IACnB,eAAe,EAAE,qBAAqB,GAAG,IAAI,CAAC;IAC9C,gBAAgB,CAAC,EAAE,wBAAwB,CAAC;IAC5C,mBAAmB,EAAE,MAAM,GAAG,IAAI,CAAC;CACpC,GACA,OAAO,CAAC,OAAO,CAAC,CA+GlB"}