3v324v23 commited on
Commit
44df9ce
·
1 Parent(s): fee8cd0

更gemini.py空格刪除

Browse files
Files changed (1) hide show
  1. gemini_simple.py +1 -1
gemini_simple.py CHANGED
@@ -14,7 +14,7 @@ client = genai.Client(api_key=api_key)
14
  chat = client.chats.create(model="gemini-2.0-flash")
15
  system_prompt = "You are a helpful assistant and always respond in Traditional Chinese."
16
 
17
- # 回應函數(符合 type="messages" 的格式)
18
  def respond(message,history):
19
  response = chat.send_message(f"{system_prompt}:{message}")
20
  return response.text
 
14
  chat = client.chats.create(model="gemini-2.0-flash")
15
  system_prompt = "You are a helpful assistant and always respond in Traditional Chinese."
16
 
17
+ # 回應函數(符合 type="messages"的格式)
18
  def respond(message,history):
19
  response = chat.send_message(f"{system_prompt}:{message}")
20
  return response.text