(ctx context.Context, userInput string, state *agent.AgentState, sessionID ...string)
| 559 | type delayedSubmitEngine struct{} |
| 560 | |
| 561 | func (e *delayedSubmitEngine) SubmitMessage(ctx context.Context, userInput string, state *agent.AgentState, sessionID ...string) <-chan agent.StreamEvent { |
| 562 | out := make(chan agent.StreamEvent) |
| 563 | go func() { |
| 564 | defer close(out) |
| 565 | select { |
| 566 | case <-time.After(350 * time.Millisecond): |
| 567 | out <- agent.NewStreamEvent("done", "", nil) |
| 568 | case <-ctx.Done(): |
| 569 | } |
| 570 | }() |
| 571 | return out |
| 572 | } |
| 573 | |
| 574 | type cancelAwareSubmitEngine struct{} |
| 575 |
nothing calls this directly
no test coverage detected