This commit is contained in:
iruletheworldmo 2024-08-10 10:33:32 -06:00 committed by GitHub
parent 53b3b7fdfc
commit 8ac8b1f41d
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -1,47 +1,19 @@
import os import os
import time from openai import OpenAI
YELLOW = '\033[93m' beta_headers = {
BROWN = '\033[38;5;52m' "authorization": f"Bearer {os.environ['OPENAI_BETA_KEY']}",
RESET = '\033[0m' "openai-beta": "early-access-strawberry"
}
def garden(sub_stage=0): client = OpenAI(default_headers=beta_headers)
frame = [
" ",
" ",
" ",
" ",
f"{BROWN}~~~~~~~~~~~~~~~~{RESET}",
f"{BROWN}################{RESET}",
f"{BROWN}################{RESET}",
f"{BROWN}################{RESET}",
f"{BROWN}################{RESET}",
f"{BROWN}################{RESET}"
]
if sub_stage < 4: completion = client.chat.completions.create(
frame[sub_stage] = f" {YELLOW}(q*){RESET} " model="gpt-4o-large-2024-08-13",
elif sub_stage == 4: messages=[
frame[4] = f"{BROWN}~~~~~~{YELLOW}(q*){BROWN}~~~~~~{RESET}" {"role": "system", "content": "use your level two capabilities"},
elif sub_stage == 5: {"role": "user", "content": "give us ubi"}
frame[5] = f"{BROWN}######{YELLOW}(q*){BROWN}######{RESET}" ]
elif sub_stage == 6: )
frame[6] = f"{BROWN}######{YELLOW}(q*){BROWN}######{RESET}"
elif sub_stage == 7:
frame[7] = f"{BROWN}######{YELLOW}(q*){BROWN}######{RESET}"
return "\n".join(frame) print(completion.choices[0].message)
def delicious():
while True:
for i in range(8):
os.system('cls' if os.name == 'nt' else 'clear')
print(garden(i))
time.sleep(0.5)
time.sleep(1)
if __name__ == "__main__":
try:
delicious()
except KeyboardInterrupt:
print("\nAnimation stopped.")