GenAICoder commited on
Commit
43a4f8f
·
verified ·
1 Parent(s): 47e9ea8

Update analytics/ai_assistant.py

Browse files
Files changed (1) hide show
  1. analytics/ai_assistant.py +1 -1
analytics/ai_assistant.py CHANGED
@@ -144,7 +144,7 @@ def generate_ai_answer(question: str, df: pd.DataFrame, as_of_month: str = None,
144
 
145
  client = _get_inference_client()
146
  print("Inference called successfully")
147
- response = client.text_generation(
148
  model=HF_MODEL_ID,
149
  prompt = prompt,
150
  max_new_tokens= HF_MAX_TOKENS,
 
144
 
145
  client = _get_inference_client()
146
  print("Inference called successfully")
147
+ response = client.chat.completions.create(
148
  model=HF_MODEL_ID,
149
  prompt = prompt,
150
  max_new_tokens= HF_MAX_TOKENS,