-
Notifications
You must be signed in to change notification settings - Fork 5
Open
Description
Summary
The status field on datamachine_agents supports active, inactive, and archived states, but nothing checks this before allowing a chat session. An inactive or archived agent can still chat.
Current Behavior
ChatOrchestrator::createSession() resolves the agent via datamachine_resolve_or_create_agent_id() and proceeds regardless of the agent's status field. The status column exists in the schema but is never checked in the chat flow.
Proposed Fix
Check agent status in ChatOrchestrator before creating or continuing a session:
active→ proceed normallyinactive→ reject with appropriate error ("Your chat agent is currently disabled")archived→ reject with appropriate error ("This agent has been archived")
This gives site admins a kill switch for individual agents without deleting them, and is a prerequisite for any moderation system where a misbehaving agent needs to be disabled.
Related
- Consider agent-level runtime authentication #740 — Agent-level runtime authentication
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels