Intelligence · interface

AuthoritativeAgentOptions

Explained in Agents and behaviour.

interface AuthoritativeAgentOptions
import type { AuthoritativeAgentOptions } from '@driftengine/ai';

Properties

NameTypeDescription
channelDecisionChannel
logCommandLogThe log both sides read.
More

On the authority the session writes it and this publishes from it; on a participant the channel fills it and the replay reads it. One structure, because a second one would be a second answer to what the agent decided.

Methods

role

role(): AgentRole

Which side this is, asked every tick.

More

A function and not a flag because authority can move, and a wrapper that cached the answer at construction would keep deciding after it stopped being allowed to.