The docker-compose.yml file uses:
- values for
LOCAL_BEAM_SECRET_SPOT, LOCAL_BEAM_ID, SITESetc. from the.envfile - certificates from the
/certsfolder
Please run the following before pushing to GH:
bash scripts/validate-json-schema.bash
npm install
npm run lint
npm run formatThe catalogue.json file expected by any project-specific explorer (i.e. this new Lens) is obtained from the catalogue definitions from the old project-specific explorer (i.e. the old Lens). For this purpose, a lens-catalogue-transformer tool is written. Please check the README.md file of the above tool to transform your old catalogues to a new format.
The various .ts files from lens-cce/src/assets were copied to the lens-catalogue-transformer/src/inputs/cce dir and the command npm run local transform cce was run to get the current version of the catalogue in catalogue.json.
- for VitalStatus, the key was changed from
75186-7toVitalStatusincatalogue.json(on 30-Sep-2025)
docker compose up
npm run devcopy from old Lens1
-
Q. what is alias for?
-
A. It is a map of
keystoCodeSystem URLs -
Q. what is cqltemplate for?
-
A.
-
Q. why doesn't cqltemplate have anything for vitalstatus?
-
A.
-
Q. what is criterionMap for?
-
A.
this file should work as it is copy measures from Lens1
-
Q. what is a measure?
-
A.
-
Q. what is a stratifier?
-
A. gender, stratum is male/female
-
Q. what about values like DKTK_STRAT_GENDER_STRATIFIER?
-
A. focus/resources/cql
- negotiate button is used by project-manager
- request data - data science orchestrator, bbmri negotiator or
base64 thing is the query
There are 3 representations (or formats) of a query -
- In query store
- AST (the query store format is converted to AST format)
- Focus gets the AST and transform it into a CQL query
If you convert AST to CQL in Lens, then only you need measures.ts & ast-to-cql-translator.ts files.
- Stratifier is defined in focus (e.g. name ABC)
- It's used in measures.ts ([stratifier:criteria:expression "ABC"]) stratifier:code:text "abc"
- stratifier:code:text is used in any control's
dataKeyproperty - Library should contain one or more stratifiers
- Library should contain stratifier code (e.g. fn name DiseaseExtentCode)
- Post Measure contains measures which use fn names defined in library (DiseaseExtentCode)
- Evaluate Measure is common for all
- stratifier - breakdown of fhir resource based on some param - e.g. gender, sample types (1 chart)
- strata is one bar in a graph (1 bar in the chart is a stratum)
- measure - the response sent by fhir,
- the response is called measure report (group patients by stratifier, then stratum)
- a measure is something which defines how you get the response of the function evaluate measure
- defines structure of a report
Old Lens query (cce-lens)
library Retrieve
using FHIR version '4.0.0'
include FHIRHelpers version '4.0.0'
codesystem SampleMaterialType: 'https://fhir.bbmri.de/CodeSystem/SampleMaterialType'
codesystem loinc: 'http://loinc.org'
context Patient
DKTK_STRAT_GENDER_STRATIFIER
DKTK_STRAT_AGE_STRATIFIER
DKTK_STRAT_DECEASED_STRATIFIER
DKTK_STRAT_DIAGNOSIS_STRATIFIER
DKTK_STRAT_SPECIMEN_STRATIFIER
DKTK_STRAT_PROCEDURE_STRATIFIER
DKTK_STRAT_MEDICATION_STRATIFIER
DKTK_STRAT_DEF_IN_INITIAL_POPULATION
true
CCE-Explorer query
library Retrieve
using FHIR version '4.0.0'
include FHIRHelpers version '4.0.0'
codesystem loinc: 'http://loinc.org'
context Patient
DKTK_STRAT_GENDER_STRATIFIER
DKTK_STRAT_PRIMARY_DIAGNOSIS_NO_SORT_STRATIFIER
DKTK_STRAT_AGE_CLASS_STRATIFIER
CCE_STRAT_DECEASED_STRATIFIER
DKTK_STRAT_DIAGNOSIS_STRATIFIER
CCE_STRAT_PROCEDURE_STRATIFIER
DKTK_STRAT_DEF_IN_INITIAL_POPULATION
true
CCP-Explorer query
library Retrieve
using FHIR version '4.0.0'
include FHIRHelpers version '4.0.0'
codesystem loinc: 'http://loinc.org'
context Patient
DKTK_STRAT_GENDER_STRATIFIER
DKTK_STRAT_PRIMARY_DIAGNOSIS_NO_SORT_STRATIFIER
DKTK_STRAT_AGE_CLASS_STRATIFIER
DKTK_STRAT_DECEASED_STRATIFIER
DKTK_STRAT_DIAGNOSIS_STRATIFIER
DKTK_REPLACE_SPECIMEN_STRATIFIERif InInitialPopulation then [Specimen] else {} as List<Specimen>
DKTK_STRAT_PROCEDURE_STRATIFIER
DKTK_STRAT_MEDICATION_STRATIFIER
DKTK_REPLACE_HISTOLOGY_STRATIFIER
if histo.code.coding.where(code = '59847-4').code.first() is null then 0 else 1
DKTK_STRAT_GENETIC_VARIANT
DKTK_STRAT_DEF_IN_INITIAL_POPULATION
true