Merge pull request #10529 from ryankashi/master

Added /sdapi/v1/refresh-loras api checkpoint post request
This commit is contained in:
AUTOMATIC1111 2023-05-19 08:04:13 +03:00 committed by GitHub
commit e38e7dbfb9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -77,6 +77,10 @@ def api_loras(_: gr.Blocks, app: FastAPI):
async def get_loras(): async def get_loras():
return [create_lora_json(obj) for obj in lora.available_loras.values()] return [create_lora_json(obj) for obj in lora.available_loras.values()]
@app.post("/sdapi/v1/refresh-loras")
async def refresh_loras():
return lora.list_available_loras()
script_callbacks.on_app_started(api_loras) script_callbacks.on_app_started(api_loras)