microsoft/MLOS

Add ability to load class instances from json config string, not just a file

Closed this issue · 0 comments

This is mostly a nicety for writing interactive documentation in #869

Most user interactions with mlos_bench go through json configs, so that's really what we want to document the most.

I'd like to make those more easily browsable in the Sphinx generated docs, which means putting the json example configs into docstrings, but we want to ensure that those continue to load correctly by using doctest

Right now, ConfigPersistenceService only does load_environment via a file, but it'd be pretty easy to extend it to support a json config string as well.