feat: enhance gemini models (#11497)

This commit is contained in:
非法操作
2024-12-17 12:05:13 +08:00
committed by GitHub
parent 56cfdce453
commit 74fdc16bd1
23 changed files with 138 additions and 113 deletions

View File

@@ -101,13 +101,14 @@ class ImagePromptMessageContent(PromptMessageContent):
type: PromptMessageContentType = PromptMessageContentType.IMAGE
detail: DETAIL = DETAIL.LOW
format: str = Field("jpg", description="Image format")
class DocumentPromptMessageContent(PromptMessageContent):
type: PromptMessageContentType = PromptMessageContentType.DOCUMENT
encode_format: Literal["base64"]
mime_type: str
data: str
format: str = Field(..., description="Document format")
class PromptMessage(ABC, BaseModel):