Buckets:
AnonymousSpottedToad/candidate_bucket / codebase /python /olaflaitinen_Promethium /src /promethium /api /schemas /experiment.py
| """ | |
| Experiment schemas. | |
| """ | |
| from datetime import datetime | |
| from typing import Optional, Dict, Any, List | |
| from pydantic import BaseModel, Field | |
| class ExperimentBase(BaseModel): | |
| """Base experiment schema.""" | |
| name: str = Field(..., min_length=1, max_length=255) | |
| description: Optional[str] = None | |
| tags: List[str] = [] | |
| metadata_json: Dict[str, Any] = {} | |
| class ExperimentCreate(ExperimentBase): | |
| """Experiment creation schema.""" | |
| pass | |
| class ExperimentUpdate(BaseModel): | |
| """Experiment update schema.""" | |
| name: Optional[str] = Field(None, min_length=1, max_length=255) | |
| description: Optional[str] = None | |
| tags: Optional[List[str]] = None | |
| metadata_json: Optional[Dict[str, Any]] = None | |
| class ExperimentRead(ExperimentBase): | |
| """Experiment response schema.""" | |
| id: int | |
| owner_id: Optional[int] = None | |
| created_at: datetime | |
| # We could include job summaries here if needed | |
| class Config: | |
| from_attributes = True | |
Xet Storage Details
- Size:
- 981 Bytes
- Xet hash:
- 18d1fc6bf32b54b5246b407cc26e3bb556e604a4d3692504af9ce25837c49221
·
Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.