hello-world-handler / handler.py
nateraw's picture
Upload handler.py with huggingface_hub
655e52e
raw
history blame contribute delete
396 Bytes
class EndpointHandler():
def __init__(self, path=""):
pass
def __call__(self, data):
"""
Args:
data (:obj:):
includes the input data and the parameters for the inference.
Return:
A :obj:`dict`:. base64 encoded image
"""
inputs = data.pop("inputs", data)
return [f"Hello, {x}" for x in inputs]