OSP observed-data import¶
The first importer supports OSP observed-data v1.9. It pins the upstream commit and workbook checksum in python/src/pkdb/importers/osp/release.py for reproducible imports.
Import¶
pkdb import osp --creator osp-import --output /path/to/new-import
# For an existing workbook, add: --offline --workbook /path/to/ObsDataPK_OSP.xlsx
The output directory must be new or empty. It contains study folders, a portable vocabulary, original source rows, and import-report.json with mapping warnings. The initial local import produced 741 studies and 33,103 reported outputs from 3,079 assessments; artifacts and database verification are under .cache/osp/v1.9/.
Studies are identified by publication + source. OSP records use source osp.observed-data and are labelled Automatic import. Manual curation, imports, and automatic curation share the scientific model but retain separate provenance and citation snapshots. Re-importing a release replaces the same source study without overwriting manual curation. See the data model.
Ambiguous statistics, units, and dosing schedules remain in source attachments and are listed in the report. Individual values and doses are written to mean, and geometric means to gmean, so an OSP geometric summary keeps its meaning. The geometric SD of a geometric mean is written to gsd when it is a dimensionless factor of at least 1, and its geometric CV in percent to gcv as a fraction; other uncertainty of a geometric mean, and geometric uncertainty of an arithmetic mean, remain in the source attachment and are reported as uncertainty_retained_in_source. Unknown sample sizes stay null. Review the vocabulary additions and warnings before uploading; not every source cell has a native scientific representation.
To load a configured server, create the attribution account, apply migration p004sources, and reconcile the vocabulary additions first. Set PKDB_API_TOKEN, then run:
pkdb-server validate /path/to/new-import/studies --api-url "$PKDB_API_URL"
pkdb-server upload /path/to/new-import/studies --api-url "$PKDB_API_URL"
Imports default to private access and closed licence. The portable vocabulary is for validation, not a replacement for an existing server's vocabulary.
Regular release check¶
The OSP release check GitHub Actions workflow checks the latest stable upstream release every Monday at 07:23 UTC, with a manual Run workflow option. It becomes scheduled once merged into the repository's default branch, as required by GitHub scheduled workflows.
The job summary reports the pinned and latest versions. A newer release fails the check to flag an update for review; request failures are reported separately. No data is downloaded or imported by this check. Run it locally with:
Exit codes: 0 current, 2 newer release, 1 failed check or unexpected upstream metadata. When an update appears, review the release and workbook changes, update the commit/checksum/version pin, adjust mappings if needed, validate, then import through the normal pipeline.