mirror of
https://github.com/MODSetter/SurfSense.git
synced 2026-06-06 20:15:17 +02:00
refactor(agents): move kb_persistence middleware into main_agent (owner)
The KB-persistence impl lived in shared/middleware/ but no subagent uses it -- consumers are the main_agent builder and the boundary event loop. Colocate with its owner using the folder-per-middleware shape; __init__ re-exports the public surface. Tests that reached module internals now alias the .middleware submodule. main_agent/middleware/kb_persistence.py -> kb_persistence/builder.py shared/middleware/kb_persistence.py -> kb_persistence/middleware.py
This commit is contained in:
parent
a7a642fedc
commit
0081b627e9
6 changed files with 19 additions and 5 deletions
|
|
@ -15,7 +15,7 @@ from unittest.mock import AsyncMock
|
|||
import numpy as np
|
||||
import pytest
|
||||
|
||||
from app.agents.chat.multi_agent_chat.shared.middleware import kb_persistence
|
||||
from app.agents.chat.multi_agent_chat.main_agent.middleware.kb_persistence import middleware as kb_persistence
|
||||
from app.db import Document
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -21,7 +21,7 @@ from unittest.mock import AsyncMock, MagicMock
|
|||
|
||||
import pytest
|
||||
|
||||
from app.agents.chat.multi_agent_chat.shared.middleware import kb_persistence
|
||||
from app.agents.chat.multi_agent_chat.main_agent.middleware.kb_persistence import middleware as kb_persistence
|
||||
|
||||
pytestmark = pytest.mark.unit
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue