fix: type memory recall graph state (#806)#1002
Open
radu-mocanu wants to merge 1 commit into
Open
Conversation
There was a problem hiding this comment.
Pull request overview
This PR improves type-safety around episodic memory recall in the ReAct agent graph by typing the memory recall node against the graph’s Pydantic state, while preserving compatibility with dynamically-extended input schemas (per #806).
Changes:
- Type
memory_recall_node’sstateparameter asAgentGraphStateinstead ofAny. - Update the memory node tests to construct a merged Pydantic graph state via
create_state_with_input(...). - Bump package version to
0.14.15(and reflect it inuv.lock).
Reviewed changes
Copilot reviewed 3 out of 4 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
src/uipath_langchain/agent/react/memory_node.py |
Types the memory recall node state parameter as AgentGraphState to enable static checking. |
tests/agent/react/test_memory_node.py |
Updates test state construction to use the combined Pydantic graph state model. |
pyproject.toml |
Bumps project version to 0.14.15. |
uv.lock |
Updates locked metadata to match the new project version. |
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.



Summary
Why
Fixes #806
this lets static checks catch invalid state usage while preserving dynamic input fields.
Validation
uv run --no-sync pytest tests/agent/react/test_memory_node.pyuv run --no-sync mypy --config-file pyproject.toml .uv run --no-sync ruff check .uv run --no-sync ruff format --check .uv run --no-sync python scripts/lint_httpx_client.py