OHDSI/MIMIC ? reverse-engineered prompt
Reverse engineered prompt
Build me a Python project that converts MIMIC IV hospital data into OMOP CDM tables.
I want one clear workflow that can refresh vocabularies, load any waveform sample data, create the empty target tables, stage and clean the source data, map source codes to OMOP concepts, run the ETL into the CDM tables, run basic unit tests, generate QA metrics, and then unload the final OMOP output for analysis in OHDSI tools like ATLAS or DQD.
Please make it work for both a small demo setup and a full run, with simple config files for each environment. It should also support custom concept mappings, keep intermediate staging tables separate from the final CDM tables, and include a script or command flow that is easy to run from the project root. If anything depends on current OMOP vocabulary setup or other external docs, look it up online if needed.
Are you gonna build this?
make sure you review the code using coderabbit