Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -31,8 +31,8 @@ row_texts = df.apply(lambda row: " | ".join(row.astype(str)), axis=1)
|
|
31 |
row_embeddings = embedding_model.encode(row_texts.tolist(), convert_to_tensor=True)
|
32 |
|
33 |
# Load mô hình Qwen và tokenizer cho việc tạo phản hồi
|
34 |
-
fc_model = AutoModelForCausalLM.from_pretrained('Qwen/Qwen2.5-
|
35 |
-
fc_tokenizer = AutoTokenizer.from_pretrained('Qwen/Qwen2.5-
|
36 |
|
37 |
# --------------------------
|
38 |
# Hàm tạo phản hồi streaming theo thời gian thực
|
|
|
31 |
row_embeddings = embedding_model.encode(row_texts.tolist(), convert_to_tensor=True)
|
32 |
|
33 |
# Load mô hình Qwen và tokenizer cho việc tạo phản hồi
|
34 |
+
fc_model = AutoModelForCausalLM.from_pretrained('Qwen/Qwen2.5-1.5B-Instruct', torch_dtype=torch.float16)
|
35 |
+
fc_tokenizer = AutoTokenizer.from_pretrained('Qwen/Qwen2.5-1.5B-Instruct')
|
36 |
|
37 |
# --------------------------
|
38 |
# Hàm tạo phản hồi streaming theo thời gian thực
|