| 1 | #nullable enable |
| 2 | |
| 3 | namespace CascadeIDE.Features.Chat.Application; |
| 4 | |
| 5 | /// <summary>Порты UI/сессии для <see cref="IntercomOutboundSendOrchestrator"/> (ADR 0119 / 0128).</summary> |
| 6 | public sealed class IntercomOutboundSendHost |
| 7 | { |
| 8 | public required Func<string> GetTrimmedInput { get; init; } |
| 9 | |
| 10 | public required Func<string?> GetWorkspaceRoot { get; init; } |
| 11 | |
| 12 | public required Func<int> GetPendingAttachCount { get; init; } |
| 13 | |
| 14 | /// <summary>Обработать строку-слэш; <c>true</c> — сценарий завершён, дальше не идти.</summary> |
| 15 | public required Func<string, Task<bool>> TryHandleSlashLineAsync { get; init; } |
| 16 | |
| 17 | public required Func<string, CancellationToken, Task<(bool Ok, IntercomAttachmentMessageBuilder.Outbound Outbound, string Error)>> TryBuildOutboundAsync { get; init; } |
| 18 | |
| 19 | public required Func<Task> BeginPrepareOutboundAsync { get; init; } |
| 20 | |
| 21 | public required Func<Task> EndPrepareOutboundAsync { get; init; } |
| 22 | |
| 23 | public required Func<string, string?> ApplyProductSpine { get; init; } |
| 24 | |
| 25 | public required Func<string, IntercomAttachmentMessageBuilder.Outbound, string> FormatAgentInput { get; init; } |
| 26 | |
| 27 | public required Func<string, IntercomAttachmentMessageBuilder.Outbound, bool, string, Task> CommitUserMessageAsync { get; init; } |
| 28 | |
| 29 | public required Func<string> ConsumeDeliveryMode { get; init; } |
| 30 | |
| 31 | public required Func<string, bool> ShouldDeferProviderDispatch { get; init; } |
| 32 | |
| 33 | public required Action<string> CancelActiveTurnIfSteer { get; init; } |
| 34 | |
| 35 | public required Func<string, Task> EnqueueFollowUpAgentInputAsync { get; init; } |
| 36 | |
| 37 | public required Func<Task> ProcessFollowUpQueueAsync { get; init; } |
| 38 | |
| 39 | public required Func<bool> GetChatMcpOnly { get; init; } |
| 40 | |
| 41 | public required Func<string> GetActiveAiProvider { get; init; } |
| 42 | |
| 43 | public required Func<string, Task> SendCursorAcpAsync { get; init; } |
| 44 | |
| 45 | public required Func<string, string, Task> SendStreamingAsync { get; init; } |
| 46 | |
| 47 | public required Func<string, Task> SetClarificationStatusAsync { get; init; } |
| 48 | |
| 49 | public required Func<Task> EndProviderTurnAsync { get; init; } |
| 50 | } |
| 51 | |