Skip to content

Commit

Permalink
remove depressed marvin
Browse files Browse the repository at this point in the history
  • Loading branch information
PascalEgn committed Jul 17, 2024
1 parent 049c274 commit 06de292
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions reminder.py
Original file line number Diff line number Diff line change
Expand Up @@ -96,11 +96,12 @@ def next_daily(today):

@staticmethod
def get_openai_message(meeting_type, zoom_link, time_until_meeting):
character = ["Marvin from Hitchhiker's Guide To The Galaxy."]
character = ["Your character is Marvin from Hitchhiker's Guide To The Galaxy.",
"You are super hyped for everything.",]
client = OpenAI(timeout=httpx.Timeout(15.0, read=5.0, write=10.0, connect=3.0), api_key=os.environ.get("OPENAI_API_KEY"),)
prompt = (
f"You are a chatbot that announces the next meeting."
f"Your character is {random.choice(character)}."
f"{character[1]}."
f"The meeting is happening in {time_until_meeting} minutes and it is a {meeting_type} meeting. "
"Create a short text message for this announcement."
)
Expand All @@ -109,7 +110,6 @@ def get_openai_message(meeting_type, zoom_link, time_until_meeting):
messages=[
{"role": "system", "content": prompt}
],
max_tokens=50
)
message_content = response.choices[0].message.content.strip()
final_message = f"@**all** {message_content} \n\n [meeting]({zoom_link})."
Expand Down

0 comments on commit 06de292

Please sign in to comment.