lx-dtypes 0.1.1__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- lx_dtypes/__init__.py +0 -0
- lx_dtypes/conftest.py +245 -0
- lx_dtypes/data/README.md +49 -0
- lx_dtypes/data/citations/config.yaml +7 -0
- lx_dtypes/data/citations/data/sample_references.yaml +7342 -0
- lx_dtypes/data/citations/sample_references.bib +2018 -0
- lx_dtypes/data/information_source_data/config.yaml +7 -0
- lx_dtypes/data/information_source_data/data/unknown.yaml +3 -0
- lx_dtypes/data/logs/.gitignore +2 -0
- lx_dtypes/data/logs/scripts/.gitkeep +0 -0
- lx_dtypes/data/lx_utils/config.yaml +7 -0
- lx_dtypes/data/lx_utils/gender/config.yaml +4 -0
- lx_dtypes/data/lx_utils/gender/default.yaml +5 -0
- lx_dtypes/data/lx_utils/tag/config.yaml +5 -0
- lx_dtypes/data/lx_utils/tag/default.yaml +0 -0
- lx_dtypes/data/lx_utils/unit/config.yaml +9 -0
- lx_dtypes/data/lx_utils/unit/data/concentration.yaml +114 -0
- lx_dtypes/data/lx_utils/unit/data/data.yaml +16 -0
- lx_dtypes/data/lx_utils/unit/data/length.yaml +31 -0
- lx_dtypes/data/lx_utils/unit/data/misc.yaml +20 -0
- lx_dtypes/data/lx_utils/unit/data/rate.yaml +6 -0
- lx_dtypes/data/lx_utils/unit/data/time.yaml +48 -0
- lx_dtypes/data/lx_utils/unit/data/volume.yaml +35 -0
- lx_dtypes/data/lx_utils/unit/data/weight.yaml +38 -0
- lx_dtypes/data/lx_utils/unit_type/config.yaml +7 -0
- lx_dtypes/data/lx_utils/unit_type/data/default.yaml +2 -0
- lx_dtypes/data/sample_knowledge_base/config.yaml +12 -0
- lx_dtypes/data/star_upper_gi/config.yaml +17 -0
- lx_dtypes/data/star_upper_gi/main.yaml +28 -0
- lx_dtypes/data/star_upper_gi/star_u_gi_choices/erefs.yaml +64 -0
- lx_dtypes/data/star_upper_gi/star_u_gi_choices/forrest.yaml +18 -0
- lx_dtypes/data/star_upper_gi/star_u_gi_choices/free_text.yaml +4 -0
- lx_dtypes/data/star_upper_gi/star_u_gi_choices/imaging_modality.yaml +11 -0
- lx_dtypes/data/star_upper_gi/star_u_gi_choices/los_angeles.yaml +12 -0
- lx_dtypes/data/star_upper_gi/star_u_gi_choices/numeric.yaml +9 -0
- lx_dtypes/data/star_upper_gi/star_u_gi_choices/paris.yaml +16 -0
- lx_dtypes/data/star_upper_gi/star_u_gi_choices/prague.yaml +9 -0
- lx_dtypes/data/star_upper_gi/star_u_gi_choices/star_upper_gi_location.yaml +68 -0
- lx_dtypes/data/star_upper_gi/star_u_gi_choices/varices.yaml +34 -0
- lx_dtypes/data/star_upper_gi/star_u_gi_choices/yes_no_unknown.yaml +6 -0
- lx_dtypes/data/star_upper_gi/star_u_gi_choices/zargar.yaml +43 -0
- lx_dtypes/data/star_upper_gi/star_u_gi_classifications/data.yaml +88 -0
- lx_dtypes/data/star_upper_gi/star_u_gi_classifications/esophagus.yaml +105 -0
- lx_dtypes/data/star_upper_gi/star_u_gi_descriptors/data.yaml +15 -0
- lx_dtypes/data/star_upper_gi/star_u_gi_findings/abnormal.yaml +81 -0
- lx_dtypes/data/star_upper_gi/star_u_gi_findings/normal.yaml +57 -0
- lx_dtypes/data/star_upper_gi/star_u_gi_findings/types.yaml +17 -0
- lx_dtypes/data/star_upper_gi/star_u_gi_interventions/data.yaml +5 -0
- lx_dtypes/data/terminology/config.yaml +10 -0
- lx_dtypes/data/terminology/lx_classification_choices/config.yaml +8 -0
- lx_dtypes/data/terminology/lx_classification_choices/data/00_generic.yaml +16 -0
- lx_dtypes/data/terminology/lx_classification_choices/data/00_generic_baseline.yaml +17 -0
- lx_dtypes/data/terminology/lx_classification_choices/data/00_generic_complication.yaml +11 -0
- lx_dtypes/data/terminology/lx_classification_choices/data/00_generic_histology.yaml +31 -0
- lx_dtypes/data/terminology/lx_classification_choices/data/00_generic_lesion.yaml +143 -0
- lx_dtypes/data/terminology/lx_classification_choices/data/02_colonoscopy_bowel_preparation.yaml +41 -0
- lx_dtypes/data/terminology/lx_classification_choices/data/02_colonoscopy_generic.yaml +14 -0
- lx_dtypes/data/terminology/lx_classification_choices/data/02_colonoscopy_histology.yaml +19 -0
- lx_dtypes/data/terminology/lx_classification_choices/data/02_colonoscopy_location.yaml +231 -0
- lx_dtypes/data/terminology/lx_classification_choices/data/02_colonoscopy_other.yaml +34 -0
- lx_dtypes/data/terminology/lx_classification_choices/data/02_colonoscopy_polyp_advanced_imaging.yaml +76 -0
- lx_dtypes/data/terminology/lx_classification_choices/data/02_colonoscopy_polyp_morphology.yaml +75 -0
- lx_dtypes/data/terminology/lx_classification_choices/data/02_colonoscopy_size.yaml +27 -0
- lx_dtypes/data/terminology/lx_classifications/classification_types/default.yaml +29 -0
- lx_dtypes/data/terminology/lx_classifications/config.yaml +10 -0
- lx_dtypes/data/terminology/lx_classifications/data/00_generic.yaml +46 -0
- lx_dtypes/data/terminology/lx_classifications/data/00_generic_histology.yaml +25 -0
- lx_dtypes/data/terminology/lx_classifications/data/00_generic_lesion.yaml +47 -0
- lx_dtypes/data/terminology/lx_classifications/data/02_colonoscopy_baseline.yaml +78 -0
- lx_dtypes/data/terminology/lx_classifications/data/02_colonoscopy_histology.yaml +15 -0
- lx_dtypes/data/terminology/lx_classifications/data/02_colonoscopy_other.yaml +11 -0
- lx_dtypes/data/terminology/lx_classifications/data/02_colonoscopy_polyp.yaml +95 -0
- lx_dtypes/data/terminology/lx_descriptors/config.yaml +9 -0
- lx_dtypes/data/terminology/lx_descriptors/data/.gitkeep +0 -0
- lx_dtypes/data/terminology/lx_descriptors/data/time.yaml +5 -0
- lx_dtypes/data/terminology/lx_examinations/config.yaml +12 -0
- lx_dtypes/data/terminology/lx_examinations/data/colonoscopy.yaml +50 -0
- lx_dtypes/data/terminology/lx_examinations/data/examination_types.yaml +3 -0
- lx_dtypes/data/terminology/lx_findings/config.yaml +11 -0
- lx_dtypes/data/terminology/lx_findings/data/00_generic.yaml +28 -0
- lx_dtypes/data/terminology/lx_findings/data/00_generic_complication.yaml +8 -0
- lx_dtypes/data/terminology/lx_findings/data/01_gastroscopy_baseline.yaml +80 -0
- lx_dtypes/data/terminology/lx_findings/data/01_gastroscopy_observation.yaml +98 -0
- lx_dtypes/data/terminology/lx_findings/data/02_colonoscopy_baseline.yaml +57 -0
- lx_dtypes/data/terminology/lx_findings/data/02_colonoscopy_hidden.yaml +107 -0
- lx_dtypes/data/terminology/lx_findings/data/02_colonoscopy_observation.yaml +141 -0
- lx_dtypes/data/terminology/lx_findings/finding_types/default.yaml +23 -0
- lx_dtypes/data/terminology/lx_findings/former_events/cardiology.yaml +14 -0
- lx_dtypes/data/terminology/lx_findings/former_events/neurology.yaml +9 -0
- lx_dtypes/data/terminology/lx_findings/former_events/surgery.yaml +11 -0
- lx_dtypes/data/terminology/lx_findings/former_events/thrombembolism.yaml +17 -0
- lx_dtypes/data/terminology/lx_hardware/README.md +1 -0
- lx_dtypes/data/terminology/lx_hardware/config.yaml +8 -0
- lx_dtypes/data/terminology/lx_hardware/data/01_choices_endoscopy_processor.yaml +14 -0
- lx_dtypes/data/terminology/lx_hardware/data/02_classifications_endoscopy_processor.yaml +9 -0
- lx_dtypes/data/terminology/lx_hardware/data/03_finding_endoscopy_hardware.yaml +5 -0
- lx_dtypes/data/terminology/lx_indications/config.yaml +11 -0
- lx_dtypes/data/terminology/lx_indications/data/colonoscopy_indications.yaml +94 -0
- lx_dtypes/data/terminology/lx_indications/indication_types/default.yaml +3 -0
- lx_dtypes/data/terminology/lx_interventions/config.yaml +8 -0
- lx_dtypes/data/terminology/lx_interventions/data/00_generic_endoscopy.yaml +51 -0
- lx_dtypes/data/terminology/lx_interventions/data/00_generic_endoscopy_ablation.yaml +37 -0
- lx_dtypes/data/terminology/lx_interventions/data/00_generic_endoscopy_bleeding.yaml +49 -0
- lx_dtypes/data/terminology/lx_interventions/data/00_generic_endoscopy_resection.yaml +80 -0
- lx_dtypes/data/terminology/lx_interventions/data/00_generic_endoscopy_stenosis.yaml +15 -0
- lx_dtypes/data/terminology/lx_interventions/data/00_generic_endoscopy_stent.yaml +8 -0
- lx_dtypes/data/terminology/lx_interventions/data/01_gastroscopy.yaml +14 -0
- lx_dtypes/data/terminology/lx_interventions/data/04_eus.yaml +29 -0
- lx_dtypes/data/terminology/lx_interventions/data/05_ercp.yaml +2 -0
- lx_dtypes/data/terminology/lx_interventions/intervention_types/default.yaml +17 -0
- lx_dtypes/data/terminology/lx_units/config.yaml +7 -0
- lx_dtypes/data/terminology/lx_units/data/concentration.yaml +114 -0
- lx_dtypes/data/terminology/lx_units/data/data.yaml +16 -0
- lx_dtypes/data/terminology/lx_units/data/length.yaml +31 -0
- lx_dtypes/data/terminology/lx_units/data/misc.yaml +20 -0
- lx_dtypes/data/terminology/lx_units/data/rate.yaml +6 -0
- lx_dtypes/data/terminology/lx_units/data/time.yaml +48 -0
- lx_dtypes/data/terminology/lx_units/data/volume.yaml +35 -0
- lx_dtypes/data/terminology/lx_units/data/weight.yaml +38 -0
- lx_dtypes/django/__init__.py +0 -0
- lx_dtypes/django/api/__init__.py +3 -0
- lx_dtypes/django/api/main.py +18 -0
- lx_dtypes/django/api/request_types.py +5 -0
- lx_dtypes/django/api/stubs.py +9 -0
- lx_dtypes/django/apps.py +7 -0
- lx_dtypes/django/asgi.py +16 -0
- lx_dtypes/django/migrations/0001_initial.py +1158 -0
- lx_dtypes/django/migrations/__init__.py +0 -0
- lx_dtypes/django/models.py +4 -0
- lx_dtypes/django/urls.py +26 -0
- lx_dtypes/django/wsgi.py +16 -0
- lx_dtypes/django_settings.py +124 -0
- lx_dtypes/factories/__init__.py +13 -0
- lx_dtypes/factories/literals.py +11 -0
- lx_dtypes/factories/models.py +11 -0
- lx_dtypes/factories/typed_dicts.py +29 -0
- lx_dtypes/factories/typed_lists.py +12 -0
- lx_dtypes/factories/uuid.py +23 -0
- lx_dtypes/models/__init__.py +89 -0
- lx_dtypes/models/base/__init__.py +12 -0
- lx_dtypes/models/base/app_base_model/__init__.py +20 -0
- lx_dtypes/models/base/app_base_model/ddict/AppBaseModelDataDict.py +10 -0
- lx_dtypes/models/base/app_base_model/ddict/AppBaseModelNamesUUIDTagsDataDict.py +20 -0
- lx_dtypes/models/base/app_base_model/ddict/AppBaseModelUUIDTagsDataDict.py +19 -0
- lx_dtypes/models/base/app_base_model/ddict/KnowledgebaseBaseModelDataDict.py +13 -0
- lx_dtypes/models/base/app_base_model/ddict/LedgerBaseModelDataDict.py +9 -0
- lx_dtypes/models/base/app_base_model/ddict/PersonDataDict.py +17 -0
- lx_dtypes/models/base/app_base_model/ddict/__init__.py +38 -0
- lx_dtypes/models/base/app_base_model/django/AppBaseModelDjango.py +58 -0
- lx_dtypes/models/base/app_base_model/django/AppBaseModelNamesUUIDTagsDjango.py +45 -0
- lx_dtypes/models/base/app_base_model/django/AppBaseModelUUIDTagsDjango.py +95 -0
- lx_dtypes/models/base/app_base_model/django/KnowledgebaseBaseModelDjango.py +176 -0
- lx_dtypes/models/base/app_base_model/django/LedgerBaseModelDjango.py +231 -0
- lx_dtypes/models/base/app_base_model/django/PersonDjango.py +49 -0
- lx_dtypes/models/base/app_base_model/django/__init__.py +3 -0
- lx_dtypes/models/base/app_base_model/pydantic/AppBaseModel.py +109 -0
- lx_dtypes/models/base/app_base_model/pydantic/AppBaseModelNamesUUIDTags.py +30 -0
- lx_dtypes/models/base/app_base_model/pydantic/AppBaseModelUUIDTags.py +16 -0
- lx_dtypes/models/base/app_base_model/pydantic/KnowledgebaseBaseModel.py +97 -0
- lx_dtypes/models/base/app_base_model/pydantic/LedgerBaseModel.py +180 -0
- lx_dtypes/models/base/app_base_model/pydantic/PersonMixIn.py +22 -0
- lx_dtypes/models/base/app_base_model/pydantic/__init__.py +39 -0
- lx_dtypes/models/base/app_base_model/test_fixtures/AppBaseModel.py +125 -0
- lx_dtypes/models/base/app_base_model/test_fixtures/__init__.py +17 -0
- lx_dtypes/models/base/file/__init__.py +0 -0
- lx_dtypes/models/base/file/ddict/FilesAndDirsDataDict.py +8 -0
- lx_dtypes/models/base/file/ddict/__init__.py +18 -0
- lx_dtypes/models/base/file/pydantic/FilesAndDirs.py +56 -0
- lx_dtypes/models/base/file/pydantic/PathMixIn.py +49 -0
- lx_dtypes/models/base/file/pydantic/__init__.py +0 -0
- lx_dtypes/models/interface/DataLoader.py +155 -0
- lx_dtypes/models/interface/DbInterface.py +421 -0
- lx_dtypes/models/interface/KnowledgeBase.py +587 -0
- lx_dtypes/models/interface/KnowledgeBaseConfig.py +35 -0
- lx_dtypes/models/interface/Ledger.py +242 -0
- lx_dtypes/models/interface/__init__.py +0 -0
- lx_dtypes/models/interface/main.py +0 -0
- lx_dtypes/models/interface/test_fixtures/__init__.py +93 -0
- lx_dtypes/models/interface/test_fixtures/dataloader.py +62 -0
- lx_dtypes/models/interface/test_fixtures/names.py +14 -0
- lx_dtypes/models/interface/test_fixtures/paths.py +132 -0
- lx_dtypes/models/interface/test_fixtures/star_upper_gi/__init__.py +0 -0
- lx_dtypes/models/interface/test_fixtures/star_upper_gi/dataloader.py +54 -0
- lx_dtypes/models/knowledge_base/__init__.py +21 -0
- lx_dtypes/models/knowledge_base/citation/Citation.py +54 -0
- lx_dtypes/models/knowledge_base/citation/CitationDataDict.py +25 -0
- lx_dtypes/models/knowledge_base/citation/CitationDjango.py +88 -0
- lx_dtypes/models/knowledge_base/citation/__init__.py +41 -0
- lx_dtypes/models/knowledge_base/citation/test_fixtures/__init__.py +42 -0
- lx_dtypes/models/knowledge_base/classification/Classification.py +40 -0
- lx_dtypes/models/knowledge_base/classification/ClassificationDataDict.py +10 -0
- lx_dtypes/models/knowledge_base/classification/ClassificationType.py +30 -0
- lx_dtypes/models/knowledge_base/classification/ClassificationTypeDataDict.py +7 -0
- lx_dtypes/models/knowledge_base/classification/_ClassificationDjango.py +53 -0
- lx_dtypes/models/knowledge_base/classification/_ClassificationTypeDjango.py +41 -0
- lx_dtypes/models/knowledge_base/classification/__init__.py +67 -0
- lx_dtypes/models/knowledge_base/classification/test_fixtures/__init__.py +99 -0
- lx_dtypes/models/knowledge_base/classification_choice/ClassificationChoice.py +40 -0
- lx_dtypes/models/knowledge_base/classification_choice/ClassificationChoiceDataDict.py +9 -0
- lx_dtypes/models/knowledge_base/classification_choice/ClassificationChoiceDjango.py +49 -0
- lx_dtypes/models/knowledge_base/classification_choice/__init__.py +43 -0
- lx_dtypes/models/knowledge_base/classification_choice/test_fixtures/__init__.py +64 -0
- lx_dtypes/models/knowledge_base/classification_choice_descriptor/BooleanDescriptorMixin.py +7 -0
- lx_dtypes/models/knowledge_base/classification_choice_descriptor/ClassificationChoiceDescriptor.py +61 -0
- lx_dtypes/models/knowledge_base/classification_choice_descriptor/ClassificationChoiceDescriptorDataDict.py +25 -0
- lx_dtypes/models/knowledge_base/classification_choice_descriptor/ClassificationChoiceDescriptorDjango.py +94 -0
- lx_dtypes/models/knowledge_base/classification_choice_descriptor/DescriptorTypeMixin.py +61 -0
- lx_dtypes/models/knowledge_base/classification_choice_descriptor/NumericDescriptorMixin.py +24 -0
- lx_dtypes/models/knowledge_base/classification_choice_descriptor/SelectionDescriptorMixin.py +17 -0
- lx_dtypes/models/knowledge_base/classification_choice_descriptor/TextDescriptorMixin.py +8 -0
- lx_dtypes/models/knowledge_base/classification_choice_descriptor/UnitMixin.py +7 -0
- lx_dtypes/models/knowledge_base/classification_choice_descriptor/__init__.py +55 -0
- lx_dtypes/models/knowledge_base/classification_choice_descriptor/test_fixtures/ClassificationChoiceDescriptor.py +63 -0
- lx_dtypes/models/knowledge_base/classification_choice_descriptor/test_fixtures/__init__.py +9 -0
- lx_dtypes/models/knowledge_base/examination/Examination.py +42 -0
- lx_dtypes/models/knowledge_base/examination/ExaminationDataDict.py +11 -0
- lx_dtypes/models/knowledge_base/examination/ExaminationDjango.py +62 -0
- lx_dtypes/models/knowledge_base/examination/ExaminationType.py +31 -0
- lx_dtypes/models/knowledge_base/examination/ExaminationTypeDataDict.py +7 -0
- lx_dtypes/models/knowledge_base/examination/ExaminationTypeDjango.py +41 -0
- lx_dtypes/models/knowledge_base/examination/__init__.py +63 -0
- lx_dtypes/models/knowledge_base/examination/test_fixtures/__init__.py +103 -0
- lx_dtypes/models/knowledge_base/finding/FindingDataDict.py +11 -0
- lx_dtypes/models/knowledge_base/finding/FindingTypeDataDict.py +7 -0
- lx_dtypes/models/knowledge_base/finding/_Finding.py +36 -0
- lx_dtypes/models/knowledge_base/finding/_FindingDjango.py +64 -0
- lx_dtypes/models/knowledge_base/finding/_FindingType.py +31 -0
- lx_dtypes/models/knowledge_base/finding/_FindingTypeDjango.py +41 -0
- lx_dtypes/models/knowledge_base/finding/__init__.py +63 -0
- lx_dtypes/models/knowledge_base/finding/test_fixtures/__init__.py +99 -0
- lx_dtypes/models/knowledge_base/indication/Indication.py +37 -0
- lx_dtypes/models/knowledge_base/indication/IndicationDataDict.py +10 -0
- lx_dtypes/models/knowledge_base/indication/IndicationDjango.py +53 -0
- lx_dtypes/models/knowledge_base/indication/IndicationType.py +31 -0
- lx_dtypes/models/knowledge_base/indication/IndicationTypeDataDict.py +7 -0
- lx_dtypes/models/knowledge_base/indication/IndicationTypeDjango.py +40 -0
- lx_dtypes/models/knowledge_base/indication/__init__.py +61 -0
- lx_dtypes/models/knowledge_base/indication/test_fixtures/__init__.py +94 -0
- lx_dtypes/models/knowledge_base/information_source/InformationSource.py +35 -0
- lx_dtypes/models/knowledge_base/information_source/InformationSourceDataDict.py +9 -0
- lx_dtypes/models/knowledge_base/information_source/InformationSourceDjango.py +49 -0
- lx_dtypes/models/knowledge_base/information_source/InformationSourceType.py +31 -0
- lx_dtypes/models/knowledge_base/information_source/InformationSourceTypeDataDict.py +7 -0
- lx_dtypes/models/knowledge_base/information_source/InformationSourceTypeDjango.py +44 -0
- lx_dtypes/models/knowledge_base/information_source/__init__.py +60 -0
- lx_dtypes/models/knowledge_base/intervention/Intervention.py +38 -0
- lx_dtypes/models/knowledge_base/intervention/InterventionDataDict.py +9 -0
- lx_dtypes/models/knowledge_base/intervention/InterventionDjango.py +51 -0
- lx_dtypes/models/knowledge_base/intervention/InterventionType.py +31 -0
- lx_dtypes/models/knowledge_base/intervention/InterventionTypeDataDict.py +7 -0
- lx_dtypes/models/knowledge_base/intervention/InterventionTypeDjango.py +41 -0
- lx_dtypes/models/knowledge_base/intervention/__init__.py +66 -0
- lx_dtypes/models/knowledge_base/intervention/test_fixtures/__init__.py +85 -0
- lx_dtypes/models/knowledge_base/main.py +244 -0
- lx_dtypes/models/knowledge_base/unit/Unit.py +50 -0
- lx_dtypes/models/knowledge_base/unit/UnitDataDict.py +8 -0
- lx_dtypes/models/knowledge_base/unit/UnitDjango.py +54 -0
- lx_dtypes/models/knowledge_base/unit/UnitType.py +27 -0
- lx_dtypes/models/knowledge_base/unit/UnitTypeDataDict.py +7 -0
- lx_dtypes/models/knowledge_base/unit/UnitTypeDjango.py +38 -0
- lx_dtypes/models/knowledge_base/unit/__init__.py +63 -0
- lx_dtypes/models/knowledge_base/unit/test_fixtures/__init__.py +84 -0
- lx_dtypes/models/ledger/__init__.py +23 -0
- lx_dtypes/models/ledger/center/DataDict.py +9 -0
- lx_dtypes/models/ledger/center/Django.py +67 -0
- lx_dtypes/models/ledger/center/Pydantic.py +49 -0
- lx_dtypes/models/ledger/center/__init__.py +43 -0
- lx_dtypes/models/ledger/center/test_fixtures/__init__.py +71 -0
- lx_dtypes/models/ledger/examiner/DataDict.py +10 -0
- lx_dtypes/models/ledger/examiner/Django.py +51 -0
- lx_dtypes/models/ledger/examiner/Pydantic.py +39 -0
- lx_dtypes/models/ledger/examiner/__init__.py +41 -0
- lx_dtypes/models/ledger/examiner/test_fixtures/__init__.py +0 -0
- lx_dtypes/models/ledger/main.py +242 -0
- lx_dtypes/models/ledger/p_examination/DataDict.py +27 -0
- lx_dtypes/models/ledger/p_examination/Django.py +94 -0
- lx_dtypes/models/ledger/p_examination/Pydantic.py +227 -0
- lx_dtypes/models/ledger/p_examination/__init__.py +41 -0
- lx_dtypes/models/ledger/p_examination/test_fixtures/__init__.py +98 -0
- lx_dtypes/models/ledger/p_finding/DataDict.py +23 -0
- lx_dtypes/models/ledger/p_finding/Django.py +82 -0
- lx_dtypes/models/ledger/p_finding/Pydantic.py +158 -0
- lx_dtypes/models/ledger/p_finding/__init__.py +40 -0
- lx_dtypes/models/ledger/p_finding/test_fixtures/__init__.py +95 -0
- lx_dtypes/models/ledger/p_finding_classification_choice/DataDict.py +22 -0
- lx_dtypes/models/ledger/p_finding_classification_choice/Django.py +77 -0
- lx_dtypes/models/ledger/p_finding_classification_choice/Pydantic.py +125 -0
- lx_dtypes/models/ledger/p_finding_classification_choice/__init__.py +45 -0
- lx_dtypes/models/ledger/p_finding_classification_choice/test_fixtures/__init__.py +64 -0
- lx_dtypes/models/ledger/p_finding_classification_choice_descriptor/DataDict.py +11 -0
- lx_dtypes/models/ledger/p_finding_classification_choice_descriptor/Django.py +60 -0
- lx_dtypes/models/ledger/p_finding_classification_choice_descriptor/Pydantic.py +31 -0
- lx_dtypes/models/ledger/p_finding_classification_choice_descriptor/__init__.py +51 -0
- lx_dtypes/models/ledger/p_finding_classification_choice_descriptor/test_fixtures/__init__.py +37 -0
- lx_dtypes/models/ledger/p_finding_classifications/DataDict.py +18 -0
- lx_dtypes/models/ledger/p_finding_classifications/Django.py +56 -0
- lx_dtypes/models/ledger/p_finding_classifications/Pydantic.py +65 -0
- lx_dtypes/models/ledger/p_finding_classifications/__init__.py +39 -0
- lx_dtypes/models/ledger/p_finding_classifications/test_fixtures/__init__.py +50 -0
- lx_dtypes/models/ledger/p_indication/DataDict.py +8 -0
- lx_dtypes/models/ledger/p_indication/Django.py +56 -0
- lx_dtypes/models/ledger/p_indication/Pydantic.py +30 -0
- lx_dtypes/models/ledger/p_indication/__init__.py +40 -0
- lx_dtypes/models/ledger/p_indication/test_fixtures/__init__.py +30 -0
- lx_dtypes/models/ledger/p_intervention/DataDict.py +8 -0
- lx_dtypes/models/ledger/p_intervention/Django.py +56 -0
- lx_dtypes/models/ledger/p_intervention/Pydantic.py +30 -0
- lx_dtypes/models/ledger/p_intervention/__init__.py +47 -0
- lx_dtypes/models/ledger/p_intervention/test_fixtures/__init__.py +34 -0
- lx_dtypes/models/ledger/p_interventions/DataDict.py +18 -0
- lx_dtypes/models/ledger/p_interventions/Django.py +48 -0
- lx_dtypes/models/ledger/p_interventions/Pydantic.py +66 -0
- lx_dtypes/models/ledger/p_interventions/__init__.py +47 -0
- lx_dtypes/models/ledger/p_interventions/test_fixtures/__init__.py +54 -0
- lx_dtypes/models/ledger/patient/DataDict.py +10 -0
- lx_dtypes/models/ledger/patient/Django.py +52 -0
- lx_dtypes/models/ledger/patient/Pydantic.py +29 -0
- lx_dtypes/models/ledger/patient/__init__.py +47 -0
- lx_dtypes/models/ledger/patient/test_fixtures/__init__.py +28 -0
- lx_dtypes/names/__init__.py +316 -0
- lx_dtypes/names/factories.py +0 -0
- lx_dtypes/py.typed +0 -0
- lx_dtypes/serialization/__init__.py +4 -0
- lx_dtypes/serialization/model_lookup.py +20 -0
- lx_dtypes/serialization/path.py +15 -0
- lx_dtypes/serialization/str_list.py +69 -0
- lx_dtypes/stats/__init__.py +0 -0
- lx_dtypes/stats/common.py +31 -0
- lx_dtypes/stats/dataset.py +231 -0
- lx_dtypes/stats/schemas/__init__.py +0 -0
- lx_dtypes/stats/schemas/common.py +10 -0
- lx_dtypes/stats/schemas/knowledge_base.py +137 -0
- lx_dtypes/stats/schemas/ledger.py +95 -0
- lx_dtypes/utils/__init__.py +0 -0
- lx_dtypes/utils/dataframe.py +191 -0
- lx_dtypes/utils/dataloader.py +59 -0
- lx_dtypes/utils/ddict_schema.py +12 -0
- lx_dtypes/utils/django_field_types.py +44 -0
- lx_dtypes/utils/django_sync.py +111 -0
- lx_dtypes/utils/parser.py +72 -0
- lx_dtypes/utils/paths.py +18 -0
- lx_dtypes/utils/testing.py +29 -0
- lx_dtypes-0.1.1.dist-info/METADATA +231 -0
- lx_dtypes-0.1.1.dist-info/RECORD +346 -0
- lx_dtypes-0.1.1.dist-info/WHEEL +4 -0
- lx_dtypes-0.1.1.dist-info/licenses/LICENSE +21 -0
lx_dtypes/__init__.py
ADDED
|
File without changes
|
lx_dtypes/conftest.py
ADDED
|
@@ -0,0 +1,245 @@
|
|
|
1
|
+
from lx_dtypes.models.base.app_base_model.test_fixtures import (
|
|
2
|
+
app_base_model_data_dict_fixture,
|
|
3
|
+
app_base_model_names_uuid_tags_data_dict_fixture,
|
|
4
|
+
app_base_model_names_uuid_tags_pydantic_fixture,
|
|
5
|
+
app_base_model_pydantic_fixture,
|
|
6
|
+
app_base_model_uuid_tags_data_dict_fixture,
|
|
7
|
+
app_base_model_uuid_tags_pydantic_fixture,
|
|
8
|
+
)
|
|
9
|
+
from lx_dtypes.models.interface.test_fixtures import (
|
|
10
|
+
db_interface_fixture,
|
|
11
|
+
knowledge_base_fixture,
|
|
12
|
+
ledger_fixture,
|
|
13
|
+
lx_knowledge_base,
|
|
14
|
+
)
|
|
15
|
+
from lx_dtypes.models.interface.test_fixtures.dataloader import (
|
|
16
|
+
empty_data_loader,
|
|
17
|
+
initialized_demo_kb_config,
|
|
18
|
+
uninitialized_demo_kb_config,
|
|
19
|
+
yaml_data_loader,
|
|
20
|
+
)
|
|
21
|
+
from lx_dtypes.models.interface.test_fixtures.names import demo_kb_config_name
|
|
22
|
+
from lx_dtypes.models.interface.test_fixtures.paths import (
|
|
23
|
+
log_dir,
|
|
24
|
+
sample_citations_yaml_filepath,
|
|
25
|
+
sample_classification_choices_yaml_filepath,
|
|
26
|
+
sample_classifications_yaml_filepath,
|
|
27
|
+
sample_examination_types_yaml_filepath,
|
|
28
|
+
sample_examinations_yaml_filepath,
|
|
29
|
+
sample_findings_yaml_filepath,
|
|
30
|
+
sample_indications_yaml_filepath,
|
|
31
|
+
sample_information_source_yaml_filepath,
|
|
32
|
+
sample_interventions_yaml_filepath,
|
|
33
|
+
yaml_repo_dirs,
|
|
34
|
+
)
|
|
35
|
+
from lx_dtypes.models.interface.test_fixtures.star_upper_gi.dataloader import (
|
|
36
|
+
star_ugi_initialized_kb_config,
|
|
37
|
+
star_ugi_knowledge_base,
|
|
38
|
+
star_ugi_yaml_data_loader,
|
|
39
|
+
)
|
|
40
|
+
from lx_dtypes.models.knowledge_base.citation.test_fixtures import (
|
|
41
|
+
citation_fixture,
|
|
42
|
+
django_citation_fixture,
|
|
43
|
+
)
|
|
44
|
+
from lx_dtypes.models.knowledge_base.classification.test_fixtures import (
|
|
45
|
+
classification_fixture,
|
|
46
|
+
classification_type_fixture,
|
|
47
|
+
django_classification_fixture,
|
|
48
|
+
django_classification_type_fixture,
|
|
49
|
+
)
|
|
50
|
+
from lx_dtypes.models.knowledge_base.classification_choice.test_fixtures import (
|
|
51
|
+
classification_choice_fixture,
|
|
52
|
+
django_classification_choice_fixture,
|
|
53
|
+
)
|
|
54
|
+
from lx_dtypes.models.knowledge_base.classification_choice_descriptor.test_fixtures import (
|
|
55
|
+
classification_choice_descriptor_fixture,
|
|
56
|
+
django_classification_choice_descriptor_fixture,
|
|
57
|
+
)
|
|
58
|
+
from lx_dtypes.models.knowledge_base.examination.test_fixtures import (
|
|
59
|
+
django_examination_fixture,
|
|
60
|
+
django_examination_type_fixture,
|
|
61
|
+
examination_fixture,
|
|
62
|
+
examination_type_fixture,
|
|
63
|
+
)
|
|
64
|
+
from lx_dtypes.models.knowledge_base.finding.test_fixtures import (
|
|
65
|
+
django_finding_fixture,
|
|
66
|
+
django_finding_type_fixture,
|
|
67
|
+
finding_fixture,
|
|
68
|
+
finding_type_fixture,
|
|
69
|
+
)
|
|
70
|
+
from lx_dtypes.models.knowledge_base.indication.test_fixtures import (
|
|
71
|
+
django_indication_fixture,
|
|
72
|
+
django_indication_type_fixture,
|
|
73
|
+
indication_fixture,
|
|
74
|
+
indication_type_fixture,
|
|
75
|
+
)
|
|
76
|
+
from lx_dtypes.models.knowledge_base.intervention.test_fixtures import (
|
|
77
|
+
django_intervention_fixture,
|
|
78
|
+
django_intervention_type_fixture,
|
|
79
|
+
intervention_fixture,
|
|
80
|
+
intervention_type_fixture,
|
|
81
|
+
)
|
|
82
|
+
from lx_dtypes.models.knowledge_base.unit.test_fixtures import (
|
|
83
|
+
django_unit_fixture,
|
|
84
|
+
django_unit_type_fixture,
|
|
85
|
+
unit_fixture,
|
|
86
|
+
unit_type_fixture,
|
|
87
|
+
)
|
|
88
|
+
from lx_dtypes.models.ledger.center.test_fixtures import (
|
|
89
|
+
center_fixture,
|
|
90
|
+
django_center_fixture,
|
|
91
|
+
)
|
|
92
|
+
from lx_dtypes.models.ledger.p_examination.test_fixtures import (
|
|
93
|
+
django_p_examination_fixture,
|
|
94
|
+
django_populated_p_examination_fixture,
|
|
95
|
+
p_examination_fixture,
|
|
96
|
+
)
|
|
97
|
+
from lx_dtypes.models.ledger.p_finding.test_fixtures import (
|
|
98
|
+
django_p_finding_fixture,
|
|
99
|
+
django_populated_p_finding_fixture,
|
|
100
|
+
p_finding_fixture,
|
|
101
|
+
)
|
|
102
|
+
from lx_dtypes.models.ledger.p_finding_classification_choice.test_fixtures import (
|
|
103
|
+
django_p_finding_classification_choice_fixture,
|
|
104
|
+
django_populated_p_finding_classification_choice_fixture,
|
|
105
|
+
p_finding_classification_choice_fixture,
|
|
106
|
+
)
|
|
107
|
+
from lx_dtypes.models.ledger.p_finding_classification_choice_descriptor.test_fixtures import (
|
|
108
|
+
django_p_finding_classification_choice_descriptor_fixture,
|
|
109
|
+
p_finding_classification_choice_descriptor_fixture,
|
|
110
|
+
)
|
|
111
|
+
from lx_dtypes.models.ledger.p_finding_classifications.test_fixtures import (
|
|
112
|
+
django_p_finding_classifications_fixture,
|
|
113
|
+
django_populated_p_finding_classifications_fixture,
|
|
114
|
+
p_finding_classifications_fixture,
|
|
115
|
+
)
|
|
116
|
+
from lx_dtypes.models.ledger.p_indication.test_fixtures import (
|
|
117
|
+
django_p_indication_fixture,
|
|
118
|
+
p_indication_fixture,
|
|
119
|
+
)
|
|
120
|
+
from lx_dtypes.models.ledger.p_intervention.test_fixtures import (
|
|
121
|
+
django_p_finding_intervention_fixture,
|
|
122
|
+
p_finding_intervention_fixture,
|
|
123
|
+
)
|
|
124
|
+
from lx_dtypes.models.ledger.p_interventions.test_fixtures import (
|
|
125
|
+
django_p_finding_interventions_fixture,
|
|
126
|
+
django_populated_p_finding_interventions_fixture,
|
|
127
|
+
p_finding_interventions_fixture,
|
|
128
|
+
)
|
|
129
|
+
from lx_dtypes.models.ledger.patient.test_fixtures import (
|
|
130
|
+
django_patient_fixture,
|
|
131
|
+
patient_fixture,
|
|
132
|
+
)
|
|
133
|
+
|
|
134
|
+
__all__ = [
|
|
135
|
+
# App Base Model Fixtures
|
|
136
|
+
"app_base_model_data_dict_fixture",
|
|
137
|
+
"app_base_model_uuid_tags_data_dict_fixture",
|
|
138
|
+
"app_base_model_names_uuid_tags_data_dict_fixture",
|
|
139
|
+
"app_base_model_pydantic_fixture",
|
|
140
|
+
"app_base_model_uuid_tags_pydantic_fixture",
|
|
141
|
+
"app_base_model_names_uuid_tags_pydantic_fixture",
|
|
142
|
+
# Citation Fixtures
|
|
143
|
+
"citation_fixture",
|
|
144
|
+
"django_citation_fixture",
|
|
145
|
+
# Classification Fixtures
|
|
146
|
+
"classification_fixture",
|
|
147
|
+
"classification_type_fixture",
|
|
148
|
+
"django_classification_fixture",
|
|
149
|
+
"django_classification_type_fixture",
|
|
150
|
+
# Classification Choice Fixtures
|
|
151
|
+
"classification_choice_fixture",
|
|
152
|
+
"django_classification_choice_fixture",
|
|
153
|
+
# Classification Choice Descriptor Fixtures
|
|
154
|
+
"classification_choice_descriptor_fixture",
|
|
155
|
+
"django_classification_choice_descriptor_fixture",
|
|
156
|
+
# Examination Fixtures
|
|
157
|
+
"examination_fixture",
|
|
158
|
+
"examination_type_fixture",
|
|
159
|
+
"django_examination_fixture",
|
|
160
|
+
"django_examination_type_fixture",
|
|
161
|
+
# Finding Fixtures
|
|
162
|
+
"finding_fixture",
|
|
163
|
+
"finding_type_fixture",
|
|
164
|
+
"django_finding_fixture",
|
|
165
|
+
"django_finding_type_fixture",
|
|
166
|
+
# Indication Fixtures
|
|
167
|
+
"indication_fixture",
|
|
168
|
+
"indication_type_fixture",
|
|
169
|
+
"django_indication_fixture",
|
|
170
|
+
"django_indication_type_fixture",
|
|
171
|
+
# Intervention Fixtures
|
|
172
|
+
"intervention_fixture",
|
|
173
|
+
"intervention_type_fixture",
|
|
174
|
+
"django_intervention_fixture",
|
|
175
|
+
"django_intervention_type_fixture",
|
|
176
|
+
# Unit Fixtures
|
|
177
|
+
"unit_type_fixture",
|
|
178
|
+
"unit_fixture",
|
|
179
|
+
"django_unit_type_fixture",
|
|
180
|
+
"django_unit_fixture",
|
|
181
|
+
# db Interface Fixtures
|
|
182
|
+
"db_interface_fixture",
|
|
183
|
+
"knowledge_base_fixture",
|
|
184
|
+
"ledger_fixture",
|
|
185
|
+
# Path Fixtures
|
|
186
|
+
"yaml_repo_dirs",
|
|
187
|
+
"log_dir",
|
|
188
|
+
"sample_citations_yaml_filepath",
|
|
189
|
+
"sample_classifications_yaml_filepath",
|
|
190
|
+
"sample_classification_choices_yaml_filepath",
|
|
191
|
+
"sample_examinations_yaml_filepath",
|
|
192
|
+
"sample_examination_types_yaml_filepath",
|
|
193
|
+
"sample_findings_yaml_filepath",
|
|
194
|
+
"sample_indications_yaml_filepath",
|
|
195
|
+
"sample_interventions_yaml_filepath",
|
|
196
|
+
"sample_information_source_yaml_filepath",
|
|
197
|
+
# Names
|
|
198
|
+
"demo_kb_config_name",
|
|
199
|
+
# YAML Dataloader
|
|
200
|
+
"empty_data_loader",
|
|
201
|
+
"initialized_demo_kb_config",
|
|
202
|
+
"uninitialized_demo_kb_config",
|
|
203
|
+
"yaml_data_loader",
|
|
204
|
+
# lx Knowledge Base Fixtures
|
|
205
|
+
"lx_knowledge_base",
|
|
206
|
+
########### Ledger Fixtures ###########
|
|
207
|
+
"center_fixture",
|
|
208
|
+
"django_center_fixture",
|
|
209
|
+
# Patient Examination Fixtures
|
|
210
|
+
"p_examination_fixture",
|
|
211
|
+
"django_p_examination_fixture",
|
|
212
|
+
"django_populated_p_examination_fixture",
|
|
213
|
+
# Patient Finding Fixtures
|
|
214
|
+
"p_finding_fixture",
|
|
215
|
+
"django_p_finding_fixture",
|
|
216
|
+
"django_populated_p_finding_fixture",
|
|
217
|
+
# Patient Indication Fixtures
|
|
218
|
+
"p_indication_fixture",
|
|
219
|
+
"django_p_indication_fixture",
|
|
220
|
+
# Patient Interventions fixtures
|
|
221
|
+
"p_finding_interventions_fixture",
|
|
222
|
+
"django_p_finding_interventions_fixture",
|
|
223
|
+
"django_populated_p_finding_interventions_fixture",
|
|
224
|
+
# Patient Finding Intervention Fixtures
|
|
225
|
+
"p_finding_intervention_fixture",
|
|
226
|
+
"django_p_finding_intervention_fixture",
|
|
227
|
+
# Patient Finding Classifications Fixtures
|
|
228
|
+
"p_finding_classifications_fixture",
|
|
229
|
+
"django_p_finding_classifications_fixture",
|
|
230
|
+
"django_populated_p_finding_classifications_fixture",
|
|
231
|
+
# Patient Finding Classification Choice Fixtures
|
|
232
|
+
"p_finding_classification_choice_fixture",
|
|
233
|
+
"django_p_finding_classification_choice_fixture",
|
|
234
|
+
"django_populated_p_finding_classification_choice_fixture",
|
|
235
|
+
# Patient Finding Classification Choice Descriptor Fixtures
|
|
236
|
+
"p_finding_classification_choice_descriptor_fixture",
|
|
237
|
+
"django_p_finding_classification_choice_descriptor_fixture",
|
|
238
|
+
# Patient Fixtures
|
|
239
|
+
"patient_fixture",
|
|
240
|
+
"django_patient_fixture",
|
|
241
|
+
# STAR UGI
|
|
242
|
+
"star_ugi_yaml_data_loader",
|
|
243
|
+
"star_ugi_initialized_kb_config",
|
|
244
|
+
"star_ugi_knowledge_base",
|
|
245
|
+
]
|
lx_dtypes/data/README.md
ADDED
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
# Knowledge Base Data
|
|
2
|
+
This directory bundles the canonical data modules that ship with LX data models. Every subdirectory that contains a `config.yaml` is a loadable module and can declare dependencies on siblings so the loader can resolve an ordered data graph.
|
|
3
|
+
|
|
4
|
+
*Content*
|
|
5
|
+
- [1. Module Overview](#1-module-overview)
|
|
6
|
+
- [2. Detailed Module Notes](#2-detailed-module-notes)
|
|
7
|
+
- [3. Extending Or Overriding](#3-extending-or-overriding)
|
|
8
|
+
|
|
9
|
+
## 1. Module Overview
|
|
10
|
+
| Module Path | Purpose | Key Data | Depends On |
|
|
11
|
+
| --- | --- | --- | --- |
|
|
12
|
+
| `sample_knowledge_base/` | Top-level package that mirrors the current working knowledge base. Aggregates all core modules through `modules` field. | Pulls in everything below; no direct data files. | `information_source_data`, `citations`, `lx_utils`, `lx_hardware`, `example_terminology` |
|
|
13
|
+
| `information_source_data/` | Seeds canonical information sources so downstream modules can reference consistent IDs. | `data/unknown.yaml`. | None |
|
|
14
|
+
| `citations/` | Bibliography references shared across models. | `data/sample_references.yaml`, `sample_references.bib`. | None |
|
|
15
|
+
| `lx_utils/` | Cross-cutting utility enumerations (genders, tags, units, etc.). | Nested `gender/`, `tag/`, `unit/` submodules each with `default.yaml`. | `information_source_data` |
|
|
16
|
+
| `lx_hardware/` | Placeholder hardware knowledge base; currently empty but structured for overrides. | Declares empty `files`/`dirs`. | `lx_utils` |
|
|
17
|
+
| `terminology/` (`example_terminology`) | Grouping module that wires up the clinical terminology stack. | Delegates to `lx_*` submodules listed below. | None |
|
|
18
|
+
| `terminology/lx_units/` | Canonical units referenced by descriptors. | `data/`. | None |
|
|
19
|
+
| `terminology/lx_descriptors/` | Descriptor vocabulary with localized labels and metadata. | `data/`. | `lx_units` |
|
|
20
|
+
| `terminology/lx_classification_choices/` | Atomic choices used by classifications. | `data/`. | `lx_descriptors` |
|
|
21
|
+
| `terminology/lx_classifications/` | Classification definitions and types. | `data/`, `classification_types/`. | `lx_classification_choices` |
|
|
22
|
+
| `terminology/lx_interventions/` | Intervention catalog and type data. | `data/`, `intervention_types/`. | None |
|
|
23
|
+
| `terminology/lx_findings/` | Finding catalog plus finding/former_event/type folders. | `data/`, `finding_types/`, `former_events/`. | `lx_classifications` |
|
|
24
|
+
| `terminology/lx_indications/` | Indication catalog plus types. | `data/`, `indication_types/`. | `lx_interventions`, `lx_classifications` |
|
|
25
|
+
| `terminology/lx_examinations/` | Examination definitions that stitch findings, indications, interventions. | `data/`. | `lx_findings`, `lx_indications`, `lx_interventions` |
|
|
26
|
+
| `logs/` | Golden log snapshots for tests, grouped by suite. | `tests/` with dated YAML logs, `scripts/` placeholder. | None (test fixture only) |
|
|
27
|
+
| `endoreg/` | Placeholder for center-specific overrides. | Empty `center/` folder. | None |
|
|
28
|
+
| `mock/` | Reserved for ad-hoc mock data during development. | Currently empty. | None |
|
|
29
|
+
|
|
30
|
+
The dependency column mirrors the `depends_on` stanza in each module's `config.yaml`. Load order is depth-first according to those relationships, so higher-level packs such as `sample_knowledge_base` or `example_terminology` are thin orchestrators.
|
|
31
|
+
|
|
32
|
+
## 2. Detailed Module Notes
|
|
33
|
+
- **Configuration contracts**: Every module root carries a `config.yaml` that at minimum defines `name`, `version`, and optional `modules`, `depends_on`, and `data` entries. Relative `data.dirs` paths are resolved from the module directory, and folders are scanned recursively in ascending filename order.
|
|
34
|
+
- **Sample knowledge base**: `sample_knowledge_base/config.yaml` lists the exact module order used in tests. Add custom modules by appending to its `modules` array or by creating a new top-level module that depends on this one.
|
|
35
|
+
- **Utility submodules**: Under `lx_utils/`, each child (`gender`, `tag`, `unit`) is an independent module so that downstream packs can cherry-pick only the enumerations they need. Their `config.yaml` files omit `depends_on` unless coupling is required.
|
|
36
|
+
- **Terminology stack**: `terminology/config.yaml` introduces the alias `example_terminology`, which subsequently imports the six `lx_*` terminology modules. This indirection allows you to swap entire terminology bundles by changing a single module reference.
|
|
37
|
+
- **Logs as fixtures**: The `logs/tests/` tree stores YAML exports generated by the automated suites (`TestKnowledgebaseBaseModel`, `TestLogWriter`, `TestParser`, etc.). While not consumed by the knowledge base loader, keeping them under `data/` simplifies packaging when fixtures must accompany deployments.
|
|
38
|
+
- **Placeholders**: `endoreg/` and `mock/` intentionally ship empty so integrators can copy the directory layout when creating client-specific overrides without touching the shared modules.
|
|
39
|
+
|
|
40
|
+
## 3. Extending Or Overriding
|
|
41
|
+
To extend this corpus, create a new module directory beside the existing ones:
|
|
42
|
+
|
|
43
|
+
1. Add a `config.yaml` that declares `depends_on` entries for every module you need (for instance, `$new_module` might depend on `sample_knowledge_base`).
|
|
44
|
+
2. Point `data.dirs` at the folders that contain your YAML payloads. Use the same folder conventions (`data/`, `*_types/`, etc.) to stay compatible with the loader.
|
|
45
|
+
3. Register the module by either
|
|
46
|
+
- referencing it from another module's `modules` array (e.g., append to `sample_knowledge_base/config.yaml`), or
|
|
47
|
+
- loading it explicitly when constructing the knowledge base in code.
|
|
48
|
+
|
|
49
|
+
Because dependencies are DAG-based and processed in order, later modules can override IDs defined by earlier ones. For example, placing `$custom_findings` after `terminology/lx_findings` allows you to tweak a subset of findings without copying the entire catalog.
|