diff --git a/app/main.py b/app/main.py index 90e5279798528bad1e0cb3d316620227f630a129..b745c615670efaac775b3f0669b0a5b3465a385c 100644 --- a/app/main.py +++ b/app/main.py @@ -73,6 +73,11 @@ async def get_model_copyright(model_id: str, response:Response): requested_model = get_model_instance(model_id) return requested_model.copyright if requested_model is not None else _result_or_404(None, model_id, response) +@app.get("/models/{model_id}/sampleconfig/", response_class=PlainTextResponse, name="Get a sample configuration") +async def get_model_sampleconfig(model_id: str, response:Response): + requested_model = get_model_instance(model_id) + return requested_model.sample_config if requested_model is not None else _result_or_404(None, model_id, response) + @app.get("/models/{model_id}/warningstatusinterpretation/{language}/", response_class=PlainTextResponse, name="How to interpret the warning status (red-yellow-green, what does it mean?) in the specified language (<a href='http://www.loc.gov/standards/iso639-2/php/English_list.php'>ISO-639-2</a>)") async def get_model_warning_status_interpretation(model_id: str, language: str, response:Response): return _result_or_404(_get_model_warning_status_interpretation(model_id, language), model_id, response)