File size: 317 Bytes
ea99abb |
1 2 3 4 5 6 7 8 |
from utils.remote_client import execute_remote_task
def information_extraction(text: str, model: str) -> str:
resp = execute_remote_task("extraction", {"text": text, "model": model})
if "error" in resp:
return "Oops! Something went wrong. Please try again later."
return resp.get("entities", "")
|