Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -14,7 +14,7 @@ class TextInput(BaseModel):
|
|
14 |
class EmbeddingOutput(BaseModel):
|
15 |
embedding: List[float]
|
16 |
|
17 |
-
@app.
|
18 |
async def encode_text(text_input: TextInput):
|
19 |
config = ModelConfig()
|
20 |
model = ProdFeatureEncoder(config=config)
|
|
|
14 |
class EmbeddingOutput(BaseModel):
|
15 |
embedding: List[float]
|
16 |
|
17 |
+
@app.get("/encode_text/{text}", response_model=EmbeddingOutput)
|
18 |
async def encode_text(text_input: TextInput):
|
19 |
config = ModelConfig()
|
20 |
model = ProdFeatureEncoder(config=config)
|