2026-03-27 14:41:13 +08:00
|
|
|
from typing import Optional, List
|
|
|
|
|
|
|
|
|
|
from pydantic import BaseModel, Field
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class SAMRequestModel(BaseModel):
|
2026-03-27 14:56:14 +08:00
|
|
|
bucket: str = Field(..., description="minio bucket name ")
|
|
|
|
|
object_name: str = Field(..., description="minio object name ")
|
2026-03-27 14:41:13 +08:00
|
|
|
image_path: str = Field(..., description="图片路径,必填字段")
|
|
|
|
|
type: str = Field(..., description="推理类型,必填字段")
|
|
|
|
|
points: Optional[List[List[float]]] | None = None
|
|
|
|
|
labels: Optional[List[int]] | None = None
|
|
|
|
|
box: Optional[List[int]] | None = None
|