Commit Graph

371 Commits

Author SHA1 Message Date
Adrian Lyjak 35d271cb87 Enter pre-release 2026-02-27 17:02:02 -05:00
Tuana Çelik 7037a8e151 adding more context to the landing (#401) 2026-02-27 06:58:08 -06:00
Tuana Çelik ff9daec115 Agent Docs Updates (#387) 2026-02-20 22:44:10 +01:00
llama-org-ci-bot[bot] a720c9a4de chore: version packages (#370) llama-index-workflows@2.14.2 llama-agents-client@0.1.3 llama-agents-server@v0.1.3 llama-index-utils-workflow@0.9.2 llama-agents-server@0.1.3 2026-02-13 15:54:24 -06:00
Logan 359091361f fix span handling and span hierarchy propagation (#381) 2026-02-13 15:41:09 -06:00
Adrian Lyjak e5c84561bd fix: skip auto-fix PR step when secrets are unavailable (#369) 2026-02-11 18:12:04 +00:00
github-actions[bot] b45f9b8ca5 chore: bump llama-index-core (#364)
Co-authored-by: llama-org-ci-bot[bot] <231146559+llama-org-ci-bot[bot]@users.noreply.github.com>
2026-02-11 13:02:27 -05:00
dependabot[bot] 8a341fc35d chore(deps): bump cryptography from 46.0.3 to 46.0.5 (#365)
Bumps [cryptography](https://github.com/pyca/cryptography) from 46.0.3 to 46.0.5.
- [Changelog](https://github.com/pyca/cryptography/blob/main/CHANGELOG.rst)
- [Commits](https://github.com/pyca/cryptography/compare/46.0.3...46.0.5)

---
updated-dependencies:
- dependency-name: cryptography
  dependency-version: 46.0.5
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-02-11 13:00:07 -05:00
Vincent Koc 5a923ae965 Add Opik to observability docs (#366)
* Add Opik observability docs via OpenTelemetry

* Update README.md
2026-02-11 12:20:33 -05:00
Adrian Lyjak 7433d4cddb Add fix for double send when waiter event and accepted event match (#351) 2026-02-09 18:40:40 -05:00
Adrian Lyjak df2c4fd8f9 Only run openapi auto on main (#349) 2026-02-09 15:23:12 -05:00
Adrian Lyjak 7bc7750043 Add semver ↔ PEP 440 version format conversion utilities (#345) llama-agents-server@v0.2.0-rc.0 2026-02-09 13:27:16 -05:00
Logan 6e6b11314b fix agent data links in docs (#344) 2026-02-08 22:49:44 -06:00
Adrian Lyjak b48b8c24f3 fix: update debugger assets paths after server package move (#343)
The server package moved from llama-index-workflows to llama-agents-server,
but the update-index-html CLI command and GitHub Actions workflow still
referenced the old path. Update both to point to the new location at
packages/llama-agents-server/src/llama_agents/server/static/index.html.

https://claude.ai/code/session_01QTCs9m11U3ubvmXmKAfg6A

Co-authored-by: Claude <noreply@anthropic.com>
2026-02-06 19:22:02 -05:00
llama-org-ci-bot[bot] fa804b6dcf chore: version packages (#338)
Co-authored-by: llama-org-ci-bot[bot] <231146559+llama-org-ci-bot[bot]@users.noreply.github.com>
llama-agents-server@0.1.2 llama-agents-server@v0.1.2 llama-index-workflows@2.14.1 llama-index-utils-workflow@0.9.1 llama-agents-client@0.1.2
2026-02-06 14:46:20 -05:00
Adrian Lyjak 6ece7970dd Fix concurrent step cancellation regression in 2.14.0 (#340)
* Add xfailing test for concurrent step cancellation regression in 2.14.0

This test exposes a regression introduced in 2.14.0:
- In 2.13.1: A single asyncio.sleep(0) yield after stop_step returns is
  sufficient for cancellation to propagate, blocking other_step's write.
- In 2.14.0: The yield is not enough - other_step's write still goes through.

Test sequence:
1. stop_step returns StopEvent
2. Single yield point (asyncio.sleep(0))
3. other_step writes to stream

In 2.13.1: write is blocked (PASS)
In 2.14.0: write goes through (FAIL)

The architectural change from asyncio.Queue to tick_buffer + wait_for_next_task
in commit 45e7614 ("Remove asyncio queue from control_loop #315") changed the
timing characteristics, requiring longer delays for cancellation to take effect.

In 2.13.1, workers immediately put ticks in the queue via queue_tick(), and
the continuous _pull() task meant quick processing. In 2.14.0, workers return
results collected by wait_for_next_task, adding overhead that delays cancellation.

Related: https://llama-index.slack.com/archives/C0A3TFERFHV/p1770391664693399

https://claude.ai/code/session_01VWUvDsJ88uaVn4jT68Ny8X

* Fix concurrent step cancellation regression in 2.14.0

When a worker returns a StopEvent, immediately cancel other running
workers before adding the tick to the buffer. This restores the 2.13.1
behavior where a single asyncio.sleep(0) yield after stop_step returns
is sufficient for cancellation to propagate.

The regression was introduced in commit 45e7614 ("Remove asyncio queue
from control_loop #315") which changed the architecture from asyncio.Queue
to tick_buffer + wait_for_next_task. The new architecture had more overhead,
causing cancellation to take longer.

The fix checks if the completed worker's result contains a StopEvent, and
if so, calls cleanup_tasks() immediately to cancel other workers before
they can write to the event stream.

Also removes internal implementation references from comments.

Fixes: https://llama-index.slack.com/archives/C0A3TFERFHV/p1770391664693399

https://claude.ai/code/session_01VWUvDsJ88uaVn4jT68Ny8X

* Add patch changeset for concurrent step cancellation fix

* fix lint

* Improve StopEvent cancellation speed for sibling steps

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-02-06 14:41:46 -05:00
Adrian Lyjak ef7f808c70 Fix OpenAPI schema version to use correct package name (#337) 2026-02-06 01:38:44 -05:00
Adrian Lyjak 94dc6ad51d update openapi release for llama-agents-server (#336) llama-agents-server@v0.1.1 2026-02-05 16:27:10 -05:00
Adrian Lyjak e9c1fa4467 Fix openapi generation script to use correct module path (#335)
* Fix openapi generation script to use correct module path

The hatch script `server:openapi` was invoking `python -m workflows.server.server`,
but `workflows.server` is just a re-export shim with no `server.py` submodule.
The actual module with the `__main__` block lives at `llama_agents.server.server`.

* Move OpenAPI generation from workflows package to server package

The hatch openapi script and CI workflow were configured in the
llama-index-workflows package, which required a special hatch environment
with the `server` extra to access the server module. Since the actual
server code lives in llama-agents-server, move everything there where
all dependencies are already available directly.

- Add hatch config and openapi script to llama-agents-server pyproject.toml
- Remove hatch config and hatch dev dep from llama-index-workflows pyproject.toml
- Update publish_openapi.yml to run from packages/llama-agents-server
2026-02-05 16:02:36 -05:00
llama-org-ci-bot[bot] 5d48601ed7 chore: version packages (#334) llama-index-workflows@2.14.0 llama-agents-server@0.1.1 llama-agents-client@0.1.1 llama-index-utils-workflow@0.9.0 2026-02-05 15:15:16 -05:00
Adrian Lyjak 8824dbb21f fixup invalid changeset (#333) 2026-02-05 15:12:09 -05:00
Adrian Lyjak b0210c4f5c Fix release commands and make copyright headers consistent (#332) 2026-02-05 15:08:00 -05:00
Adrian Lyjak 808cddc4a3 refactor(server): Split up server.py and add service (#326)
* refactor(server): Split up server.py and add service
2026-02-04 15:23:04 -05:00
Adrian Lyjak 84c5cdd115 feat: add auto-fix PR manager action for lint failures (#322) 2026-02-03 16:50:45 -05:00
Adrian Lyjak 45e7614554 Remove asyncio queue from control_loop (#315) 2026-02-03 12:50:10 -05:00
Adrian Lyjak 6d70056da4 docs: clarify that Agent Builder changes require explicit redeployment (#321)
Add documentation explaining that changes made during Agent Builder sessions
don't automatically update existing deployments. Users must explicitly push
changes to GitHub and redeploy to update their production workflow. This
enables safe experimentation without affecting stable deployments.

https://claude.ai/code/session_01Rok9AU8XDhhgH1x3FhbhGg

Co-authored-by: Claude <noreply@anthropic.com>
2026-02-03 09:16:28 -05:00
Adrian Lyjak 0d8f5a7b27 fix: improve dev CLI pytest robustness (#320) 2026-02-02 19:02:44 -05:00
Adrian Lyjak 10d619a551 rename llama-index-workflows-* -> llama-agents-* (#319)
* rename llama-index-workflows-client -> llama-agents-client

* integration tests too
2026-02-02 16:40:17 -05:00
Adrian Lyjak 5ded4b40fa chore: CI/testing improvements for parallel test execution (#317)
* chore: CI/testing improvements for parallel test execution

- Add workflows-dev pytest command with parallel test runner
- Add pytest-xdist for parallel test execution (-nauto)
- Add timeouts to prevent test hangs (--timeout=10/60/120)
- Use module-scoped async fixtures for faster tests
- Remove mypy in favor of basedpyright/ty type checking
- Add test-docker CI job for integration tests with testcontainers
- Exclude integration tests from Python 3.9/3.14 in CI matrix
2026-02-02 13:27:10 -05:00
Adrian Lyjak 73c12541f5 refact: introduce runtime plugin architecture and context separation (#296)
* refact: introduce runtime plugin architecture and context separation

- Add Runtime abstract base class with BasicRuntime as default implementation
- Split context into external, internal, and pre-context modules
- Replace workflow_registry with workflow_tracker for workflow lifecycle management
- Remove broker.py in favor of runtime-managed execution
- Add plugins package with get_current_runtime() for context-aware runtime access
- Update handler and workflow to use new runtime interfaces
2026-01-31 18:19:42 -05:00
Adrian Lyjak 33bbd2398b Read workflows from globals rather than sys modules, (#314)
* Read workflows from globals rather than sys modules, to avoid module conflicts
2026-01-30 14:44:50 -05:00
Adrian Lyjak 6fdc45c746 chore: use deterministic changeset filename for debugger assets (#313)
Change the debugger asset update workflow to use a fixed filename
(.changeset/update-debugger-assets.md) instead of a timestamp-based
one. This ensures multiple updates accumulate into a single changelog
entry with the latest contents, rather than creating separate entries
for each update.

https://claude.ai/code/session_018SR5swLkGS4mVgY8RUR9iP

Co-authored-by: Claude <noreply@anthropic.com>
2026-01-29 18:47:26 -05:00
Adrian Lyjak db90f89b74 Separate server/client, and move to llama_agents namespace (#277)
* prep packages

* wrong coverage detection I think

* add ts deps?

* extend path for namespaces

* the big move, import issues though

* llama_index.workflows

* llama_agents

* alias may be working

* add type checker ignores for workflows secondary namespace, update ty, and add re-exports

* Add descriptions to new client and server packages

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* Rather, commit the outputs

* keep the py files separate

* ignore examples deps

* Create afraid-books-own.md

---------

Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-29 18:16:02 -05:00
Adrian Lyjak 2d5974de0c Add agent builder docs, add resource config docs, re-organize wf docs with more explicit cloud docs section (#305) 2026-01-28 12:45:04 -05:00
hippopond 0e826b111b Draw nested workflows (#292) 2026-01-27 18:16:29 +00:00
Adrian Lyjak bc94ae31d5 Add documentation for handling blocking code in workflows (#310)
* docs: add guide for handling blocking code in workflows

Workflows run on asyncio, so blocking calls in steps stall the entire
event loop. This new page documents best practices:
- Offload blocking I/O to threads with asyncio.to_thread
- Offload CPU-intensive work to a small dedicated thread/process pool
  using loop.run_in_executor

https://claude.ai/code/session_018DdW3KPH2nt1FbWECt1uKF

* reframe to async

* docs: link to async Python overview from async workflows guide

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-01-27 13:04:13 -05:00
llama-org-ci-bot[bot] 3a2336356d chore: update debugger assets (#309)
Co-authored-by: llama-org-ci-bot[bot] <231146559+llama-org-ci-bot[bot]@users.noreply.github.com>
2026-01-27 07:26:45 -05:00
Adrian Lyjak f37e4e164b chore: add workflow to bump llama-index-core dependency (#308)
https://claude.ai/code/session_01XmJV7dHRYt9Y2GvFY3qRw2

Co-authored-by: Claude <noreply@anthropic.com>
2026-01-26 19:17:01 -05:00
Adrian Lyjak 2900f58f69 Support state type inheritance in workflows (#301) 2026-01-26 12:23:36 -05:00
llama-org-ci-bot[bot] 5716b1ec7f chore: version packages (#304)
Co-authored-by: llama-org-ci-bot[bot] <231146559+llama-org-ci-bot[bot]@users.noreply.github.com>
llama-index-workflows@v2.13.1 llama-index-workflows@2.13.1
2026-01-25 09:51:24 -05:00
Adrian Lyjak e958ed28db fix: ResourceConfig was loading config file eagerly (#306) 2026-01-25 09:43:38 -05:00
Adrian Lyjak ebaf212bbe Add resource validation to workflow.validate() (#303)
* feat: Add resource and resource config validation to workflow validate()

Adds optional resource validation to validate():

- validate_resource_configs (default True): Validates config files exist
  and match their Pydantic schemas
- validate_resources (default False): Resolves resource factories, also
  catches circular dependencies via ResourceManager

Key implementation:
- _validate_resource_configs(): Stack-based traversal of all resources
  and their dependencies, validates _ResourceConfig instances
- _validate_resources(): Resolves resources via ResourceManager.get()
- validate() now runs even with disable_validation=True when called
  explicitly
- Python 3.9 compat: restore event loop after asyncio.run()

* Create smooth-donkeys-run.md

* Update test_resources.py

Kill off a silly extra test

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-01-23 19:49:22 -05:00
llama-org-ci-bot[bot] e6bb9ec67b chore: version packages (#302)
Co-authored-by: llama-org-ci-bot[bot] <231146559+llama-org-ci-bot[bot]@users.noreply.github.com>
llama-index-workflows@v2.13.0 llama-index-utils-workflow@0.8.0 llama-index-workflows@2.13.0
2026-01-23 16:55:31 -05:00
Adrian Lyjak 6dd7fc0de8 Add resource config node support to workflow representation (#294) 2026-01-23 16:14:30 -05:00
Adrian Lyjak be198692de feat: Make resource dependencies more flexible (#295) 2026-01-23 12:41:37 -05:00
dependabot[bot] 5a4c694692 Bump marshmallow from 3.26.1 to 3.26.2 (#297)
Bumps [marshmallow](https://github.com/marshmallow-code/marshmallow) from 3.26.1 to 3.26.2.
- [Changelog](https://github.com/marshmallow-code/marshmallow/blob/dev/CHANGELOG.rst)
- [Commits](https://github.com/marshmallow-code/marshmallow/compare/3.26.1...3.26.2)

---
updated-dependencies:
- dependency-name: marshmallow
  dependency-version: 3.26.2
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-23 11:41:08 -05:00
dependabot[bot] acd3c97d91 Bump urllib3 from 2.5.0 to 2.6.3 (#298)
Bumps [urllib3](https://github.com/urllib3/urllib3) from 2.5.0 to 2.6.3.
- [Release notes](https://github.com/urllib3/urllib3/releases)
- [Changelog](https://github.com/urllib3/urllib3/blob/main/CHANGES.rst)
- [Commits](https://github.com/urllib3/urllib3/compare/2.5.0...2.6.3)

---
updated-dependencies:
- dependency-name: urllib3
  dependency-version: 2.6.3
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-23 11:40:52 -05:00
dependabot[bot] 57a4c0e5f4 Bump aiohttp from 3.13.2 to 3.13.3 (#299)
---
updated-dependencies:
- dependency-name: aiohttp
  dependency-version: 3.13.3
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-23 11:40:34 -05:00
Adrian Lyjak 9910929b82 add llama_index integration tests (#293)
* chore: add llama_index to gitignore

Added cloned reference repository llama_index/ to gitignore to avoid
tracking the large external repository.

* feat: add llama-index-integration-tests package

Add a new internal (not published) package for running integration tests
against llama-index-core workflow abstractions. This ensures that updates
to the workflows package don't break the agent classes in llama-index-core.

Includes tests for:
- FunctionAgent: basic execution, tools, max iterations, context handling
- ReActAgent: basic execution, retry on parse errors, memory persistence
- AgentWorkflow: multi-agent execution, handoff, memory, event streaming

Uses a custom MockFunctionCallingLLM to mock LLM responses without external
dependencies, ensuring tests run reliably.

* refactor: use llama-index-core MockFunctionCallingLLM

- Update llama-index-core dependency to >= 0.14.13
- Remove custom mock_llm.py, use built-in MockFunctionCallingLLM
- Enable test_early_stopping_method_generate (no longer needs skip)

All 12 integration tests now pass.

* fix: improve integration tests package

- Update basedpyright config to Python 3.13
- Fix ruff format/check issues (sorted imports, removed unused imports)
- Remove unused conftest.py fixture
- Add workflow feature tests:
  - wait_for_event inside tool functions (HITL pattern)
  - Context state management via ctx.store
  - Pickle serialization for workflow pause/resume
  - Multiple sequential tool calls with shared state

All 16 tests pass.

* refactor: reorganize integration tests by workflow feature

- Organize tests by workflow capability rather than agent type:
  - test_context_store.py: ctx.store.get/set operations
  - test_event_streaming.py: stream_events() and event types
  - test_human_in_the_loop.py: wait_for_event, serialization
  - test_error_handling.py: max_iterations, early stopping

- Add pytest parameterization for FunctionAgent vs ReActAgent where applicable
  (non-tool tests use both; tool-based tests use FunctionAgent only since
  it uses function calling format)

- Move helper functions to src/llama_index_integration_tests/helpers.py
  to avoid conftest.py import issues

- Remove tests/__init__.py to fix mypy duplicate module error

- Add type: ignore comments for Event dynamic fields

* fix ci

* better types

* type fixes/ignores

* Update packages/llama-index-integration-tests/src/llama_index_integration_tests/helpers.py

Co-authored-by: Clelia (Astra) Bertelli <133636879+AstraBert@users.noreply.github.com>

* fix

* add to ci

* 3.9 compat

---------

Co-authored-by: Claude <noreply@anthropic.com>
Co-authored-by: Clelia (Astra) Bertelli <133636879+AstraBert@users.noreply.github.com>
2026-01-23 09:54:22 -05:00
Adrian Lyjak 11b9c37007 docs: fix missing imports, typos and syntax errors in workflow docs (#290)
- managing_state.md: Add missing Context import, fix state variable name
  typo (state -> ctx_state), fix workflow variable name (w -> workflow)
- concurrent_execution.md: Add missing random import in two code examples
- resources.md: Add missing imports for Workflow, step, Event, StartEvent,
  StopEvent
- human_in_the_loop.md: Add missing imports for Workflow, step, StartEvent,
  StopEvent and Context
- durable_workflows.md: Fix sync function to async (def -> async def) in two
  examples that use await, fix variable typo (converted_id -> converted_ids)
- customizing_entry_exit_points.md: Fix missing ev. prefix on a_string_field,
  add missing keyword argument (critique=) in MyStopEvent constructor
- retry_steps.md: Add missing imports for Workflow, Context, step, StartEvent,
  StopEvent and Optional
- unbound_functions.md: Add missing imports for Workflow, step, StartEvent,
  StopEvent
- drawing.md: Add missing WorkflowServer import
- deployment.md: Add missing asyncio import, fix missing colon after async def
  main(), fix typo in import path (workflow.client -> workflows.client),
  fix missing colon in if statement

Co-authored-by: Claude <noreply@anthropic.com>
2026-01-19 15:04:28 -05:00