Skip to content

Commit ae19201

Browse files
committed
[verify.research.ρ.D8+] make the closed loop visible and continuously testable
The attachment requires a visible loop, explicit claim boundaries, a regenerated architecture twin, and new provider/loop gates. Add one first-class twin flow from frozen context through untrusted Qwen proposal, validation, exact human-approved RunSet and evidence refresh; document workflow completion versus execution correctness versus scientific validity; and make portable plus isolated-PostgreSQL acceptance executable from the canonical gate suite. The generated JSON/HTML are the same action because the checker proves they embed the source model without drift.
1 parent 5ba4699 commit ae19201

6 files changed

Lines changed: 22944 additions & 11033 deletions

File tree

‎README.md‎

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,27 @@ identity, missing preparation witnesses, hard clashes and unverified mappings ke
7171
execution locked. Human review can accept a pose hypothesis; it cannot manufacture a
7272
scientific result or override missing machine evidence.
7373

74+
#### AI-guided FEP research loop
75+
76+
The Workbench Research Loop drawer closes one bounded evidence-acquisition cycle over an
77+
already governed, planned FEP Campaign. An OpenAI-compatible Qwen provider receives a
78+
frozen, size-bounded context and may return only a schema-validated proposal. Dirac—not the
79+
model—resolves server-owned references, compiles the exact action, enforces the frozen
80+
budget and policy, and requires a human decision for physical R3 execution. Durable Jobs,
81+
Artifacts, events, approvals and request keys allow the cycle to resume after browser or
82+
backend restart.
83+
84+
The three completion claims remain separate:
85+
86+
- **Workflow completion** means the controller reached an explicit stop or terminal state.
87+
- **Execution correctness** means the admitted Job/RunSet completed under its pinned inputs,
88+
method and provenance contract.
89+
- **Scientific validity** requires the existing quality projection and typed Evidence path;
90+
a model proposal and a `completed_unvalidated` FEP result are not scientific evidence.
91+
92+
Provider failure degrades only this optional capability. It does not disable the FEP
93+
Workbench, existing Commands, Jobs or Artifacts, and no automatic provider fallback occurs.
94+
7495
### Motif Workbench · Field
7596

7697
![A computed electrostatic field rendered in Dirac's shared molecular scene](docs/screenshots/02_fields_electrostatic_well.png)

‎backend/README.md‎

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ scientific output.
4141
| `artifacts.py` | local and PostgreSQL content-addressed artifact stores |
4242
| `programs/` | durable Program aggregate and repository logic |
4343
| `motif/` | governed data, model, proposal, structure, physics and closed-loop workflows |
44+
| `research/` | bounded provider adapter and durable AI-guided FEP evidence-acquisition controller |
4445
| `execution_control/` | allocation, attempt identity, leases, retries, reconciliation and completion |
4546
| `executors/` | local process/GPU and Kubernetes/Kueue adapters |
4647
| `db/` | PostgreSQL schema, migrations, checks and operational views |
@@ -100,3 +101,24 @@ After changing any backend file on the canonical workstation, restart
100101
- A Job/transport parity test proves routing and persistence, not scientific validity.
101102
- GPU work is submitted through the configured execution boundary; repository users must
102103
not launch competing unmanaged CUDA work.
104+
- Research-loop completion is workflow state, not proof of execution correctness or
105+
scientific validity. Model proposals remain non-evidence; completed FEP Method results
106+
remain `completed_unvalidated` until the existing typed quality/evidence projection.
107+
108+
## AI research-loop verification
109+
110+
The provider is optional and OpenAI-compatible. Missing provider configuration leaves the
111+
core service healthy and reports the AI capability as degraded; shared-Dirac-GPU provider
112+
profiles are refused. The production loop requires forward migrations 049 and 050.
113+
114+
```bash
115+
bash scripts/gates.sh research
116+
117+
# Additional durable PostgreSQL and fake-provider acceptance:
118+
DIRAC_TEST_DSN='dbname=<isolated-test-db>' bash scripts/gates.sh research
119+
```
120+
121+
The acceptance script replaces only the expensive OpenFE RunSet with an explicitly fake,
122+
deterministic implementation. Command dispatch, Method invocation, provider HTTP, Jobs,
123+
Artifacts, approvals, database checkpoints and reload are real. It refuses any database
124+
whose name does not contain `test`.

‎docs/architecture/dirac-digital-twin.html‎

Lines changed: 1 addition & 1 deletion
Large diffs are not rendered by default.

0 commit comments

Comments
 (0)