Model Development Kit (MDK)¶
The oasislmf Python package comes with a command line interface for creating, testing and managing models.
The tool is split into several namespaces that group similar commands.
For a full list of namespaces use oasislmf --help
, and oasislmf <namespace> --help
for a full list of commands available in each namespace.
config¶
Describes the format of the configuration (JSON) file to use the MDK
model run
command for running models end-to-end.
One file will need to be defined per model, usually in the model repository and with an indicative name.
The path-related keys should be strings, given relative to the location of configuration file. Optional arguments for a command are usually defaulted with appropriate values, but can be overridden by providing a runtime flag.
- analysis_settings_json
Analysis settings (JSON) file path
- lookup_data_dir
Model lookup/keys data path (optional)
- lookup_config_json
Model built-in lookup config. (JSON) file path (optional)
- lookup_package_dir
Model custom lookup package path (optional)
- model_version_csv
Model version (CSV) file path (optional)
- model_data_dir
Model data path
- model_package_dir
Path to the directory to use as the model specific package (optional)
- model_run_dir
Model run directory (optional)
- oed_location_csv
Source OED exposure (CSV) file path
- oed_accounts_csv
Source OED accounts (CSV) file path (optional)
- oed_info_csv
Reinsurance (RI) info. file path (optional)
- oed_scope_csv
RI scope file path (optional)
- profile_location_csv
Source OED exposure (JSON) profile describing the financial terms contained in the source exposure file (optional)
- profile_accounts_json
Source OED accouns (JSON) profile describing the financial terms contained in the source accounts file (optional)
- summarise_exposure
Generates an exposure summary report in JSON
- ktools_num_processes
The number of concurrent processes used by ktools during model execution - default is
2
- ktools_fifo_relative
Whether to create ktools FIFO queues under the
./fifo
subfolder (in the model run directory)- ktools_alloc_rule_gul
Override the allocation used in
fmcalc
- default is1
- ktools_alloc_rule_il
Override the allocation used in
fmcalc
- default is2
model¶
oasislmf model generate-exposure-pre-analysis
¶
Generate a new EOD from original one by specifying a model specific pre-analysis hook for exposure modification see ExposurePreAnalysis for more detail
oasislmf model generate-keys
¶
Generates keys from a model lookup, and write Oasis keys and keys error files.
oasislmf model generate-losses
¶
Generates the standard Oasis GUL input files + optionally the IL/FM input files and the RI input files.
oasislmf model generate-oasis-files
¶
Generates the standard Oasis GUL input files + optionally the IL/FM input files and the RI input files.
oasislmf model run
¶
Run models end to end.
The command line arguments can be supplied in the configuration file
(oasislmf.json
by default or specified with the --config
flag).
exposure¶
oasislmf exposure run
¶
Run models end to end.
The command line arguments can be supplied in the configuration file
(oasislmf.json
by default or specified with the --config
flag).
API client¶
oasislmf api run
¶
Run a model via the Oasis Platoform API end to end
version¶
Prints the installed package version