-
Notifications
You must be signed in to change notification settings - Fork 260
LLM Streaming Functionality with E2E Integration Tests #1088
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
|
Please see write-up on introduction of Streaming Capability interface. |
1247ec8 to
2a68147
Compare
poutsma
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good, I only have a few minor suggestions and one major change that I would like to see: the method name change in StreamPromptRunnerOperations.
That said, I would like to revisit StreamingCapabilities later, once this PR has been merged, as discussed here: embabel/embabel-common#89 (comment)
...pi/src/main/kotlin/com/embabel/agent/api/common/streaming/StreamingPromptRunnerOperations.kt
Outdated
Show resolved
Hide resolved
...pi/src/main/kotlin/com/embabel/agent/api/common/streaming/StreamingPromptRunnerOperations.kt
Outdated
Show resolved
Hide resolved
...ent-api/src/main/kotlin/com/embabel/agent/api/common/support/OperationContextPromptRunner.kt
Show resolved
Hide resolved
...bel-agent-api/src/main/kotlin/com/embabel/agent/spi/streaming/StreamingCapabilityDetector.kt
Outdated
Show resolved
Hide resolved
embabel-agent-api/src/main/kotlin/com/embabel/agent/spi/streaming/StreamingLlmOperations.kt
Show resolved
Hide resolved
rebased one more time;
generalized LLM Thinking detection;
added more tests on reactive pattern: {onNext, onError, onComplete...}
enhanced logic on multi-chuncked JSONL-based objects
rebased to agent-api 0.3.1 synchronized with test-domain major update to Streaming Chat Client Operations; addition of LLM IT test, to be executed manually
2a68147 to
6c907eb
Compare
move from spi package to api common/support marked as 'internal'
|
poutsma
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This can be merged from my perspective.




LLM Streaming Integration with Tooling Support
Overview
This PR introduces comprehensive LLM streaming capabilities with full tooling integration, providing reactive streaming APIs that work seamlessly with
@Toolannotated methods.User Code Usage
Basic Streaming with Tools
Extension Functions API
// Pure casting (fast)
runner.asStreaming()
// Safe conversion with validation
runner.asStreamingWithValidation()
Code Organization
New Components
Architecture Flow
OperationContextPromptRunner serves as the bridge between existing code and streaming features, enabling seamless transition from traditional blocking operations to reactive streaming
without requiring changes to existing business logic or tool definitions.
Challenge: Minimal Changes to Existing Artifacts
StreamingJacksonOutputConverter
Workflow
Flux4.Tools invoked
Testing Coverage
Remaining Major Tasks: