manikumargouni commited on
Commit
869e285
·
verified ·
1 Parent(s): cd882f4

Upload inference_intent_type.py with huggingface_hub

Browse files
Files changed (1) hide show
  1. inference_intent_type.py +4 -1
inference_intent_type.py CHANGED
@@ -1,7 +1,10 @@
1
  import argparse
2
  import json
3
 
4
- from model_runtime import get_head
 
 
 
5
 
6
 
7
  def predict(text: str, confidence_threshold: float | None = None):
 
1
  import argparse
2
  import json
3
 
4
+ try:
5
+ from .model_runtime import get_head # type: ignore
6
+ except ImportError:
7
+ from model_runtime import get_head
8
 
9
 
10
  def predict(text: str, confidence_threshold: float | None = None):