MCPcopy Create free account
hub / github.com/OpenBMB/BMTools / text2text_generation

Function text2text_generation

bmtools/tools/hugging_tools/api.py:154–156  ·  view source on GitHub ↗
(model_id: str,text: str)

Source from the content-addressed store, hash-verified

152 return str(inference(text))
153 @task
154 def text2text_generation(model_id: str,text: str) -> str:
155 inference = InferenceApi(repo_id=model_id, token=CONFIG["huggingface"]["token"])
156 return str(inference(text))
157 @task
158 def summarization(model_id: str, text: str) -> str:
159 inference = InferenceApi(repo_id=model_id, token=CONFIG["huggingface"]["token"])

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected