alchemiscale
alchemiscale copied to clipboard
Use `pydantic` models for encoding `SynchronousComputeService` settings
Currently, SynchronousComputeService takes its intensive settings in via kwargs on its __int__ method, with extensive settings on its start method (e.g. max number of tasks, max run time). This is okay, but we may be better served by creating a general settings pydantic model with nested init and start settings models for these two methods.
This would allow us to:
- validate inputs in the models themselves
- expand the models via inheritance for e.g. the
AsynchronousComputeService - keep all settings in a single object within an initialized compute service for easy export and remixing, such as in the test suite
Could also use the pydantic model as the basis for producing a sample config file on demand via the CLI.
Addressing this in #218.