From 06d1cd43888d6a7abc21f860ec7ecb7a5082fc52 Mon Sep 17 00:00:00 2001 From: Luke Childs Date: Sat, 5 Aug 2023 18:55:33 +0700 Subject: [PATCH] Simplify --- humanscript | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/humanscript b/humanscript index 194df78..af25bcf 100755 --- a/humanscript +++ b/humanscript @@ -52,11 +52,9 @@ $(cat "${humanscript_path}") ### Output script:" -# JSON encode strings +# Format JSON payload stringified_system_prompt=$(echo "${system_prompt}"| jq -sRr @json) stringified_user_prompt=$(echo "${user_prompt}"| jq -sRr @json) - -# Format JSON payload data=$(echo '{ "model": "'$HUMANSCRIPT_MODEL'", "messages": [{"role": "system", "content": '$stringified_system_prompt'},{"role": "user", "content": '$stringified_user_prompt'}],