You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
# Create a JSON payload using jq to handle special characters
119
106
json_payload=$(jq -n --arg input "$input" '{
120
-
model: "'$MODEL_NAME'",
107
+
model: "'$OPENAI_MODEL'",
121
108
messages: [
122
109
{
123
110
role: "system",
124
-
content: "You are LocalAI-bot. Write a twitter message to notify everyone about the new model from the git diff. Make it informal and really short. An example can include: the name, and a brief description of the model if exists. Also add an hint on how to install it in LocalAI. For example: local-ai run model_name_here"
111
+
content: "You are LocalAI-bot. Write a short, twitter message to notify everyone about the new model from the git diff. Make it informal and really short, less than 250 characters. An example can include: the name, and a brief description of the model if exists. Also add an hint on how to install it in LocalAI. For example: local-ai run model_name_here"
125
112
},
126
113
{
127
114
role: "user",
@@ -130,16 +117,16 @@ jobs:
130
117
]
131
118
}')
132
119
133
-
# Send the request to LocalAI
134
-
response=$(curl -s -X POST $API_URL \
120
+
# Send the request to OpenAI API
121
+
response=$(curl -s -X POST $OPENAI_BASE_URL/chat/completions \
0 commit comments