Renamed to DiscordDraftManager for naming consistency. Discord's
MessageDraft has platform-specific features (truncation, message
splitting, stripPattern) that diverge from the shared Draft primitive,
so the class documents this divergence while following the established
naming convention.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Replace local DiscordSendQueue with the shared SendQueue from
src/adapters/shared/primitives/send-queue.js across all Discord
adapter files, and delete the now-redundant local send-queue.ts.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Replace TelegramSendQueue with shared SendQueue from primitives.
Delete local send-queue.ts.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Also fix mock paths for agent-catalog and agent-store to point to the
correct subpath (core/agents/) so the mocks actually intercept dynamic
imports in setup-agents.ts instead of falling through to the real impl.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Add resource and resource_link content type branches in the agent_message_chunk
case to emit resource_content and resource_link AgentEvents. Add explanatory
comment for model_update: the ACP SDK has no model_update session update
notification — model changes only occur synchronously via setModel().
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Add setName() to Session and handle session_info_update, current_mode_update,
config_option_update, model_update, user_message_chunk, resource_content, and
resource_link events in SessionBridge, forwarding them to the adapter via
MessageTransformer.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Add session_info_update, current_mode_update, config_option_update,
user_message_chunk handling in the sessionUpdate switch. Add rawOutput
forwarding on tool_call and tool_update events. Add setMode,
setConfigOption, setModel, listSessions, loadSession, authenticate,
forkSession, closeSession methods. Protocol version negotiation with
mismatch warning. MCP server passthrough support in spawn/resume.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
New types: SessionMode, ConfigOption, ModelInfo, AgentCapabilities,
AuthMethod, ContentBlock, McpServerConfig, PromptResponse, etc.
Expanded AgentEvent and OutgoingMessage unions with new ACP event types.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Move log, typed-emitter, file-service, streams, stderr-capture,
install-binary, and install-jq to src/core/utils/ along with their
tests. Update all import paths across the codebase.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Replace shared mutable instance properties (_currentThreadId, _currentThread,
_currentIsAssistant) with per-session Maps keyed by sessionId. This prevents
concurrent sendMessage() calls for different sessions from racing on shared
thread context fields.
- TelegramAdapter: _currentThreadId -> _sessionThreadIds Map + getThreadId()
- DiscordAdapter: _currentThread/_currentIsAssistant -> _sessionContexts Map + getSessionContext()
- Cleanup in finally blocks after super.sendMessage() completes
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Replace ChannelAdapter base class with MessagingAdapter, converting
messageHandlers object to overridden handle* methods. Remove dispatchMessage
and evaluateNoise imports (now handled by MessagingAdapter.shouldDisplay()).
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Replace ChannelAdapter base with MessagingAdapter. Convert messageHandlers
to overridden protected handle* methods. All existing behavior preserved.
Noise filtering for tool_call now handled by MessagingAdapter.shouldDisplay().
Updated spawnAssistant to accept IChannelAdapter instead of ChannelAdapter.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Update all core files and tests to use IChannelAdapter interface instead of
ChannelAdapter class. Add name property to all existing adapters. Make
deleteSessionThread, archiveSessionTopic, sendSkillCommands, and
cleanupSkillCommands optional on the interface with optional chaining at
all call sites.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>