@interf/compiler 0.6.6 → 0.6.7
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.
- package/README.md +85 -192
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -3,30 +3,30 @@
|
|
|
3
3
|
Interf prepares context for your agents.
|
|
4
4
|
Use it to check whether your files are ready for the work you want your agents to do.
|
|
5
5
|
|
|
6
|
-
|
|
6
|
+
**Files alone are not automatically ready for agent work.**
|
|
7
7
|
|
|
8
|
-
|
|
9
|
-
Your source files stay the source of truth. Interf builds on them; it does not replace them.
|
|
8
|
+
Coding agents now run real work from folders of PDFs, exports, notes, and transcripts. Those folders can still be missing the structure that work needs.
|
|
10
9
|
|
|
11
|
-
|
|
10
|
+
A chart buried inside a market-report PDF can be obvious to a human analyst and easy for an agent to miss. Interf checks the source files first, then builds portable context when the raw files are not enough.
|
|
11
|
+
|
|
12
|
+
`Interf Compiler` is the local, open-source runtime behind that loop. It uses your local agent to organize the files for one piece of work and build portable context next to them. `interf test` scores the source files and the portable context on the same questions.
|
|
12
13
|
|
|
13
14
|
```text
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
15
|
+
your-folder/
|
|
16
|
+
market-report/
|
|
17
|
+
report.pdf
|
|
18
|
+
notes.md
|
|
19
|
+
exports/
|
|
20
|
+
interf.json # saved setup and questions for this work
|
|
21
|
+
interf/
|
|
22
|
+
market-report/ # portable context your agent starts from
|
|
23
|
+
tests/
|
|
24
|
+
market-report/ # source-files vs portable-context scores
|
|
20
25
|
```
|
|
21
26
|
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
One public example from a PDF market report uses checks like:
|
|
27
|
+
## What a run looks like
|
|
25
28
|
|
|
26
|
-
|
|
27
|
-
- `What were Bristol's availability values in 2018 and 2016?`
|
|
28
|
-
|
|
29
|
-
On those same checks, one recent public comparison produced:
|
|
29
|
+
A recent public run — one PDF market report, two questions, two agents on the same setup — produced:
|
|
30
30
|
|
|
31
31
|
<!-- PUBLIC_BENCHMARK_TABLE:START -->
|
|
32
32
|
| Agent | Source files | Portable context |
|
|
@@ -35,114 +35,78 @@ On those same checks, one recent public comparison produced:
|
|
|
35
35
|
| Claude Code (Claude Opus 4.6, max) | `0/2` | `2/2` |
|
|
36
36
|
<!-- PUBLIC_BENCHMARK_TABLE:END -->
|
|
37
37
|
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
- Codex already passed on the source files.
|
|
41
|
-
- Claude Code needed the portable context to pass.
|
|
42
|
-
|
|
43
|
-
That gives you a readiness signal for the work and a fair comparison on the same files.
|
|
44
|
-
|
|
45
|
-
Same work. Same checks. Same local setup.
|
|
46
|
-
|
|
47
|
-
## How It Works
|
|
48
|
-
|
|
49
|
-
1. Pick the files for the work.
|
|
50
|
-
2. Tell Interf what you need from them.
|
|
51
|
-
3. Review or edit the questions.
|
|
52
|
-
4. Run a source-files baseline if you want to check readiness first.
|
|
53
|
-
5. Build the portable context for your agents.
|
|
54
|
-
6. Run `interf test` on the same questions.
|
|
55
|
-
|
|
56
|
-
Check the source files first if you want the baseline. If the files already pass, keep them. If the portable context does better, use it.
|
|
57
|
-
|
|
58
|
-
## Why It Exists
|
|
59
|
-
|
|
60
|
-
Raw files are often not enough.
|
|
61
|
-
|
|
62
|
-
Local agents can open reports, decks, transcripts, exports, PDFs, notes, and mixed folders. They can still miss the structure the work needs.
|
|
38
|
+
Codex passed on the raw files; Claude Code only passed after Interf prepared the portable context. Both numbers come from `interf test`, which scores the same questions against the source files and the portable context.
|
|
63
39
|
|
|
64
|
-
|
|
40
|
+
The table is a sample, not a leaderboard. Run it on your own files. If you run more than one local agent, the same pass gives you a fair comparison between them on the same files.
|
|
65
41
|
|
|
66
|
-
|
|
42
|
+
## The loop
|
|
67
43
|
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
44
|
+
1. Drop the files for one piece of work under a folder.
|
|
45
|
+
2. Run `interf` and describe the work. Interf recommends a few questions you can verify from the files.
|
|
46
|
+
3. `interf test --target raw` scores the source files.
|
|
47
|
+
4. `interf compile` builds portable context next to the files.
|
|
48
|
+
5. `interf test` scores the portable context on the same questions.
|
|
49
|
+
6. Use whichever side did better.
|
|
73
50
|
|
|
74
|
-
|
|
51
|
+
Step 3 is optional. It is the honest first check: sometimes the files are already enough, and Interf will say so instead of building something you do not need.
|
|
75
52
|
|
|
76
|
-
|
|
53
|
+
## Install
|
|
77
54
|
|
|
78
|
-
```
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
report.pdf
|
|
82
|
-
notes.md
|
|
83
|
-
exports/
|
|
84
|
-
interf.json
|
|
85
|
-
interf/
|
|
86
|
-
market-report/
|
|
87
|
-
tests/
|
|
88
|
-
market-report/
|
|
55
|
+
```bash
|
|
56
|
+
npm install -g @interf/compiler
|
|
57
|
+
interf # opens the setup wizard in the current folder
|
|
89
58
|
```
|
|
90
59
|
|
|
91
|
-
|
|
60
|
+
Requires Node.js 20+ and a local coding agent such as Claude Code or Codex. Run `interf doctor --live` if the executor is not detected.
|
|
92
61
|
|
|
93
|
-
|
|
62
|
+
## Core commands
|
|
94
63
|
|
|
95
|
-
|
|
64
|
+
- `interf` or `interf init` — open the wizard for the current folder
|
|
65
|
+
- `interf compile` — build portable context for your agents
|
|
66
|
+
- `interf test` — score source files and portable context on the same questions
|
|
67
|
+
- `interf create workflow` — draft or copy a reusable workflow
|
|
68
|
+
- `interf create dataset` — add another piece of work to this project
|
|
69
|
+
- `interf list` — list the pieces of work in this project
|
|
70
|
+
- `interf status` — show deterministic health
|
|
71
|
+
- `interf doctor` — check the local agent executor
|
|
72
|
+
- `interf verify <check>` — deterministic verification for automation
|
|
73
|
+
- `interf reset <scope>` — reset generated state while keeping source files
|
|
96
74
|
|
|
97
|
-
|
|
75
|
+
## Portable context
|
|
98
76
|
|
|
99
|
-
|
|
100
|
-
- a local coding agent such as Claude Code or Codex
|
|
77
|
+
`interf/<work>/` is the folder your agent starts from when the raw files are not enough. For the built-in `interf` workflow, it includes:
|
|
101
78
|
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
79
|
+
```text
|
|
80
|
+
interf/market-report/
|
|
81
|
+
AGENTS.md # how to use this folder
|
|
82
|
+
CLAUDE.md # same guidance for Claude Code
|
|
83
|
+
raw/ # snapshot of the source files for this work
|
|
84
|
+
home.md # top-level map for the work
|
|
85
|
+
summaries/ # per-file summaries
|
|
86
|
+
knowledge/ # linked notes built from the files
|
|
106
87
|
```
|
|
107
88
|
|
|
108
|
-
|
|
89
|
+
Interf builds next to the source files; it does not replace them. The portable context is a sibling folder you can version, inspect line-by-line, or hand to a different agent.
|
|
109
90
|
|
|
110
|
-
|
|
111
|
-
interf
|
|
112
|
-
```
|
|
91
|
+
It carries its own `raw/` snapshot for verification. Any CLI that reads a local directory — Claude Code, Codex, your own — can work from it.
|
|
113
92
|
|
|
114
|
-
The
|
|
93
|
+
The method that builds the portable context is a workflow. In plain language, it is how Interf summarizes the files, extracts structure, and links notes for agent use.
|
|
115
94
|
|
|
116
|
-
|
|
117
|
-
- let you choose the source folder for the work
|
|
118
|
-
- ask what work you need help with
|
|
119
|
-
- recommend questions you can verify from the files, or let you add them manually
|
|
120
|
-
- run a source-files baseline so you can see whether the files are already enough
|
|
121
|
-
- build the portable context your agents will use for that work
|
|
122
|
-
- check that portable context on the same questions
|
|
95
|
+
Technically, the workflow is a workflow package; the folder shape it writes is the context interface; the built folder is the compiled context. Run `interf create workflow` if the built-in method is not enough for your work. Most users only touch `interf/<work>/`.
|
|
123
96
|
|
|
124
|
-
|
|
97
|
+
## Questions
|
|
125
98
|
|
|
126
|
-
|
|
127
|
-
interf doctor --live
|
|
128
|
-
```
|
|
99
|
+
Interf runs question-and-answer checks.
|
|
129
100
|
|
|
130
|
-
|
|
101
|
+
In the flow, they feel like plain questions. In `interf.json`, they live under `checks[]` — small facts that define what "good enough" means for this work.
|
|
131
102
|
|
|
132
|
-
|
|
133
|
-
They are small questions that tell you whether the work is actually covered.
|
|
134
|
-
|
|
135
|
-
Interf runs the same checks on the source files and on the portable context. That gives you a source-files baseline and a portable-context comparison on the same task.
|
|
136
|
-
|
|
137
|
-
Good first checks are small and easy to verify from the files:
|
|
103
|
+
They should be small, verifiable facts you already know from the files:
|
|
138
104
|
|
|
139
105
|
- one exact number from a chart, table, or filing
|
|
140
106
|
- one short statement that should be true or false
|
|
141
|
-
- one
|
|
142
|
-
|
|
143
|
-
Interf can recommend a starting set from the files and the work description. You can confirm, edit, or replace them.
|
|
107
|
+
- one comparison across years, files, or sections
|
|
144
108
|
|
|
145
|
-
|
|
109
|
+
Interf proposes an initial set from the files and the work description. You confirm, edit, or replace them.
|
|
146
110
|
|
|
147
111
|
A maintained public test example in this repo stores them like this:
|
|
148
112
|
|
|
@@ -170,106 +134,35 @@ A maintained public test example in this repo stores them like this:
|
|
|
170
134
|
```
|
|
171
135
|
<!-- PUBLIC_TEST_CHECKS:END -->
|
|
172
136
|
|
|
173
|
-
##
|
|
174
|
-
|
|
175
|
-
`interf test` compares the source files and the portable context your agents would use on the same questions.
|
|
176
|
-
|
|
177
|
-
That makes it a small benchmark for the work at hand:
|
|
178
|
-
|
|
179
|
-
- same work
|
|
180
|
-
- same checks
|
|
181
|
-
- same local agent setup
|
|
182
|
-
- source files on one side
|
|
183
|
-
- portable context your agents use on the other
|
|
184
|
-
|
|
185
|
-
If you run more than one local agent, it also gives you a fair comparison between them on the same files.
|
|
186
|
-
|
|
187
|
-
If the portable context does not help, keep the source files.
|
|
188
|
-
|
|
189
|
-
Use `interf test` on your own files instead of trusting a frozen benchmark snapshot in the docs.
|
|
190
|
-
|
|
191
|
-
Interf saves the latest comparison plus the underlying source-files and portable-context runs under `interf/tests/` in the same project.
|
|
192
|
-
|
|
193
|
-
## The Compile And Check Loop
|
|
194
|
-
|
|
195
|
-
1. Save a few checks for the work in `interf.json`.
|
|
196
|
-
2. Run `interf test --target raw` if you want the source-files baseline.
|
|
197
|
-
3. Run `interf compile`.
|
|
198
|
-
4. Run `interf test`.
|
|
199
|
-
5. If self-improving loops are enabled, let Interf revise the workflow and try again on the same work and checks.
|
|
200
|
-
|
|
201
|
-
`interf.json` stores the saved setup and checks. Technically, that portable context is the compiled context Interf reuses for repeat runs.
|
|
202
|
-
|
|
203
|
-
## Workflows
|
|
204
|
-
|
|
205
|
-
A workflow is the preparation method Interf runs on your files.
|
|
206
|
-
|
|
207
|
-
In plain language, it is the method that organizes and structures those files for agent use.
|
|
208
|
-
|
|
209
|
-
It can summarize files, extract structure, and build the local context layer your agent starts from.
|
|
210
|
-
|
|
211
|
-
Interf runs that method with your local coding agent and builds the result on disk as portable context.
|
|
212
|
-
|
|
213
|
-
The folder shape it produces for the agent is the context interface. The reusable method itself is the workflow package.
|
|
137
|
+
## Self-improving loops
|
|
214
138
|
|
|
215
|
-
|
|
139
|
+
One compile pass is not always enough. If the portable context still fails some questions, Interf can revise the workflow and compile again: same files, same questions, different preparation.
|
|
216
140
|
|
|
217
|
-
Interf
|
|
141
|
+
Each loop edits the workflow between attempts. Interf keeps every scored run under `interf/tests/<work>/`, so you can diff why one version did better than the next.
|
|
218
142
|
|
|
219
|
-
|
|
220
|
-
interf create workflow
|
|
221
|
-
```
|
|
222
|
-
|
|
223
|
-
Workflow creation supports two paths:
|
|
224
|
-
|
|
225
|
-
- draft a workflow from the current project with a local agent
|
|
226
|
-
- copy an existing workflow and edit stage guidance directly
|
|
227
|
-
|
|
228
|
-
After assignment, build the portable context for your agents with `interf compile` and run `interf test` on the same questions.
|
|
229
|
-
|
|
230
|
-
## Self-Improving Loops
|
|
231
|
-
|
|
232
|
-
Interf can do more than one compile pass.
|
|
233
|
-
|
|
234
|
-
If the first portable context is still weak, Interf can revise the workflow and compile again.
|
|
235
|
-
|
|
236
|
-
Each loop keeps the work and the checks fixed. The thing that changes is the preparation method.
|
|
237
|
-
|
|
238
|
-
If self-improving loops are enabled, Interf can:
|
|
143
|
+
## Design choices
|
|
239
144
|
|
|
240
|
-
-
|
|
241
|
-
-
|
|
242
|
-
-
|
|
243
|
-
-
|
|
244
|
-
-
|
|
145
|
+
- `Explicit`: portable context is a folder on disk you can inspect, diff, and version.
|
|
146
|
+
- `File over app`: Interf builds next to the source files.
|
|
147
|
+
- `Bring your own AI`: use Claude Code, Codex, or another local agent.
|
|
148
|
+
- `Proof over vibes`: `interf test` scores source files and portable context on the same questions.
|
|
149
|
+
- `Source files stay the source of truth`: Interf builds next to them; it does not replace them.
|
|
245
150
|
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
## Use It With Your Agent
|
|
249
|
-
|
|
250
|
-
If you already work through a local coding agent, hand it the whole flow:
|
|
251
|
-
|
|
252
|
-
Paste something like this into your agent:
|
|
253
|
-
|
|
254
|
-
```text
|
|
255
|
-
Install `@interf/compiler`, run `interf` in this folder, and use the local agent executor.
|
|
256
|
-
|
|
257
|
-
If `interf.json` is missing, draft one dataset entry for this work. Ask what I need from the selected files. Recommend a few questions I can verify from those files, and add the expected answers for me to confirm under `checks[]`.
|
|
258
|
-
|
|
259
|
-
Run a source-files baseline if useful. Build the portable context for my agents for that work. Then run `interf test` on the same questions.
|
|
260
|
-
|
|
261
|
-
Only recommend the portable context if it passes those questions. If you also ran the source-files baseline, tell me whether it did better than the source files.
|
|
262
|
-
```
|
|
151
|
+
## What Interf is not
|
|
263
152
|
|
|
264
|
-
|
|
153
|
+
- Not a second brain or memory product. One folder per piece of work; nothing global.
|
|
154
|
+
- Not a vector store or RAG server. The portable context is plain files.
|
|
155
|
+
- Not a hosted context layer. Interf runs locally and `interf/` is yours.
|
|
156
|
+
- Not an agent harness. Interf prepares the folder; your existing agent reads it.
|
|
157
|
+
- Not a public leaderboard. Every score comes from your files, your questions, and your agent.
|
|
265
158
|
|
|
266
|
-
|
|
267
|
-
- [src/packages/compiler/PACKAGE.md](./src/packages/compiler/PACKAGE.md) for compiler primitives and the runtime contract
|
|
268
|
-
- [src/packages/workflow-package/PACKAGE.md](./src/packages/workflow-package/PACKAGE.md) for the workflow package model
|
|
269
|
-
- [src/packages/workflow-authoring/PACKAGE.md](./src/packages/workflow-authoring/PACKAGE.md) for workflow authoring and self-improving loops
|
|
159
|
+
## Docs
|
|
270
160
|
|
|
271
|
-
|
|
161
|
+
- [src/packages/README.md](./src/packages/README.md) — system map
|
|
162
|
+
- [src/packages/compiler/PACKAGE.md](./src/packages/compiler/PACKAGE.md) — compiler primitives and runtime contract
|
|
163
|
+
- [src/packages/workflow-package/PACKAGE.md](./src/packages/workflow-package/PACKAGE.md) — workflow package model
|
|
164
|
+
- [src/packages/workflow-authoring/PACKAGE.md](./src/packages/workflow-authoring/PACKAGE.md) — workflow authoring and self-improving loops
|
|
272
165
|
|
|
273
|
-
|
|
166
|
+
Contributors: see [CONTRIBUTING.md](./CONTRIBUTING.md).
|
|
274
167
|
|
|
275
|
-
Code
|
|
168
|
+
Code: Apache 2.0. Name and branding: see [TRADEMARKS.md](./TRADEMARKS.md).
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@interf/compiler",
|
|
3
|
-
"version": "0.6.
|
|
3
|
+
"version": "0.6.7",
|
|
4
4
|
"description": "Interf prepares context for your agents by checking your files first, building a local folder when needed, and using self-improving loops until more questions pass.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|