{
  "schema": "poieti.his-mapping/1",
  "id": "demo-hospital",
  "version": 1,
  "description": "Synthetic demonstration mapping for the demo-hospital institution. The NUR_ADM form, its column codes and option codes are invented for tests and demos; they belong to no real hospital.",
  "feature": {
    "id": "nursing-admission",
    "templateVersion": 1
  },
  "target": {
    "form": "NUR_ADM",
    "formVersion": "2026.1",
    "timezone": "Asia/Taipei",
    "charset": "cp950"
  },
  "observedAt": {
    "date": "admission.wardDate",
    "time": "admission.wardTime"
  },
  "codeTables": {
    "NONE_YES": {
      "none": "N",
      "yes": "Y"
    },
    "NONE_UNKNOWN_YES": {
      "none": "N",
      "unknown": "U",
      "yes": "Y"
    },
    "NONE_YES_UNCERTAIN": {
      "none": "N",
      "yes": "Y",
      "uncertain": "U"
    },
    "YES_NO": {
      "yes": "Y",
      "no": "N"
    },
    "POS_NEG": {
      "positive": "P",
      "negative": "N"
    },
    "MARITAL": {
      "single": "1",
      "married": "2",
      "divorced": "3",
      "separated": "4",
      "cohabiting": "5",
      "widowed": "6"
    },
    "DENTURE": {
      "fixed": "F",
      "removable": "R"
    },
    "DIET_DETAIL": {
      "soft": "S",
      "liquid": "L",
      "diabetic": "DM",
      "low_fat": "LF",
      "low_salt": "LS"
    },
    "VISION": {
      "clear": "00",
      "blind": "01",
      "presbyopia": "02",
      "myopia": "03",
      "diplopia": "04",
      "amblyopia": "05",
      "hemianopia": "06",
      "cataract": "07",
      "glaucoma": "08",
      "other": "99"
    },
    "HEARING": {
      "clear": "00",
      "hard_of_hearing": "01",
      "deaf": "02",
      "tinnitus": "03",
      "hearing_aid": "04",
      "cochlear_implant": "05",
      "other": "99"
    }
  },
  "fields": [
    {
      "source": "basic.education",
      "encode": "code",
      "target": "EDU",
      "codes": {
        "illiterate": "0",
        "elementary": "1",
        "junior_high": "2",
        "senior_high": "3",
        "college": "4",
        "university_or_above": "5"
      },
      "required": true
    },
    {
      "source": "basic.languages",
      "encode": "joined",
      "target": "LANG",
      "separator": ",",
      "codes": {
        "mandarin": "zh",
        "taiwanese_hokkien": "tw",
        "hakka": "hak",
        "amis": "ami",
        "atayal": "tay",
        "rukai": "dru",
        "yami": "tao",
        "english": "en",
        "indonesian": "id",
        "japanese": "ja",
        "thai": "th",
        "filipino": "fil",
        "other": "oth"
      }
    },
    {
      "source": "basic.religions",
      "encode": "joined",
      "target": "RELIGION",
      "separator": ",",
      "codes": {
        "none": "00",
        "other": "99",
        "buddhism": "01",
        "taoism": "02",
        "christianity": "03",
        "catholicism": "04",
        "islam": "05"
      }
    },
    {
      "source": "alerts.antithromboticUse",
      "encode": "code",
      "target": "ALG_ANTITHROMBOTIC_USE",
      "codeTable": "NONE_YES_UNCERTAIN"
    },
    {
      "source": "alerts.drugAllergy",
      "encode": "code",
      "target": "DRUG_ALG",
      "codeTable": "NONE_UNKNOWN_YES",
      "required": true
    },
    {
      "source": "alerts.drugAllergyNote",
      "encode": "text",
      "target": "DRUG_ALG_NOTE",
      "maxBytes": 2000
    },
    {
      "source": "alerts.drugAllergens",
      "encode": "joined",
      "target": "DRUG_ALG_ITEMS",
      "separator": ",",
      "codes": {
        "other": "99",
        "contrast_media": "01",
        "blood_transfusion": "02",
        "nsaid": "03",
        "sulfonamides": "04",
        "penicillin": "05",
        "g6pd": "06"
      }
    },
    {
      "source": "alerts.otherDrugAllergen",
      "encode": "text",
      "target": "DRUG_ALG_OTHER",
      "maxBytes": 1000
    },
    {
      "source": "alerts.foodAllergy",
      "encode": "code",
      "target": "FOOD_ALG",
      "codeTable": "NONE_UNKNOWN_YES",
      "required": true
    },
    {
      "source": "alerts.foodAllergens",
      "encode": "joined",
      "target": "FOOD_ALG_ITEMS",
      "separator": ",",
      "codes": {
        "other": "99",
        "seafood": "01",
        "mushroom": "02",
        "beef": "03"
      }
    },
    {
      "source": "alerts.transfusionReaction",
      "encode": "code",
      "target": "ALG_TRANSFUSION_REACTION",
      "codeTable": "NONE_UNKNOWN_YES"
    },
    {
      "source": "alerts.bloodType",
      "encode": "code",
      "target": "BLOOD_TYPE",
      "codes": {
        "o_positive": "O+",
        "a_positive": "A+",
        "b_positive": "B+",
        "ab_positive": "AB+",
        "o_negative": "O-",
        "a_negative": "A-",
        "b_negative": "B-",
        "ab_negative": "AB-",
        "unknown": "UNK"
      },
      "required": true
    },
    {
      "source": "alerts.recentForeignTravel",
      "encode": "code",
      "target": "ALG_RECENT_FOREIGN_TRAVEL",
      "codeTable": "NONE_YES"
    },
    {
      "source": "alerts.travelLocation",
      "encode": "text",
      "target": "ALG_TRAVEL_LOCATION",
      "maxBytes": 1000
    },
    {
      "source": "alerts.treatmentRestrictions",
      "encode": "flags",
      "flags": {
        "none": "RESTRICT_NONE",
        "left_hand": "RESTRICT_LH",
        "right_hand": "RESTRICT_RH",
        "left_foot": "RESTRICT_LF",
        "right_foot": "RESTRICT_RF",
        "other": "RESTRICT_OTHER"
      },
      "true": "Y",
      "false": "N"
    },
    {
      "source": "alerts.tubes",
      "encode": "flags",
      "flags": {
        "none": "TUBE_NONE",
        "ng": "TUBE_NG",
        "foley": "TUBE_FOLEY",
        "tracheostomy": "TUBE_TRACH",
        "pigtail": "TUBE_PIGTAIL",
        "port_a": "TUBE_PORTA",
        "av_shunt": "TUBE_AVS",
        "other": "TUBE_OTHER"
      },
      "true": "Y",
      "false": "N"
    },
    {
      "source": "alerts.rapidTestDate",
      "encode": "partial-date",
      "target": "RAPID_DATE",
      "partial": "text"
    },
    {
      "source": "alerts.rapidTestResult",
      "encode": "code",
      "target": "ALG_RAPID_TEST_RESULT",
      "codeTable": "POS_NEG"
    },
    {
      "source": "alerts.pcrDate",
      "encode": "partial-date",
      "targets": {
        "year": "PCR_Y",
        "month": "PCR_M",
        "day": "PCR_D"
      },
      "partial": "split"
    },
    {
      "source": "alerts.pcrResult",
      "encode": "code",
      "target": "ALG_PCR_RESULT",
      "codeTable": "POS_NEG"
    },
    {
      "source": "alerts.pcrCtValue",
      "encode": "number",
      "target": "PCR_CT",
      "decimals": 1
    },
    {
      "source": "health.familyHistoryStatus",
      "encode": "code",
      "target": "HLT_FAMILY_HISTORY_STATUS",
      "codeTable": "NONE_YES_UNCERTAIN"
    },
    {
      "source": "health.familyHistory",
      "encode": "rows",
      "target": "FAM_HX",
      "maxRows": 10,
      "rowFields": [
        {
          "source": "relation",
          "encode": "code",
          "target": "REL",
          "codes": {
            "father": "F",
            "mother": "M",
            "son": "S",
            "daughter": "D",
            "paternal_grandfather": "PGF",
            "paternal_grandmother": "PGM",
            "other": "O"
          }
        },
        {
          "source": "diseases",
          "encode": "joined",
          "target": "DZ",
          "separator": ",",
          "codes": {
            "other": "99",
            "hypertension": "01",
            "heart_disease": "02",
            "diabetes": "03",
            "liver_cancer": "04",
            "colorectal_cancer": "05",
            "asthma": "06",
            "blood_disease": "07",
            "cancer": "08",
            "cerebrovascular_disease": "09",
            "mental_illness": "10"
          }
        }
      ]
    },
    {
      "source": "health.maritalStatus",
      "encode": "code",
      "target": "HLT_MARITAL_STATUS",
      "codeTable": "MARITAL"
    },
    {
      "source": "health.livingStatus",
      "encode": "code",
      "target": "HLT_LIVING_STATUS",
      "codes": {
        "other": "99",
        "spouse_only": "01",
        "with_family": "02",
        "alone_family_support": "03",
        "alone_friend_support": "04",
        "alone_independent": "05",
        "alone_dependent": "06",
        "care_facility": "07"
      }
    },
    {
      "source": "health.familyInteraction",
      "encode": "code",
      "target": "HLT_FAMILY_INTERACTION",
      "codes": {
        "other": "99",
        "caring": "01",
        "distant": "02",
        "no_contact": "03"
      }
    },
    {
      "source": "health.otherFamilyInteraction",
      "encode": "text",
      "target": "HLT_OTHER_FAMILY_INTERACTION",
      "maxBytes": 1000
    },
    {
      "source": "health.primaryCaregivers",
      "encode": "joined",
      "target": "HLT_PRIMARY_CAREGIVERS",
      "separator": ",",
      "codes": {
        "none": "00",
        "other": "99",
        "spouse": "01",
        "parents": "02",
        "children": "03",
        "friends": "04",
        "caregiver": "05",
        "foreign_caregiver": "06"
      }
    },
    {
      "source": "health.otherPrimaryCaregiver",
      "encode": "text",
      "target": "HLT_OTHER_PRIMARY_CAREGIVER",
      "maxBytes": 1000
    },
    {
      "source": "health.occupation",
      "encode": "code",
      "target": "HLT_OCCUPATION",
      "codes": {
        "none": "00",
        "other": "99",
        "military": "01",
        "civil_service": "02",
        "education": "03",
        "industrial": "04",
        "commerce": "05",
        "agriculture": "06",
        "student": "07",
        "healthcare": "08",
        "service": "09"
      }
    },
    {
      "source": "health.otherOccupation",
      "encode": "text",
      "target": "HLT_OTHER_OCCUPATION",
      "maxBytes": 1000
    },
    {
      "source": "health.financialStatus",
      "encode": "code",
      "target": "HLT_FINANCIAL_STATUS",
      "codes": {
        "affluent": "01",
        "comfortable": "02",
        "barely_sustaining": "03",
        "low_income": "04"
      }
    },
    {
      "source": "health.smokingStatus",
      "encode": "code",
      "target": "HLT_SMOKING_STATUS",
      "codes": {
        "none": "00",
        "current": "01",
        "quitting_under_six_months": "02",
        "quit_six_months_or_more": "03"
      }
    },
    {
      "source": "health.smokingAmount",
      "encode": "number",
      "target": "HLT_SMOKING_AMOUNT",
      "decimals": 1
    },
    {
      "source": "health.smokingAmountUnit",
      "encode": "code",
      "target": "HLT_SMOKING_AMOUNT_UNIT",
      "codes": {
        "packs_per_day": "01",
        "cigarettes_per_day": "02"
      }
    },
    {
      "source": "health.smokingYears",
      "encode": "number",
      "target": "HLT_SMOKING_YEARS",
      "decimals": 1
    },
    {
      "source": "health.quitSmokingExperience",
      "encode": "code",
      "target": "HLT_QUIT_SMOKING_EXPERIENCE",
      "codeTable": "NONE_YES"
    },
    {
      "source": "health.quitSmokingWillingness",
      "encode": "code",
      "target": "HLT_QUIT_SMOKING_WILLINGNESS",
      "codeTable": "YES_NO"
    },
    {
      "source": "health.alcoholUse",
      "encode": "code",
      "target": "HLT_ALCOHOL_USE",
      "codes": {
        "none": "00",
        "quit": "01",
        "occasional": "02",
        "frequent": "03",
        "daily": "04"
      }
    },
    {
      "source": "health.betelNutStatus",
      "encode": "code",
      "target": "HLT_BETEL_NUT_STATUS",
      "codes": {
        "none": "00",
        "quit": "01",
        "current": "02"
      }
    },
    {
      "source": "health.betelNutAmount",
      "encode": "number",
      "target": "HLT_BETEL_NUT_AMOUNT",
      "decimals": 1
    },
    {
      "source": "health.betelNutYears",
      "encode": "number",
      "target": "HLT_BETEL_NUT_YEARS",
      "decimals": 1
    },
    {
      "source": "health.medicalHistory",
      "encode": "joined",
      "target": "HLT_MEDICAL_HISTORY",
      "separator": ",",
      "codes": {
        "none": "00",
        "other": "99",
        "breast_cancer": "01",
        "blood_disease": "02",
        "mental_illness": "03",
        "hypertension": "04",
        "liver_cancer": "05",
        "cancer": "06",
        "heart_disease": "07",
        "colorectal_cancer": "08",
        "suicide": "09",
        "diabetes": "10",
        "asthma": "11",
        "cerebrovascular_disease": "12"
      }
    },
    {
      "source": "health.surgeryExperience",
      "encode": "code",
      "target": "HLT_SURGERY_EXPERIENCE",
      "codeTable": "NONE_YES"
    },
    {
      "source": "health.surgeryNote",
      "encode": "text",
      "target": "HLT_SURGERY_NOTE",
      "maxBytes": 1000
    },
    {
      "source": "health.recentEmergencyOrAdmissionCount",
      "encode": "code",
      "target": "HLT_RECENT_EMERGENCY_OR_ADMISSION_COUNT",
      "codes": {
        "none": "00",
        "one": "01",
        "two": "02",
        "more_than_two": "03"
      }
    },
    {
      "source": "health.currentMedications",
      "encode": "joined",
      "target": "HLT_CURRENT_MEDICATIONS",
      "separator": ",",
      "codes": {
        "none": "00",
        "other": "99",
        "antidepressant_or_antipsychotic": "01",
        "cardiac": "02",
        "laxative_or_stool_softener": "03",
        "antihypertensive": "04",
        "antiepileptic": "05",
        "anticoagulant": "06",
        "anesthetic_analgesic": "07",
        "glucose_lowering": "08",
        "anti_parkinson": "09",
        "erythropoietin": "10",
        "muscle_relaxant": "11",
        "diuretic": "12",
        "oral_anticancer": "13",
        "sedative_hypnotic": "14"
      }
    },
    {
      "source": "nutrition.heightCm",
      "encode": "number",
      "target": "HT_MM",
      "decimals": 0,
      "scale": 10
    },
    {
      "source": "nutrition.weightKg",
      "encode": "number",
      "target": "WT_KG",
      "decimals": 2
    },
    {
      "source": "nutrition.measurementUnavailableReason",
      "encode": "text",
      "target": "NUT_MEASUREMENT_UNAVAILABLE_REASON",
      "maxBytes": 1000
    },
    {
      "source": "nutrition.edemaStatus",
      "encode": "code",
      "target": "NUT_EDEMA_STATUS",
      "codes": {
        "none": "00",
        "present": "01"
      }
    },
    {
      "source": "nutrition.edemaFindings",
      "encode": "rows",
      "target": "EDEMA",
      "maxRows": 8,
      "rowFields": [
        {
          "source": "site",
          "encode": "code",
          "target": "SITE",
          "codes": {
            "left_upper_limb": "01",
            "right_upper_limb": "02",
            "left_lower_limb": "03",
            "right_lower_limb": "04",
            "both_upper_limbs": "05",
            "both_lower_limbs": "06",
            "all_limbs": "07"
          }
        },
        {
          "source": "severity",
          "encode": "code",
          "target": "GRADE",
          "codes": {
            "grade_1": "1+",
            "grade_2": "2+",
            "grade_3": "3+",
            "grade_4": "4+"
          }
        }
      ]
    },
    {
      "source": "nutrition.feedingRoutes",
      "encode": "joined",
      "target": "NUT_FEEDING_ROUTES",
      "separator": ",",
      "codes": {
        "other": "99",
        "oral": "01",
        "ng_feeding": "02",
        "gastrostomy": "03",
        "enterostomy": "04",
        "tpn_ppn": "05"
      }
    },
    {
      "source": "nutrition.feedingStatus",
      "encode": "joined",
      "target": "NUT_FEEDING_STATUS",
      "separator": ",",
      "codes": {
        "normal": "00",
        "other": "99",
        "decreased_appetite": "01",
        "dysphagia": "02",
        "chewing_difficulty": "03",
        "npo": "04"
      }
    },
    {
      "source": "nutrition.oralConditions",
      "encode": "joined",
      "target": "NUT_ORAL_CONDITIONS",
      "separator": ",",
      "codes": {
        "normal": "00",
        "other": "99",
        "mucosal_damage": "01",
        "oral_odor": "02"
      }
    },
    {
      "source": "nutrition.dentures",
      "encode": "joined",
      "target": "NUT_DENTURES",
      "separator": ",",
      "codes": {
        "none": "00",
        "upper": "01",
        "lower": "02"
      }
    },
    {
      "source": "nutrition.upperDentureType",
      "encode": "code",
      "target": "NUT_UPPER_DENTURE_TYPE",
      "codeTable": "DENTURE"
    },
    {
      "source": "nutrition.lowerDentureType",
      "encode": "code",
      "target": "NUT_LOWER_DENTURE_TYPE",
      "codeTable": "DENTURE"
    },
    {
      "source": "nutrition.dietTypes",
      "encode": "joined",
      "target": "NUT_DIET_TYPES",
      "separator": ",",
      "codes": {
        "other": "99",
        "regular": "01",
        "tube_feeding": "02",
        "vegetarian": "03",
        "special": "04"
      }
    },
    {
      "source": "nutrition.vegetarianDietDetails",
      "encode": "joined",
      "target": "NUT_VEGETARIAN_DIET_DETAILS",
      "separator": ",",
      "codeTable": "DIET_DETAIL"
    },
    {
      "source": "nutrition.specialDietDetails",
      "encode": "joined",
      "target": "NUT_SPECIAL_DIET_DETAILS",
      "separator": ",",
      "codeTable": "DIET_DETAIL"
    },
    {
      "source": "nutrition.otherDiet",
      "encode": "text",
      "target": "NUT_OTHER_DIET",
      "maxBytes": 1000
    },
    {
      "source": "nutrition.foodRestriction",
      "encode": "code",
      "target": "NUT_FOOD_RESTRICTION",
      "codeTable": "NONE_YES"
    },
    {
      "source": "nutrition.foodRestrictionNote",
      "encode": "text",
      "target": "NUT_FOOD_RESTRICTION_NOTE",
      "maxBytes": 1000
    },
    {
      "source": "nutrition.otherSymptoms",
      "encode": "joined",
      "target": "NUT_OTHER_SYMPTOMS",
      "separator": ",",
      "codes": {
        "none": "00",
        "nausea": "01",
        "vomiting": "02",
        "hiccups": "03",
        "bloating": "04"
      }
    },
    {
      "source": "sleep.conditions",
      "encode": "joined",
      "target": "SLP_CONDITIONS",
      "separator": ",",
      "codes": {
        "normal": "00",
        "other": "99",
        "day_night_reversal": "01",
        "insomnia": "02",
        "fatigue": "03"
      }
    },
    {
      "source": "sleep.usualHours",
      "encode": "number",
      "target": "SLP_USUAL_HOURS",
      "decimals": 1
    },
    {
      "source": "activity.mobility",
      "encode": "code",
      "target": "ACT_MOBILITY",
      "codes": {
        "unable_to_walk": "01",
        "walks_with_person_assistance": "02",
        "independent": "03"
      }
    },
    {
      "source": "activity.needsMobilityAid",
      "encode": "boolean",
      "target": "MOB_AID",
      "true": "Y",
      "false": "N"
    },
    {
      "source": "activity.mobilityAids",
      "encode": "joined",
      "target": "ACT_MOBILITY_AIDS",
      "separator": ",",
      "codes": {
        "other": "99",
        "cane": "01",
        "walker": "02",
        "wheelchair": "03",
        "prosthesis": "04",
        "mobile_commode": "05",
        "mobile_iv_stand": "06"
      }
    },
    {
      "source": "activity.otherMobilityAid",
      "encode": "text",
      "target": "ACT_OTHER_MOBILITY_AID",
      "maxBytes": 1000
    },
    {
      "source": "activity.leftUpperMuscleStrength",
      "encode": "integer",
      "target": "MS_LU"
    },
    {
      "source": "activity.rightUpperMuscleStrength",
      "encode": "integer",
      "target": "MS_RU"
    },
    {
      "source": "activity.leftLowerMuscleStrength",
      "encode": "integer",
      "target": "MS_LL"
    },
    {
      "source": "activity.rightLowerMuscleStrength",
      "encode": "integer",
      "target": "MS_RL"
    },
    {
      "source": "activity.limbAppearance",
      "encode": "code",
      "target": "ACT_LIMB_APPEARANCE",
      "codes": {
        "normal": "00",
        "abnormal": "01"
      }
    },
    {
      "source": "activity.gait",
      "encode": "code",
      "target": "ACT_GAIT",
      "codes": {
        "stable": "01",
        "unstable": "02"
      }
    },
    {
      "source": "activity.unstableGaitDetails",
      "encode": "joined",
      "target": "ACT_UNSTABLE_GAIT_DETAILS",
      "separator": ",",
      "codes": {
        "other": "99",
        "left_hemiplegia": "01",
        "right_hemiplegia": "02",
        "limp": "03",
        "unable_to_assess": "04"
      }
    },
    {
      "source": "activity.otherGait",
      "encode": "text",
      "target": "ACT_OTHER_GAIT",
      "maxBytes": 1000
    },
    {
      "source": "activity.selfCareAbility",
      "encode": "code",
      "target": "ACT_SELF_CARE_ABILITY",
      "codes": {
        "independent": "01",
        "needs_help": "02"
      }
    },
    {
      "source": "activity.selfCareAssistance",
      "encode": "joined",
      "target": "ACT_SELF_CARE_ASSISTANCE",
      "separator": ",",
      "codes": {
        "eating": "01",
        "dressing": "02",
        "bathing": "03",
        "toileting": "04",
        "transfer": "05",
        "medication": "06",
        "cooking": "07",
        "finances": "08",
        "shopping": "09",
        "going_out": "10"
      }
    },
    {
      "source": "activity.fallInPastYear",
      "encode": "code",
      "target": "ACT_FALL_IN_PAST_YEAR",
      "codes": {
        "yes": "01",
        "no": "02",
        "uncertain": "03"
      }
    },
    {
      "source": "respiratory.chestSymmetry",
      "encode": "code",
      "target": "RSP_CHEST_SYMMETRY",
      "codes": {
        "normal": "00",
        "abnormally_symmetric": "01"
      }
    },
    {
      "source": "respiratory.patterns",
      "encode": "joined",
      "target": "RSP_PATTERNS",
      "separator": ",",
      "codes": {
        "normal": "00",
        "labored": "01",
        "orthopnea": "02",
        "accessory_muscle_use": "03",
        "ventilator_use": "04"
      }
    },
    {
      "source": "respiratory.coughFrequency",
      "encode": "code",
      "target": "RSP_COUGH_FREQUENCY",
      "codes": {
        "none": "00",
        "occasional": "01",
        "frequent": "02"
      }
    },
    {
      "source": "respiratory.sputumClearance",
      "encode": "code",
      "target": "RSP_SPUTUM_CLEARANCE",
      "codes": {
        "normal": "00",
        "needs_assistance": "01",
        "suction": "02"
      }
    },
    {
      "source": "respiratory.sputumStatus",
      "encode": "code",
      "target": "RSP_SPUTUM_STATUS",
      "codeTable": "NONE_YES"
    },
    {
      "source": "respiratory.sputumColor",
      "encode": "code",
      "target": "RSP_SPUTUM_COLOR",
      "codes": {
        "yellow": "01",
        "white": "02",
        "red": "03",
        "rust": "04"
      }
    },
    {
      "source": "respiratory.sputumViscosity",
      "encode": "code",
      "target": "RSP_SPUTUM_VISCOSITY",
      "codes": {
        "thin": "01",
        "thick": "02"
      }
    },
    {
      "source": "respiratory.sputumAmount",
      "encode": "code",
      "target": "RSP_SPUTUM_AMOUNT",
      "codes": {
        "large": "01",
        "medium": "02",
        "small": "03"
      }
    },
    {
      "source": "respiratory.breathSounds",
      "encode": "joined",
      "target": "RSP_BREATH_SOUNDS",
      "separator": ",",
      "codes": {
        "normal": "00",
        "diminished": "01",
        "rhonchi": "02",
        "wheezing": "03",
        "stridor": "04"
      }
    },
    {
      "source": "respiratory.oxygenTherapies",
      "encode": "joined",
      "target": "RSP_OXYGEN_THERAPIES",
      "separator": ",",
      "codes": {
        "none": "00",
        "other": "99",
        "nasal_cannula": "01",
        "mask": "02",
        "ventilator": "03",
        "peep": "04",
        "fio2": "05",
        "tracheostomy": "06"
      }
    },
    {
      "source": "circulation.implantStatus",
      "encode": "code",
      "target": "CIR_IMPLANT_STATUS",
      "codeTable": "NONE_YES"
    },
    {
      "source": "circulation.implantTypes",
      "encode": "joined",
      "target": "CIR_IMPLANT_TYPES",
      "separator": ",",
      "codes": {
        "pacemaker": "01",
        "metal_valve": "02"
      }
    },
    {
      "source": "circulation.peripheralCirculation",
      "encode": "code",
      "target": "CIR_PERIPHERAL_CIRCULATION",
      "codes": {
        "other": "99",
        "warm": "01",
        "cold": "02"
      }
    },
    {
      "source": "circulation.symptoms",
      "encode": "joined",
      "target": "CIR_SYMPTOMS",
      "separator": ",",
      "codes": {
        "none": "00",
        "other": "99",
        "palpitations": "01",
        "clubbing": "02",
        "jugular_venous_distention": "03",
        "epigastric_burning": "04",
        "chest_tightness": "05",
        "dizziness": "06"
      }
    },
    {
      "source": "cognition.leftVision",
      "encode": "joined",
      "target": "COG_LEFT_VISION",
      "separator": ",",
      "codeTable": "VISION"
    },
    {
      "source": "cognition.rightVision",
      "encode": "joined",
      "target": "COG_RIGHT_VISION",
      "separator": ",",
      "codeTable": "VISION"
    },
    {
      "source": "cognition.leftHearing",
      "encode": "joined",
      "target": "COG_LEFT_HEARING",
      "separator": ",",
      "codeTable": "HEARING"
    },
    {
      "source": "cognition.rightHearing",
      "encode": "joined",
      "target": "COG_RIGHT_HEARING",
      "separator": ",",
      "codeTable": "HEARING"
    },
    {
      "source": "cognition.orientation",
      "encode": "code",
      "target": "COG_ORIENTATION",
      "codes": {
        "fully_oriented": "01",
        "sometimes_partially_disoriented": "02",
        "always_partially_disoriented": "03",
        "sometimes_fully_disoriented": "04",
        "always_fully_disoriented": "05",
        "coma": "06"
      }
    },
    {
      "source": "cognition.behaviors",
      "encode": "joined",
      "target": "COG_BEHAVIORS",
      "separator": ",",
      "codes": {
        "appropriate": "00",
        "other": "99",
        "wandering": "01",
        "restless": "02",
        "confused": "03"
      }
    },
    {
      "source": "cognition.painStatus",
      "encode": "code",
      "target": "COG_PAIN_STATUS",
      "codes": {
        "none": "00",
        "present": "01",
        "unable_to_assess": "02"
      }
    },
    {
      "source": "cognition.painFindings",
      "encode": "rows",
      "target": "PAIN",
      "maxRows": 10,
      "rowFields": [
        {
          "source": "site",
          "encode": "code",
          "target": "SITE",
          "codes": {
            "other": "99",
            "head": "01",
            "tooth": "02",
            "mouth": "03",
            "eye": "04",
            "ear": "05",
            "neck": "06",
            "back": "07",
            "chest": "08",
            "abdomen": "09",
            "waist": "10",
            "upper_limb": "11",
            "lower_limb": "12"
          }
        },
        {
          "source": "score",
          "encode": "integer",
          "target": "SCORE"
        },
        {
          "source": "otherSite",
          "encode": "text",
          "target": "SITE_OTHER",
          "maxBytes": 100
        }
      ]
    },
    {
      "source": "cognition.speech",
      "encode": "code",
      "target": "COG_SPEECH",
      "codes": {
        "normal": "00",
        "other": "99",
        "unclear_articulation": "01",
        "speech_disorder": "02",
        "aphasia": "03"
      }
    },
    {
      "source": "cognition.skinAppearance",
      "encode": "code",
      "target": "COG_SKIN_APPEARANCE",
      "codes": {
        "normal": "00",
        "other": "99",
        "abnormal": "01"
      }
    },
    {
      "source": "cognition.skinFindings",
      "encode": "rows",
      "target": "SKIN",
      "maxRows": 10,
      "rowFields": [
        {
          "source": "type",
          "encode": "code",
          "target": "TYPE",
          "codes": {
            "pallor": "01",
            "rash": "02",
            "blister": "03",
            "swelling": "04",
            "ulcer": "05",
            "jaundice": "06",
            "wound": "07",
            "peeling": "08",
            "cracking": "09"
          }
        },
        {
          "source": "sites",
          "encode": "joined",
          "target": "SITES",
          "separator": ",",
          "codes": {
            "other": "99",
            "face": "01",
            "eyelid": "02",
            "mouth": "03",
            "neck": "04",
            "back": "05",
            "chest": "06",
            "abdomen": "07",
            "waist": "08",
            "upper_limb": "09",
            "lower_limb": "10"
          }
        }
      ]
    },
    {
      "source": "elimination.stoolConditions",
      "encode": "joined",
      "target": "ELM_STOOL_CONDITIONS",
      "separator": ",",
      "codes": {
        "normal": "00",
        "other": "99",
        "incontinence": "01",
        "constipation": "02",
        "diarrhea": "03",
        "colostomy": "04"
      }
    },
    {
      "source": "elimination.stoolColor",
      "encode": "code",
      "target": "ELM_STOOL_COLOR",
      "codes": {
        "normal": "00",
        "other": "99",
        "bloody": "01",
        "black": "02",
        "clay": "03",
        "gray_white": "04"
      }
    },
    {
      "source": "elimination.urinationConditions",
      "encode": "joined",
      "target": "ELM_URINATION_CONDITIONS",
      "separator": ",",
      "codes": {
        "normal": "00",
        "other": "99",
        "incontinence": "01",
        "nocturia": "02",
        "frequency": "03",
        "difficulty": "04",
        "dysuria": "05",
        "oliguria": "06",
        "renal_stoma": "07",
        "bladder_stoma": "08",
        "indwelling_catheter": "09",
        "intermittent_catheter": "10"
      }
    },
    {
      "source": "elimination.urineColor",
      "encode": "code",
      "target": "ELM_URINE_COLOR",
      "codes": {
        "normal": "00",
        "other": "99",
        "tea": "01",
        "cloudy": "02",
        "bloody": "03"
      }
    },
    {
      "source": "elimination.otherSymptoms",
      "encode": "joined",
      "target": "ELM_OTHER_SYMPTOMS",
      "separator": ",",
      "codes": {
        "hematemesis": "01",
        "profuse_sweating": "02",
        "ascites": "03"
      }
    },
    {
      "source": "reproduction.maleGenitalAppearance",
      "encode": "joined",
      "target": "REP_MALE_GENITAL_APPEARANCE",
      "separator": ",",
      "codes": {
        "normal": "00",
        "other": "99",
        "abnormal_discharge": "01",
        "enlarged_prostate": "02"
      }
    },
    {
      "source": "contacts.decisionMakerName",
      "encode": "text",
      "target": "CON_DECISION_MAKER_NAME",
      "maxLength": 50
    },
    {
      "source": "contacts.decisionMakerPhone",
      "encode": "text",
      "target": "CON_DECISION_MAKER_PHONE",
      "maxBytes": 20
    },
    {
      "source": "contacts.decisionMakerRelation",
      "encode": "text",
      "target": "CON_DECISION_MAKER_RELATION",
      "maxLength": 20
    },
    {
      "source": "contacts.informationProviderName",
      "encode": "text",
      "target": "CON_INFORMATION_PROVIDER_NAME",
      "maxLength": 50
    },
    {
      "source": "contacts.informationProviderPhone",
      "encode": "text",
      "target": "CON_INFORMATION_PROVIDER_PHONE",
      "maxBytes": 20
    },
    {
      "source": "contacts.informationProviderRelation",
      "encode": "text",
      "target": "CON_INFORMATION_PROVIDER_RELATION",
      "maxLength": 20
    },
    {
      "source": "contacts.contactName",
      "encode": "text",
      "target": "CON_CONTACT_NAME",
      "maxLength": 50
    },
    {
      "source": "contacts.contactPhone",
      "encode": "text",
      "target": "CON_CONTACT_PHONE",
      "maxBytes": 20
    },
    {
      "source": "contacts.contactRelation",
      "encode": "text",
      "target": "CON_CONTACT_RELATION",
      "maxLength": 20
    },
    {
      "source": "admission.wardDate",
      "encode": "date",
      "target": "ADM_DATE",
      "format": "ROC",
      "required": true
    },
    {
      "source": "admission.wardTime",
      "encode": "time",
      "target": "ADM_TIME",
      "format": "HHmm",
      "required": true
    },
    {
      "source": "admission.reason",
      "encode": "text",
      "target": "ADM_REASON",
      "maxBytes": 4000,
      "required": true
    },
    {
      "source": "family.members",
      "encode": "rows",
      "target": "FAMILY",
      "maxRows": 20,
      "rowFields": [
        {
          "source": "role",
          "encode": "code",
          "target": "ROLE",
          "codes": {
            "other": "99",
            "self": "01",
            "spouse": "02",
            "father": "03",
            "mother": "04",
            "paternal_grandfather": "05",
            "paternal_grandmother": "06",
            "maternal_grandfather": "07",
            "maternal_grandmother": "08",
            "older_brother": "09",
            "older_sister": "10",
            "younger_brother": "11",
            "younger_sister": "12",
            "son": "13",
            "daughter_in_law": "14",
            "daughter": "15",
            "son_in_law": "16",
            "fetus": "17",
            "grandson": "18",
            "grandson_spouse": "19",
            "granddaughter": "20",
            "granddaughter_spouse": "21",
            "maternal_grandson": "22",
            "maternal_grandson_spouse": "23",
            "maternal_granddaughter": "24",
            "maternal_granddaughter_spouse": "25",
            "stepfather": "26",
            "stepmother": "27",
            "adoptive_father": "28",
            "adoptive_mother": "29",
            "adopted_son": "30",
            "adopted_daughter": "31"
          }
        },
        {
          "source": "otherRole",
          "encode": "text",
          "target": "ROLE_OTHER",
          "maxBytes": 100
        },
        {
          "source": "aliveStatus",
          "encode": "code",
          "target": "ALIVE",
          "codes": {
            "alive": "A",
            "deceased": "D"
          }
        },
        {
          "source": "isDecisionMaker",
          "encode": "code",
          "target": "DECIDER",
          "codeTable": "YES_NO"
        },
        {
          "source": "livesTogether",
          "encode": "code",
          "target": "COHABIT",
          "codeTable": "YES_NO"
        },
        {
          "source": "birthOrder",
          "encode": "integer",
          "target": "BIRTH_ORDER"
        },
        {
          "source": "age",
          "encode": "integer",
          "target": "AGE"
        },
        {
          "source": "sex",
          "encode": "code",
          "target": "SEX",
          "codes": {
            "male": "M",
            "female": "F",
            "unknown": "U"
          }
        },
        {
          "source": "multipleBirth",
          "encode": "code",
          "target": "MULTI_BIRTH",
          "codeTable": "YES_NO"
        },
        {
          "source": "maritalStatus",
          "encode": "code",
          "target": "MARITAL",
          "codeTable": "MARITAL"
        },
        {
          "source": "familyHistory",
          "encode": "joined",
          "target": "HX",
          "separator": ",",
          "codes": {
            "none": "00",
            "other": "99",
            "hypertension": "01",
            "heart_disease": "02",
            "diabetes": "03",
            "liver_cancer": "04",
            "colorectal_cancer": "05",
            "asthma": "06",
            "blood_disease": "07",
            "cancer": "08",
            "cerebrovascular_disease": "09",
            "mental_illness": "10"
          }
        },
        {
          "source": "otherMedicalHistory",
          "encode": "text",
          "target": "HX_OTHER",
          "maxBytes": 200
        }
      ]
    }
  ],
  "excluded": [
    {
      "source": "contacts.contactPhone2",
      "reason": "NUR_ADM keeps one telephone number per contact."
    },
    {
      "source": "family.members[].note",
      "reason": "NUR_ADM has no free-text column for family members."
    }
  ]
}
