oh-my-knowledge 0.25.1 → 0.27.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 +111 -366
- package/README.zh.md +148 -395
- package/dist/src/analysis/report-diagnostics.d.ts +1 -1
- package/dist/src/analysis/report-diagnostics.js +1 -1
- package/dist/src/analysis/sample-diagnostics.d.ts +2 -2
- package/dist/src/analysis/sample-diagnostics.js +2 -2
- package/dist/src/authoring/generator.d.ts.map +1 -1
- package/dist/src/authoring/generator.js +9 -8
- package/dist/src/authoring/generator.js.map +1 -1
- package/dist/src/cli/cli-exit.d.ts +15 -0
- package/dist/src/cli/cli-exit.d.ts.map +1 -0
- package/dist/src/cli/cli-exit.js +19 -0
- package/dist/src/cli/cli-exit.js.map +1 -0
- package/dist/src/cli/commands/_shared.d.ts +12 -0
- package/dist/src/cli/commands/_shared.d.ts.map +1 -0
- package/dist/src/cli/commands/_shared.js +26 -0
- package/dist/src/cli/commands/_shared.js.map +1 -0
- package/dist/src/cli/commands/doctor.d.ts +2 -0
- package/dist/src/cli/commands/doctor.d.ts.map +1 -0
- package/dist/src/cli/commands/doctor.js +137 -0
- package/dist/src/cli/commands/doctor.js.map +1 -0
- package/dist/src/cli/commands/eval-debias.d.ts +2 -0
- package/dist/src/cli/commands/eval-debias.d.ts.map +1 -0
- package/dist/src/cli/commands/eval-debias.js +88 -0
- package/dist/src/cli/commands/eval-debias.js.map +1 -0
- package/dist/src/cli/commands/eval-gold.d.ts +2 -0
- package/dist/src/cli/commands/eval-gold.d.ts.map +1 -0
- package/dist/src/cli/commands/eval-gold.js +137 -0
- package/dist/src/cli/commands/eval-gold.js.map +1 -0
- package/dist/src/cli/commands/eval-runner.d.ts +2 -0
- package/dist/src/cli/commands/eval-runner.d.ts.map +1 -0
- package/dist/src/cli/commands/eval-runner.js +299 -0
- package/dist/src/cli/commands/eval-runner.js.map +1 -0
- package/dist/src/cli/commands/eval.d.ts +2 -0
- package/dist/src/cli/commands/eval.d.ts.map +1 -0
- package/dist/src/cli/commands/eval.js +16 -0
- package/dist/src/cli/commands/eval.js.map +1 -0
- package/dist/src/cli/commands/export-diff.d.ts +2 -0
- package/dist/src/cli/commands/export-diff.d.ts.map +1 -0
- package/dist/src/cli/commands/export-diff.js +177 -0
- package/dist/src/cli/commands/export-diff.js.map +1 -0
- package/dist/src/cli/commands/export-saturation.d.ts +2 -0
- package/dist/src/cli/commands/export-saturation.d.ts.map +1 -0
- package/dist/src/cli/commands/export-saturation.js +59 -0
- package/dist/src/cli/commands/export-saturation.js.map +1 -0
- package/dist/src/cli/commands/export-verdict.d.ts +2 -0
- package/dist/src/cli/commands/export-verdict.d.ts.map +1 -0
- package/dist/src/cli/commands/export-verdict.js +45 -0
- package/dist/src/cli/commands/export-verdict.js.map +1 -0
- package/dist/src/cli/commands/export.d.ts +2 -0
- package/dist/src/cli/commands/export.d.ts.map +1 -0
- package/dist/src/cli/commands/export.js +150 -0
- package/dist/src/cli/commands/export.js.map +1 -0
- package/dist/src/cli/commands/improve-failures.d.ts +2 -0
- package/dist/src/cli/commands/improve-failures.d.ts.map +1 -0
- package/dist/src/cli/commands/improve-failures.js +59 -0
- package/dist/src/cli/commands/improve-failures.js.map +1 -0
- package/dist/src/cli/commands/improve-plan.d.ts +2 -0
- package/dist/src/cli/commands/improve-plan.d.ts.map +1 -0
- package/dist/src/cli/commands/improve-plan.js +75 -0
- package/dist/src/cli/commands/improve-plan.js.map +1 -0
- package/dist/src/cli/commands/improve-samples.d.ts +2 -0
- package/dist/src/cli/commands/improve-samples.d.ts.map +1 -0
- package/dist/src/cli/commands/improve-samples.js +120 -0
- package/dist/src/cli/commands/improve-samples.js.map +1 -0
- package/dist/src/cli/commands/improve-skill.d.ts +2 -0
- package/dist/src/cli/commands/improve-skill.d.ts.map +1 -0
- package/dist/src/cli/commands/improve-skill.js +115 -0
- package/dist/src/cli/commands/improve-skill.js.map +1 -0
- package/dist/src/cli/commands/improve.d.ts +2 -0
- package/dist/src/cli/commands/improve.d.ts.map +1 -0
- package/dist/src/cli/commands/improve.js +34 -0
- package/dist/src/cli/commands/improve.js.map +1 -0
- package/dist/src/cli/commands/init.d.ts +2 -0
- package/dist/src/cli/commands/init.d.ts.map +1 -0
- package/dist/src/cli/commands/init.js +110 -0
- package/dist/src/cli/commands/init.js.map +1 -0
- package/dist/src/cli/commands/observe.d.ts +2 -0
- package/dist/src/cli/commands/observe.d.ts.map +1 -0
- package/dist/src/cli/commands/observe.js +77 -0
- package/dist/src/cli/commands/observe.js.map +1 -0
- package/dist/src/cli/commands/registry.d.ts +11 -0
- package/dist/src/cli/commands/registry.d.ts.map +1 -0
- package/dist/src/cli/commands/registry.js +42 -0
- package/dist/src/cli/commands/registry.js.map +1 -0
- package/dist/src/cli/commands/studio.d.ts +2 -0
- package/dist/src/cli/commands/studio.d.ts.map +1 -0
- package/dist/src/cli/commands/studio.js +76 -0
- package/dist/src/cli/commands/studio.js.map +1 -0
- package/dist/src/cli/coverage-renderer.d.ts +1 -1
- package/dist/src/cli/coverage-renderer.js +1 -1
- package/dist/src/cli/i18n-dict.d.ts +4 -4
- package/dist/src/cli/i18n-dict.d.ts.map +1 -1
- package/dist/src/cli/i18n-dict.js +613 -581
- package/dist/src/cli/i18n-dict.js.map +1 -1
- package/dist/src/cli/index.js +43 -1487
- package/dist/src/cli/index.js.map +1 -1
- package/dist/src/cli/parse-run-config.d.ts +3 -4
- package/dist/src/cli/parse-run-config.d.ts.map +1 -1
- package/dist/src/cli/parse-run-config.js +5 -5
- package/dist/src/cli/parse-run-config.js.map +1 -1
- package/dist/src/cli/parse-strict.d.ts +0 -13
- package/dist/src/cli/parse-strict.d.ts.map +1 -1
- package/dist/src/cli/parse-strict.js +2 -1
- package/dist/src/cli/parse-strict.js.map +1 -1
- package/dist/src/cli/run-tally.d.ts +18 -0
- package/dist/src/cli/run-tally.d.ts.map +1 -0
- package/dist/src/cli/run-tally.js +31 -0
- package/dist/src/cli/run-tally.js.map +1 -0
- package/dist/src/doctor/index.d.ts +2 -2
- package/dist/src/doctor/index.d.ts.map +1 -1
- package/dist/src/doctor/index.js +19 -5
- package/dist/src/doctor/index.js.map +1 -1
- package/dist/src/doctor/preflight.d.ts +2 -2
- package/dist/src/doctor/preflight.js +2 -2
- package/dist/src/doctor/rules.d.ts +1 -1
- package/dist/src/doctor/rules.d.ts.map +1 -1
- package/dist/src/doctor/rules.js +49 -9
- package/dist/src/doctor/rules.js.map +1 -1
- package/dist/src/eval-core/dependency-checker.d.ts +9 -3
- package/dist/src/eval-core/dependency-checker.d.ts.map +1 -1
- package/dist/src/eval-core/dependency-checker.js +16 -29
- package/dist/src/eval-core/dependency-checker.js.map +1 -1
- package/dist/src/eval-core/fact-checker.js +1 -1
- package/dist/src/eval-core/fact-checker.js.map +1 -1
- package/dist/src/eval-core/layer-gates.d.ts +1 -1
- package/dist/src/eval-core/layer-gates.js +1 -1
- package/dist/src/eval-core/verdict.d.ts +4 -4
- package/dist/src/eval-core/verdict.d.ts.map +1 -1
- package/dist/src/eval-core/verdict.js +2 -2
- package/dist/src/eval-workflows/batch-evaluation-workflow.d.ts +15 -2
- package/dist/src/eval-workflows/batch-evaluation-workflow.d.ts.map +1 -1
- package/dist/src/eval-workflows/batch-evaluation-workflow.js +13 -2
- package/dist/src/eval-workflows/batch-evaluation-workflow.js.map +1 -1
- package/dist/src/eval-workflows/evaluation-pipeline.d.ts +6 -3
- package/dist/src/eval-workflows/evaluation-pipeline.d.ts.map +1 -1
- package/dist/src/eval-workflows/evaluation-pipeline.js +10 -9
- package/dist/src/eval-workflows/evaluation-pipeline.js.map +1 -1
- package/dist/src/eval-workflows/run-evaluation.d.ts +1 -1
- package/dist/src/eval-workflows/run-evaluation.d.ts.map +1 -1
- package/dist/src/eval-workflows/run-evaluation.js +14 -7
- package/dist/src/eval-workflows/run-evaluation.js.map +1 -1
- package/dist/src/executors/script.d.ts.map +1 -1
- package/dist/src/executors/script.js +16 -3
- package/dist/src/executors/script.js.map +1 -1
- package/dist/src/grading/debias-validate.d.ts +2 -2
- package/dist/src/grading/debias-validate.js +2 -2
- package/dist/src/grading/gold-cli.d.ts +2 -5
- package/dist/src/grading/gold-cli.d.ts.map +1 -1
- package/dist/src/grading/gold-cli.js +4 -8
- package/dist/src/grading/gold-cli.js.map +1 -1
- package/dist/src/grading/judge.d.ts +1 -1
- package/dist/src/renderer/html-renderer.js +1 -1
- package/dist/src/renderer/layout.js +5 -5
- package/dist/src/renderer/layout.js.map +1 -1
- package/dist/src/renderer/skill-health-renderer.d.ts +1 -1
- package/dist/src/renderer/skill-health-renderer.js +1 -1
- package/dist/src/renderer/summary.js +8 -8
- package/dist/src/server/report-server.d.ts +1 -0
- package/dist/src/server/report-server.d.ts.map +1 -1
- package/dist/src/server/report-server.js +40 -6
- package/dist/src/server/report-server.js.map +1 -1
- package/dist/src/types/doctor.d.ts +28 -6
- package/dist/src/types/doctor.d.ts.map +1 -1
- package/dist/src/types/doctor.js +3 -1
- package/dist/src/types/doctor.js.map +1 -1
- package/dist/src/types/eval.d.ts +1 -1
- package/dist/src/types/report.d.ts +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -21,31 +21,14 @@ omk answers with objective data, not gut feeling.
|
|
|
21
21
|
## Quick start
|
|
22
22
|
|
|
23
23
|
```bash
|
|
24
|
-
# install
|
|
25
24
|
npm i oh-my-knowledge -g
|
|
26
|
-
|
|
27
|
-
#
|
|
28
|
-
omk
|
|
29
|
-
cd my-eval
|
|
30
|
-
|
|
31
|
-
# drop the artifacts you want to compare into skills/
|
|
32
|
-
# option 1: plain .md files (skills/v1.md, skills/v2.md)
|
|
33
|
-
# option 2: full artifact dirs (skills/my-skill-v1/SKILL.md, ...)
|
|
34
|
-
# a single artifact also works — baseline is auto-added as control
|
|
35
|
-
|
|
36
|
-
# preview the plan
|
|
37
|
-
omk bench run --dry-run
|
|
38
|
-
|
|
39
|
-
# run the evaluation (auto-discovers everything under skills/)
|
|
40
|
-
omk bench run # → HTML report with verdict in 5 minutes
|
|
41
|
-
# (omk doctor + LLM connectivity check both run as mandatory gates;
|
|
42
|
-
# --skip-connectivity available for connectivity, doctor is unconditional)
|
|
43
|
-
|
|
44
|
-
# CLI output language: zh (default) / en — flag wins over env
|
|
45
|
-
omk bench run --lang en
|
|
46
|
-
OMK_LANG=en omk bench report
|
|
25
|
+
omk init my-eval && cd my-eval
|
|
26
|
+
# edit skills/code-review-v1/SKILL.md and skills/code-review-v2/SKILL.md with your two versions
|
|
27
|
+
omk eval --control code-review-v1 --treatment code-review-v2 # → HTML report with verdict in 5 minutes
|
|
47
28
|
```
|
|
48
29
|
|
|
30
|
+
Deeper: [use inside Claude Code / Codex](#use-inside-ai-coding-agents) · [`omk eval` flags](#omk-eval) · [artifact directory layout](#artifact-directory-layout) · [`--lang` / `OMK_LANG`](#environment-variables)
|
|
31
|
+
|
|
49
32
|
## Use inside AI Coding Agents
|
|
50
33
|
|
|
51
34
|
### Use inside Claude Code
|
|
@@ -54,8 +37,8 @@ When the `omk` skill is available in Claude Code, you can invoke it directly lik
|
|
|
54
37
|
|
|
55
38
|
```bash
|
|
56
39
|
/omk eval # evaluate the artifact(s) in the current project
|
|
57
|
-
/omk
|
|
58
|
-
/omk
|
|
40
|
+
/omk improve skill # auto-iterate to improve an artifact
|
|
41
|
+
/omk improve samples # generate test cases
|
|
59
42
|
```
|
|
60
43
|
|
|
61
44
|
You can also just say "compare v1 vs v2 for me" or "improve this artifact" and omk picks the right command.
|
|
@@ -65,9 +48,9 @@ You can also just say "compare v1 vs v2 for me" or "improve this artifact" and o
|
|
|
65
48
|
Codex does not support Claude Code style `/omk ...` slash commands by default. In Codex, the usual pattern is to ask the agent to run the `omk` CLI directly, for example:
|
|
66
49
|
|
|
67
50
|
```bash
|
|
68
|
-
omk
|
|
69
|
-
omk
|
|
70
|
-
omk
|
|
51
|
+
omk eval
|
|
52
|
+
omk improve skill skills/my-skill.md
|
|
53
|
+
omk improve samples skills/my-skill.md
|
|
71
54
|
```
|
|
72
55
|
|
|
73
56
|
You can also describe the goal in natural language, such as "compare v1 vs v2" or "generate test cases for this skill".
|
|
@@ -78,13 +61,13 @@ Teams doing knowledge engineering produce lots of knowledge artifacts (skills to
|
|
|
78
61
|
|
|
79
62
|
## Key features
|
|
80
63
|
|
|
81
|
-
- **Pre-evaluation health check** — `omk doctor` runs as a mandatory gate before `
|
|
82
|
-
- **Controlled-variable offline
|
|
64
|
+
- **Pre-evaluation health check** — `omk doctor` runs as a mandatory gate before `omk eval`; checks skill readability, metadata, dependencies, samples contract — pure static, zero LLM calls (like lint + typecheck for knowledge artifacts). Executor / judge connectivity is a separate phase, controllable via `--skip-connectivity`
|
|
65
|
+
- **Controlled-variable offline eval** — fix the model and samples, vary only the artifact; works with Claude Code skills, CLAUDE.md prompts, RAG knowledge bases, or any markdown-based instruction
|
|
83
66
|
- **Six-dimension scoring** — separate signals for Fact / Behavior / LLM-judge / Cost / Efficiency / Stability, so a regression in one axis isn't hidden by gains in another
|
|
84
67
|
- **Production session observability** — parse Claude Code session JSONL traces, measure per-skill failure rate, latency, token cost, and knowledge-gap signals on real user sessions
|
|
85
68
|
- **Knowledge-gap detection** — severity-weighted signals (explicit markers / failed searches / hedging language / repeated failures) quantify risk exposure instead of claiming completeness
|
|
86
|
-
- **Pre-merge CI gate** — `omk
|
|
87
|
-
- **One-line ship/no-ship verdict** — `omk
|
|
69
|
+
- **Pre-merge CI gate** — `omk eval` enforces three-layer all-pass (fact + behavior + llm-judge) semantics, catching single-layer regressions a composite score would hide
|
|
70
|
+
- **One-line ship/no-ship verdict** — `omk eval` aggregates bootstrap CI / three-layer ci-gate / saturation / human α into a six-tier verdict (PROGRESS / CAUTIOUS / REGRESS / NOISE / UNDERPOWERED / SOLO) plus an action recommendation; the exit code reflects whether to ship
|
|
88
71
|
|
|
89
72
|
## Why omk over alternatives
|
|
90
73
|
|
|
@@ -107,17 +90,17 @@ RAG-specific evals: see RAGAS (separate niche, complementary to omk). Full compa
|
|
|
107
90
|
|
|
108
91
|
| Feature | What it does |
|
|
109
92
|
|---|---|
|
|
110
|
-
| **One-line verdict** | `omk
|
|
93
|
+
| **One-line verdict** | `omk eval` six-tier verdict + ship recommendation + exit-code routing; HTML pill shares the same rules |
|
|
111
94
|
| **Six-dim evaluation** | Fact / Behavior / LLM-judge / Cost / Efficiency / Stability shown independently |
|
|
112
95
|
| **Multi-executor** | Claude CLI / Claude SDK / Codex CLI / Codex SDK / OpenAI / Gemini / any custom command |
|
|
113
96
|
| **21+ assertion types** | substring, regex, JSON Schema, ROUGE/BLEU/Levenshtein similarity, agent tool-call assertions, semantic similarity, custom JS, and more |
|
|
114
97
|
| **Statistical rigor** | Bootstrap CI / Krippendorff α / length-debias / saturation curve — all on by default. [Details →](docs/statistical-rigor.md) |
|
|
115
|
-
| **Sample diagnostics** | `omk
|
|
116
|
-
| **Failure clustering** | `omk
|
|
98
|
+
| **Sample diagnostics** | `omk improve <id>` — 7 issue kinds (low discrimination / duplicates / ambiguous rubric / cost outliers / etc.) + 0-100 healthScore |
|
|
99
|
+
| **Failure clustering** | `omk improve failures <id>` — single LLM call clusters failed samples and emits per-cluster fixes |
|
|
117
100
|
| **RAG metrics** | `faithfulness` / `answer_relevancy` / `context_recall` — anti-hallucination + answer relevance + context coverage; auto-inherits length-debias |
|
|
118
101
|
| **Hard budget caps** | `--budget-usd / --budget-per-sample-usd / --budget-per-sample-ms` — abort on total-cost overrun, flag per-sample overruns; partial report persisted |
|
|
119
102
|
| **Construct-validity isolation** | `--strict-baseline` (default ON) cuts three contamination channels so baseline doesn't silently see the skill it's being compared against: (1) SDK skill auto-discovery, (2) subagent Skill tool, (3) cwd file-system access via the `skills/<name>/` symlink that's normally there for the treatment variant. eval.yaml `allowedSkills` for per-variant whitelists |
|
|
120
|
-
| **Sample design science** | Sample schema with `capability` / `difficulty` / `construct` / `provenance` metadata fields (HF Dataset Cards style). `
|
|
103
|
+
| **Sample design science** | Sample schema with `capability` / `difficulty` / `construct` / `provenance` metadata fields (HF Dataset Cards style). `omk improve` shows coverage breakdown + flags `rubric_clarity_low` (short rubric without grading keywords) / `capability_thin` (capability supported by ≤ N×0.2 samples). `omk improve samples` auto-stamps provenance. See [docs/sample-design-spec.md](docs/sample-design-spec.md) for the 8 industry-gap mapping |
|
|
121
104
|
| **Multi-judge ensemble** | `--judge-models claude:opus,openai:gpt-4o` cross-vendor scoring + agreement metrics |
|
|
122
105
|
| **MCP URL fetching** | pull content from private-doc URLs via an MCP server (SSO-protected knowledge bases, etc.) |
|
|
123
106
|
| **Blind A/B** | `--blind` hides variant names; HTML report has a reveal button |
|
|
@@ -376,351 +359,113 @@ Reports display results across six independent dimensions. The three scoring lay
|
|
|
376
359
|
|
|
377
360
|
## CLI reference
|
|
378
361
|
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
```bash
|
|
382
|
-
omk bench run [options]
|
|
383
|
-
|
|
384
|
-
options:
|
|
385
|
-
--samples <path> sample file (default: eval-samples.json, also detects .yaml/.yml)
|
|
386
|
-
--skill-dir <path> artifact dir (default: skills)
|
|
387
|
-
--control <expr> control-group variant expression (experiment role = control)
|
|
388
|
-
--treatment <v1,v2> treatment-group variant expressions, comma-separated
|
|
389
|
-
at least one of --control / --treatment is required
|
|
390
|
-
(unless you use --config or --batch)
|
|
391
|
-
special values: baseline (empty artifact), git:name (git HEAD),
|
|
392
|
-
git:ref:name (specific commit), path with "/" (read file directly)
|
|
393
|
-
--config <path> YAML/JSON config file (evaluation-as-code); declares
|
|
394
|
-
samples + variants + model + executor in one file; CLI
|
|
395
|
-
flags override config fields when both are provided
|
|
396
|
-
--model <name> task execution model (default: sonnet)
|
|
397
|
-
--judge-models <list> judge config; 1 entry = single judge (default
|
|
398
|
-
claude:haiku), ≥ 2 entries = ensemble. Format:
|
|
399
|
-
`executor:model[,executor:model]`
|
|
400
|
-
--output-dir <path> output dir (default: ~/.oh-my-knowledge/reports/)
|
|
401
|
-
--no-judge skip the LLM judge
|
|
402
|
-
--no-cache disable result cache (on by default; identical inputs reuse)
|
|
403
|
-
--dry-run preview only
|
|
404
|
-
--blind blind mode
|
|
405
|
-
--concurrency <n> parallel tasks (default: 1)
|
|
406
|
-
--timeout <sec> per-task executor timeout (default: 120)
|
|
407
|
-
--repeat <n> repeat N times for variance analysis (default: 1)
|
|
408
|
-
--executor <name> executor (default: claude); supports custom commands
|
|
409
|
-
--skip-connectivity skip the LLM connectivity check (doctor still runs;
|
|
410
|
-
doctor is mandatory and has no skip flag).
|
|
411
|
-
Auto-applied on --resume (the original run already
|
|
412
|
-
verified connectivity).
|
|
413
|
-
--mcp-config <path> MCP config for fetching private-doc URLs via MCP Server
|
|
414
|
-
(default: .mcp.json in cwd)
|
|
415
|
-
--no-serve don't auto-start the report server after the run
|
|
416
|
-
--verbose print per-sample details (duration, tokens, output preview)
|
|
417
|
-
--batch batch mode: evaluate each artifact independently vs baseline
|
|
418
|
-
requires {name}.eval-samples.json paired with each artifact
|
|
419
|
-
--judge-repeat <n> run the LLM judge N times per (sample × dimension) and report stddev
|
|
420
|
-
--bootstrap enable distribution-free CIs: bootstrap CI per variant +
|
|
421
|
-
pairwise diff CI (CI containing 0 = not significant)
|
|
422
|
-
--bootstrap-samples N bootstrap resample count (default 1000)
|
|
423
|
-
--gold-dir <path> after the run, compare scores against the gold dataset
|
|
424
|
-
(Krippendorff α / κ / Pearson). Result is written to
|
|
425
|
-
report.meta.humanAgreement and shown in the HTML report
|
|
426
|
-
--no-debias-length revert to legacy v2-cot judge prompt (no "length is not
|
|
427
|
-
a quality signal" paragraph) — for byte-compat with
|
|
428
|
-
legacy reports whose hash predates v3-cot-length
|
|
429
|
-
--budget-usd <num> total cost cap (USD); on overrun the run aborts and
|
|
430
|
-
a partial report is persisted (`report.meta.budgetExhausted = true`)
|
|
431
|
-
--budget-per-sample-usd <num> per-sample cost cap; offending samples fail individually,
|
|
432
|
-
the run continues
|
|
433
|
-
--budget-per-sample-ms <num> per-sample latency cap (ms); same semantics as cost cap
|
|
434
|
-
```
|
|
435
|
-
|
|
436
|
-
**eval.yaml budget**: declare `budget: { totalUSD?, perSampleUSD?, perSampleMs? }` (all optional, must be ≥ 0). CLI flags of the same name override the config values.
|
|
437
|
-
|
|
438
|
-
**eval.yaml experiment-design fields**: the same flags above can be set in `eval.yaml` for reproducible experiment configuration (CLI > eval.yaml > default):
|
|
439
|
-
|
|
440
|
-
```yaml
|
|
441
|
-
samples: ./eval-samples.yaml
|
|
442
|
-
model: sonnet
|
|
443
|
-
repeat: 5 # multi-run variance, ≥ 1
|
|
444
|
-
judgeRepeat: 3 # per (sample × dim) judge self-consistency, ≥ 1
|
|
445
|
-
bootstrap: true # distribution-free CI per variant
|
|
446
|
-
bootstrapSamples: 2000 # default 1000, ≥ 100
|
|
447
|
-
goldDir: ./gold # post-run α / κ / Pearson against human anchor
|
|
448
|
-
lengthDebias: true # default; set false to reproduce pre-v0.21 hash
|
|
449
|
-
strictBaseline: true # default; set false to disable skill isolation
|
|
450
|
-
noJudge: false # default; set true to skip LLM judge entirely
|
|
451
|
-
judgeModels: # 1 entry = single judge; ≥ 2 = ensemble
|
|
452
|
-
- { executor: claude, model: opus }
|
|
453
|
-
- { executor: openai-api, model: gpt-4o }
|
|
454
|
-
variants:
|
|
455
|
-
- { name: baseline, role: control, artifact: baseline }
|
|
456
|
-
- { name: my-skill, role: treatment, artifact: ./skills/my-skill.md }
|
|
457
|
-
```
|
|
458
|
-
|
|
459
|
-
**Field entry points**: `bench run` reads every field above. `bench gate` goes through `parseRunConfig` and picks up the shared subset (`variants` / `executor` / `model` / `judgeModels` — both single-judge and ensemble — / `noJudge` / `noCache` / `blind` / `strictBaseline` / `budget` / `mcpConfig` / `variantAllowedSkills`); the experiment-design fields handled by `handleRun` (`repeat` / `judgeRepeat` / `bootstrap` / `bootstrapSamples` / `goldDir` / `lengthDebias`) are intentionally not read by `gate` and can be extended later. Other subcommands (`evolve` / `verdict` / `diff` / `analyze` / …) do not read `eval.yaml`.
|
|
460
|
-
|
|
461
|
-
**Difference from `cost_max` / `latency_max` assertions**: assertions are **per-sample scoring rules** (exceeding the cap fails that one assertion, the run continues); budget caps are **workflow-level hard limits** (`totalUSD` overrun aborts the run and persists a partial report; per-sample overruns fail the offending sample but the run continues). Assertions answer "is quality acceptable?"; budgets answer "are cost/time within the envelope?".
|
|
462
|
-
|
|
463
|
-
### `omk bench run --batch` (batch mode)
|
|
464
|
-
|
|
465
|
-
When `skills/` contains several **independent** artifacts, use `--batch` to evaluate each one against baseline and produce a BatchEvaluationReport with child EvaluationReports.
|
|
466
|
-
|
|
467
|
-
```
|
|
468
|
-
skills/
|
|
469
|
-
├── asset.md ← artifact file
|
|
470
|
-
├── asset.eval-samples.json ← paired samples
|
|
471
|
-
├── home.md
|
|
472
|
-
├── home.eval-samples.json
|
|
473
|
-
└── product/ ← directory format also supported
|
|
474
|
-
├── SKILL.md
|
|
475
|
-
└── eval-samples.json
|
|
476
|
-
```
|
|
477
|
-
|
|
478
|
-
Pairing rules:
|
|
362
|
+
omk exposes a workflow CLI for knowledge artifacts. The public surface is organized around the way users work: initialize, check, evaluate, observe, improve, export evidence, and open the local studio.
|
|
479
363
|
|
|
480
|
-
|
|
481
|
-
- `{name}/SKILL.md` → looks for `{name}/eval-samples.json`
|
|
482
|
-
- artifacts without paired samples are skipped with a warning
|
|
364
|
+
### `omk init`
|
|
483
365
|
|
|
484
366
|
```bash
|
|
485
|
-
omk
|
|
486
|
-
omk bench run --batch --dry-run
|
|
367
|
+
omk init [dir]
|
|
487
368
|
```
|
|
488
369
|
|
|
489
|
-
|
|
370
|
+
Scaffolds an evaluation project with two starter skill variants and an `eval-samples.json` file.
|
|
490
371
|
|
|
491
|
-
|
|
372
|
+
### `omk doctor`
|
|
492
373
|
|
|
493
374
|
```bash
|
|
494
|
-
#
|
|
495
|
-
omk
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
omk bench gen-samples --batch
|
|
499
|
-
|
|
500
|
-
# specify sample count
|
|
501
|
-
omk bench gen-samples skills/my-skill.md --count 10
|
|
502
|
-
```
|
|
503
|
-
|
|
504
|
-
Options:
|
|
505
|
-
|
|
506
|
-
```
|
|
507
|
-
--batch batch-generate for every artifact missing samples
|
|
508
|
-
--count <n> samples per artifact (default: 5)
|
|
509
|
-
--model <name> model used for generation (default: sonnet)
|
|
510
|
-
--skill-dir <path> artifact dir (default: skills), used with --batch
|
|
375
|
+
omk doctor # check current dir / ./skills
|
|
376
|
+
omk doctor skills/v1.md # check one skill file
|
|
377
|
+
omk doctor skills/ --json # machine-readable output
|
|
378
|
+
omk doctor --gate; echo $? # silent CI gate
|
|
511
379
|
```
|
|
512
380
|
|
|
513
|
-
|
|
381
|
+
Pure static checks: skill readability, frontmatter, directory-skill layout, dependency hints, and sample contract. It is also run automatically before `omk eval`.
|
|
514
382
|
|
|
515
|
-
|
|
383
|
+
### `omk eval`
|
|
516
384
|
|
|
517
385
|
```bash
|
|
518
|
-
|
|
519
|
-
omk
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
omk
|
|
386
|
+
omk eval --control code-review-v1 --treatment code-review-v2
|
|
387
|
+
omk eval --config eval.yaml
|
|
388
|
+
omk eval --batch
|
|
389
|
+
omk eval gold compare <report-id> --gold-dir gold-dataset
|
|
390
|
+
omk eval debias length <report-id>
|
|
523
391
|
```
|
|
524
392
|
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
```
|
|
528
|
-
--rounds <n> max iteration rounds (default: 5)
|
|
529
|
-
--target <score> stop early when the score reaches this threshold
|
|
530
|
-
--samples <path> sample file (default: eval-samples.json)
|
|
531
|
-
--improve-model <name> model used for rewrites (default: sonnet)
|
|
532
|
-
```
|
|
533
|
-
|
|
534
|
-
Each round's output is saved under `skills/evolve/` (`my-skill.r0.md`, `my-skill.r1.md`…), so you can `diff` to see what the AI changed. The best round is written back to the original file.
|
|
535
|
-
|
|
536
|
-
### `omk bench gate`
|
|
537
|
-
|
|
538
|
-
Run the evaluation inside CI. Exit code 0 on pass, 1 on fail — can be wired into gates directly.
|
|
539
|
-
|
|
540
|
-
The gate is **three-layer all-pass**: `avgFactScore >= threshold AND avgBehaviorScore >= threshold AND avgJudgeScore >= threshold`. Any layer below threshold is FAIL, and the output shows which layer broke. This stops cases like `fact 4.5→2.5 but judge 3→5` from passing via composite averaging — if one layer regresses, the gate catches it.
|
|
541
|
-
|
|
542
|
-
```bash
|
|
543
|
-
omk bench gate [options]
|
|
544
|
-
--threshold <number> per-layer minimum score (default: 3.5); applied
|
|
545
|
-
independently to fact / behavior / judge
|
|
546
|
-
```
|
|
547
|
-
|
|
548
|
-
### `omk doctor` (pre-evaluation health check)
|
|
549
|
-
|
|
550
|
-
Pure static / zero-LLM checks — analogous to lint + typecheck in the SE toolchain. Runs as a mandatory gate before `bench run` / `bench gate` so a typo'd YAML or missing dependency aborts with an actionable error instead of producing a garbage-in verdict. Also runnable standalone for local iteration or CI.
|
|
551
|
-
|
|
552
|
-
```bash
|
|
553
|
-
omk doctor # batch check every skill in current dir / ./skills
|
|
554
|
-
omk doctor skills/v1.md # single file
|
|
555
|
-
omk doctor skills/ --json # JSON output for CI consumption
|
|
556
|
-
omk doctor --gate; echo $? # silent mode — exit 1 if any fatal check fails
|
|
557
|
-
```
|
|
558
|
-
|
|
559
|
-
What `doctor` checks:
|
|
560
|
-
|
|
561
|
-
- **skill readable** — file exists, content non-empty, has minimum length
|
|
562
|
-
- **skill metadata** — front-matter (if present) is valid YAML; directory-skills have `SKILL.md`
|
|
563
|
-
- **dependencies present** — referenced CLI tools, files, env vars all available (reuses `preflightDependencies`)
|
|
564
|
-
- **samples ↔ skill contract** — when samples are provided, validate they're non-empty and have prompt fields (warn-level)
|
|
565
|
-
|
|
566
|
-
Executor / judge connectivity is verified by a separate evaluation preflight phase, not by doctor — clean boundary: doctor is static, eval is dynamic. `bench run` / `bench gate` abort with `exit 1` and stderr `doctor failed:` prefix when doctor fails. **Doctor is mandatory and not skippable** (static checks have no cost reason to skip); LLM connectivity is separately controllable via `--skip-connectivity` (auto-skipped on `--resume`).
|
|
393
|
+
Runs the offline evaluation, applies the verdict gate, persists the report, and returns a ship/no-ship exit code. Bootstrap CI is enabled by default on this workflow.
|
|
567
394
|
|
|
568
|
-
|
|
395
|
+
Common options:
|
|
569
396
|
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
|
|
573
|
-
|
|
574
|
-
--
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
|
|
587
|
-
|
|
588
|
-
|
|
589
|
-
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
|
|
593
|
-
Dataset layout:
|
|
594
|
-
|
|
595
|
-
```
|
|
596
|
-
gold-dir/
|
|
597
|
-
├── metadata.yaml # annotator (must NOT match the omk judge model — would trigger contamination warning) + date + version
|
|
598
|
-
└── annotations.yaml # [{ sample_id, score, reason? }] concatenated by sample_id
|
|
599
|
-
```
|
|
600
|
-
|
|
601
|
-
α thresholds follow Krippendorff (2011): ≥ 0.80 strong agreement; [0.67, 0.80) acceptable; < 0.40 large divergence — investigate rubric / prompt.
|
|
602
|
-
|
|
603
|
-
Full demo: [examples/gold-dataset/](examples/gold-dataset/)
|
|
604
|
-
|
|
605
|
-
### `omk bench debias-validate length` (judge length-bias check)
|
|
606
|
-
|
|
607
|
-
Re-judges every (sample × variant) of an existing report with the OPPOSITE length-debias setting (v3-cot-length ↔ v2-cot) and bootstraps the CI on the score difference. A significant shift = the judge is sensitive to the length-debias instruction (indirect evidence of length bias).
|
|
608
|
-
|
|
609
|
-
```bash
|
|
610
|
-
omk bench debias-validate length <reportId> [options]
|
|
611
|
-
--variant <name> check a single variant only
|
|
612
|
-
--judge-models <executor:model> override the report's judge (single-judge only)
|
|
613
|
-
--bootstrap-samples N bootstrap iterations (default 1000)
|
|
614
|
-
--seed N deterministic seed
|
|
615
|
-
```
|
|
616
|
-
|
|
617
|
-
Verdict bucket: none / weak / medium (|0.2-0.5|) / strong (≥ 0.5). Re-judge cost roughly doubles vs the original judge pass.
|
|
618
|
-
|
|
619
|
-
### `omk bench saturation` (saturation curve)
|
|
620
|
-
|
|
621
|
-
Answers "have I run enough samples?". Reads the saturation trace from an existing report (no re-run). Verdicts only emit when the original run used `--repeat ≥ 5`; below that, the curve is plotted but no verdict is computed.
|
|
622
|
-
|
|
623
|
-
```bash
|
|
624
|
-
omk bench saturation <reportId> [options]
|
|
625
|
-
--variant <name> single-variant view
|
|
626
|
-
--method <m> slope | bootstrap-ci-width (default) | plateau-height
|
|
627
|
-
--threshold <num> method-specific cutoff (defaults match the method)
|
|
628
|
-
--window <num> consecutive windows that must satisfy the threshold (default 3)
|
|
629
|
-
```
|
|
630
|
-
|
|
631
|
-
The HTML report inlines an SVG curve (cumulative N on X, mean ± 95% CI shading on Y, one curve per variant) automatically.
|
|
632
|
-
|
|
633
|
-
### `omk bench verdict` (one-line ship/no-ship verdict)
|
|
634
|
-
|
|
635
|
-
Aggregates bootstrap CI / three-layer ci-gate / saturation / human α into one of six verdicts: **PROGRESS** (significant improvement, all three layers pass → exit 0), **CAUTIOUS** (real gain but with a warning — broken gate / trivially small / control regressed → exit 1), **REGRESS** (significant negative shift → exit 1), **NOISE** (CI spans 0, undecidable → exit 1), **UNDERPOWERED** (sample size too small → exit 1), **SOLO** (single variant; exit 0 only if its own three-layer gate passes).
|
|
636
|
-
|
|
637
|
-
```bash
|
|
638
|
-
omk bench verdict <reportId> [options]
|
|
639
|
-
--threshold <num> three-layer gate threshold (default 3.5, matches `omk bench gate`)
|
|
640
|
-
--trivial-diff <num> "practically tiny" cutoff (default 0.1)
|
|
641
|
-
--verbose expand per-pair detail
|
|
397
|
+
```text
|
|
398
|
+
--samples <path> sample file (default: eval-samples.json, also detects .yaml/.yml)
|
|
399
|
+
--skill-dir <path> artifact dir (default: skills)
|
|
400
|
+
--control <expr> control variant expression
|
|
401
|
+
--treatment <v1,v2> treatment variants, comma-separated
|
|
402
|
+
--config <path> YAML/JSON evaluation config
|
|
403
|
+
--model <name> task execution model (default: sonnet)
|
|
404
|
+
--judge-models <list> judge config, e.g. claude:haiku or claude:opus,openai:gpt-4o
|
|
405
|
+
--executor <name> claude / claude-sdk / codex / codex-sdk / openai-api / gemini / custom
|
|
406
|
+
--no-judge skip LLM judge
|
|
407
|
+
--dry-run preview only
|
|
408
|
+
--blind blind A/B mode
|
|
409
|
+
--concurrency <n> parallel tasks
|
|
410
|
+
--timeout <sec> per-task timeout
|
|
411
|
+
--repeat <n> repeat N times for variance analysis
|
|
412
|
+
--batch evaluate each artifact independently vs baseline
|
|
413
|
+
--bootstrap-samples N bootstrap resample count (default 1000)
|
|
414
|
+
--threshold <number> verdict layer-gate threshold (default 3.5)
|
|
415
|
+
--trivial-diff <num> practically tiny diff cutoff (default 0.1)
|
|
416
|
+
--report-only produce the report and print verdict, but always exit 0
|
|
417
|
+
--no-gate alias for --report-only
|
|
418
|
+
--skip-connectivity skip model connectivity check; doctor still runs
|
|
419
|
+
--no-serve do not auto-start the report server after evaluation
|
|
642
420
|
```
|
|
643
421
|
|
|
644
|
-
|
|
645
|
-
|
|
646
|
-
### `omk bench diagnose` (sample quality diagnostics)
|
|
647
|
-
|
|
648
|
-
Answers "is the conclusion polluted by bad samples?". Diagnoses 7 sample-quality issues: `flat_scores` (low discrimination), `all_pass` (too easy), `all_fail` (broken — error severity), `near_duplicate` (prompt ROUGE-1 ≥ threshold), `ambiguous_rubric` (high judge stddev across `--judge-repeat ≥ 2`), `cost_outlier` (≥ k× median), `latency_outlier` (≥ k× median), `error_prone` (executor failure).
|
|
422
|
+
### `omk observe`
|
|
649
423
|
|
|
650
424
|
```bash
|
|
651
|
-
omk
|
|
652
|
-
|
|
653
|
-
|
|
654
|
-
|
|
655
|
-
|
|
656
|
-
--latency-k <num> latency-outlier multiplier vs median (default 3)
|
|
657
|
-
--flat <num> flat_scores spread threshold (default 0.5)
|
|
425
|
+
omk observe ~/.claude/projects/-Users-you-Documents-my-project
|
|
426
|
+
omk observe ~/.claude/projects/my-project --last 7d
|
|
427
|
+
omk observe ~/.claude/projects/my-project --from 2026-04-01T00:00:00Z --to 2026-04-15T23:59:59Z
|
|
428
|
+
omk observe ~/.claude/projects/my-project --skills audit,polish
|
|
429
|
+
omk observe ~/.claude/projects/my-project --kb /path/to/project
|
|
658
430
|
```
|
|
659
431
|
|
|
660
|
-
|
|
661
|
-
|
|
662
|
-
### `omk bench failures` (failure case LLM clustering)
|
|
432
|
+
Turns real Claude Code session traces into skill-health reports: knowledge usage, gap signals, execution stability, tokens, and latency. This is production observation, not production scoring.
|
|
663
433
|
|
|
664
|
-
|
|
434
|
+
### `omk improve`
|
|
665
435
|
|
|
666
436
|
```bash
|
|
667
|
-
omk
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
|
|
437
|
+
omk improve <report-id> # sample diagnostics and repair plan
|
|
438
|
+
omk improve plan <report-id> # explicit repair-plan form
|
|
439
|
+
omk improve failures <report-id> # cluster failed samples into root causes
|
|
440
|
+
omk improve samples [skill] # generate or fill eval samples
|
|
441
|
+
omk improve skill <skill> # iterate a skill through eval-driven rewrites
|
|
672
442
|
```
|
|
673
443
|
|
|
674
|
-
|
|
675
|
-
|
|
676
|
-
### `omk bench diff` (report comparison — single / dual mode)
|
|
677
|
-
|
|
678
|
-
**Single-arg mode** (within-report sample-level): `omk bench diff <reportId>` — within one report, drill down per-sample comparing `variants[0]` against `variants[1]` (or `--variant <name>`).
|
|
444
|
+
Use this after `omk eval` or `omk observe` to decide what to change next. Generated sample assertions use English, numbers, or code tokens so they are easier to compare across bilingual outputs.
|
|
679
445
|
|
|
680
|
-
|
|
446
|
+
### `omk export`
|
|
681
447
|
|
|
682
448
|
```bash
|
|
683
|
-
omk
|
|
684
|
-
omk
|
|
449
|
+
omk export <report-id> --format html
|
|
450
|
+
omk export <report-id> --format markdown --out report.md
|
|
451
|
+
omk export <report-id> --format github-summary
|
|
452
|
+
omk export diff <report-id> --regressions-only
|
|
453
|
+
omk export verdict <report-id>
|
|
454
|
+
omk export saturation <report-id>
|
|
685
455
|
```
|
|
686
456
|
|
|
687
|
-
|
|
457
|
+
Exports evidence for PRs, CI summaries, and audit trails. HTML writes a standalone report file; markdown and GitHub summary print to stdout unless `--out` is provided. The export subtree also owns sample/report diffing, persisted verdict reads, and saturation inspection.
|
|
688
458
|
|
|
689
|
-
|
|
690
|
-
|
|
691
|
-
`omk bench run` is **offline evaluation** (fixed controls, repeatable, scored). Production is different — no control group, no ground truth, no repetition, so scoring isn't valid there. `omk analyze` turns existing Claude Code session traces into **skill-health reports** (coverage, gap signals, execution stability, tokens/latency per skill). It gives you clues about **which skill is worth re-evaluating offline**, not a production score.
|
|
459
|
+
### `omk studio`
|
|
692
460
|
|
|
693
461
|
```bash
|
|
694
|
-
|
|
695
|
-
omk
|
|
696
|
-
|
|
697
|
-
|
|
698
|
-
omk analyze ~/.claude/projects/my-project --last 7d
|
|
699
|
-
|
|
700
|
-
# absolute time window
|
|
701
|
-
omk analyze ~/.claude/projects/my-project --from 2026-04-01T00:00:00Z --to 2026-04-15T23:59:59Z
|
|
702
|
-
|
|
703
|
-
# whitelist specific skills
|
|
704
|
-
omk analyze ~/.claude/projects/my-project --skills audit,polish
|
|
705
|
-
|
|
706
|
-
# override the inferred knowledge-base root
|
|
707
|
-
omk analyze ~/.claude/projects/my-project --kb /path/to/project
|
|
462
|
+
omk studio
|
|
463
|
+
omk studio --port 7799
|
|
464
|
+
omk studio --reports-dir ~/.oh-my-knowledge/reports
|
|
465
|
+
omk studio --no-open
|
|
708
466
|
```
|
|
709
467
|
|
|
710
|
-
|
|
711
|
-
|
|
712
|
-
**What you get per skill:**
|
|
713
|
-
|
|
714
|
-
- **Knowledge usage** — which KB files this skill actually read (coverage %)
|
|
715
|
-
- **Knowledge gaps** — four weighted signals (failed search / model-flagged gap / hedging / repeated miss); hedging goes through an LLM-assisted classifier to filter out business-possibility hedging vs genuine knowledge uncertainty
|
|
716
|
-
- **Execution stability** — tool-failure rate; a skill with > 20% failures gets a warning that its gap signals may be environmental noise rather than real knowledge gaps
|
|
717
|
-
- **Usage cost** — billable tokens (input+output) separate from cached tokens, total duration
|
|
718
|
-
|
|
719
|
-
**What this is NOT:**
|
|
720
|
-
|
|
721
|
-
- Not a general APM (request/response/latency tracing is Langfuse / Datadog territory)
|
|
722
|
-
- Not streaming / alerting (batch only — run on a cron if you want periodic snapshots)
|
|
723
|
-
- Not a production score (no control group, no ground truth — use `omk bench run` for scoring)
|
|
468
|
+
Starts the local knowledge workbench for browsing reports and observation analyses.
|
|
724
469
|
|
|
725
470
|
## Executors
|
|
726
471
|
|
|
@@ -738,15 +483,15 @@ The command writes `~/.oh-my-knowledge/analyses/<timestamp>-skill-health.json`.
|
|
|
738
483
|
|
|
739
484
|
API-direct executors support custom base URLs via env: `ANTHROPIC_BASE_URL`, `OPENAI_BASE_URL`.
|
|
740
485
|
|
|
741
|
-
Codex construct-validity notes: (1) `codex` uses the `codex` binary on `PATH`; `codex-sdk` uses the bundled `@openai/codex` binary resolved by `@openai/codex-sdk`. Reports persist per-variant `meta.executorRuntimes`, `meta.executorRuntime`, and per-judge `meta.judgeModels[].runtime` fingerprints (binary or SDK version + capability snapshot), and
|
|
486
|
+
Codex construct-validity notes: (1) `codex` uses the `codex` binary on `PATH`; `codex-sdk` uses the bundled `@openai/codex` binary resolved by `@openai/codex-sdk`. Reports persist per-variant `meta.executorRuntimes`, `meta.executorRuntime`, and per-judge `meta.judgeModels[].runtime` fingerprints (binary or SDK version + capability snapshot), and strict comparability checks warn when runtime fingerprints cannot be audited. If runtime fingerprints differ, treat results as an executor-runtime comparison, not only prompt/template behavior. (2) Both executors isolate user-level config: `codex` passes `--ephemeral` + `--ignore-user-config`; `codex-sdk` redirects `$CODEX_HOME` to a per-process tmp dir (auth.json symlinked through). User-level `~/.codex/config.toml` does not leak into eval runs in either case.
|
|
742
487
|
|
|
743
488
|
### Custom executor
|
|
744
489
|
|
|
745
490
|
Any shell command can serve as an executor, communicating via stdin/stdout JSON:
|
|
746
491
|
|
|
747
492
|
```bash
|
|
748
|
-
omk
|
|
749
|
-
omk
|
|
493
|
+
omk eval --executor "python my_provider.py"
|
|
494
|
+
omk eval --executor "./my-executor.sh"
|
|
750
495
|
```
|
|
751
496
|
|
|
752
497
|
**Protocol:**
|
|
@@ -787,28 +532,28 @@ When both `--control` and `--treatment` are omitted, use `--config eval.yaml` or
|
|
|
787
532
|
|
|
788
533
|
```bash
|
|
789
534
|
# explicit: one control, one or more treatments
|
|
790
|
-
omk
|
|
791
|
-
omk
|
|
535
|
+
omk eval --control v1 --treatment v2
|
|
536
|
+
omk eval --control baseline --treatment v1,v2,v3
|
|
792
537
|
|
|
793
538
|
# compare empty artifact vs explicit artifact
|
|
794
|
-
omk
|
|
539
|
+
omk eval --control baseline --treatment my-skill
|
|
795
540
|
|
|
796
541
|
# observe project-level runtime context in isolation (use a self-describing label)
|
|
797
|
-
omk
|
|
542
|
+
omk eval --control baseline --treatment project-env@/path/to/target-project
|
|
798
543
|
|
|
799
544
|
# compare "project-level runtime context" vs "explicit artifact injection"
|
|
800
|
-
omk
|
|
545
|
+
omk eval \
|
|
801
546
|
--control project-env@/path/to/target-project \
|
|
802
547
|
--treatment /path/to/target-project/.claude/skills/prd/SKILL.md@/path/to/target-project
|
|
803
548
|
|
|
804
549
|
# before vs after (old version read from git history)
|
|
805
|
-
omk
|
|
550
|
+
omk eval --control git:my-skill --treatment my-skill
|
|
806
551
|
|
|
807
552
|
# direct file paths
|
|
808
|
-
omk
|
|
553
|
+
omk eval --control ./old-skill.md --treatment ./new-skill.md
|
|
809
554
|
|
|
810
555
|
# config-file driven (evaluation-as-code)
|
|
811
|
-
omk
|
|
556
|
+
omk eval --config eval.yaml
|
|
812
557
|
```
|
|
813
558
|
|
|
814
559
|
**Prerequisites:**
|
|
@@ -839,7 +584,7 @@ In OMK, `agent` is not a catch-all term and neither is `skill`. A cleaner phrasi
|
|
|
839
584
|
#### Recommended executor
|
|
840
585
|
|
|
841
586
|
```bash
|
|
842
|
-
omk
|
|
587
|
+
omk eval --executor claude-sdk
|
|
843
588
|
```
|
|
844
589
|
|
|
845
590
|
#### Agent-related assertions
|
|
@@ -859,7 +604,7 @@ omk bench run --executor claude-sdk
|
|
|
859
604
|
No system prompt and no knowledge-carrying project dir. Requires at least one treatment to compare against:
|
|
860
605
|
|
|
861
606
|
```bash
|
|
862
|
-
omk
|
|
607
|
+
omk eval \
|
|
863
608
|
--executor claude-sdk \
|
|
864
609
|
--control baseline \
|
|
865
610
|
--treatment my-skill
|
|
@@ -870,7 +615,7 @@ omk bench run \
|
|
|
870
615
|
No system prompt, but runs inside a project dir. This is **not** a strict "bare baseline" — it is "empty artifact + project-level runtime context".
|
|
871
616
|
|
|
872
617
|
```bash
|
|
873
|
-
omk
|
|
618
|
+
omk eval \
|
|
874
619
|
--executor claude-sdk \
|
|
875
620
|
--control baseline \
|
|
876
621
|
--treatment project-env@/path/to/target-project
|
|
@@ -881,7 +626,7 @@ omk bench run \
|
|
|
881
626
|
Inject an external `SKILL.md` as the artifact while also keeping the project dir. Good for contrasting "project-level runtime context" vs "explicit single-artifact injection".
|
|
882
627
|
|
|
883
628
|
```bash
|
|
884
|
-
omk
|
|
629
|
+
omk eval \
|
|
885
630
|
--executor claude-sdk \
|
|
886
631
|
--control project-env@/path/to/target-project \
|
|
887
632
|
--treatment /path/to/target-project/.claude/skills/prd/SKILL.md@/path/to/target-project
|
|
@@ -892,7 +637,7 @@ omk bench run \
|
|
|
892
637
|
For PRD / complex business-knowledge scenarios, start with:
|
|
893
638
|
|
|
894
639
|
```bash
|
|
895
|
-
omk
|
|
640
|
+
omk eval \
|
|
896
641
|
--executor claude-sdk \
|
|
897
642
|
--samples skills/evaluate-review/eval-samples.yaml \
|
|
898
643
|
--control baseline \
|
|
@@ -902,7 +647,7 @@ omk bench run \
|
|
|
902
647
|
If you want to prove whether "the knowledge sitting inside the project directory" is effective on its own, add a second treatment:
|
|
903
648
|
|
|
904
649
|
```bash
|
|
905
|
-
omk
|
|
650
|
+
omk eval \
|
|
906
651
|
--executor claude-sdk \
|
|
907
652
|
--samples skills/evaluate-review/eval-samples.yaml \
|
|
908
653
|
--control baseline \
|
|
@@ -923,32 +668,32 @@ omk bench run \
|
|
|
923
668
|
# GLM (Zhipu)
|
|
924
669
|
export OPENAI_API_KEY="your Zhipu API key"
|
|
925
670
|
export OPENAI_BASE_URL="https://open.bigmodel.cn/api/paas/v4"
|
|
926
|
-
omk
|
|
671
|
+
omk eval --executor openai-api --model glm-4-plus \
|
|
927
672
|
--judge-models openai-api:glm-4-plus --no-cache
|
|
928
673
|
|
|
929
674
|
# Qwen (Alibaba)
|
|
930
675
|
export OPENAI_API_KEY="your Qwen API key"
|
|
931
676
|
export OPENAI_BASE_URL="https://dashscope.aliyuncs.com/compatible-mode/v1"
|
|
932
|
-
omk
|
|
677
|
+
omk eval --executor openai-api --model qwen-plus \
|
|
933
678
|
--judge-models openai-api:qwen-plus
|
|
934
679
|
|
|
935
680
|
# DeepSeek
|
|
936
681
|
export OPENAI_API_KEY="your DeepSeek API key"
|
|
937
682
|
export OPENAI_BASE_URL="https://api.deepseek.com"
|
|
938
|
-
omk
|
|
683
|
+
omk eval --executor openai-api --model deepseek-chat \
|
|
939
684
|
--judge-models openai-api:deepseek-chat
|
|
940
685
|
|
|
941
686
|
# Moonshot (Kimi)
|
|
942
687
|
export OPENAI_API_KEY="your Moonshot API key"
|
|
943
688
|
export OPENAI_BASE_URL="https://api.moonshot.cn/v1"
|
|
944
|
-
omk
|
|
689
|
+
omk eval --executor openai-api --model moonshot-v1-8k \
|
|
945
690
|
--judge-models openai-api:moonshot-v1-8k
|
|
946
691
|
```
|
|
947
692
|
|
|
948
693
|
**Ollama local model:**
|
|
949
694
|
|
|
950
695
|
```bash
|
|
951
|
-
omk
|
|
696
|
+
omk eval --executor "python examples/custom-executor/ollama-executor.py" \
|
|
952
697
|
--model llama3 --no-judge
|
|
953
698
|
```
|
|
954
699
|
|
|
@@ -964,7 +709,7 @@ omk bench run --executor "python examples/custom-executor/ollama-executor.py" \
|
|
|
964
709
|
| Variable | Description |
|
|
965
710
|
|---|---|
|
|
966
711
|
| `CCV_PROXY_URL` | proxy requests through cc-viewer for live eval-traffic visualization |
|
|
967
|
-
| `
|
|
712
|
+
| `OMK_REPORT_PORT` | report server port (default: 7799) |
|
|
968
713
|
|
|
969
714
|
## Requirements
|
|
970
715
|
|
|
@@ -983,7 +728,7 @@ This tool is designed for **local trusted environments** (dev machines, CI pipel
|
|
|
983
728
|
|
|
984
729
|
**Recommendations:**
|
|
985
730
|
|
|
986
|
-
- Do not expose
|
|
731
|
+
- Do not expose the local report server on the public internet (no auth)
|
|
987
732
|
- Don't use third-party eval-samples you haven't vetted
|
|
988
733
|
- Custom assertions have a 30-second timeout but no sandbox isolation
|
|
989
734
|
|