[PR #260] [MERGED] Implement event streaming from workflows #359

Closed
opened 2026-02-16 01:17:02 -05:00 by yindo · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/run-llama/llama_deploy/pull/260
Author: @logan-markewich
Created: 9/18/2024
Status: Merged
Merged: 9/24/2024
Merged by: @logan-markewich

Base: mainHead: logan/implement_event_streaming


📝 Commits (10+)

📊 Changes

27 files changed (+1058 additions, -271 deletions)

View changed files

.github/workflows/e2e_test.yml (+36 -0)
📝 .github/workflows/publish_release.yml (+1 -1)
📝 .pre-commit-config.yaml (+1 -1)
📝 README.md (+38 -2)
📝 docs/docs/module_guides/workflow/deployment.md (+82 -11)
e2e_tests/README.md (+9 -0)
e2e_tests/basic_streaming/launch_core.py (+14 -0)
e2e_tests/basic_streaming/launch_workflow.py (+81 -0)
e2e_tests/basic_streaming/run.sh (+25 -0)
e2e_tests/basic_streaming/test_run_client.py (+82 -0)
e2e_tests/basic_workflow/launch_core.py (+14 -0)
e2e_tests/basic_workflow/launch_workflow.py (+40 -0)
e2e_tests/basic_workflow/run.sh (+25 -0)
e2e_tests/basic_workflow/test_run_client.py (+85 -0)
e2e_tests/run_all_e2e_tests.sh (+11 -0)
📝 llama_deploy/client/async_client.py (+49 -4)
📝 llama_deploy/client/sync_client.py (+52 -3)
📝 llama_deploy/control_plane/server.py (+103 -4)
📝 llama_deploy/deploy/deploy.py (+8 -3)
📝 llama_deploy/orchestrators/simple.py (+1 -0)

...and 7 more files

📄 Description

This PR adds the ability to
a) expose streaming events from a workflow
b) client code to pass these events in a helpful way to the user. Since we can only put serialized items over the wire, we need to json.dumps the pydantic object. On the client side, I added some logic to at least pass it back to the user as a loaded dict, so that they can rehydrate on their end

I also added some new e2e tests for the CICD, so that we have some assurance that things still work in PRs :)

What this PR does NOT do

  • expose streaming for subworkflows -- I actually don't think this is possible, at least with the handful of ways I was trying it

Things I don't like


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/run-llama/llama_deploy/pull/260 **Author:** [@logan-markewich](https://github.com/logan-markewich) **Created:** 9/18/2024 **Status:** ✅ Merged **Merged:** 9/24/2024 **Merged by:** [@logan-markewich](https://github.com/logan-markewich) **Base:** `main` ← **Head:** `logan/implement_event_streaming` --- ### 📝 Commits (10+) - [`2890ac3`](https://github.com/run-llama/llama_deploy/commit/2890ac3b2f784837f6c15d43ec17b0ccd5797ddb) add streaming - [`e6d4b97`](https://github.com/run-llama/llama_deploy/commit/e6d4b97b3fffeb27b143fa2e921f080798ad5566) merge main - [`cffe433`](https://github.com/run-llama/llama_deploy/commit/cffe4336c80878621a543b0626cbef2ab4f530ed) fix tests - [`2ada6c7`](https://github.com/run-llama/llama_deploy/commit/2ada6c7330b98053fe15c416292610125f39fa22) merge main - [`02e4471`](https://github.com/run-llama/llama_deploy/commit/02e4471bc254832d7cc23acf25469b694a876c36) update version in publish release - [`c973658`](https://github.com/run-llama/llama_deploy/commit/c973658c9506bdaaf6740c8381324829f3bc33f8) add e2e tests - [`ffa9d37`](https://github.com/run-llama/llama_deploy/commit/ffa9d378f9bf3d19bdff76362f854fce9525c408) use poetry as an entry point - [`913cd90`](https://github.com/run-llama/llama_deploy/commit/913cd90d5346585a45e87a65364bb2435d47453c) fix some issues in cicd - [`26d0f91`](https://github.com/run-llama/llama_deploy/commit/26d0f91e674f6c6b9bda8f17a9d53ed0ab2ad004) improve process for spinning up message queue - [`c1b9a53`](https://github.com/run-llama/llama_deploy/commit/c1b9a5314d7520f4b9079eaf601c5360479f0966) don't use poetry run? ### 📊 Changes **27 files changed** (+1058 additions, -271 deletions) <details> <summary>View changed files</summary> ➕ `.github/workflows/e2e_test.yml` (+36 -0) 📝 `.github/workflows/publish_release.yml` (+1 -1) 📝 `.pre-commit-config.yaml` (+1 -1) 📝 `README.md` (+38 -2) 📝 `docs/docs/module_guides/workflow/deployment.md` (+82 -11) ➕ `e2e_tests/README.md` (+9 -0) ➕ `e2e_tests/basic_streaming/launch_core.py` (+14 -0) ➕ `e2e_tests/basic_streaming/launch_workflow.py` (+81 -0) ➕ `e2e_tests/basic_streaming/run.sh` (+25 -0) ➕ `e2e_tests/basic_streaming/test_run_client.py` (+82 -0) ➕ `e2e_tests/basic_workflow/launch_core.py` (+14 -0) ➕ `e2e_tests/basic_workflow/launch_workflow.py` (+40 -0) ➕ `e2e_tests/basic_workflow/run.sh` (+25 -0) ➕ `e2e_tests/basic_workflow/test_run_client.py` (+85 -0) ➕ `e2e_tests/run_all_e2e_tests.sh` (+11 -0) 📝 `llama_deploy/client/async_client.py` (+49 -4) 📝 `llama_deploy/client/sync_client.py` (+52 -3) 📝 `llama_deploy/control_plane/server.py` (+103 -4) 📝 `llama_deploy/deploy/deploy.py` (+8 -3) 📝 `llama_deploy/orchestrators/simple.py` (+1 -0) _...and 7 more files_ </details> ### 📄 Description This PR adds the ability to a) expose streaming events from a workflow b) client code to pass these events in a helpful way to the user. Since we can only put serialized items over the wire, we need to json.dumps the pydantic object. On the client side, I added some logic to at least pass it back to the user as a loaded dict, so that they can rehydrate on their end I also added some new e2e tests for the CICD, so that we have some assurance that things still work in PRs :) What this PR does NOT do - expose streaming for subworkflows -- I actually don't think this is possible, at least with the handful of ways I was trying it Things I don't like - so far, you can use this gist to test https://gist.github.com/logan-markewich/02564c6f1d1135ebe00a9c63ab2da612 --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
yindo added the pull-request label 2026-02-16 01:17:02 -05:00
yindo closed this issue 2026-02-16 01:17:02 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: run-llama/llama_deploy#359