Collect a finished NLME job
collect_nlme_job.RdReturns a compact summary plus artifact paths. Does not stream large files.
Usage
collect_nlme_job(
job_id,
project_dir = ".",
refresh_fit_health = TRUE,
darwin_ofv = NULL,
ofv_tolerance = NULL
)Arguments
- job_id
Job id.
- project_dir
Project root.
- refresh_fit_health
When
TRUE(the default), recomputefit_healthat collection time. SetFALSEto reusefit_healthfrom a recentget_nlme_job_status()/wait_for_nlme_job()poll when the job already succeeded and artifacts are unlikely to have changed.- darwin_ofv
Optional
results.csv$ofv(raw-2LL, NOTfitness) from a pyDarwin (Certara.RDarwin) search candidate that this job is a refit of. When supplied and the fit succeeded, anofv_parityblock is attached reconcilingdarwin_ofvagainst this refit'sfit_health$neg2ll. Required before treating this job as a qualified structural anchor for any nested LRT (seevalidate_sequential_lrt()).- ofv_tolerance
Optional absolute tolerance (in
-2LLunits) for theofv_paritycheck. Defaults tomax(0.5, 0.001 * abs(darwin_ofv))to accommodate pyDarwin's chained##ESTARGSstages, which can shift the final -2LL by a small amount versus a single-stage RsNLME refit.
Value
A list summary with state, run_dir, artifact_dir, artifacts
(paths relative to artifact_dir), fit_health, tail of logs, and a
next_action directive: save_analysis_plan with blocking = TRUE when
no plan is saved and this job was not launched under an approved
allow_unplanned exception; get_project_workflow_status (non-blocking)
on success once a plan exists or the exception is on record; NULL for a
failed/dead job (see $failure instead). For failed/dead jobs
requires_user_attention is TRUE and a failure block carries a
normalized error_class, suggested_fix, and related_kb entry. When
darwin_ofv is supplied, also includes ofv_parity. artifact_integrity
reports whether the artifacts still match the manifest recorded for this
job; a "violation" takes precedence over every other directive and
yields a blocking artifact_integrity_violation next_action.
Details
The summary includes a fit_health block (data file size, engine status,
return code, -2LL, and whether stderr mentions a missing dataset) so a
state == "succeeded" is not mistaken for a good fit - the common failure
mode where a metamodel with a missing ## DATA path "succeeds" on an empty
data1.txt.