Spaces:
Runtime error
Runtime error
| def get_response(user_input: str, scraped_data: str) -> str: | |
| user_input_lower = user_input.lower() | |
| scraped_data_lower = scraped_data.lower() | |
| print("User Input:", user_input_lower) | |
| print("Scraped Data:", scraped_data_lower) | |
| if "birthplace" in user_input_lower and "imran khan" in scraped_data_lower: | |
| return "Imran Khan was born in Lahore, Pakistan." | |
| else: | |
| return "I'm sorry, I couldn't find an answer based on the provided data." | |