Source code for bojaxns.common

from typing import Literal, Dict, Union, List

from pydantic import BaseModel, confloat


[docs] class FloatValue(BaseModel):
[docs] type: Literal['float'] = 'float'
[docs] value: float
[docs] class IntValue(BaseModel):
[docs] type: Literal['int'] = 'int'
[docs] value: int
[docs] ParamValues = Dict[str, Union[FloatValue, IntValue]]
[docs] UValue = List[confloat(ge=0., le=1.)]