Skip to content

Conversation

@OskarStark
Copy link
Contributor

Q A
Bug fix? no
New feature? no
Docs? no
Issues --
License MIT

This ensures Agent bridge tools can only depend on the Agent component and not on each other, preventing cross-bridge dependencies.

  • Renamed layers to *Component convention
  • Added individual layers for each Agent bridge tool
  • SimilaritySearchTool can access StoreComponent and PlatformComponent
  • Other tools can only access AgentComponent

This ensures Agent bridge tools can only depend on the Agent component
and not on each other, preventing cross-bridge dependencies.

- Renamed layers to *Component convention
- Added individual layers for each Agent bridge tool
- SimilaritySearchTool can access StoreComponent and PlatformComponent
- Other tools can only access AgentComponent
@OskarStark OskarStark force-pushed the deptrac-agent-bridges branch from 43cc8d5 to 389697e Compare November 29, 2025 09:36
- StoreComponent
BraveTool:
- AgentComponent
- PlatformComponent
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is needed for example, as the #[With] is used from the Platform component

- ./src
exclude_files:
- '#.*test.*#'
- '#.*test.*#i'
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The original pattern #.test.# only matches lowercase "test", but the test files in this codebase are in directories named Tests (capital T), like:
src/agent/src/Bridge/SimilaritySearch/Tests/SimilaritySearchTest.php

Without the i flag, deptrac was analyzing test files and reporting violations for test-only dependencies (like the test using Symfony\AI\Platform\Vector\Vector).

With #.test.#i, it matches both test and Tests, properly excluding all test files from analysis.

@OskarStark OskarStark merged commit d61bbc3 into symfony:main Nov 29, 2025
13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants