import gradio as gr # Define the knowledge base as a dictionary knowledge_base = { "SOP": "Sales Operations Planning / Standard Operational Procedure / Start of Production", "NTO": "Net Turnover", "D&A": "Data & Analytics", "HOF":"Head of Function", "APFO": "Adjusted Profit from Operations", "LEP": "Limited Edition Pack", "AD": "Area Director", "IDT" : "Information & Digital Technology", "CORA" : "Corporate & Regulatory Affairs", "EOB" : "End of Business Day", "OOO" :"Out of Office", } # Define the Gradio interface function def chatbot_interface(acronym): acronym = acronym.strip().toUpperCase() # Remove leading/trailing whitespace and convert to uppercase if (acronym in knowledge_base): response = f"Answer: {knowledge_base[acronym]}" else: response = "Not found in the BATCCAPEDIA" return response # HTML code to add the logo header_html = """