We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4daa257 commit 32538e5Copy full SHA for 32538e5
chatgpt.sh
@@ -97,7 +97,7 @@ request_to_image() {
97
request_to_chat() {
98
message="$1"
99
# escape quotation marks and newlines in the prompt
100
- escaped_prompt=$(echo "$SYSTEM_PROMPT" | sed 's/"/\\"/g' | sed ':a;N;$!ba;s/\n/\\n/g')
+ escaped_system_prompt=$(echo "$SYSTEM_PROMPT" | sed 's/"/\\"/g' | sed ':a;N;$!ba;s/\n/\\n/g')
101
response=$(curl https://api.openai.com/v1/chat/completions \
102
-sS \
103
-H 'Content-Type: application/json' \
0 commit comments