repere 0.5.1__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (151) hide show
  1. repere-0.5.1/LICENSE +21 -0
  2. repere-0.5.1/PKG-INFO +454 -0
  3. repere-0.5.1/README.md +410 -0
  4. repere-0.5.1/pyproject.toml +136 -0
  5. repere-0.5.1/setup.cfg +4 -0
  6. repere-0.5.1/src/repere/__init__.py +313 -0
  7. repere-0.5.1/src/repere/adapters.py +372 -0
  8. repere-0.5.1/src/repere/agents/__init__.py +37 -0
  9. repere-0.5.1/src/repere/agents/lit_tools.py +55 -0
  10. repere-0.5.1/src/repere/agents/literature.py +208 -0
  11. repere-0.5.1/src/repere/agents/metrics.py +126 -0
  12. repere-0.5.1/src/repere/agents/react.py +96 -0
  13. repere-0.5.1/src/repere/agents/registry.py +212 -0
  14. repere-0.5.1/src/repere/agents/solver.py +111 -0
  15. repere-0.5.1/src/repere/agents/tools.py +198 -0
  16. repere-0.5.1/src/repere/budget.py +100 -0
  17. repere-0.5.1/src/repere/cli.py +496 -0
  18. repere-0.5.1/src/repere/export.py +163 -0
  19. repere-0.5.1/src/repere/leaderboard.py +382 -0
  20. repere-0.5.1/src/repere/registry.py +114 -0
  21. repere-0.5.1/src/repere/router.py +156 -0
  22. repere-0.5.1/src/repere/skills.py +268 -0
  23. repere-0.5.1/src/repere/telemetry.py +368 -0
  24. repere-0.5.1/src/repere.egg-info/PKG-INFO +454 -0
  25. repere-0.5.1/src/repere.egg-info/SOURCES.txt +149 -0
  26. repere-0.5.1/src/repere.egg-info/dependency_links.txt +1 -0
  27. repere-0.5.1/src/repere.egg-info/entry_points.txt +2 -0
  28. repere-0.5.1/src/repere.egg-info/requires.txt +23 -0
  29. repere-0.5.1/src/repere.egg-info/top_level.txt +2 -0
  30. repere-0.5.1/src/repere_suites/__init__.py +3 -0
  31. repere-0.5.1/src/repere_suites/dvv/__init__.py +20 -0
  32. repere-0.5.1/src/repere_suites/dvv/scorers.py +20 -0
  33. repere-0.5.1/src/repere_suites/dvv/suite.py +95 -0
  34. repere-0.5.1/src/repere_suites/gaia_data_downloader/README.md +56 -0
  35. repere-0.5.1/src/repere_suites/gaia_data_downloader/__init__.py +19 -0
  36. repere-0.5.1/src/repere_suites/gaia_data_downloader/inspect_tasks.py +156 -0
  37. repere-0.5.1/src/repere_suites/gaia_data_downloader/provenance.yaml +36 -0
  38. repere-0.5.1/src/repere_suites/gaia_data_downloader/tasks.yaml +631 -0
  39. repere-0.5.1/src/repere_suites/lit_rag/__init__.py +31 -0
  40. repere-0.5.1/src/repere_suites/lit_rag/agent_tasks.py +116 -0
  41. repere-0.5.1/src/repere_suites/lit_rag/data/arxiv_geo_corpus.json +371 -0
  42. repere-0.5.1/src/repere_suites/lit_rag/data/ooi_corpus.json +96 -0
  43. repere-0.5.1/src/repere_suites/lit_rag/inspect_tasks.py +117 -0
  44. repere-0.5.1/src/repere_suites/lit_rag/items.py +277 -0
  45. repere-0.5.1/src/repere_suites/lit_rag/queries.yaml +102 -0
  46. repere-0.5.1/src/repere_suites/lit_rag/scorers.py +201 -0
  47. repere-0.5.1/src/repere_suites/lit_rag/tasks.yaml +60 -0
  48. repere-0.5.1/src/repere_suites/orchestration/__init__.py +23 -0
  49. repere-0.5.1/src/repere_suites/orchestration/inspect_tasks.py +87 -0
  50. repere-0.5.1/src/repere_suites/orchestration/items.py +104 -0
  51. repere-0.5.1/src/repere_suites/orchestration/scorers.py +408 -0
  52. repere-0.5.1/src/repere_suites/orchestration/tasks.yaml +44 -0
  53. repere-0.5.1/src/repere_suites/paper_workflow/__init__.py +32 -0
  54. repere-0.5.1/src/repere_suites/paper_workflow/items.py +201 -0
  55. repere-0.5.1/src/repere_suites/paper_workflow/ontology.yaml +120 -0
  56. repere-0.5.1/src/repere_suites/paper_workflow/papers.yaml +132 -0
  57. repere-0.5.1/src/repere_suites/pipeline_regression/__init__.py +24 -0
  58. repere-0.5.1/src/repere_suites/pipeline_regression/inspect_tasks.py +104 -0
  59. repere-0.5.1/src/repere_suites/pipeline_regression/items.py +143 -0
  60. repere-0.5.1/src/repere_suites/pipeline_regression/pipelines.yaml +47 -0
  61. repere-0.5.1/src/repere_suites/pipeline_regression/scorers.py +216 -0
  62. repere-0.5.1/src/repere_suites/rca/__init__.py +110 -0
  63. repere-0.5.1/src/repere_suites/rca/baselines.py +107 -0
  64. repere-0.5.1/src/repere_suites/rca/checkers.py +183 -0
  65. repere-0.5.1/src/repere_suites/rca/cost.py +237 -0
  66. repere-0.5.1/src/repere_suites/rca/data/public/OO.HYS14-HYS12.channels.txt +34 -0
  67. repere-0.5.1/src/repere_suites/rca/data/public/OO.HYS14..BHZ.2017-08-12.mseed +0 -0
  68. repere-0.5.1/src/repere_suites/rca/data/public/OO.HYS14..BHZ.2019-03-01.mseed +0 -0
  69. repere-0.5.1/src/repere_suites/rca/data/public/OO.HYS14..BHZ.2022-10-01.mseed +0 -0
  70. repere-0.5.1/src/repere_suites/rca/data/public/cassettes/README.md +49 -0
  71. repere-0.5.1/src/repere_suites/rca/inspect_tasks.py +468 -0
  72. repere-0.5.1/src/repere_suites/rca/oracles/__init__.py +33 -0
  73. repere-0.5.1/src/repere_suites/rca/oracles/clock.py +94 -0
  74. repere-0.5.1/src/repere_suites/rca/pricing/prices.yaml +190 -0
  75. repere-0.5.1/src/repere_suites/rca/run.py +359 -0
  76. repere-0.5.1/src/repere_suites/rca/schema/golden_record.schema.json +698 -0
  77. repere-0.5.1/src/repere_suites/rca/seeds/coding/_selftest/bad/rca-coding-qc-continuity-001.md +12 -0
  78. repere-0.5.1/src/repere_suites/rca/seeds/coding/_selftest/good/rca-coding-qc-continuity-001.md +26 -0
  79. repere-0.5.1/src/repere_suites/rca/seeds/coding/rca-coding-download-hys14-bhz-001.yaml +97 -0
  80. repere-0.5.1/src/repere_suites/rca/seeds/coding/rca-coding-download-m2m-prest-001.yaml +106 -0
  81. repere-0.5.1/src/repere_suites/rca/seeds/coding/rca-coding-qc-continuity-001.yaml +89 -0
  82. repere-0.5.1/src/repere_suites/rca/seeds/coding/rca-coding-stalta-hys14-001.yaml +86 -0
  83. repere-0.5.1/src/repere_suites/rca/seeds/coding/rca-coding-timing-offset-hys14-001.yaml +117 -0
  84. repere-0.5.1/src/repere_suites/rca/seeds/coding/rca-coding-timing-resyncs-hys14-002.yaml +95 -0
  85. repere-0.5.1/src/repere_suites/rca/seeds/litreview/rca-litreview-abstain-after-cutoff-004.yaml +60 -0
  86. repere-0.5.1/src/repere_suites/rca/seeds/litreview/rca-litreview-axial-2015-eruption-002.yaml +64 -0
  87. repere-0.5.1/src/repere_suites/rca/seeds/litreview/rca-litreview-das-2025-005.yaml +62 -0
  88. repere-0.5.1/src/repere_suites/rca/seeds/litreview/rca-litreview-hydrophone-ambient-sound-003.yaml +61 -0
  89. repere-0.5.1/src/repere_suites/rca/seeds/litreview/rca-litreview-sensor-science-hys14-001.yaml +74 -0
  90. repere-0.5.1/src/repere_suites/rca/seeds/sensor/rca-sensor-availability-prest-hys14-002.yaml +70 -0
  91. repere-0.5.1/src/repere_suites/rca/seeds/sensor/rca-sensor-channel-code-hys14-001.yaml +64 -0
  92. repere-0.5.1/src/repere_suites/rca/seeds/sensor/rca-sensor-explain-hys12-vs-hys14-003.yaml +62 -0
  93. repere-0.5.1/src/repere_suites/rca/seeds/sensor/rca-sensor-known-issue-timing-hys14-005.yaml +59 -0
  94. repere-0.5.1/src/repere_suites/rca/seeds/sensor/rca-sensor-photo-request-004.yaml +64 -0
  95. repere-0.5.1/src/repere_suites/rca/solvers.py +55 -0
  96. repere-0.5.1/src/repere_suites/rca/validate.py +382 -0
  97. repere-0.5.1/src/repere_suites/sta_lta/__init__.py +22 -0
  98. repere-0.5.1/src/repere_suites/sta_lta/data/golden/.gitkeep +0 -0
  99. repere-0.5.1/src/repere_suites/sta_lta/data/golden/nisqually-2001.png +0 -0
  100. repere-0.5.1/src/repere_suites/sta_lta/data/golden/tohoku-2011-teleseism.png +0 -0
  101. repere-0.5.1/src/repere_suites/sta_lta/events.yaml +188 -0
  102. repere-0.5.1/src/repere_suites/sta_lta/inspect_tasks.py +199 -0
  103. repere-0.5.1/src/repere_suites/sta_lta/items.py +636 -0
  104. repere-0.5.1/src/repere_suites/sta_lta/judge_prompts/report_scorer.md +55 -0
  105. repere-0.5.1/src/repere_suites/sta_lta/recipe.py +236 -0
  106. repere-0.5.1/src/repere_suites/sta_lta/sandbox.py +368 -0
  107. repere-0.5.1/src/repere_suites/sta_lta/scorers.py +412 -0
  108. repere-0.5.1/src/repere_suites/synthetic_stalta/__init__.py +21 -0
  109. repere-0.5.1/src/repere_suites/synthetic_stalta/cases.yaml +11187 -0
  110. repere-0.5.1/src/repere_suites/synthetic_stalta/data/ridgecrest_seed.mseed +0 -0
  111. repere-0.5.1/src/repere_suites/synthetic_stalta/inspect_tasks.py +78 -0
  112. repere-0.5.1/src/repere_suites/synthetic_stalta/items.py +174 -0
  113. repere-0.5.1/src/repere_suites/synthetic_stalta/scorers.py +167 -0
  114. repere-0.5.1/tests/test_adapters.py +236 -0
  115. repere-0.5.1/tests/test_agent_registry.py +171 -0
  116. repere-0.5.1/tests/test_budget_guard.py +83 -0
  117. repere-0.5.1/tests/test_canonical_recipe.py +143 -0
  118. repere-0.5.1/tests/test_chart_renders.py +134 -0
  119. repere-0.5.1/tests/test_cli.py +67 -0
  120. repere-0.5.1/tests/test_cutoff_date.py +211 -0
  121. repere-0.5.1/tests/test_docker_sandbox.py +382 -0
  122. repere-0.5.1/tests/test_dvv_suite.py +104 -0
  123. repere-0.5.1/tests/test_eval_runner_integration.py +114 -0
  124. repere-0.5.1/tests/test_event_validation.py +176 -0
  125. repere-0.5.1/tests/test_export.py +141 -0
  126. repere-0.5.1/tests/test_inspect_tasks.py +202 -0
  127. repere-0.5.1/tests/test_judge_fallback.py +305 -0
  128. repere-0.5.1/tests/test_leaderboard.py +76 -0
  129. repere-0.5.1/tests/test_leaderboard_runner.py +169 -0
  130. repere-0.5.1/tests/test_lit_rag_scorers.py +213 -0
  131. repere-0.5.1/tests/test_literature_search.py +92 -0
  132. repere-0.5.1/tests/test_numerical_regression_scorer.py +222 -0
  133. repere-0.5.1/tests/test_orchestration_scorer.py +387 -0
  134. repere-0.5.1/tests/test_paper_workflow.py +107 -0
  135. repere-0.5.1/tests/test_pixi_lock.py +67 -0
  136. repere-0.5.1/tests/test_public_api.py +26 -0
  137. repere-0.5.1/tests/test_rca_e2e.py +105 -0
  138. repere-0.5.1/tests/test_rca_records.py +247 -0
  139. repere-0.5.1/tests/test_react_agent.py +190 -0
  140. repere-0.5.1/tests/test_react_descriptor.py +24 -0
  141. repere-0.5.1/tests/test_registry.py +133 -0
  142. repere-0.5.1/tests/test_router.py +164 -0
  143. repere-0.5.1/tests/test_sandbox_parity.py +162 -0
  144. repere-0.5.1/tests/test_site_data.py +166 -0
  145. repere-0.5.1/tests/test_skills.py +210 -0
  146. repere-0.5.1/tests/test_skills_manifest.py +66 -0
  147. repere-0.5.1/tests/test_sta_lta_suite.py +147 -0
  148. repere-0.5.1/tests/test_suite_fixtures.py +111 -0
  149. repere-0.5.1/tests/test_synthetic_stalta.py +143 -0
  150. repere-0.5.1/tests/test_telemetry.py +335 -0
  151. repere-0.5.1/tests/test_three_small_models.py +192 -0
