(model_id: str, text: str)
| 144 | return str(inference({"source_sentence": text, "sentences" : [(context if context else "")]})) |
| 145 | @task |
| 146 | def text_classification(model_id: str, text: str) -> str: |
| 147 | inference = InferenceApi(repo_id=model_id, token=CONFIG["huggingface"]["token"]) |
| 148 | return str(inference(text)) |
| 149 | @task |
| 150 | def token_classification(model_id: str, text: str) -> str: |
| 151 | inference = InferenceApi(repo_id=model_id, token=CONFIG["huggingface"]["token"]) |
nothing calls this directly
no outgoing calls
no test coverage detected