Pre-alpha. No tagged release and no upgrade path between versions. Use for evaluation and development only, not production.
Core DevPre-alpha

Field types

Models embed sdk.Model and use typed field markers. Schema is inferred at registration from Go types and sumeru struct tags.

Scalar and relational types

Go typePostgreSQLNotes
sdk.StringVARCHAR (default 255)size= for length
sdk.TextTEXT
sdk.BooleanBOOLEAN
sdk.IntegerBIGINT
sdk.FloatREAL32-bit
sdk.Float64DOUBLE PRECISION64-bit
sdk.NumericNUMERIC(p,s)precision=, scale=
sdk.DateDATE
sdk.DateTimeTIMESTAMPTZ
sdk.JsonJSONB
sdk.Many2One[T]BIGINTFK; comodel= when using sdk.Any
sdk.One2Many[T]*(no column)*inverse relation
sdk.Many2Many[T]*(no column)*table=, left=, right=

Selection fields use sdk.String with selection=key:Label,... in the tag.

Common struct tags

required, unique, index, default=, string= (label), column=, comodel=, selection=

Registration

Generated models/zmodels.go calls sdk.MustRegister on make generate. Authors do not write Fields() or init() registration.