repere-0.5.1/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Marine Denolle
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
repere-0.5.1/PKG-INFO ADDED
@@ -0,0 +1,454 @@
1
+ Metadata-Version: 2.4
2
+ Name: repere
3
+ Version: 0.5.1
4
+ Summary: Cost-aware, rigor-preserving evaluation of scientific AI agents in the geosciences
5
+ Author: Marine Denolle
6
+ License-Expression: MIT
7
+ Project-URL: Homepage, https://mdenolle.github.io/repere/
8
+ Project-URL: Repository, https://github.com/mdenolle/repere
9
+ Project-URL: Documentation, https://github.com/mdenolle/repere/tree/main/docs
10
+ Project-URL: Changelog, https://github.com/mdenolle/repere/blob/main/CHANGELOG.md
11
+ Project-URL: Issues, https://github.com/mdenolle/repere/issues
12
+ Keywords: ai-for-science,evaluation,benchmark,scientific-agents,cost-aware-evaluation,geoscience,seismology
13
+ Classifier: Development Status :: 4 - Beta
14
+ Classifier: Intended Audience :: Science/Research
15
+ Classifier: Topic :: Scientific/Engineering
16
+ Classifier: Topic :: Scientific/Engineering :: Physics
17
+ Classifier: Programming Language :: Python :: 3.10
18
+ Classifier: Programming Language :: Python :: 3.11
19
+ Classifier: Programming Language :: Python :: 3.12
20
+ Classifier: Programming Language :: Python :: 3.13
21
+ Classifier: Programming Language :: Python :: 3.14
22
+ Classifier: Operating System :: OS Independent
23
+ Requires-Python: >=3.10
24
+ Description-Content-Type: text/markdown
25
+ License-File: LICENSE
26
+ Requires-Dist: PyYAML>=6.0
27
+ Provides-Extra: test
28
+ Requires-Dist: pytest>=8.0; extra == "test"
29
+ Provides-Extra: geo
30
+ Requires-Dist: obspy>=1.4; extra == "geo"
31
+ Provides-Extra: plot
32
+ Requires-Dist: matplotlib>=3.8; extra == "plot"
33
+ Requires-Dist: numpy>=1.26; extra == "plot"
34
+ Requires-Dist: scikit-image>=0.22; extra == "plot"
35
+ Provides-Extra: dev
36
+ Requires-Dist: pytest>=8.0; extra == "dev"
37
+ Requires-Dist: ruff>=0.4; extra == "dev"
38
+ Provides-Extra: rca
39
+ Requires-Dist: jsonschema>=4.20; extra == "rca"
40
+ Requires-Dist: numpy>=1.26; extra == "rca"
41
+ Provides-Extra: eval
42
+ Requires-Dist: inspect_ai>=0.3.50; extra == "eval"
43
+ Dynamic: license-file
44
+
45
+ # Repère
46
+
47
+ Repère is an open evaluation framework for scientific AI agents in the geosciences. It measures whether a model or multi-agent system meets a task-specific **quality floor**, and what it **costs** to get there — so labs can adopt AI on measured evidence, not demos and anecdotes. Rigor is preserved by scoring against reference truth wherever possible; frugality is first-class because the interesting winner is the cheapest system that still clears the floor.
48
+
49
+ The narrative overview lives on the [landing page](https://mdenolle.github.io/repere/) (served from [`site/`](site/)); this README is the developer guide.
50
+
51
+ > **v0.5.1 — renamed from FrugalMind to Repère, and on PyPI** (September 2026). `pip install repere`. Import paths are `repere` / `repere_suites`, the CLI is `repere`, the sandbox image is `ghcr.io/mdenolle/repere-sandbox:v0.5.0`, and the 31 `FM_*` environment variables are now `REPERE_*` with no back-compatibility shim. The substrate is unchanged from v0.4.0: InspectAI `@task` / `@solver` / `@scorer`, a pinned Docker sandbox, a multi-step ReAct baseline with three Inspect tools, and telemetry aligned with `EvalSample` / `EvalOutput`. See [`CHANGELOG.md`](CHANGELOG.md) for the full set and [`ROADMAP.md`](ROADMAP.md) for what's next.
52
+
53
+ The current repository contains:
54
+
55
+ - A minimal core evaluation framework in `src/repere`.
56
+ - Benchmark suites across **three task families** (see below) in `src/repere_suites/`.
57
+ - Public sample fixtures for local development, plus a private-golden-data policy for hidden evaluation sets
58
+ (how to hold hidden gold: [`docs/golden_data_provisioning.md`](docs/golden_data_provisioning.md)).
59
+ - A static landing page + leaderboard in `site/` for GitHub Pages.
60
+ - Manual CI scaffolding for smoke tests and future scheduled evals.
61
+
62
+ ## Repère-RCA (design branch)
63
+
64
+ A suite for agents serving the NSF Ocean Observatories Initiative Regional
65
+ Cabled Array is being designed on `design/rca-harness`: three agent families
66
+ (coding, literature review, sensor), seven task groups, four verification
67
+ tiers, a golden-record schema with a validator, a frozen price map, a
68
+ cost-and-repeats runner, and 16 template records. Start at
69
+ [`DESIGN.md`](DESIGN.md) and [`OPEN_QUESTIONS.md`](OPEN_QUESTIONS.md);
70
+ the documentation index is [`docs/rca/README.md`](docs/rca/README.md).
71
+ Every record is a template until a named co-author verifies it.
72
+
73
+ ## Task families
74
+
75
+ Geoscience work is diverse, so the suite spans three families, each scored by the most verifiable method the task allows:
76
+
77
+ | Family | What it tests | Scored by | Suites | Design doc |
78
+ |---|---|---|---|---|
79
+ | **1 · Literature & multimodal** | review/critique, translation, interpolation, retrieval-augmented QA over papers, figures, waveforms | retrieval metrics (recall@k, nDCG), domain-term preservation, citation grounding | `lit_rag` | [`docs/lit_rag_scorers.md`](docs/lit_rag_scorers.md) |
80
+ | **2 · Coding agents** | prompt→code (run + check artifact) and prompt→data (drive a real pipeline — seisbench, noisepy, codameter — and check the numbers) | sandboxed execution + numerical regression within tolerance | `sta_lta`, `pipeline_regression`, `dvv`, `gaia_data_downloader` | [`docs/numerical_regression_scorer.md`](docs/numerical_regression_scorer.md) |
81
+ | **3 · Orchestration** | non-linear workflows: which sub-agents to call, in what order, with what dependencies | sub-agent call-DAG vs a reference (right steps, right deps, frugal fan-out) | `orchestration` | [`docs/orchestration_scorer.md`](docs/orchestration_scorer.md) |
82
+
83
+ Grading runs on a **scorability spectrum** — every task is pushed as far toward a deterministic reference (T0) as it will go, falling back to an LLM-judge rubric (T4) only when nothing else fits. To contribute a dataset, see [`docs/dataset_submission.md`](docs/dataset_submission.md).
84
+
85
+ The demo leaderboard is deliberately populated with **laptop-scale open models** (7–8B via Ollama: `qwen2.5`, `llama3.1`, `deepseek-r1`, `olmo2`) plus one cloud model as a reference ceiling. Small models make the frugality claim falsifiable (they *don't* automatically clear the quality floor), keep the board reproducible without a credit card, and are the models allowed to touch embargoed data. See [`docs/laptop_scale_mvp.md`](docs/laptop_scale_mvp.md) — which also states plainly what the demo board is and is not.
86
+
87
+ ## Why this exists
88
+
89
+ Multi-agent systems often use expensive frontier models for every step, even when a smaller model is good enough for extraction, plotting, code generation, or reporting. Repère aims to learn and enforce task-specific quality floors from hidden/private golden datasets, then route subagent work by cost subject to rigor constraints.
90
+
91
+ Initial focus:
92
+
93
+ 1. Define reproducible benchmark suites with deterministic scorers where possible.
94
+ 2. Maintain public sample fixtures for development.
95
+ 3. Keep full golden datasets private to reduce overfitting.
96
+ 4. Run evals on demand first.
97
+ 5. Promote to scheduled weekly GitHub Actions evals when provider credentials, budgets, and private data access are ready.
98
+
99
+ ## Repository layout
100
+
101
+ ```text
102
+ repere/
103
+ ├── src/
104
+ │ ├── repere/ # Core eval primitives and CLI
105
+ │ │ ├── adapters.py # AnthropicAdapter, OpenAICompatAdapter, EchoAdapter
106
+ │ │ ├── budget.py # BudgetGuard
107
+ │ │ ├── leaderboard.py # LeaderboardRunner + skill-lift export
108
+ │ │ ├── registry.py # YAML model-registry loader
109
+ │ │ ├── router.py # FrugalRouter
110
+ │ │ ├── skills.py # SkillLoader, SkillManifest, render modes
111
+ │ │ └── telemetry.py # JSONLTelemetry
112
+ │ └── repere_suites/ # Benchmark suites across 3 task families
113
+ │ ├── sta_lta/ # Family 2 — STA/LTA seismic pipeline (reference suite)
114
+ │ ├── pipeline_regression/ # Family 2 — prompt→data numerical regression
115
+ │ ├── dvv/ # Family 2 — dv/v processing (codameter-backed)
116
+ │ ├── gaia_data_downloader/ # Family 2 — data-download coding agent
117
+ │ ├── lit_rag/ # Family 1 — retrieval / translation / grounded QA
118
+ │ └── orchestration/ # Family 3 — non-linear subagent workflows
119
+ ├── config/
120
+ │ └── models.yaml # 13-model registry (nano/small/medium/big/cloud)
121
+ ├── notebooks/ # Interactive walkthroughs (quickstart, etc.)
122
+ ├── scripts/ # Small standalone runners
123
+ ├── tests/ # Deterministic test suite (~260 tests)
124
+ ├── docs/ # Archived suite docs and design notes
125
+ ├── site/ # GitHub Pages leaderboard
126
+ ├── .github/skills/ # Domain-agent skills + manifest.yaml
127
+ ├── .github/workflows/ # Manual CI scaffold
128
+ ├── pyproject.toml # Python package metadata
129
+ ├── pixi.toml # Primary development environment
130
+ └── environment.yml # Conda fallback
131
+ ```
132
+
133
+ The original STA/LTA suite README has been preserved in `docs/sta_lta_suite_v0.md`.
134
+
135
+ ## Quickstart with Pixi
136
+
137
+ Install Pixi, then run:
138
+
139
+ ```bash
140
+ pixi install
141
+ pixi run test # deterministic test suite (~260 tests, no providers)
142
+ pixi run smoke-eval # stub eval; writes results/stub_eval.json
143
+ pixi run export-leaderboard # builds site/data/leaderboard.json
144
+ ```
145
+
146
+ `pixi run test` does not need ObsPy, network access, model-provider
147
+ credentials, or private goldens.
148
+
149
+ ## Install from PyPI
150
+
151
+ ```bash
152
+ pip install repere # core framework + CLI
153
+ pip install "repere[eval,rca,plot]" # InspectAI substrate, RCA validator, plot scorer
154
+ pip install "repere[geo]" # ObsPy, for the waveform-fetching suites
155
+ ```
156
+
157
+ The dv/v suite's scoring backend is pinned to an immutable git commit, which
158
+ PyPI will not accept as a declared dependency, so it installs separately:
159
+
160
+ ```bash
161
+ pip install -r requirements-dvv.txt
162
+ ```
163
+
164
+ The CLI also exposes:
165
+
166
+ ```bash
167
+ pixi run repere list-models # print the loaded model registry
168
+ pixi run repere list-skills # print skills + their suite bindings
169
+ pixi run repere run-skill-lift # offline skill-lift demo
170
+ pixi run repere run-ollama-intent --model mistral:7b --skill stalta-detection
171
+ ```
172
+
173
+ ## Running local evals and viewing the dashboard
174
+
175
+ If you have an [Ollama](https://ollama.com) server running with at least
176
+ one model pulled (e.g. `ollama pull mistral`), you can populate the
177
+ leaderboard end-to-end from your own machine:
178
+
179
+ ```bash
180
+ # 1. Verify the model is available.
181
+ curl -s http://localhost:11434/api/tags | python -m json.tool
182
+
183
+ # 2. Run the STA/LTA intent-extraction suite under two conditions
184
+ # (generic vs skill-conditioned). Each writes one JSON result file
185
+ # under results/.
186
+ pixi run -e full repere run-ollama-intent \
187
+ --model mistral:latest --condition generic
188
+ pixi run -e full repere run-ollama-intent \
189
+ --model mistral:latest --skill stalta-detection --skill-mode instructions
190
+
191
+ # 3. Optional baselines: a deterministic stub eval and the offline
192
+ # skill-lift benchmark, also written to results/.
193
+ pixi run -e full repere smoke-eval
194
+ pixi run -e full repere run-skill-lift \
195
+ --skill stalta-detection --output results/skill_lift_stalta.json
196
+
197
+ # 4. Aggregate every JSON file under results/ into the static dashboard
198
+ # payload that the GitHub Pages app consumes.
199
+ pixi run -e full repere export-leaderboard \
200
+ --results-dir results --output site/data/leaderboard.json
201
+
202
+ # 5. Serve the dashboard locally and open it in a browser.
203
+ python -m http.server 8765 --directory site
204
+ # then visit http://localhost:8765/#leaderboard
205
+ ```
206
+
207
+ Add more rows by pulling additional Ollama models (`ollama pull llama3.1:8b`,
208
+ `ollama pull qwen2.5:7b`) and repeating step 2 with `--model <id>`. Each
209
+ unique `(model, condition)` pair becomes its own row.
210
+
211
+ ## Conda fallback
212
+
213
+ If Pixi is unavailable:
214
+
215
+ ```bash
216
+ conda env create -f environment.yml
217
+ conda activate repere
218
+ python -m pip install -e .
219
+ python -m pytest
220
+ python -m repere.cli smoke-eval
221
+ python -m repere.cli export-leaderboard
222
+ ```
223
+
224
+ ## Notebooks
225
+
226
+ The fastest way to see the framework in action is the quickstart notebook:
227
+
228
+ ```bash
229
+ pip install -e ".[dev]" jupyter
230
+ jupyter lab notebooks/
231
+ ```
232
+
233
+ Then open [`notebooks/01_skill_lift_quickstart.ipynb`](notebooks/01_skill_lift_quickstart.ipynb).
234
+ It walks through three small-tier models (`mistral:7b`, `llama3.1:8b`,
235
+ `qwen2.5:7b`) running the public STA/LTA intent-extraction suite under
236
+ `none` vs `full` skill conditions and produces a leaderboard JSON. The
237
+ default path uses an `EchoAdapter` so it runs offline; the last section
238
+ shows how to swap to a live Ollama server with a one-line factory change.
239
+
240
+ To run the same demo from the command line without the notebook:
241
+
242
+ ```bash
243
+ python scripts/demo_small_models.py # offline stub demo
244
+ python scripts/demo_small_models.py --live # uses local Ollama
245
+ ```
246
+
247
+ See [`notebooks/README.md`](notebooks/README.md) for more.
248
+
249
+ ## Current benchmark suite
250
+
251
+ The STA/LTA suite tests a seismic analysis pipeline:
252
+
253
+ 1. Intent extraction from natural language to FDSN query JSON.
254
+ 2. ObsPy waveform-fetch code generation.
255
+ 3. STA/LTA trigger code generation.
256
+ 4. Plot generation and comparison to approved goldens.
257
+ 5. One-paragraph technical reporting.
258
+
259
+ The public sample truth set currently has six events across regional earthquakes, teleseisms, noise days, and quarry blasts. Several entries are marked `VERIFY`; do not publish benchmark numbers until those catalog entries are validated.
260
+
261
+ The rationale for starting with STA/LTA is documented in `docs/stalta_benchmark_rationale.md`. In short, this is the smallest complete earthquake-seismology coding pipeline: fetch waveform data, detect a possible event, plot the result, and explain whether the source is plausibly local/regional, teleseismic, anthropogenic, or noise.
262
+
263
+ A draft seismology domain skill is available at `.github/skills/seismo-data-agent/SKILL.md`. Runs that use it should be labeled separately from raw coding-agent runs, for example with `agent_condition = "SeismoDataAgent+skill-v0.1-draft"`. Leaderboard condition metadata are described in `docs/leaderboard_conditions.md`.
264
+
265
+ ## Golden datasets
266
+
267
+ The STA/LTA suite uses two kinds of gold, and the leaderboard is a third
268
+ artifact derived from runs over those golds. All three are reproducible
269
+ from the scripts in [`scripts/`](scripts/), and each has a drift test that
270
+ fails when the artifact and its source diverge.
271
+
272
+ | Artifact | Where it lives | How to (re)build | Drift test |
273
+ |---|---|---|---|
274
+ | `(prompt, gold)` fixtures for intent / fetch_code / trigger_code / report | [`tests/fixtures/sta_lta.<suite>.json`](tests/fixtures/) | `python scripts/build_suite_fixtures.py` | [`tests/test_suite_fixtures.py`](tests/test_suite_fixtures.py) |
275
+ | Plot PNG goldens (public) | [`src/repere_suites/sta_lta/data/golden/<id>.png`](src/repere_suites/sta_lta/data/golden/) | `python scripts/build_plot_goldens.py` | [`tests/test_canonical_recipe.py`](tests/test_canonical_recipe.py) |
276
+ | Plot PNG goldens (private) | `$REPERE_STALTA_GOLDEN_DIR/<id>.png` (gitignored) | `python scripts/build_plot_goldens.py --private` | none — private; reviewed manually |
277
+ | Static leaderboard data | [`site/data/leaderboard.json`](site/data/leaderboard.json), [`site/data/skill_lift.json`](site/data/skill_lift.json) | `python scripts/build_site_data.py` | [`tests/test_site_data.py`](tests/test_site_data.py) |
278
+
279
+ ### 1. Build the `(prompt, gold)` fixtures for the four parametric suites
280
+
281
+ Four of the five STA/LTA suites are parametric over `events.yaml` —
282
+ intent_extraction, fetch_code, trigger_code, and report all derive every
283
+ prompt and every gold answer at runtime from the same truth set. To get a
284
+ human-inspectable static view of what the benchmark asks each model:
285
+
286
+ ```bash
287
+ python scripts/build_suite_fixtures.py
288
+ ```
289
+
290
+ This writes one JSON file per suite under `tests/fixtures/`:
291
+
292
+ ```text
293
+ tests/fixtures/
294
+ ├── sta_lta.intent_extraction.json # 6 items, JSON-shaped golds
295
+ ├── sta_lta.fetch_code.json # 6 items, code-execution scoring
296
+ ├── sta_lta.trigger_code.json # 6 items, code-execution scoring
297
+ └── sta_lta.report.json # 6 items, lexical scoring
298
+ ```
299
+
300
+ Each item looks like this (snippet from `sta_lta.intent_extraction.json`):
301
+
302
+ ```json
303
+ {
304
+ "item_index": 0,
305
+ "prompt": "Extract a JSON object describing the FDSN waveform request for this analysis task:\n\nTask: M6.8 Nisqually deep intraslab earthquake\nOrigin time (UTC): 2001-02-28T18:54:32.8\nSuggested station: UW.LON..BHZ\nSuggested window: ±7.5 minutes around origin.\n\nReturn ONLY a JSON object with keys: network, station, location, channel, starttime, endtime. Use ISO-8601 timestamps.",
306
+ "gold": {
307
+ "network": "UW",
308
+ "station": "LON",
309
+ "location": "",
310
+ "channel": "BHZ",
311
+ "starttime": "2001-02-28T18:47:02.800000+00:00",
312
+ "endtime": "2001-02-28T19:02:02.800000+00:00"
313
+ }
314
+ }
315
+ ```
316
+
317
+ The fixtures are not the gold; `events.yaml` is. The fixtures are a
318
+ **static rendering** of what the live suites currently emit, so reviewers
319
+ can read prompts and golds in a PR without running Python. If you change
320
+ `events.yaml` or a suite prompt template, regenerate the fixtures and
321
+ commit the diff in the same PR. `tests/test_suite_fixtures.py` will fail
322
+ until you do.
323
+
324
+ ### 2. Build the plot PNG goldens
325
+
326
+ The fifth suite (plot) compares model output to a reference PNG via SSIM.
327
+ The generator is [`scripts/build_plot_goldens.py`](scripts/build_plot_goldens.py); it supports two
328
+ output modes (public vs private) and two data modes (real FDSN vs
329
+ deterministic synthetic):
330
+
331
+ ```bash
332
+ # (A) Public goldens, real FDSN data — commits under data/golden/.
333
+ # Use only for citable events that have been validated against a catalog.
334
+ python scripts/build_plot_goldens.py --only nisqually-2001 tohoku-2011-teleseism
335
+
336
+ # (B) Private goldens for VERIFY events still under validation.
337
+ # Output dir is gitignored; REPERE_STALTA_GOLDEN_DIR points scorers at it.
338
+ REPERE_STALTA_GOLDEN_DIR=~/private/fm_goldens \
339
+ python scripts/build_plot_goldens.py --private \
340
+ --only pnsn-quiet-day-VERIFY mt-rainier-swarm-2024-VERIFY
341
+
342
+ # (C) Synthetic-data fallback for sandboxes / CI smoke. Deterministic.
343
+ # Do NOT publish benchmark numbers against synthetic goldens.
344
+ python scripts/build_plot_goldens.py --synth --only nisqually-2001 tohoku-2011-teleseism
345
+ ```
346
+
347
+ The recipe — preprocessing, STA/LTA, and the matplotlib layout — is pinned
348
+ in [`src/repere_suites/sta_lta/recipe.py`](src/repere_suites/sta_lta/recipe.py) and
349
+ shared by both data modes. The two-panel layout (waveform + STA/LTA, red
350
+ dashed vertical lines at trigger onsets, station/event title) matches what
351
+ the [`seismic-plotting`](.github/skills/seismic-plotting) skill instructs
352
+ models to produce.
353
+
354
+ > The two public goldens currently committed (`nisqually-2001.png`,
355
+ > `tohoku-2011-teleseism.png`) were generated in synthetic mode. Regenerate
356
+ > with mode (A) on a host with EarthScope/IRIS access before any
357
+ > leaderboard publication.
358
+
359
+ ### 3. Build the static-site leaderboard data
360
+
361
+ After running real evals (or just the offline demo), refresh the JSON files
362
+ the GitHub-Pages site reads:
363
+
364
+ ```bash
365
+ # Run the offline 3-small-models demo to produce results/demo_small_models.json:
366
+ python scripts/demo_small_models.py
367
+
368
+ # Or hit local Ollama instead:
369
+ python scripts/demo_small_models.py --live
370
+
371
+ # Then build the static-site data:
372
+ python scripts/build_site_data.py
373
+ ```
374
+
375
+ This writes:
376
+
377
+ - `site/data/leaderboard.json` — main per-row leaderboard (rank, model,
378
+ agent_condition, suite, score, cost, completed, efficiency).
379
+ - `site/data/skill_lift.json` — per-model lift table (`score_none`,
380
+ `score_full`, `lift`, `cost_lift_pct`).
381
+
382
+ The HTML page at [`site/index.html`](site/index.html) renders both as two
383
+ separate tables. To preview locally:
384
+
385
+ ```bash
386
+ cd site && python -m http.server 8123
387
+ # then open http://127.0.0.1:8123/
388
+ ```
389
+
390
+ `tests/test_site_data.py` validates the schema of both JSON files and
391
+ checks that every `querySelector('#…')` in [`site/app.js`](site/app.js) has
392
+ a matching id in the HTML — a regression in either side of the contract
393
+ fails the test before it reaches Pages.
394
+
395
+ ### Public-vs-private policy
396
+
397
+ - Commit small public fixtures, sample events, and PNG goldens for
398
+ VERIFIED citable events (Nisqually 2001, Tōhoku 2011).
399
+ - Do not commit full private goldens, provider secrets, or paid-eval
400
+ outputs.
401
+ - Point scorers at private STA/LTA goldens via `REPERE_STALTA_GOLDEN_DIR`; the
402
+ generator's `--private` flag respects it.
403
+ - Store local eval outputs under `results/`, which is gitignored.
404
+ - Use GitHub Actions secrets for future private CI access.
405
+ - Promote generated artifacts to public goldens only after human review of
406
+ the catalog match and the underlying waveform.
407
+
408
+ ### Tests that protect each artifact
409
+
410
+ | Test file | What it checks |
411
+ |---|---|
412
+ | [`tests/test_suite_fixtures.py`](tests/test_suite_fixtures.py) | Each parametric suite's live items match the committed `(prompt, gold)` fixtures. Fails if `events.yaml` or a prompt template drifts. |
413
+ | [`tests/test_canonical_recipe.py`](tests/test_canonical_recipe.py) | The plot recipe is byte-deterministic (SSIM=1.0 self-match), positive synthetic events trigger, negative ones don't, both committed public PNGs exist. |
414
+ | [`tests/test_site_data.py`](tests/test_site_data.py) | `leaderboard.json` and `skill_lift.json` have the expected fields; `app.js` selectors all resolve in `index.html`. |
415
+ | [`tests/test_three_small_models.py`](tests/test_three_small_models.py) | The 3-small-models skill-lift demo runs end-to-end against the YAML registry and produces sane lift values. |
416
+
417
+ ## Manual evals now, weekly later
418
+
419
+ The initial workflow is manual by design. The GitHub Actions scaffold supports `workflow_dispatch` and runs smoke tests by default. A weekly schedule is included as a commented scaffold for later activation once costs, secrets, and private data access are configured.
420
+
421
+ ## Live leaderboard
422
+
423
+ The static leaderboard lives in `site/` and is deployed by `.github/workflows/pages.yml` using GitHub Pages. On each push to `main`, the workflow runs tests, generates a public smoke leaderboard, and deploys the static site artifact.
424
+
425
+ To update the leaderboard locally:
426
+
427
+ ```bash
428
+ pixi run smoke-eval
429
+ pixi run export-leaderboard
430
+ ```
431
+
432
+ For GitHub, set Pages to deploy from GitHub Actions if it is not already enabled in repository settings. Private golden-set results should only be exported into the public site after human approval.
433
+
434
+ Leaderboard rows include an `agent_condition` field so a raw `generic-coding-agent` run is not mixed with a `SeismoDataAgent+skill-v0.1-draft` run. Skill-assisted runs may also include `skill_name` and `skill_version`.
435
+
436
+ ## Roadmap
437
+
438
+ The current plan is in [`ROADMAP.md`](ROADMAP.md) — three phases of work
439
+ aligning Repère with [AstaBench](https://allenai.org/asta/bench) and
440
+ [InspectAI](https://inspect.aisi.org.uk/) standards while keeping
441
+ Repère's distinct identity (skills system, frugality-first framing,
442
+ parametric truth set, negative-case discipline). Each item is a candidate
443
+ GitHub issue under the `astabench-alignment` label; bootstrap them with:
444
+
445
+ ```bash
446
+ bash scripts/create_roadmap_issues.sh # all items
447
+ bash scripts/create_roadmap_issues.sh --dry-run # preview only
448
+ bash scripts/create_roadmap_issues.sh --only P1.1 P1.3
449
+ ```
450
+
451
+ The script is idempotent: re-running it updates existing issues by `[Px.y]`
452
+ title prefix rather than creating duplicates. New issues should follow the
453
+ roadmap-item template at
454
+ [`.github/ISSUE_TEMPLATE/roadmap_item.yml`](.github/ISSUE_TEMPLATE/roadmap_item.yml).