Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrInvalidAgentType = errors.New("invalid agent type")
ErrInvalidAgentType is returned when an AgentType value is not one of the canonical domain values (ai, service, operator).
Functions ¶
This section is empty.
Types ¶
type Agent ¶
type Agent struct {
ID string
Name string
Type AgentType
Owner string
ModelVersion string // applicable when Type == AgentTypeAI
Endpoint string // service or model endpoint used for invocation (if applicable)
OperationalState OperationalState
CreatedAt time.Time
UpdatedAt time.Time
}
Agent represents an autonomous actor (AI agent, automated service, human operator).
type AgentRepository ¶
type AgentRepository interface {
GetByID(ctx context.Context, id string) (*Agent, error)
Create(ctx context.Context, a *Agent) error
Update(ctx context.Context, a *Agent) error
List(ctx context.Context) ([]*Agent, error)
}
AgentRepository is the persistence interface for Agent. All implementations live in internal/store/postgres.
type AgentType ¶
type AgentType string
AgentType classifies what kind of actor an agent is.
type OperationalState ¶
type OperationalState string
OperationalState represents whether an agent is permitted to act globally. This is independent of authority grants, which are managed separately.
const ( OperationalStateActive OperationalState = "active" OperationalStateSuspended OperationalState = "suspended" OperationalStateRevoked OperationalState = "revoked" )
Click to show internal directories.
Click to hide internal directories.