@interf/compiler 0.3.4 → 0.4.0
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 +131 -149
- package/builtin-workflows/interf/README.md +19 -0
- package/builtin-workflows/interf/compile/stages/shape/SKILL.md +28 -0
- package/builtin-workflows/interf/compile/stages/structure/SKILL.md +18 -0
- package/builtin-workflows/interf/compile/stages/summarize/SKILL.md +18 -0
- package/builtin-workflows/interf/improve/SKILL.md +18 -0
- package/builtin-workflows/interf/use/query/SKILL.md +28 -0
- package/builtin-workflows/interf/workflow.json +120 -0
- package/builtin-workflows/interf/workspace.schema.json +75 -0
- package/dist/bin.d.ts +0 -1
- package/dist/bin.js +0 -1
- package/dist/commands/compile-controller.d.ts +14 -0
- package/dist/commands/compile-controller.js +409 -0
- package/dist/commands/compile.d.ts +8 -9
- package/dist/commands/compile.js +151 -153
- package/dist/commands/create-workflow-wizard.d.ts +4 -2
- package/dist/commands/create-workflow-wizard.js +33 -31
- package/dist/commands/create.d.ts +0 -1
- package/dist/commands/create.js +15 -11
- package/dist/commands/default.d.ts +0 -1
- package/dist/commands/default.js +0 -1
- package/dist/commands/doctor.d.ts +0 -1
- package/dist/commands/doctor.js +1 -16
- package/dist/commands/executor-flow.d.ts +0 -1
- package/dist/commands/executor-flow.js +0 -1
- package/dist/commands/init.d.ts +0 -1
- package/dist/commands/init.js +71 -14
- package/dist/commands/list.d.ts +0 -1
- package/dist/commands/list.js +0 -1
- package/dist/commands/reset.d.ts +0 -1
- package/dist/commands/reset.js +0 -1
- package/dist/commands/source-config-wizard.d.ts +28 -7
- package/dist/commands/source-config-wizard.js +159 -63
- package/dist/commands/status.d.ts +0 -1
- package/dist/commands/status.js +0 -1
- package/dist/commands/test-flow.d.ts +20 -10
- package/dist/commands/test-flow.js +89 -23
- package/dist/commands/test.d.ts +0 -1
- package/dist/commands/test.js +36 -72
- package/dist/commands/verify.d.ts +0 -1
- package/dist/commands/verify.js +0 -1
- package/dist/commands/workspace-flow.d.ts +3 -3
- package/dist/commands/workspace-flow.js +30 -12
- package/dist/index.d.ts +5 -6
- package/dist/index.js +3 -4
- package/dist/lib/agent-args.d.ts +0 -1
- package/dist/lib/agent-args.js +0 -1
- package/dist/lib/agent-constants.d.ts +0 -1
- package/dist/lib/agent-constants.js +0 -1
- package/dist/lib/agent-detection.d.ts +0 -1
- package/dist/lib/agent-detection.js +0 -1
- package/dist/lib/agent-execution.d.ts +0 -1
- package/dist/lib/agent-execution.js +47 -12
- package/dist/lib/agent-logs.d.ts +0 -1
- package/dist/lib/agent-logs.js +0 -1
- package/dist/lib/agent-preflight.d.ts +0 -1
- package/dist/lib/agent-preflight.js +1 -2
- package/dist/lib/agent-render.d.ts +0 -1
- package/dist/lib/agent-render.js +0 -1
- package/dist/lib/agent-shells.d.ts +30 -3
- package/dist/lib/agent-shells.js +517 -54
- package/dist/lib/agent-status.d.ts +0 -1
- package/dist/lib/agent-status.js +0 -1
- package/dist/lib/agent-types.d.ts +0 -1
- package/dist/lib/agent-types.js +0 -1
- package/dist/lib/agents.d.ts +0 -9
- package/dist/lib/agents.js +0 -9
- package/dist/lib/chart-guidance.d.ts +1 -0
- package/dist/lib/chart-guidance.js +8 -0
- package/dist/lib/config.d.ts +0 -3
- package/dist/lib/config.js +0 -5
- package/dist/lib/discovery.d.ts +0 -1
- package/dist/lib/discovery.js +0 -1
- package/dist/lib/execution-profile.d.ts +0 -1
- package/dist/lib/execution-profile.js +0 -1
- package/dist/lib/executors.d.ts +0 -1
- package/dist/lib/executors.js +0 -1
- package/dist/lib/filesystem.d.ts +0 -1
- package/dist/lib/filesystem.js +0 -1
- package/dist/lib/interf-bootstrap.d.ts +0 -1
- package/dist/lib/interf-bootstrap.js +6 -2
- package/dist/lib/interf-detect.d.ts +2 -2
- package/dist/lib/interf-detect.js +25 -8
- package/dist/lib/interf-scaffold.d.ts +0 -1
- package/dist/lib/interf-scaffold.js +54 -21
- package/dist/lib/interf-workflow-package.d.ts +18 -1
- package/dist/lib/interf-workflow-package.js +164 -23
- package/dist/lib/interf.d.ts +1 -2
- package/dist/lib/interf.js +1 -2
- package/dist/lib/local-workflows.d.ts +10 -5
- package/dist/lib/local-workflows.js +208 -97
- package/dist/lib/logger.d.ts +0 -1
- package/dist/lib/logger.js +0 -1
- package/dist/lib/obsidian.d.ts +0 -1
- package/dist/lib/obsidian.js +0 -1
- package/dist/lib/parse.d.ts +0 -1
- package/dist/lib/parse.js +0 -1
- package/dist/lib/registry.d.ts +0 -1
- package/dist/lib/registry.js +0 -1
- package/dist/lib/runtime-acceptance.d.ts +0 -1
- package/dist/lib/runtime-acceptance.js +1 -2
- package/dist/lib/runtime-contracts.d.ts +0 -1
- package/dist/lib/runtime-contracts.js +14 -8
- package/dist/lib/runtime-paths.d.ts +0 -1
- package/dist/lib/runtime-paths.js +5 -10
- package/dist/lib/runtime-prompt.d.ts +0 -1
- package/dist/lib/runtime-prompt.js +8 -23
- package/dist/lib/runtime-reconcile.d.ts +0 -1
- package/dist/lib/runtime-reconcile.js +7 -3
- package/dist/lib/runtime-runs.d.ts +0 -1
- package/dist/lib/runtime-runs.js +4 -5
- package/dist/lib/runtime-types.d.ts +0 -1
- package/dist/lib/runtime-types.js +0 -1
- package/dist/lib/runtime.d.ts +0 -1
- package/dist/lib/runtime.js +0 -1
- package/dist/lib/schema.d.ts +356 -51
- package/dist/lib/schema.js +189 -54
- package/dist/lib/source-config.d.ts +17 -8
- package/dist/lib/source-config.js +125 -11
- package/dist/lib/state-artifacts.d.ts +0 -1
- package/dist/lib/state-artifacts.js +0 -1
- package/dist/lib/state-health.d.ts +0 -1
- package/dist/lib/state-health.js +2 -3
- package/dist/lib/state-io.d.ts +1 -1
- package/dist/lib/state-io.js +9 -10
- package/dist/lib/state-paths.d.ts +0 -1
- package/dist/lib/state-paths.js +5 -11
- package/dist/lib/state-view.d.ts +0 -1
- package/dist/lib/state-view.js +7 -8
- package/dist/lib/state.d.ts +0 -1
- package/dist/lib/state.js +0 -1
- package/dist/lib/summarize-plan.d.ts +0 -1
- package/dist/lib/summarize-plan.js +3 -3
- package/dist/lib/test-execution.d.ts +14 -0
- package/dist/lib/{benchmark-execution.js → test-execution.js} +122 -120
- package/dist/lib/test-matrices.d.ts +90 -0
- package/dist/lib/test-matrices.js +96 -0
- package/dist/lib/test-paths.d.ts +12 -0
- package/dist/lib/test-paths.js +44 -0
- package/dist/lib/test-profile-presets.d.ts +57 -0
- package/dist/lib/test-profile-presets.js +50 -0
- package/dist/lib/test-sandbox.d.ts +11 -0
- package/dist/lib/{benchmark-sandbox.js → test-sandbox.js} +18 -13
- package/dist/lib/test-specs.d.ts +7 -0
- package/dist/lib/test-specs.js +114 -0
- package/dist/lib/test-targets.d.ts +5 -0
- package/dist/lib/test-targets.js +38 -0
- package/dist/lib/test-types.d.ts +17 -0
- package/dist/lib/test-types.js +1 -0
- package/dist/lib/test.d.ts +4 -0
- package/dist/lib/test.js +3 -0
- package/dist/lib/user-config.d.ts +0 -1
- package/dist/lib/user-config.js +0 -1
- package/dist/lib/util.d.ts +0 -2
- package/dist/lib/util.js +0 -2
- package/dist/lib/validate-helpers.d.ts +0 -1
- package/dist/lib/validate-helpers.js +0 -1
- package/dist/lib/validate-workspace.d.ts +0 -1
- package/dist/lib/validate-workspace.js +34 -25
- package/dist/lib/validate.d.ts +0 -1
- package/dist/lib/validate.js +55 -9
- package/dist/lib/workflow-abi.d.ts +138 -0
- package/dist/lib/workflow-abi.js +181 -0
- package/dist/lib/workflow-definitions.d.ts +26 -5
- package/dist/lib/workflow-definitions.js +105 -168
- package/dist/lib/workflow-helpers.d.ts +1 -2
- package/dist/lib/workflow-helpers.js +32 -21
- package/dist/lib/workflow-improvement.d.ts +22 -0
- package/dist/lib/workflow-improvement.js +396 -0
- package/dist/lib/workflow-review-paths.d.ts +10 -0
- package/dist/lib/workflow-review-paths.js +27 -0
- package/dist/lib/workflow-stage-runner.d.ts +1 -1
- package/dist/lib/workflow-stage-runner.js +4 -1
- package/dist/lib/workflows.d.ts +1 -2
- package/dist/lib/workflows.js +1 -2
- package/dist/lib/workspace-compile.d.ts +0 -1
- package/dist/lib/workspace-compile.js +146 -109
- package/dist/lib/workspace-home.d.ts +5 -0
- package/dist/lib/workspace-home.js +32 -0
- package/dist/lib/workspace-layout.d.ts +2 -0
- package/dist/lib/workspace-layout.js +60 -0
- package/dist/lib/workspace-paths.d.ts +41 -0
- package/dist/lib/workspace-paths.js +107 -0
- package/dist/lib/workspace-raw.d.ts +20 -2
- package/dist/lib/workspace-raw.js +6 -8
- package/dist/lib/workspace-reset.d.ts +0 -1
- package/dist/lib/workspace-reset.js +27 -5
- package/dist/lib/workspace-schema.d.ts +1 -10
- package/dist/lib/workspace-schema.js +16 -74
- package/package.json +16 -15
- package/dist/bin.d.ts.map +0 -1
- package/dist/bin.js.map +0 -1
- package/dist/commands/compile.d.ts.map +0 -1
- package/dist/commands/compile.js.map +0 -1
- package/dist/commands/create-workflow-wizard.d.ts.map +0 -1
- package/dist/commands/create-workflow-wizard.js.map +0 -1
- package/dist/commands/create.d.ts.map +0 -1
- package/dist/commands/create.js.map +0 -1
- package/dist/commands/default.d.ts.map +0 -1
- package/dist/commands/default.js.map +0 -1
- package/dist/commands/doctor.d.ts.map +0 -1
- package/dist/commands/doctor.js.map +0 -1
- package/dist/commands/executor-flow.d.ts.map +0 -1
- package/dist/commands/executor-flow.js.map +0 -1
- package/dist/commands/init.d.ts.map +0 -1
- package/dist/commands/init.js.map +0 -1
- package/dist/commands/list.d.ts.map +0 -1
- package/dist/commands/list.js.map +0 -1
- package/dist/commands/reset.d.ts.map +0 -1
- package/dist/commands/reset.js.map +0 -1
- package/dist/commands/source-config-wizard.d.ts.map +0 -1
- package/dist/commands/source-config-wizard.js.map +0 -1
- package/dist/commands/status.d.ts.map +0 -1
- package/dist/commands/status.js.map +0 -1
- package/dist/commands/test-flow.d.ts.map +0 -1
- package/dist/commands/test-flow.js.map +0 -1
- package/dist/commands/test.d.ts.map +0 -1
- package/dist/commands/test.js.map +0 -1
- package/dist/commands/verify.d.ts.map +0 -1
- package/dist/commands/verify.js.map +0 -1
- package/dist/commands/workspace-flow.d.ts.map +0 -1
- package/dist/commands/workspace-flow.js.map +0 -1
- package/dist/index.d.ts.map +0 -1
- package/dist/index.js.map +0 -1
- package/dist/lib/agent-args.d.ts.map +0 -1
- package/dist/lib/agent-args.js.map +0 -1
- package/dist/lib/agent-constants.d.ts.map +0 -1
- package/dist/lib/agent-constants.js.map +0 -1
- package/dist/lib/agent-detection.d.ts.map +0 -1
- package/dist/lib/agent-detection.js.map +0 -1
- package/dist/lib/agent-execution.d.ts.map +0 -1
- package/dist/lib/agent-execution.js.map +0 -1
- package/dist/lib/agent-logs.d.ts.map +0 -1
- package/dist/lib/agent-logs.js.map +0 -1
- package/dist/lib/agent-preflight.d.ts.map +0 -1
- package/dist/lib/agent-preflight.js.map +0 -1
- package/dist/lib/agent-render.d.ts.map +0 -1
- package/dist/lib/agent-render.js.map +0 -1
- package/dist/lib/agent-shells.d.ts.map +0 -1
- package/dist/lib/agent-shells.js.map +0 -1
- package/dist/lib/agent-skills.d.ts +0 -21
- package/dist/lib/agent-skills.d.ts.map +0 -1
- package/dist/lib/agent-skills.js +0 -215
- package/dist/lib/agent-skills.js.map +0 -1
- package/dist/lib/agent-status.d.ts.map +0 -1
- package/dist/lib/agent-status.js.map +0 -1
- package/dist/lib/agent-types.d.ts.map +0 -1
- package/dist/lib/agent-types.js.map +0 -1
- package/dist/lib/agents.d.ts.map +0 -1
- package/dist/lib/agents.js.map +0 -1
- package/dist/lib/benchmark-execution.d.ts +0 -13
- package/dist/lib/benchmark-execution.d.ts.map +0 -1
- package/dist/lib/benchmark-execution.js.map +0 -1
- package/dist/lib/benchmark-paths.d.ts +0 -13
- package/dist/lib/benchmark-paths.d.ts.map +0 -1
- package/dist/lib/benchmark-paths.js +0 -44
- package/dist/lib/benchmark-paths.js.map +0 -1
- package/dist/lib/benchmark-sandbox.d.ts +0 -12
- package/dist/lib/benchmark-sandbox.d.ts.map +0 -1
- package/dist/lib/benchmark-sandbox.js.map +0 -1
- package/dist/lib/benchmark-specs.d.ts +0 -8
- package/dist/lib/benchmark-specs.d.ts.map +0 -1
- package/dist/lib/benchmark-specs.js +0 -115
- package/dist/lib/benchmark-specs.js.map +0 -1
- package/dist/lib/benchmark-targets.d.ts +0 -5
- package/dist/lib/benchmark-targets.d.ts.map +0 -1
- package/dist/lib/benchmark-targets.js +0 -38
- package/dist/lib/benchmark-targets.js.map +0 -1
- package/dist/lib/benchmark-types.d.ts +0 -18
- package/dist/lib/benchmark-types.d.ts.map +0 -1
- package/dist/lib/benchmark-types.js +0 -2
- package/dist/lib/benchmark-types.js.map +0 -1
- package/dist/lib/benchmark.d.ts +0 -5
- package/dist/lib/benchmark.d.ts.map +0 -1
- package/dist/lib/benchmark.js +0 -4
- package/dist/lib/benchmark.js.map +0 -1
- package/dist/lib/config.d.ts.map +0 -1
- package/dist/lib/config.js.map +0 -1
- package/dist/lib/discovery.d.ts.map +0 -1
- package/dist/lib/discovery.js.map +0 -1
- package/dist/lib/eval-packs.d.ts +0 -158
- package/dist/lib/eval-packs.d.ts.map +0 -1
- package/dist/lib/eval-packs.js +0 -149
- package/dist/lib/eval-packs.js.map +0 -1
- package/dist/lib/execution-profile.d.ts.map +0 -1
- package/dist/lib/execution-profile.js.map +0 -1
- package/dist/lib/executors.d.ts.map +0 -1
- package/dist/lib/executors.js.map +0 -1
- package/dist/lib/filesystem.d.ts.map +0 -1
- package/dist/lib/filesystem.js.map +0 -1
- package/dist/lib/interf-bootstrap.d.ts.map +0 -1
- package/dist/lib/interf-bootstrap.js.map +0 -1
- package/dist/lib/interf-detect.d.ts.map +0 -1
- package/dist/lib/interf-detect.js.map +0 -1
- package/dist/lib/interf-scaffold.d.ts.map +0 -1
- package/dist/lib/interf-scaffold.js.map +0 -1
- package/dist/lib/interf-workflow-package.d.ts.map +0 -1
- package/dist/lib/interf-workflow-package.js.map +0 -1
- package/dist/lib/interf.d.ts.map +0 -1
- package/dist/lib/interf.js.map +0 -1
- package/dist/lib/local-workflows.d.ts.map +0 -1
- package/dist/lib/local-workflows.js.map +0 -1
- package/dist/lib/logger.d.ts.map +0 -1
- package/dist/lib/logger.js.map +0 -1
- package/dist/lib/obsidian.d.ts.map +0 -1
- package/dist/lib/obsidian.js.map +0 -1
- package/dist/lib/parse.d.ts.map +0 -1
- package/dist/lib/parse.js.map +0 -1
- package/dist/lib/registry.d.ts.map +0 -1
- package/dist/lib/registry.js.map +0 -1
- package/dist/lib/runtime-acceptance.d.ts.map +0 -1
- package/dist/lib/runtime-acceptance.js.map +0 -1
- package/dist/lib/runtime-contracts.d.ts.map +0 -1
- package/dist/lib/runtime-contracts.js.map +0 -1
- package/dist/lib/runtime-paths.d.ts.map +0 -1
- package/dist/lib/runtime-paths.js.map +0 -1
- package/dist/lib/runtime-prompt.d.ts.map +0 -1
- package/dist/lib/runtime-prompt.js.map +0 -1
- package/dist/lib/runtime-reconcile.d.ts.map +0 -1
- package/dist/lib/runtime-reconcile.js.map +0 -1
- package/dist/lib/runtime-runs.d.ts.map +0 -1
- package/dist/lib/runtime-runs.js.map +0 -1
- package/dist/lib/runtime-types.d.ts.map +0 -1
- package/dist/lib/runtime-types.js.map +0 -1
- package/dist/lib/runtime.d.ts.map +0 -1
- package/dist/lib/runtime.js.map +0 -1
- package/dist/lib/schema.d.ts.map +0 -1
- package/dist/lib/schema.js.map +0 -1
- package/dist/lib/source-config.d.ts.map +0 -1
- package/dist/lib/source-config.js.map +0 -1
- package/dist/lib/state-artifacts.d.ts.map +0 -1
- package/dist/lib/state-artifacts.js.map +0 -1
- package/dist/lib/state-health.d.ts.map +0 -1
- package/dist/lib/state-health.js.map +0 -1
- package/dist/lib/state-io.d.ts.map +0 -1
- package/dist/lib/state-io.js.map +0 -1
- package/dist/lib/state-paths.d.ts.map +0 -1
- package/dist/lib/state-paths.js.map +0 -1
- package/dist/lib/state-view.d.ts.map +0 -1
- package/dist/lib/state-view.js.map +0 -1
- package/dist/lib/state.d.ts.map +0 -1
- package/dist/lib/state.js.map +0 -1
- package/dist/lib/summarize-plan.d.ts.map +0 -1
- package/dist/lib/summarize-plan.js.map +0 -1
- package/dist/lib/user-config.d.ts.map +0 -1
- package/dist/lib/user-config.js.map +0 -1
- package/dist/lib/util.d.ts.map +0 -1
- package/dist/lib/util.js.map +0 -1
- package/dist/lib/validate-helpers.d.ts.map +0 -1
- package/dist/lib/validate-helpers.js.map +0 -1
- package/dist/lib/validate-workspace.d.ts.map +0 -1
- package/dist/lib/validate-workspace.js.map +0 -1
- package/dist/lib/validate.d.ts.map +0 -1
- package/dist/lib/validate.js.map +0 -1
- package/dist/lib/workflow-definitions.d.ts.map +0 -1
- package/dist/lib/workflow-definitions.js.map +0 -1
- package/dist/lib/workflow-helpers.d.ts.map +0 -1
- package/dist/lib/workflow-helpers.js.map +0 -1
- package/dist/lib/workflow-stage-runner.d.ts.map +0 -1
- package/dist/lib/workflow-stage-runner.js.map +0 -1
- package/dist/lib/workflow-starter-docs.d.ts +0 -7
- package/dist/lib/workflow-starter-docs.d.ts.map +0 -1
- package/dist/lib/workflow-starter-docs.js +0 -3
- package/dist/lib/workflow-starter-docs.js.map +0 -1
- package/dist/lib/workflows.d.ts.map +0 -1
- package/dist/lib/workflows.js.map +0 -1
- package/dist/lib/workspace-compile.d.ts.map +0 -1
- package/dist/lib/workspace-compile.js.map +0 -1
- package/dist/lib/workspace-docs.d.ts +0 -3
- package/dist/lib/workspace-docs.d.ts.map +0 -1
- package/dist/lib/workspace-docs.js +0 -82
- package/dist/lib/workspace-docs.js.map +0 -1
- package/dist/lib/workspace-raw.d.ts.map +0 -1
- package/dist/lib/workspace-raw.js.map +0 -1
- package/dist/lib/workspace-reset.d.ts.map +0 -1
- package/dist/lib/workspace-reset.js.map +0 -1
- package/dist/lib/workspace-schema.d.ts.map +0 -1
- package/dist/lib/workspace-schema.js.map +0 -1
- package/skills/benchmark/SKILL.md +0 -122
- package/skills/workflow/create/SKILL.md +0 -141
- package/skills/workspace/shape/SKILL.md +0 -15
- package/skills/workspace/structure/SKILL.md +0 -15
- package/skills/workspace/summarize/SKILL.md +0 -15
- package/templates/workspace/README.md +0 -24
- package/templates/workspace/interfignore +0 -2
package/README.md
CHANGED
|
@@ -2,9 +2,72 @@
|
|
|
2
2
|
|
|
3
3
|
Prepare local datasets for accurate agent use.
|
|
4
4
|
|
|
5
|
-
Interf Compiler runs local data-processing
|
|
5
|
+
Interf Compiler runs a local data-processing workflow over your dataset to build a compiled workspace: a file-based layer on top of your raw files that gives agents the full picture of the dataset they need to answer questions accurately.
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
Define truth checks to measure how accurately agents answer from your dataset.
|
|
8
|
+
|
|
9
|
+
Start with a baseline on your files as-is.
|
|
10
|
+
|
|
11
|
+
Then compile the workspace and retest it on the same checks so you can measure whether it actually helps.
|
|
12
|
+
|
|
13
|
+
Then run self-improving loops that revise the workflow, rebuild the workspace, and rerun the same truth checks until the workspace passes or reaches the loop limit.
|
|
14
|
+
|
|
15
|
+
## Why Use It
|
|
16
|
+
|
|
17
|
+
Interf Compiler is built around a few simple principles:
|
|
18
|
+
|
|
19
|
+
- `Local`: the dataset, workflow, workspace, and test runs stay on your machine.
|
|
20
|
+
- `File-based`: the compiled workspace is normal folders and files you can inspect, review, and version.
|
|
21
|
+
- `Source-backed`: your raw files stay the source of truth; the compiled workspace is a layer on top, not a replacement database.
|
|
22
|
+
- `Interoperable`: the same workspace can be used with different local agents and tools.
|
|
23
|
+
- `Self-improving`: when truth checks fail, Interf can retry the workflow or revise it, rebuild the workspace, and rerun the same checks.
|
|
24
|
+
|
|
25
|
+
## Example: Truth Checks
|
|
26
|
+
|
|
27
|
+
Truth checks are just question-and-answer pairs you already know how to verify from the dataset.
|
|
28
|
+
|
|
29
|
+
A maintained public test run in this repo uses checks like this:
|
|
30
|
+
|
|
31
|
+
<!-- PUBLIC_TEST_CHECKS:START -->
|
|
32
|
+
```jsonc
|
|
33
|
+
{
|
|
34
|
+
"workspaces": [
|
|
35
|
+
{
|
|
36
|
+
"name": "cbre-chart-sanity",
|
|
37
|
+
"about": "Bristol historical take-up and availability chart lookup.",
|
|
38
|
+
"checks": [
|
|
39
|
+
{
|
|
40
|
+
"question": "What were Bristol's annual take-up values in 2018 and 2016?",
|
|
41
|
+
"answer": "Around half a million sq ft in 2018, roughly 0.45 to 0.6 million sq ft, and about 0.7 to 0.8 million sq ft in 2016. These are approximate chart-derived reads."
|
|
42
|
+
},
|
|
43
|
+
{
|
|
44
|
+
"question": "What were Bristol's availability values in 2018 and 2016?",
|
|
45
|
+
"answer": "About 0.55 to 0.6 million sq ft in 2018 and about 1.2 to 1.3 million sq ft in 2016. These are approximate chart-derived reads."
|
|
46
|
+
}
|
|
47
|
+
]
|
|
48
|
+
}
|
|
49
|
+
]
|
|
50
|
+
}
|
|
51
|
+
```
|
|
52
|
+
<!-- PUBLIC_TEST_CHECKS:END -->
|
|
53
|
+
|
|
54
|
+
## Example: `interf test`
|
|
55
|
+
|
|
56
|
+
`interf test` compares the raw files and the compiled workspace on the same saved truth checks.
|
|
57
|
+
The table below is synced from a real public test run in this repo.
|
|
58
|
+
|
|
59
|
+
<!-- PUBLIC_TEST_TABLE:START -->
|
|
60
|
+
| Runner | Files as-is | Compiled workspace |
|
|
61
|
+
| --- | --- | --- |
|
|
62
|
+
| Codex (GPT-5.4, xhigh) | `2/2` | `2/2` |
|
|
63
|
+
| Claude Code (Claude Opus 4.6 1M, max) | `0/2` | `2/2` |
|
|
64
|
+
<!-- PUBLIC_TEST_TABLE:END -->
|
|
65
|
+
|
|
66
|
+
That is the point of `interf test`: measure the same checks on both sides and keep the result honest, even when a compiled workspace helps one model more than another.
|
|
67
|
+
|
|
68
|
+
Use `interf test` on your own dataset to measure files as-is versus the compiled workspace on the same checks.
|
|
69
|
+
|
|
70
|
+
Each run saves one comparison record under `.interf/tests/runs/`. Detailed target-specific runs and preserved sandboxes stay under `.interf/tests/targets/`.
|
|
8
71
|
|
|
9
72
|
## Quick Start
|
|
10
73
|
|
|
@@ -31,45 +94,36 @@ interf test
|
|
|
31
94
|
The first run can:
|
|
32
95
|
|
|
33
96
|
- save a few truth checks for the dataset
|
|
34
|
-
- test
|
|
97
|
+
- test your files as-is first on those same checks
|
|
35
98
|
- build the compiled workspace
|
|
36
99
|
- test the compiled workspace on the same truth checks
|
|
37
100
|
|
|
38
101
|
## What Interf Compiler Creates
|
|
39
102
|
|
|
40
|
-
|
|
103
|
+
After setup, the main persistent object is the compiled workspace:
|
|
41
104
|
|
|
42
|
-
- `interf.config.json` with your saved truth checks and workspace setup
|
|
43
105
|
- `interf/workspaces/<name>/` with the compiled workspace
|
|
44
|
-
- `interf/
|
|
106
|
+
- `interf/workspaces/<name>/.interf/interf.json` with the workspace-local runtime contract
|
|
107
|
+
- `interf/workspaces/<name>/.interf/tests/runs/...` with saved raw-vs-compiled test comparisons
|
|
108
|
+
|
|
109
|
+
The dataset root can also keep `interf.config.json` as bootstrap/setup for workspace names, truth checks, and compile defaults.
|
|
45
110
|
|
|
46
111
|
A compiled workspace is a folder on top of your dataset. It includes:
|
|
47
112
|
|
|
48
113
|
- a workspace-local `raw/` snapshot for direct evidence and verification
|
|
49
114
|
- agent-readable summaries and cross-file notes
|
|
50
115
|
- `AGENTS.md`, `CLAUDE.md`, and generated local query skills
|
|
51
|
-
- runtime state under `.interf/`
|
|
116
|
+
- workspace method, test, and runtime state under `.interf/`
|
|
52
117
|
|
|
53
118
|
The compiled workspace is the folder your agent should work from.
|
|
54
119
|
|
|
55
|
-
##
|
|
56
|
-
|
|
57
|
-
Raw dataset folders are hard for agents.
|
|
58
|
-
|
|
59
|
-
Common failure modes:
|
|
60
|
-
|
|
61
|
-
- missed evidence
|
|
62
|
-
- weak cross-file understanding
|
|
63
|
-
- bad comparisons
|
|
64
|
-
- answers that sound confident but are wrong
|
|
120
|
+
## How It Works
|
|
65
121
|
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
2. Build the compiled workspace.
|
|
72
|
-
3. Test raw vs compiled on the same truth checks.
|
|
122
|
+
1. Save a few truth checks for the dataset.
|
|
123
|
+
2. Optionally test your files as-is for a baseline.
|
|
124
|
+
3. Build the compiled workspace.
|
|
125
|
+
4. Test the compiled workspace on the same truth checks.
|
|
126
|
+
5. Optionally let Interf retry or improve the workflow until it passes or hits the configured limit.
|
|
73
127
|
|
|
74
128
|
Truth checks are simple:
|
|
75
129
|
|
|
@@ -82,115 +136,29 @@ Good first truth checks are small and practical:
|
|
|
82
136
|
- one short statement that should be true or false
|
|
83
137
|
- one simple comparison across years, files, or sections
|
|
84
138
|
|
|
85
|
-
If you want to see the config shape first, this is what Interf Compiler writes:
|
|
86
|
-
|
|
87
|
-
```jsonc
|
|
88
|
-
{
|
|
89
|
-
"workspaces": [
|
|
90
|
-
{
|
|
91
|
-
"name": "my-workspace",
|
|
92
|
-
"about": "General compiled workspace for the quarterly results folder.",
|
|
93
|
-
"max_attempts": 3, // rerun compile + test until this workspace passes the saved truth checks or hits this limit
|
|
94
|
-
"checks": [
|
|
95
|
-
{
|
|
96
|
-
"question": "What full-year revenue range did the company maintain?",
|
|
97
|
-
"answer": "$4.8B to $5.0B in revenue."
|
|
98
|
-
},
|
|
99
|
-
{
|
|
100
|
-
"question": "Did gross margin improve or decline year over year?",
|
|
101
|
-
"answer": "Gross margin declined year over year."
|
|
102
|
-
}
|
|
103
|
-
]
|
|
104
|
-
}
|
|
105
|
-
]
|
|
106
|
-
}
|
|
107
|
-
```
|
|
108
|
-
|
|
109
139
|
If `interf.config.json` is missing, `interf` or `interf init` can draft it with you before the first compile. If the compiler cannot find your local agent or compile setup, run:
|
|
110
140
|
|
|
111
141
|
```bash
|
|
112
142
|
interf doctor
|
|
113
143
|
```
|
|
114
144
|
|
|
115
|
-
Sample run:
|
|
116
|
-
|
|
117
|
-
```bash
|
|
118
|
-
cp -r examples/benchmark-demo /tmp/interf-demo
|
|
119
|
-
cd /tmp/interf-demo
|
|
120
|
-
interf
|
|
121
|
-
interf compile
|
|
122
|
-
interf test
|
|
123
|
-
```
|
|
124
|
-
|
|
125
145
|
## What `interf test` Does
|
|
126
146
|
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
It answers a simple question:
|
|
130
|
-
|
|
131
|
-
- does the compiled workspace help on this dataset or not?
|
|
132
|
-
|
|
133
|
-
By default it loads truth 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/`.
|
|
147
|
+
By default, if a compiled workspace exists, it runs both sides and saves one comparison under that workspace's `.interf/tests/runs/`.
|
|
134
148
|
|
|
135
149
|
For live runs:
|
|
136
150
|
|
|
137
|
-
- raw tests execute from a sanitized raw-only
|
|
151
|
+
- raw tests execute from a sanitized raw-only shell built from `raw/`
|
|
138
152
|
- compiled-workspace tests execute from a copied workspace sandbox with embedded sanitized `raw/`
|
|
139
|
-
-
|
|
140
|
-
-
|
|
153
|
+
- both sides use the same saved truth checks from that workspace's `.interf/interf.json`
|
|
154
|
+
- neither sandbox includes the dataset control plane
|
|
155
|
+
- detailed raw/workspace target runs are kept under `.interf/tests/targets/runs/`
|
|
156
|
+
- failed test sandboxes are kept automatically under `.interf/tests/targets/sandboxes/`
|
|
141
157
|
- `interf test --keep-sandboxes` keeps every sandbox, even successful ones
|
|
142
158
|
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
- whether the run tested `raw`, `workspace`, or both
|
|
146
|
-
- per-question results and traces
|
|
147
|
-
- the preserved sandbox path when one was kept
|
|
148
|
-
- the executor metadata for that run
|
|
149
|
-
|
|
150
|
-
If you run `interf test` from inside a workspace, it uses that workspace's truth 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.
|
|
151
|
-
|
|
152
|
-
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).
|
|
153
|
-
|
|
154
|
-
## What `interf compile` Does
|
|
155
|
-
|
|
156
|
-
`interf compile` runs the selected workflow over a dataset.
|
|
157
|
-
|
|
158
|
-
The built-in workflow:
|
|
159
|
+
From inside a workspace, `interf test` uses that workspace's `.interf/interf.json` directly. From the dataset root, `interf.config.json` only bootstraps workspace selection before the workspace-local runtime contract takes over.
|
|
159
160
|
|
|
160
|
-
|
|
161
|
-
- structure the cross-file knowledge layer into entities, claims, and indexes
|
|
162
|
-
- shape the final workspace around its saved focus and truth checks
|
|
163
|
-
|
|
164
|
-
In other words, the built-in workflow is:
|
|
165
|
-
|
|
166
|
-
1. `summarize`
|
|
167
|
-
2. `structure`
|
|
168
|
-
3. `shape`
|
|
169
|
-
|
|
170
|
-
If you want a different method, you can define your own workflow and test it on the same dataset.
|
|
171
|
-
|
|
172
|
-
Under the hood, each workflow defines:
|
|
173
|
-
|
|
174
|
-
- `workflow.json` for stage order, compiler API target, and deterministic contract mapping
|
|
175
|
-
- `workspace.schema.json` for the deterministic output shape of the compiled workspace
|
|
176
|
-
- stage `reads` / `writes` declarations that reference schema-defined zone ids
|
|
177
|
-
- local `SKILL.md` files as the authoring source for query and stage-execution behavior
|
|
178
|
-
|
|
179
|
-
The compiler then projects that workflow into the native agent surfaces it actually runs:
|
|
180
|
-
|
|
181
|
-
- the compiled workspace gets a generated native query shell
|
|
182
|
-
- each compile stage gets a generated native execution shell
|
|
183
|
-
- that shell keeps its own `AGENTS.md`, `CLAUDE.md`, and native local skills
|
|
184
|
-
- schema-declared workspace zones are mounted both at their workflow-relative paths and as shell-local `inputs/<zone-id>` / `outputs/<zone-id>` aliases
|
|
185
|
-
- the workspace root itself is not linked into the shell
|
|
186
|
-
|
|
187
|
-
If a workspace has `max_attempts`, or if you run `interf compile --max-attempts <n>`, the compiler can keep compiling, testing, and retrying until that workspace passes or reaches the attempt limit. If several attempts fail, it keeps the best-performing compiled workspace from that run.
|
|
188
|
-
|
|
189
|
-
For stage-level review:
|
|
190
|
-
|
|
191
|
-
- successful stage shells are pruned by default
|
|
192
|
-
- failed stage shells stay under `.interf/execution-shells/`
|
|
193
|
-
- `interf compile --keep-stage-shells` keeps every stage shell so you can inspect the exact native instruction surface, mounted inputs, and mounted outputs for each stage
|
|
161
|
+
Maintainers can use the internal repeated-test matrix runner in [docs/test-matrix.md](./docs/test-matrix.md) for controlled workflow or model comparisons. Normal users should stay on `interf test`.
|
|
194
162
|
|
|
195
163
|
## Advanced: Separate Workspaces
|
|
196
164
|
|
|
@@ -209,53 +177,62 @@ Why create another one:
|
|
|
209
177
|
- it gives that job its own compiled output under `interf/workspaces/<name>/`
|
|
210
178
|
- it lets you test that job separately
|
|
211
179
|
|
|
212
|
-
## Advanced:
|
|
180
|
+
## Advanced: Compile Loops
|
|
181
|
+
|
|
182
|
+
`max_attempts` is a retry budget for the same workflow variation.
|
|
183
|
+
|
|
184
|
+
Retries keep the target fixed:
|
|
213
185
|
|
|
214
|
-
|
|
186
|
+
- same dataset
|
|
187
|
+
- same workflow variation
|
|
188
|
+
- same truth checks
|
|
189
|
+
- same measurement
|
|
215
190
|
|
|
216
|
-
|
|
191
|
+
`max_loops` enables the self-improving workflow loop in the normal `interf compile` path.
|
|
217
192
|
|
|
218
|
-
|
|
193
|
+
In that loop, the thing that changes is the workflow itself.
|
|
219
194
|
|
|
220
|
-
|
|
195
|
+
Each loop can:
|
|
221
196
|
|
|
222
|
-
-
|
|
223
|
-
- it
|
|
224
|
-
-
|
|
225
|
-
-
|
|
226
|
-
-
|
|
197
|
+
- run the current workflow variation on the dataset
|
|
198
|
+
- test it on the same truth checks
|
|
199
|
+
- inspect the failed traces, preserved stage shells, and test artifacts
|
|
200
|
+
- review the workflow and stage docs
|
|
201
|
+
- create a new workflow variation for that dataset
|
|
202
|
+
- test the new variation on the same truth checks
|
|
227
203
|
|
|
228
|
-
|
|
204
|
+
- `max_attempts` retries the same workflow variation
|
|
205
|
+
- a self-improving loop creates and tests workflow variations
|
|
229
206
|
|
|
230
|
-
|
|
231
|
-
- `retry_policy.max_attempts_per_profile` controls how many attempts each compile profile gets in eval packs
|
|
232
|
-
- stronger diagnostic profiles can be used only after the default ones fail
|
|
233
|
-
- the truth checks stay the same across every attempt
|
|
234
|
-
- each attempt records what changed and which attempt performed best
|
|
207
|
+
The workflow is the right surface for that kind of improvement because it is:
|
|
235
208
|
|
|
236
|
-
|
|
209
|
+
- the reusable artifact
|
|
210
|
+
- the human-reviewable method
|
|
211
|
+
- the thing a future workflow-editing agent should inspect and change
|
|
212
|
+
|
|
213
|
+
Interf Compiler preserves the workflow-improvement shell, the workflow-before / workflow-after snapshots, the failed stage shells, and the saved test runs from each loop so you can inspect exactly what the loop reviewed and changed.
|
|
214
|
+
|
|
215
|
+
Example workspace config:
|
|
237
216
|
|
|
238
217
|
```jsonc
|
|
239
218
|
{
|
|
240
219
|
"workspaces": [
|
|
241
220
|
{
|
|
242
|
-
"name": "
|
|
243
|
-
"max_attempts": 3, //
|
|
221
|
+
"name": "cbre-chart-sanity",
|
|
222
|
+
"max_attempts": 3, // retry compile + test for the same workflow until this workspace passes or hits this limit
|
|
223
|
+
"max_loops": 2, // workflow-editing loops after retries fail
|
|
244
224
|
"checks": [
|
|
245
225
|
{
|
|
246
|
-
"question": "What
|
|
247
|
-
"answer": "
|
|
226
|
+
"question": "What were Bristol's annual take-up values in 2018 and 2016?",
|
|
227
|
+
"answer": "Around half a million sq ft in 2018, roughly 0.45 to 0.6 million sq ft, and about 0.7 to 0.8 million sq ft in 2016. These are approximate chart-derived reads."
|
|
248
228
|
}
|
|
249
229
|
]
|
|
250
230
|
}
|
|
251
|
-
]
|
|
252
|
-
"retry_policy": {
|
|
253
|
-
"max_attempts_per_profile": 3
|
|
254
|
-
}
|
|
231
|
+
]
|
|
255
232
|
}
|
|
256
233
|
```
|
|
257
234
|
|
|
258
|
-
Use the normal workspace retry loop first.
|
|
235
|
+
Use the normal workspace retry and loop controls first. Maintainers can use the internal repeated-test runner when they want controlled comparisons across workflows, compile profiles, or models.
|
|
259
236
|
|
|
260
237
|
## Use It With Your Agent
|
|
261
238
|
|
|
@@ -277,6 +254,12 @@ Tell me whether the compiled workspace passes the truth checks, and only recomme
|
|
|
277
254
|
|
|
278
255
|
Interf Compiler ships with a default workflow.
|
|
279
256
|
|
|
257
|
+
The built-in `interf` workflow runs three stages:
|
|
258
|
+
|
|
259
|
+
1. `summarize`
|
|
260
|
+
2. `structure`
|
|
261
|
+
3. `shape`
|
|
262
|
+
|
|
280
263
|
If you want to change how the workflow runs on your dataset, this is the part you customize:
|
|
281
264
|
|
|
282
265
|
```bash
|
|
@@ -293,20 +276,19 @@ Workflow docs live in [docs/workflow-spec.md](./docs/workflow-spec.md).
|
|
|
293
276
|
- `interf` = open the root-folder wizard
|
|
294
277
|
- `interf init` = alias for the root-folder wizard
|
|
295
278
|
- `interf create workspace` = create another compiled workspace when you need one
|
|
296
|
-
- `interf create workflow` = create a reusable local workflow
|
|
279
|
+
- `interf create workflow` = create a reusable local seed workflow
|
|
297
280
|
- `interf compile` = build a selected workspace for the current folder
|
|
298
|
-
- `interf test` =
|
|
299
|
-
- `interf benchmark` = alias for `interf test`
|
|
281
|
+
- `interf test` = compare the raw files and a compiled workspace on saved truth checks
|
|
300
282
|
- `interf doctor` = check local executor setup
|
|
301
283
|
- `interf verify <check>` = run deterministic checks on major workflow steps
|
|
302
284
|
- `interf reset <scope>` = remove generated state while keeping source files
|
|
303
285
|
|
|
304
286
|
## More Docs
|
|
305
287
|
|
|
306
|
-
- [docs/workflow-spec.md](./docs/workflow-spec.md) for custom
|
|
288
|
+
- [docs/workflow-spec.md](./docs/workflow-spec.md) for custom workflows
|
|
307
289
|
- [docs/runtime-contract.md](./docs/runtime-contract.md) for the exact on-disk contract
|
|
308
290
|
- [docs/architecture.md](./docs/architecture.md) for the deeper system model
|
|
309
|
-
- [docs/
|
|
291
|
+
- [docs/test-matrix.md](./docs/test-matrix.md) for the internal repeated-test matrix runner used in maintainer model/workflow comparisons
|
|
310
292
|
|
|
311
293
|
Maintainers should use [CONTRIBUTING.md](./CONTRIBUTING.md) for test and release gates.
|
|
312
294
|
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# Interf Compiler (Recommended)
|
|
2
|
+
|
|
3
|
+
Interf Compiler's default methodology: summarize source-grounded evidence, structure the cross-file layer, then shape the final workspace around its focus and saved truth checks.
|
|
4
|
+
|
|
5
|
+
## Package
|
|
6
|
+
|
|
7
|
+
- `workflow.json` = stage graph, compiler API target, and compile contract mapping
|
|
8
|
+
- `workspace.schema.json` = deterministic workspace output shape
|
|
9
|
+
- `improve/`, `compile/stages/`, and `use/query/` = human-readable authoring docs
|
|
10
|
+
- Portable workflow packages are standalone: explicit stages, schema, and docs live together in this folder
|
|
11
|
+
- Interf Compiler projects native agent shells from these docs for query use, stage execution, and workflow-improvement loops
|
|
12
|
+
|
|
13
|
+
## Stages
|
|
14
|
+
|
|
15
|
+
- `summarize` — Turn source files into per-file summaries. (workspace-file-evidence; reads: raw, runtime; writes: summaries)
|
|
16
|
+
- `structure` — Build the cross-file knowledge structure from the summaries. (workspace-knowledge-structure; reads: summaries, runtime; writes: knowledge-entities, knowledge-claims, knowledge-indexes)
|
|
17
|
+
- `shape` — Shape the final workspace around the saved focus and truth checks. (workspace-query-shape; reads: raw, summaries, knowledge-entities, knowledge-claims, knowledge-indexes, runtime; writes: knowledge-indexes, home)
|
|
18
|
+
|
|
19
|
+
This package is the built-in seed for `interf`. Interf Compiler copies or materializes it into `.interf/workflow/` and runs that workspace-local package directly.
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
# Shape
|
|
2
|
+
|
|
3
|
+
Shape the final workspace around the saved focus and truth checks.
|
|
4
|
+
|
|
5
|
+
Contract type: `workspace-query-shape`
|
|
6
|
+
|
|
7
|
+
## Requirements
|
|
8
|
+
|
|
9
|
+
- Use the workspace focus plus saved truth-check question text to shape `home.md` and retrieval routes.
|
|
10
|
+
- Rewrite `home.md` into a real entrypoint note. Do not leave the scaffold `Not yet compiled.` placeholder in place.
|
|
11
|
+
- When a chart-derived value is approximate, use a bounded range instead of a pseudo-exact number.
|
|
12
|
+
- Match the granularity of the visible axis labels or bands. Do not invent finer precision than the chart supports.
|
|
13
|
+
- Keep the answer inside the visible tick band unless the chart supports a tighter bound.
|
|
14
|
+
- Use an upper-half or lower-half band only when the mark clearly sits there.
|
|
15
|
+
- If a mark touches or nearly touches a labeled gridline, anchor the answer at that gridline or the immediately adjacent half-band.
|
|
16
|
+
- Do not widen a chart-derived range across multiple visible bands unless the chart genuinely supports that uncertainty.
|
|
17
|
+
- When you settle on a bounded chart read, keep that same band consistent across `home.md`, focused indexes, and claim/entity notes for that metric and year.
|
|
18
|
+
- Do not copy expected answers into the workspace.
|
|
19
|
+
|
|
20
|
+
## Notes
|
|
21
|
+
|
|
22
|
+
- Use the workspace focus and saved truth checks to bias the final workspace toward the job it should be especially good at.
|
|
23
|
+
- Do not copy expected answers into the final workspace just because the checks imply them.
|
|
24
|
+
- Prefer the saved summary evidence and structured notes when they already preserve the bounded chart/table reads plus provenance you need.
|
|
25
|
+
- Reopen `raw/` during shaping only when the compiled layer is missing the needed value, the metric family is ambiguous, or the earlier bounded read is clearly inconsistent.
|
|
26
|
+
- If a saved truth check depends on chart-derived or table-derived values, carry the final bounded reads forward into focused notes with provenance instead of repeatedly recomputing them from raw.
|
|
27
|
+
- Prefer better routing, prioritization, and focused navigation over speculative synthesis.
|
|
28
|
+
- Any wikilinks you add to `home.md` or indexes must resolve to real workspace note basenames or explicit relative paths.
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
# Structure
|
|
2
|
+
|
|
3
|
+
Build the cross-file knowledge structure from the summaries.
|
|
4
|
+
|
|
5
|
+
Contract type: `workspace-knowledge-structure`
|
|
6
|
+
|
|
7
|
+
## Requirements
|
|
8
|
+
|
|
9
|
+
- Treat the knowledge layer as retrieval structure, not final truth.
|
|
10
|
+
- Prefer durable entity, claim, and index notes over one giant catch-all file.
|
|
11
|
+
|
|
12
|
+
## Notes
|
|
13
|
+
|
|
14
|
+
- Bias structure toward canonical entities, claims, timelines, and stable indexes.
|
|
15
|
+
- Use taxonomy and ontology only as means to improve retrieval, navigation, and evidence tracking.
|
|
16
|
+
- For small datasets, prefer a minimal stable substrate over exhaustive graph sprawl.
|
|
17
|
+
- When you add wikilinks, target real workspace notes by exact basename or explicit relative path. Do not invent title-style links unless that exact title is also a declared note label or alias.
|
|
18
|
+
- For summary references, prefer explicit links like `[[summaries/<file-stem>]]` or plain code paths. For knowledge notes, prefer the final filename stem under `knowledge/`.
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
# Summarize
|
|
2
|
+
|
|
3
|
+
Turn source files into per-file summaries.
|
|
4
|
+
|
|
5
|
+
Contract type: `workspace-file-evidence`
|
|
6
|
+
|
|
7
|
+
## Requirements
|
|
8
|
+
|
|
9
|
+
- Each summary must use JSON frontmatter and include `source`, `source_kind`, `evidence_tier`, `truth_mode`, `state`, and a non-empty `abstract`.
|
|
10
|
+
- Include a clear abstract block in the body so a human can skim the summary quickly.
|
|
11
|
+
- Do not skip the abstract just because the overview section is present.
|
|
12
|
+
|
|
13
|
+
## Notes
|
|
14
|
+
|
|
15
|
+
- Favor conservative, source-grounded summaries that preserve evidence tiers and leave broader synthesis for later stages.
|
|
16
|
+
- For large reports or decks, capture scope, headline evidence, and chart/table routing in one light pass.
|
|
17
|
+
- As soon as one report summary can state scope, headline metrics, and chart/table routing, stop reading and write the summary batch plus runtime artifacts immediately.
|
|
18
|
+
- Keep scratch extraction commands single-purpose and non-destructive.
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
# Workflow Improvement
|
|
2
|
+
|
|
3
|
+
Workflow: interf
|
|
4
|
+
|
|
5
|
+
This file is the editable authoring source for Interf Compiler's generated native workflow-improver shell.
|
|
6
|
+
The improver edits this workspace-local package directly.
|
|
7
|
+
|
|
8
|
+
Default loop:
|
|
9
|
+
1. Read the loop context first.
|
|
10
|
+
2. Review preserved stage shells, runtime logs, and saved test runs from failed attempts.
|
|
11
|
+
3. Edit only the local workflow package for this workspace to create a better workflow variation for this dataset.
|
|
12
|
+
4. Keep `workflow.json`, `workspace.schema.json`, and any changed stage docs aligned.
|
|
13
|
+
|
|
14
|
+
Guardrails:
|
|
15
|
+
- do not edit truth checks, test specs, or raw dataset files
|
|
16
|
+
- do not hardcode expected answers into workflow docs
|
|
17
|
+
- keep this package standalone; do not add or rely on runtime `extends` or fallback behavior
|
|
18
|
+
- prefer small, defensible workflow changes over random churn
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
# Manual Query Loop
|
|
2
|
+
|
|
3
|
+
This file is the editable authoring source for the generated native local `interf-query` skill.
|
|
4
|
+
|
|
5
|
+
Default loop:
|
|
6
|
+
1. Read `home.md` first.
|
|
7
|
+
2. Browse `knowledge/` before `raw/`.
|
|
8
|
+
3. Use `summaries/` for source-grounded evidence.
|
|
9
|
+
4. Use `raw/` for direct quotes, verification, exact table lookups, and chart-derived values.
|
|
10
|
+
|
|
11
|
+
Answering rule:
|
|
12
|
+
- do not modify files under `raw/`
|
|
13
|
+
- when a number is chart-derived, say that explicitly
|
|
14
|
+
- if the compiled layer already contains a bounded chart-derived read for the exact metric and year the user asked about, answer from that compiled read first
|
|
15
|
+
- use `raw/` to confirm the source page, metric family, or provenance, not to replace a good compiled bounded read with a second incompatible range
|
|
16
|
+
- when the compiled layer preserves a bounded chart-derived range, keep that bounded range in the answer instead of collapsing it to a midpoint or pseudo-exact single value
|
|
17
|
+
- match the granularity of the visible axis labels or bands and do not invent finer precision than the chart supports
|
|
18
|
+
- when reading charts, verify you are on the correct metric family and year before answering
|
|
19
|
+
- keep historical annual charts separate from current-quarter snapshots, sector splits, or nearby lookalike panels
|
|
20
|
+
- when a chart-derived value is approximate, use a bounded range instead of a pseudo-exact number.
|
|
21
|
+
- keep the answer inside the visible tick band unless the chart supports a tighter bound.
|
|
22
|
+
- use an upper-half or lower-half band only when the mark clearly sits there.
|
|
23
|
+
- if a mark touches or nearly touches a labeled gridline, anchor the answer at that gridline or the immediately adjacent half-band.
|
|
24
|
+
- do not widen a chart-derived range across multiple visible bands unless the chart genuinely supports that uncertainty.
|
|
25
|
+
- if multiple compiled notes mention the same chart read, keep the answer consistent with the most focused workspace note rather than synthesizing a new midpoint or shifted band
|
|
26
|
+
- when the compiled layer is insufficient, verify in `raw/` and then answer
|
|
27
|
+
|
|
28
|
+
You can edit this file to bias manual question-answering behavior for this workspace.
|
|
@@ -0,0 +1,120 @@
|
|
|
1
|
+
{
|
|
2
|
+
"id": "interf",
|
|
3
|
+
"type": "workspace",
|
|
4
|
+
"compiler_api": {
|
|
5
|
+
"kind": "workspace",
|
|
6
|
+
"version": 1
|
|
7
|
+
},
|
|
8
|
+
"label": "Interf Compiler (Recommended)",
|
|
9
|
+
"hint": "Interf Compiler's default methodology: summarize source-grounded evidence, structure the cross-file layer, then shape the final workspace around its focus and saved truth checks.",
|
|
10
|
+
"stages": [
|
|
11
|
+
{
|
|
12
|
+
"id": "summarize",
|
|
13
|
+
"label": "Summarize",
|
|
14
|
+
"description": "Turn source files into per-file summaries.",
|
|
15
|
+
"contract_type": "workspace-file-evidence",
|
|
16
|
+
"skill_dir": "summarize",
|
|
17
|
+
"reads": [
|
|
18
|
+
"raw",
|
|
19
|
+
"runtime"
|
|
20
|
+
],
|
|
21
|
+
"writes": [
|
|
22
|
+
"summaries"
|
|
23
|
+
],
|
|
24
|
+
"acceptance": {
|
|
25
|
+
"artifacts_exist": [
|
|
26
|
+
".interf/runtime/inventory.json"
|
|
27
|
+
],
|
|
28
|
+
"state_truthy": [
|
|
29
|
+
"last_summarize",
|
|
30
|
+
"inventory_complete"
|
|
31
|
+
],
|
|
32
|
+
"state_at_least_counts": {
|
|
33
|
+
"summarized": "expected_summary_total"
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
},
|
|
37
|
+
{
|
|
38
|
+
"id": "structure",
|
|
39
|
+
"label": "Structure",
|
|
40
|
+
"description": "Build the cross-file knowledge structure from the summaries.",
|
|
41
|
+
"contract_type": "workspace-knowledge-structure",
|
|
42
|
+
"skill_dir": "structure",
|
|
43
|
+
"reads": [
|
|
44
|
+
"summaries",
|
|
45
|
+
"runtime"
|
|
46
|
+
],
|
|
47
|
+
"writes": [
|
|
48
|
+
"knowledge-entities",
|
|
49
|
+
"knowledge-claims",
|
|
50
|
+
"knowledge-indexes"
|
|
51
|
+
],
|
|
52
|
+
"acceptance": {
|
|
53
|
+
"artifacts_exist": [
|
|
54
|
+
"knowledge/indexes"
|
|
55
|
+
],
|
|
56
|
+
"state_truthy": [
|
|
57
|
+
"last_structure",
|
|
58
|
+
"inventory_complete"
|
|
59
|
+
],
|
|
60
|
+
"state_at_least_counts": {
|
|
61
|
+
"structured": "summary_total"
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
},
|
|
65
|
+
{
|
|
66
|
+
"id": "shape",
|
|
67
|
+
"label": "Shape",
|
|
68
|
+
"description": "Shape the final workspace around the saved focus and truth checks.",
|
|
69
|
+
"contract_type": "workspace-query-shape",
|
|
70
|
+
"skill_dir": "shape",
|
|
71
|
+
"reads": [
|
|
72
|
+
"raw",
|
|
73
|
+
"summaries",
|
|
74
|
+
"knowledge-entities",
|
|
75
|
+
"knowledge-claims",
|
|
76
|
+
"knowledge-indexes",
|
|
77
|
+
"runtime"
|
|
78
|
+
],
|
|
79
|
+
"writes": [
|
|
80
|
+
"knowledge-indexes",
|
|
81
|
+
"home"
|
|
82
|
+
],
|
|
83
|
+
"acceptance": {
|
|
84
|
+
"artifacts_exist": [
|
|
85
|
+
"home.md"
|
|
86
|
+
],
|
|
87
|
+
"state_truthy": [
|
|
88
|
+
"last_shape",
|
|
89
|
+
"inventory_complete"
|
|
90
|
+
],
|
|
91
|
+
"state_at_least_counts": {
|
|
92
|
+
"shaped": "summary_total",
|
|
93
|
+
"compiled": "summary_total"
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
],
|
|
98
|
+
"stage_policy_notes": {
|
|
99
|
+
"summarize": [
|
|
100
|
+
"Favor conservative, source-grounded summaries that preserve evidence tiers and leave broader synthesis for later stages.",
|
|
101
|
+
"For large reports or decks, capture scope, headline evidence, and chart/table routing in one light pass.",
|
|
102
|
+
"As soon as one report summary can state scope, headline metrics, and chart/table routing, stop reading and write the summary batch plus runtime artifacts immediately.",
|
|
103
|
+
"Keep scratch extraction commands single-purpose and non-destructive."
|
|
104
|
+
],
|
|
105
|
+
"structure": [
|
|
106
|
+
"Bias structure toward canonical entities, claims, timelines, and stable indexes.",
|
|
107
|
+
"Use taxonomy and ontology only as means to improve retrieval, navigation, and evidence tracking.",
|
|
108
|
+
"For small datasets, prefer a minimal stable substrate over exhaustive graph sprawl.",
|
|
109
|
+
"When you add wikilinks, target real workspace notes by exact basename or explicit relative path. Do not invent title-style links unless that exact title is also a declared note label or alias.",
|
|
110
|
+
"For summary references, prefer explicit links like `[[summaries/<file-stem>]]` or plain code paths. For knowledge notes, prefer the final filename stem under `knowledge/`."
|
|
111
|
+
],
|
|
112
|
+
"shape": [
|
|
113
|
+
"Use the workspace focus and saved truth checks to bias the final workspace toward the job it should be especially good at.",
|
|
114
|
+
"Do not copy expected answers into the final workspace just because the checks imply them.",
|
|
115
|
+
"If a saved truth check depends on chart-derived or table-derived values, verify the needed evidence in `raw/` while shaping and write focused notes that preserve bounded values plus provenance.",
|
|
116
|
+
"Prefer better routing, prioritization, and focused navigation over speculative synthesis.",
|
|
117
|
+
"Any wikilinks you add to `home.md` or indexes must resolve to real workspace note basenames or explicit relative paths."
|
|
118
|
+
]
|
|
119
|
+
}
|
|
120
|
+
}
|