alanchen1115 commited on
Commit
9b8e6e3
·
verified ·
1 Parent(s): 42558dd

Update main.py

Browse files
Files changed (1) hide show
  1. main.py +8 -4
main.py CHANGED
@@ -175,11 +175,15 @@ tools = [generate_and_upload_image, analyze_image_with_text]
175
  llm = ChatGoogleGenerativeAI(google_api_key=google_api, model="gemini-2.0-flash", temperature=0.2)
176
 
177
  # 建立提示模板
178
- prompt_template = ChatPromptTemplate.from_messages([
 
 
 
 
 
179
  ("system", "你是一個強大的助理,可以根據用戶的請求使用提供的工具。"),
180
- ("user", "{input}"),
181
- ("placeholder", "{agent_scratchpad}"),
182
- ])
183
 
184
  prompt = PromptTemplate.from_template(prompt_template)
185
 
 
175
  llm = ChatGoogleGenerativeAI(google_api_key=google_api, model="gemini-2.0-flash", temperature=0.2)
176
 
177
  # 建立提示模板
178
+ # prompt_template = ChatPromptTemplate.from_messages([
179
+ # ("system", "你是一個強大的助理,可以根據用戶的請求使用提供的工具。"),
180
+ # ("user", "{input}"),
181
+ # ("placeholder", "{agent_scratchpad}"),
182
+ # ])
183
+ prompt_template = '''
184
  ("system", "你是一個強大的助理,可以根據用戶的請求使用提供的工具。"),
185
+ ("user", "{input}")
186
+ '''
 
187
 
188
  prompt = PromptTemplate.from_template(prompt_template)
189