mirror of
https://github.com/huggingface/text-generation-inference.git
synced 2025-09-11 04:14:52 +00:00
fix warning for pydantic 2
This commit is contained in:
parent
ccd5725a0c
commit
75e8521eb9
@ -243,5 +243,11 @@ class StreamResponse(BaseModel):
|
|||||||
|
|
||||||
# Inference API currently deployed model
|
# Inference API currently deployed model
|
||||||
class DeployedModel(BaseModel):
|
class DeployedModel(BaseModel):
|
||||||
|
model_config = {
|
||||||
|
# Pydantic 2 sets `model_` prefix as protected namespace and raises a
|
||||||
|
# warning when this model is loaded. Set this option to disable the warning.
|
||||||
|
"protected_namespaces": (),
|
||||||
|
}
|
||||||
|
|
||||||
model_id: str
|
model_id: str
|
||||||
sha: str
|
sha: str
|
||||||
|
Loading…
Reference in New Issue
Block a user