allekssandr commited on
Commit
7573ef8
·
verified ·
1 Parent(s): b00c930

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -1,10 +1,10 @@
1
  from fastapi import FastAPI
2
- from transformers import pipeline
3
 
4
  app = FastAPI()
5
 
6
  # Загрузка модели Hugging Face
7
- model = pipeline("text-generation", model="bartowski/Phi-3.5-mini-instruct-GGUF")
8
 
9
  @app.post("/predict")
10
  async def predict(text: str):
 
1
  from fastapi import FastAPI
2
+ from transformers import AutoModel
3
 
4
  app = FastAPI()
5
 
6
  # Загрузка модели Hugging Face
7
+ model = AutoModel.from_pretrained("bartowski/Phi-3.5-mini-instruct-GGUF")
8
 
9
  @app.post("/predict")
10
  async def predict(text: str):