from gradio_client import Client, file client = Client("ysharma/Microsoft_Phi-3-Vision-128k") # result = client.predict( # message={"text":"What is 3?", # "files":[ # file('https://ysharma-microsoft-phi-3-vision-128k.hf.space/file=/tmp/gradio/d3ea41e8ec37bd79ba8046e7183d359c812a53b6/setofmark1.jpg') # ]}, # api_name="/chat" # ) # print(result) from gradio_client import Client fp = file('https://ysharma-microsoft-phi-3-vision-128k.hf.space/file=/tmp/gradio/d3ea41e8ec37bd79ba8046e7183d359c812a53b6/setofmark1.jpg') client = Client("ysharma/Microsoft_Phi-3-Vision-128k") result = client.predict( message={"text":"how are you today","files":[fp]}, api_name="/chat" ) print(result)