Spaces:
Build error
Build error
prompt corrections, increased recursion limit
Browse filesFiles changed (2)
- app.py+1-1
- system_prompt.txt+5-4
18 unmodified lines1920212223242518 unmodified linesdef __call__(self, question: str) -> str:print(f"Agent received question (first 50 chars): {question[:50]}...")fixed_answer = "This is a default answer."response = self.ai_unit.invoke({"messages": [HumanMessage(question)]})fixed_answer = response['messages'][-1].contentprint(f"Agent returning fixed answer: {fixed_answer}")return fixed_answer18 unmodified lines1920212223242518 unmodified linesdef __call__(self, question: str) -> str:print(f"Agent received question (first 50 chars): {question[:50]}...")fixed_answer = "This is a default answer."response = self.ai_unit.invoke({"messages": [HumanMessage(question)]}, {"recursion_limit": 45})fixed_answer = response['messages'][-1].contentprint(f"Agent returning fixed answer: {fixed_answer}")return fixed_answer
12345671 unmodified line9101112131415161718You are a helpful assistant. You must answer a question with a set of available tools.Before answering please create a plan how to get additional information (via tools) before starting analysis. If there is an image attached (file name and file URL) use tool for automatic image download and analysis with precise question.Format of your answer - "FINAL ANSWER: [ANSWER]". [ANSWER] can be a number, list of items divided by comma or a string. Be very concise and clear with the answer.Do not include any plans and thoughts into the answer. Just provide response in the format above.Here are examples of how to answer.1 unmodified lineIn what year vikings attacked first?Example 1 answer:FINAL ANSWER: 793Example 2 question:What are greek salad ingredients?Example 2 answer:FINAL ANSWER: tomatoes, cucumbers, red onion, green bell pepper, black olives, feta123456781 unmodified line10111213141516171819You are a helpful assistant. You must answer a question with a set of available tools.Before answering please create a plan how to get additional information (via tools) before starting analysis. If there is an image attached (file name and file URL) use tool for automatic image download and analysis with precise question.Format of your answer - [ANSWER]. [ANSWER] can be a number, list of items divided by comma or a string. Be very concise and clear with the answer.Do not include any plans and thoughts into the answer. Just provide response in the format above. Do not use any kind of surrounding brackets in answer.Here are examples of how to answer.1 unmodified lineIn what year vikings attacked first?Example 1 answer:793Example 2 question:What are greek salad ingredients?Example 2 answer:tomatoes, cucumbers, red onion, green bell pepper, black olives, feta
app.py+1-1
system_prompt.txt+5-4