diff --git a/ai-chat b/ai-chat index 31a828f..214456b 100755 --- a/ai-chat +++ b/ai-chat @@ -7,7 +7,7 @@ prompt="You are Mr.Helper. You are an assistant that lives in a floating termina echo -n "$prompt" | jq -sR '{"role": "system", "content": .}' > "$conversation_file" -while read -rp '> ' prompt ; do +while read -rep '> ' prompt ; do [ -n "$prompt" ] || continue echo -n "$prompt" | jq -sR '{"role": "user", "content": .}' >> "$conversation_file"