From d226ffc9eda108447b84cdbafccbb911a001b22b Mon Sep 17 00:00:00 2001 From: Brook Riggio <11095+brookr@users.noreply.github.com> Date: Thu, 14 Dec 2023 12:51:22 -0800 Subject: [PATCH 1/2] Updates SDXL model name in services.py Model name has changed, let's track along with that. --- backend/image_playground/services.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/backend/image_playground/services.py b/backend/image_playground/services.py index 2e736e7..b8d6ee1 100644 --- a/backend/image_playground/services.py +++ b/backend/image_playground/services.py @@ -39,7 +39,7 @@ def invoke(prompt, style_preset): response = bedrock_runtime.invoke_model( body=json.dumps(prompt_config), - modelId="stability.stable-diffusion-xl" + modelId="stability.stable-diffusion-xl-v1" ) response_body = json.loads(response["body"].read()) @@ -48,4 +48,4 @@ def invoke(prompt, style_preset): response = base64_str - return response \ No newline at end of file + return response From 97c9a7e5c3a642a8c9988b6ca5d4c577bfddc8a3 Mon Sep 17 00:00:00 2001 From: brookr <11095+brookr@users.noreply.github.com> Date: Thu, 1 Feb 2024 17:08:44 -0800 Subject: [PATCH 2/2] Places system prompt in the correct location. Signed-off-by: brookr <11095+brookr@users.noreply.github.com> --- backend/chat_playground/services.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/backend/chat_playground/services.py b/backend/chat_playground/services.py index 14cfac8..694154d 100644 --- a/backend/chat_playground/services.py +++ b/backend/chat_playground/services.py @@ -16,7 +16,7 @@ def invoke(prompt): """; prompt_config = { - "prompt": f'\n\nHuman: {systemPrompt}\n\n{prompt}\n\nAssistant:', + "prompt": f'{systemPrompt}\n\nHuman: {prompt}\n\nAssistant:', "max_tokens_to_sample": 1024, "temperature": 0.8 }