@@ -172,6 +172,7 @@ type ClaimGrants struct {
172172 Agent * AgentGrant `json:"agent,omitempty"`
173173 Inference * InferenceGrant `json:"inference,omitempty"`
174174 Observability * ObservabilityGrant `json:"observability,omitempty"`
175+ Simulation * SimulationGrant `json:"simulation,omitempty"`
175176 // Room configuration to use if this participant initiates the room
176177 RoomConfig * RoomConfiguration `json:"roomConfig,omitempty"`
177178 // Cloud-only, config preset to use
@@ -218,6 +219,7 @@ func (c *ClaimGrants) Clone() *ClaimGrants {
218219 clone .Agent = c .Agent .Clone ()
219220 clone .Inference = c .Inference .Clone ()
220221 clone .Observability = c .Observability .Clone ()
222+ clone .Simulation = c .Simulation .Clone ()
221223 clone .Attributes = maps .Clone (c .Attributes )
222224 clone .RoomConfig = c .RoomConfig .Clone ()
223225 if len (c .KindDetails ) > 0 {
@@ -240,6 +242,7 @@ func (c *ClaimGrants) MarshalLogObject(e zapcore.ObjectEncoder) error {
240242 e .AddObject ("Agent" , c .Agent )
241243 e .AddObject ("Inference" , c .Inference )
242244 e .AddObject ("Observability" , c .Observability )
245+ e .AddObject ("Simulation" , c .Simulation )
243246 e .AddObject ("RoomConfig" , logger .Proto ((* livekit .RoomConfiguration )(c .RoomConfig )))
244247 e .AddString ("RoomPreset" , c .RoomPreset )
245248 return nil
@@ -628,6 +631,32 @@ func (s *ObservabilityGrant) MarshalLogObject(e zapcore.ObjectEncoder) error {
628631
629632// ------------------------------------------------------------------
630633
634+ type SimulationGrant struct {
635+ // Dispatch grants access to dispatch simulated humans to evaluate an agent.
636+ Dispatch bool `json:"dispatch,omitempty"`
637+ }
638+
639+ func (s * SimulationGrant ) Clone () * SimulationGrant {
640+ if s == nil {
641+ return nil
642+ }
643+
644+ clone := * s
645+
646+ return & clone
647+ }
648+
649+ func (s * SimulationGrant ) MarshalLogObject (e zapcore.ObjectEncoder ) error {
650+ if s == nil {
651+ return nil
652+ }
653+
654+ e .AddBool ("Dispatch" , s .Dispatch )
655+ return nil
656+ }
657+
658+ // ------------------------------------------------------------------
659+
631660func sourceToString (source livekit.TrackSource ) string {
632661 return strings .ToLower (source .String ())
633662}
0 commit comments