From 314f9aabf00246ea7dd7fdb2128b953e404cb7a9 Mon Sep 17 00:00:00 2001 From: Jeffrey Tang Date: Thu, 21 Nov 2024 15:58:02 -0600 Subject: [PATCH] fix: Make logprob field optional for response Pydantic validation --- clients/python/lorax/types.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/clients/python/lorax/types.py b/clients/python/lorax/types.py index 09624f3a5..2fc98b7b7 100644 --- a/clients/python/lorax/types.py +++ b/clients/python/lorax/types.py @@ -270,7 +270,7 @@ class Token(BaseModel): # Token text text: str # Logprob - logprob: float + logprob: Optional[float] # Is the token a special token # Can be used to ignore tokens when concatenating special: bool