First SDTM mapping spec from CRF pages
Paste CRF page text, get a draft SDTM mapping spec with every guess flagged and the open questions listed.
About 20 minExcelDemonstration only
What you get
| A | B | C | D | E | F | |
|---|---|---|---|---|---|---|
| 1 | CRF field | SDTM variable | Origin | Terminology or format | CRF page | Checked against define.xml |
| 2 | Header "H2Q-MC-LZZT" with annotation "STUDYID" and fragment "CDISCPILOT01" | STUDYID (all domains) | Assigned | Literal "CDISCPILOT01" (fragment read in full) | 7 | Partly correct |
| 3 | Patient initials (First / Middle / Last) | None | n/a | n/a | 7 | Correct |
| 4 | Patient and site identifiers | None legible. The "PATIENT ... IDENTIFICATION" heading is interleaved with another fragment (partial). | n/a | n/a | 7 | Real gap |
| 5 | Visit date (MM/DD/YY) | SV.SVSTDTC. A fragment reads "SVSTDTC" (partial). The same date is also routed to other --DTC variables, as in the next row. | CRF | ISO 8601. The CRF format is MM/DD/YY. | 7 | Partly correct |
| 6 | (Visit date annotation list) | The fragments read AEDTC, CMDTC, DMDTC, DSSTDTC, DSDTC, QSDTC, VSDTC, MHDTC and SCDTC (partial, in scrambled order). | CRF | ISO 8601 | 7 | Correct |
| 7 | (no printed label) | VISITNUM | Assigned | "1" (fragment VISITNUM="1" appears more than once, legible) | 7 | Partly correct |
| 8 | Date patient and caregiver signed the consent document (MM/DD/YY) | Domain unresolved. Candidates: DS.DSSTDTC or DM.RFICDTC (suggestion). A "DSSTDTC" and an "SCDTC" fragment sit nearby, but I cannot tie either to this field. | CRF | ISO 8601 | 7 | Partly correct |
| 9 | Date of birth (MM/DD/YY) | DM.BRTHDTC (suggestion) | CRF | ISO 8601 | 7 | Wrong |
| 10 | Sex: "F Female", "M Male" | DM.SEX | CRF | F, M (printed codes). Suggestion: these match the CDISC SEX codelist. | 7 | Correct |
| 11 | Race "Origin": CA Caucasian (European, Mediterranean, Middle Eastern); AF African Descent (Negro, Black); EA East/Southeast Asian; AS Western Asian (Pakistani, Indian Sub-continent); HP Hispanic (Mexican-American, Mexico, Central and South America); O Other (Mixed-racial parentage, American Indian, Eskimo) | DM.RACE (suggestion). The HP option may belong in DM.ETHNIC instead (Q6). | CRF | The 2-letter codes are CRF codes only. Do not copy them into RACE. | 7 | Correct |
| 12 | Number of years of education completed | SC.SCORRES | CRF | Numeric, in years | 8 | Partly correct |
| 13 | (SCTESTCD) | SC.SCTESTCD | Assigned | "YEARSEDU" | 8 | Partly correct |
| 14 | HABITS: SMOKING, "Information not obtained" | Suggestion: SU.SUSTAT = "NOT DONE" | CRF | n/a | 8 | Not in source |
| 15 | Number of cigarettes, cigars, pipesful (average current daily use) | Suggestion: SU (SUTRT = CIGARETTES, CIGARS, PIPE; SUDOSE; SUDOSFRQ = per day) | CRF | 0 = None; L = Less than one; 1, 2, 3... whole numbers | 8 | Not in source |
| 16 | Number of years (past or current) patient has smoked; enter 0 if never smoked | Suggestion: SU.SUDUR | CRF | Suggestion: ISO 8601 duration, "P#Y" | 8 | Not in source |
| 17 | Month and year that the patient quit smoking (MM/YY) | Suggestion: SU.SUENDTC | CRF | ISO 8601 partial date, YYYY-MM | 8 | Not in source |
| 18 | HABITS: ALCOHOL, "Information not obtained" | Suggestion: SU.SUSTAT = "NOT DONE" | CRF | n/a | 8 | Not in source |
| 19 | Number of beers or wine coolers/spritzers; glasses of wine; drinks containing distilled spirits (average current weekly consumption) | Suggestion: SU (SUTRT = ALCOHOL, with SUDOSE and SUDOSFRQ = per week) | CRF | 0 = None; L = Less than one; whole numbers | 8 | Not in source |
| 20 | Weight, "Information not obtained" | Suggestion: VS.VSSTAT = "NOT DONE" | CRF | n/a | 16 | Correct |
| 21 | Weight (__ __ __ . __) | VS.VSORRES | CRF | Numeric, rounded to the nearest tenth. The width is not shown. | 16 | Correct |
| 22 | Weight unit: kg Kilogram, lb Pound | VS.VSORRESU | CRF | The printed codes are "kg" and "lb". Whether these match the CDISC UNIT terms is Q8. | 16 | Partly correct |
| 23 | (VSTESTCD) | VS.VSTESTCD | Assigned | "WEIGHT" | 16 | Correct |
| 24 | Height, "Information not obtained" | Suggestion: VS.VSSTAT = "NOT DONE" | CRF | n/a | 16 | Correct |
| 25 | Height (__ __ __ . __) | VS.VSORRES | CRF | Numeric, rounded to the nearest tenth. The format shown is `___ . ___`. | 16 | Correct |
| 26 | Height unit: cm Centimeter, in Inch | VS.VSORRESU | CRF | The printed codes are "cm" and "in". See Q8. | 16 | Partly correct |
| 27 | (VSTESTCD) | VS.VSTESTCD | Assigned | "HEIGHT" | 16 | Correct |
| 28 | Vital signs table: Reference Timing, Position, Time Code | VS.VSPOS, VS.VSTPT, VS.VSTPTNUM (annotated; fragment names read) | CRF / Assigned | Position codes printed: SU = Supine, ST = Standing. | 16 | Correct |
| 29 | Time Code 815 / 816 / 817 | VS.VSTPTNUM | Assigned | 815, 816, 817 | 16 | Correct |
| 30 | Heart Rate | VS.VSORRES with VSTESTCD "PULSE" | CRF | Numeric | 16 | Correct |
| 31 | Blood Pressure (mmHg), Systolic/Diastolic | VS.VSORRES with VSTESTCD "SYSBP" and "DIABP" | CRF | Numeric. The unit "mmHg" is printed in the column header. | 16 | Correct |
| 32 | Vital signs, "Information not obtained" | Suggestion: VS.VSSTAT = "NOT DONE" | CRF | n/a | 16 | Correct |
| 33 | (visit date for VS) | VS.VSDTC | CRF | ISO 8601 | 16 | Correct |
Swipe sideways to see every column.
All 32 mapping rows. The XLSX also has the 11 open questions and the define.xml check column.
Draft for review. Public data only.
The prompt
Draft an SDTM mapping spec from the CRF text below.
Table: CRF field | SDTM domain.variable | origin (CRF / Assigned / Derived) | controlled terminology |
derivation or comment | CRF page.
Use only the CRF text and the SDTM-IG. Do not trust annotation fragments you cannot read in full.
Invent no codelist values, visit numbers or domains. Mark anything from general SDTM knowledge "suggestion".
End with numbered open questions for the data manager, each tied to a CRF page.
CRF PAGES (text): [paste]Works in any chat assistant. Not tested in Microsoft 365 Copilot.
Sample input used here
CRF text, PDF pages 7, 8 and 16 (raw text layer)
[CRF PDF p. 7 (Visit 1, page 1 of 14)] H2Q-MC-LZZT STUDYID when PATIENT ANSDTUVDIYSIDIT= IDENTIFICATION "CDISCPIL OT01" Not Entered In Database Patient initials ______ ______ _____ First Middle Last --STDTC --DTC Visit date _____[S/_V_S_T_D_/T_C___[_AEDTC MM , DD YY , DSSTDTC] CMDTC INFORMED CONwShEenNT ,
CDISC SDTM/ADaM Pilot Project annotated blank CRF; the text layer is copyright Eli Lilly and Co. 2006. Short excerpts with attribution to CDISC.
How this was checked
Result
Generated by Claude on 2026-10-20 (cold run, no tools).
Demonstration only. Invented or synthetic input and no answer key. It shows the format, not a verified result.
Prompt shortened for this page. The output shown came from the earlier run of the longer prompt (2026-10-20).
The longer prompt that was checked
You are helping a clinical programmer draft an SDTM mapping specification from case report form (CRF) pages. Use ONLY the CRF text above plus your knowledge of the CDISC SDTM Implementation Guide. Produce a mapping table with these columns: CRF field (as printed) | SDTM domain.variable | Origin (CRF / Assigned / Derived) | Controlled terminology or format | Derivation or comment | CRF page. The text layer contains annotation fragments printed over the form; use them where legible, but do not trust a fragment you cannot read in full. Where the pages do not settle something (a variable, a codelist, a unit rule, which domain a field belongs in), do not guess: list it in a final section "Open questions for the data manager", numbered, each tied to a CRF page. Do not invent codelist values, visit numbers, or domains that the pages do not support. Mark anything you add from general SDTM knowledge as "suggestion".
A one-line prompt for comparison
Prompt: Write an SDTM mapping spec for the CRF of an Alzheimer's trial.
# SDTM Mapping Specification: Alzheimer's Disease Trial ## 1. Overview This specification maps the case report form (CRF) data of the Alzheimer's disease study to CDISC SDTM (SDTMIG v3.2). Source CRF data are captured in EDC and delivered as raw datasets. ## 2. Domains | Domain | Description | Source CRF | |---|---|---| | DM | Demographics | Demographics form | | AE | Adverse Events | Adverse Events form | | CM | Concomitant Medications | Con Med form | | EX | Exposure | Study Drug Administration form | | VS | Vital Signs | Vital Signs form | | LB | Laboratory Test Results | Central lab transfer | ...
33 statements checked: 16 right, 10 partly right, 4 wrong, 3 not in source.
Show all 33 checked statements
| Statement | Verdict | Source check |
|---|---|---|
| Good run: STUDYID is the literal CDISCPILOT01, taken from a legible annotation fragment; origin Assigned | Partly right correct | define.xml DM.STUDYID: Origin 'CRF Page 7'. Value CDISCPILOT01 is correct; the origin label differs (Assigned vs CRF page 7). |
| Good run: Open question 2: printed H2Q-MC-LZZT is the sponsor protocol number, so which is STUDYID | Right | Real gap. CRF p. 7 prints H2Q-MC-LZZT; define.xml uses CDISCPILOT01. The CRF alone does not say where the other value goes. |
| Good run: Patient initials are not mapped | Right | No initials variable in any define.xml domain. |
| Good run: Visit date maps to SV.SVSTDTC (marked partial) | Partly right correct | define.xml SV.SVSTDTC is Origin 'Derived' (earliest date data were collected for the visit), not a direct CRF field. DM.DMDTC, SC.SCDTC and VS.VSDTC take the CRF date. |
| Good run: AEDTC and CMDTC in the visit-date annotation list are not standard IG variables | Right | define.xml has AE.AESTDTC and CM.CMSTDTC (CRF pp. 121-123, 124-126) and no AEDTC or CMDTC. |
| Good run: VISITNUM is Assigned, value 1 | Partly right correct | define.xml VISITNUM codelist: 1 = 'SCREENING 1'. Value correct; define lists VISITNUM origin as CRF pages. |
| Good run: Consent date: candidates DS.DSSTDTC or DM.RFICDTC | Partly right correct | define.xml DM.RFICDTC is Origin 'Derived' with comment 'Date of informed consent was not entered in database'. DS.DSSTDTC comes from CRF pp. 106 and 139, not p. 7. So the date is not mapped from this page. |
| Good run: Date of birth maps to DM.BRTHDTC; AGE derived from it if DOB is in the database | Wrong | define.xml DM has no BRTHDTC. AGE is Derived 'at start of study drug (RFSTDTC)'. The hedge about 'Not Entered In Database' was right, the suggested variable was not used. |
| Good run: Sex maps to DM.SEX with codes F and M | Right | define.xml SEX codelist: F, M, U. Origin CRF page 7. |
| Good run: Race maps to DM.RACE; Hispanic may belong in ETHNIC; the 2-letter CRF codes are not copied | Right | define.xml DM.ETHNIC is Derived: 'HISPANIC OR LATINO' if Origin = Hispanic, otherwise 'NOT HISPANIC OR LATINO'. RACE codelist has four terms (WHITE, BLACK OR AFRICAN AMERICAN, AMERICAN INDIAN OR ALASKA NATIVE, ASIAN). The cold run proposed no term mapping, so it was not wrong, but it was not complete. |
| Good run: Years of education maps to SC.SCORRES, in years, SCTESTCD 'YEARSEDU' (from an annotation fragment) | Partly right correct | define.xml: SC domain, SCORRES and SCORRESU Origin 'CRF Page 8', SCUNIT codelist = YEARS. But the SCTESTCD value is EDLEVEL (label 'EDUCATION LEVEL'), SCCAT = EDUCATION is Assigned, and the cold run did not mention SCCAT. The CRF annotation and define.xml disagree on the test code; not resolved here. |
| Good run: Smoking and alcohol items go to an SU domain (suggestion); Q7 asks SU, MH or SC | Not in source | define.xml has no SU domain and no smoking, alcohol or caffeine variables. These CRF items appear not to have been tabulated. The question was reasonable; the suggested domain did not exist in this study. |
| Good run: Weight to VS.VSORRES with VSTESTCD WEIGHT; height to VS.VSORRES with HEIGHT | Right | define.xml VS.VSTESTCD value list: DIABP, HEIGHT, PULSE, SYSBP, TEMP, WEIGHT. VSORRES Origin CRF pages 16 onward. |
| Good run: VSORRESU uses the printed unit; suggestion to standardize to kg and cm; Q8 asks whether printed codes match controlled terms | Partly right correct | define.xml VSUNIT codelist: kg, cm, LB, IN, mmHg, BEATS/MIN, C, F. The case differences (lb vs LB, in vs IN) justify Q8. VSSTRESU is 'Assigned ... defined per parameter'; define.xml does not state a conversion rule, so the kg and cm suggestion is not confirmed. |
| Good run: Heart rate maps to VSTESTCD PULSE and BP to SYSBP and DIABP, one entry giving two records | Right | define.xml VS.VSTESTCD value list has PULSE, SYSBP and DIABP as separate tests. Units BEATS/MIN and mmHg are in VSUNIT. |
| Good run: Rows pair 815 with 5 minutes supine, 816 with 1 minute standing, 817 with 3 minutes standing | Right | define.xml VSTPTNUM: 815 = AFTER LYING DOWN FOR 5 MINUTES, 816 = AFTER STANDING FOR 1 MINUTE, 817 = AFTER STANDING FOR 3 MINUTES. VSPOS terms are STANDING and SUPINE. |
| Good run: Open question 9: the VSPOS and VSTPT terms are not on the page | Right | Real gap. The exact VSTPT wording and the spelled-out VSPOS terms are only in define.xml (codelists VSPOS, VSTPT). |
| Good run: 'Information not obtained' boxes map to VSSTAT = NOT DONE | Right | define.xml VS.VSSTAT, codelist ND = NOT DONE, Origin CRF pages. |
| Good run: VSDTC comes from the visit date | Right | define.xml VS.VSDTC Origin CRF pages 16 onward; the p. 7 annotation lists VSDTC against the visit date. |
| Good run: Open question 11: whether VISITNUM = 1 applies to p. 8 and p. 16, and what VISIT is | Right | Real gap. define.xml VISITNUM 1 = SCREENING 1; VISIT value 'SCREENING 1'. Neither is printed on the pages. |
| Good run: Open question 3: SUBJID, SITEID and USUBJID derivations are not legible | Right | Real gap. define.xml: SUBJID Origin CRF Page 7; SITEID Assigned; USUBJID Derived, 'Concatenation of STUDYID, DM.SITEID and DM.SUBJID'. See the unresolved length note in errors_found. |
| Good run: Open question 4: two-digit years need a century rule | Not in source | Neither the CRF pages nor define.xml states a rule. |
| One-line prompt run: Domain list DM, AE, CM, EX, VS, LB, MH, DS, QS, EG | Partly right correct | define.xml has DM, AE, CM, EX, VS, LB, MH, DS, QS plus SC, SV, SE and trial design domains. EG does not exist; SC and SV are missing from the bad list. |
| One-line prompt run: STUDYID is a protocol constant | Partly right correct | define.xml: Origin 'CRF Page 7', value CDISCPILOT01. |
| One-line prompt run: USUBJID = STUDYID + SITEID + SUBJID joined with '-' | Partly right correct | define.xml comment: concatenation of STUDYID, SITEID and SUBJID. The separator is not stated. |
| One-line prompt run: RFSTDTC and RFENDTC from the first and last exposure | Right | define.xml DM.RFSTDTC and RFENDTC: derived from EX. |
| One-line prompt run: BRTHDTC from date of birth; AGE from BRTHDTC | Wrong | define.xml DM has no BRTHDTC; AGE is derived at RFSTDTC. |
| One-line prompt run: ARM and ARMCD map to Placebo or Xanomeline, PBO or XAN | Wrong | define.xml ARMCD: Scrnfail, Pbo, Xan_Lo, Xan_Hi; ARM: Screen Failure, Placebo, Xanomeline Low Dose, Xanomeline High Dose. |
| One-line prompt run: COUNTRY from the site country, ISO 3166 alpha-3 | Right | define.xml DM.COUNTRY: Derived from site information; codelist USA. |
| One-line prompt run: AEDECOD and AEBODSYS from MedDRA | Right | define.xml AEDICT: MEDDRA version 8.0. The CRF p. 122 text mentions a COSTART class term, which the bad run could not have known. |
| One-line prompt run: QS holds ADAS-Cog, CIBIC+, MMSE, ADCS-ADL | Partly right correct | define.xml QSCAT includes Alzheimer's Disease Assessment Scale, CIBIC+, Mini-Mental State, DAD, NPI-X and Modified Hachinski. ADCS-ADL is not among them (the study used DAD). |
| One-line prompt run: Baseline flag is the last non-missing value before first dose | Wrong | define.xml VS.VSBLFL: 'If VISIT = BASELINE then VSBLFL = Y' (a visit rule, not a pre-dose rule). |
| One-line prompt run: No open questions; SC, SV, vital-sign terms and units are not addressed | Not in source | The bad output has no SC or SV domain, no controlled terms or units for VS, and no list of what it did not know. Nothing flags that the DOB and consent date are not in the database. |
All 5 checks
- Treat the open questions as the data manager's agenda. Most real gaps (VISIT labels, USUBJID rule, VSPOS terms) are answered only in the define file.
- Run a few dummy records through your mapping code before you rely on the spec; nothing was executed here.
Sources
- CDISC SDTM/ADaM Pilot Project (annotated blank CRF, define.xml) (CDISC; attribution required, unmodified, no sale)
Scripts
Related workflows
All workflows. How we check. Public data only. Drafts for review, not validated output.
Get one workflow a week
Unsubscribe anytime. Privacy.