randydev commited on
Commit
dff8bb2
·
verified ·
1 Parent(s): 30d947a

Update Akeno/utils/chat.py

Browse files
Files changed (1) hide show
  1. Akeno/utils/chat.py +2 -8
Akeno/utils/chat.py CHANGED
@@ -29,19 +29,13 @@ a short and concise answer. Give short step-by-step reasoning if required.
29
  Today is {dt.now():%A %d %B %Y %H:%M}
30
  """
31
 
32
- create_pyrogram_base = f"""
33
- You are a Python program designed to interact with multiple APIs.
34
- Your job is to send requests to these APIs,
35
- process the response data,
36
- and return it in a structured format for further use.
37
- """
38
 
39
- async def chat_message_codegen(question):
40
  clients_x = Clients_g4f()
41
  response = clients_x.chat.completions.create(
42
  model="gpt-4o",
43
  messages=[
44
- {"role": "system", "content": create_pyrogram_base},
45
  {"role": "user", "content": question}
46
  ],
47
  )
 
29
  Today is {dt.now():%A %d %B %Y %H:%M}
30
  """
31
 
 
 
 
 
 
 
32
 
33
+ async def chat_message_codegen(question, system_prompt):
34
  clients_x = Clients_g4f()
35
  response = clients_x.chat.completions.create(
36
  model="gpt-4o",
37
  messages=[
38
+ {"role": "system", "content": system_prompt},
39
  {"role": "user", "content": question}
40
  ],
41
  )