Skip to content

feat: add @resource_override and folder_path support to MemoryService#1591

Merged
mjnovice merged 3 commits intomainfrom
feat/memory-service-resource-override
Apr 24, 2026
Merged

feat: add @resource_override and folder_path support to MemoryService#1591
mjnovice merged 3 commits intomainfrom
feat/memory-service-resource-override

Conversation

@mjnovice
Copy link
Copy Markdown
Contributor

Summary

  • Apply @resource_override(resource_type="memorySpace") to create/create_async so folder bindings are automatically resolved from resource overwrites (matching assets, ECS indexes, etc.)
  • Add folder_path parameter to all public methods as an alternative to folder_key
  • Plumb folder_path through to private spec builders via the existing _resolve_folder method

Why

The memory service was the only resource type that required callers to manually read _resource_overwrites to resolve folder bindings. Other services (context grounding, assets, connections) use the @resource_override decorator for automatic resolution. This was flagged in UiPath/uipath-agents-python#374 review.

Changes

_memory_service.py:

  • create / create_async: Added @resource_override(resource_type="memorySpace") decorator + folder_path param
  • list / list_async: Added folder_path param
  • search / search_async: Added folder_path param
  • escalation_search / escalation_search_async: Added folder_path param
  • escalation_ingest / escalation_ingest_async: Added folder_path param
  • All private spec builders updated to accept and forward folder_path

Notes

  • @resource_override is only applied to create/create_async since they have a name parameter (the decorator matches on name by default). list/search/escalation_* methods use memory_space_id or OData filters, so the decorator doesn't apply.
  • The memorySpace resource type was already registered in GenericResourceOverwrite.
  • Backwards compatible — folder_path defaults to None.

Test plan

  • Verify create with resource overwrites resolves folder correctly
  • Verify list/search with folder_path param works

🤖 Generated with Claude Code

- Apply @resource_override(resource_type="memorySpace") to create/create_async
  so folder bindings are automatically resolved from resource overwrites
- Add folder_path parameter to all public methods (create, list, search,
  escalation_search, escalation_ingest and their async variants)
- Plumb folder_path through to private spec builders via _resolve_folder

This aligns memory spaces with how other resources (assets, ECS indexes)
handle resource binding resolution.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@github-actions github-actions Bot added the test:uipath-langchain Triggers tests in the uipath-langchain-python repository label Apr 24, 2026
mjnovice and others added 2 commits April 24, 2026 15:17
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@mjnovice mjnovice merged commit cc24c8e into main Apr 24, 2026
122 checks passed
@mjnovice mjnovice deleted the feat/memory-service-resource-override branch April 24, 2026 22:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

test:uipath-langchain Triggers tests in the uipath-langchain-python repository

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants