mirror of
https://github.com/GNS3/gns3-server.git
synced 2026-11-03 05:51:15 +02:00
feat(copilot): replace LangGraph config with request-scoped context variables
- Refactor `llm_call` and `generate_title` nodes to retrieve `llm_config` from request-scoped context variable instead of LangGraph config - Remove `jwt_token` and `llm_config` from LangGraph configurable parameters in `AgentService.stream` - Add `set_current_llm_config` and `get_current_llm_config` functions to `connector_factory` and export them in `__init__.py` - Update `tool_node` to no longer extract `jwt_token` from config as it is now handled via context variable - Improves thread safety and decouples configuration from LangGraph's state management
This commit is contained in:
1 parent
b05e6a71b4
commit
eec4ebe3fd
4 files changed
+43
-20
No files matched your search
@@ -27,6 +27,8 @@ from .connector_factory import (
|
||||
get_llm_config,
|
||||
set_current_jwt_token,
|
||||
get_current_jwt_token,
|
||||
set_current_llm_config,
|
||||
get_current_llm_config,
|
||||
)
|
||||
from .custom_gns3fy import (
|
||||
CONSOLE_TYPES,
|
||||
@@ -66,4 +68,6 @@ __all__ = [
|
||||
"get_llm_config",
|
||||
"set_current_jwt_token",
|
||||
"get_current_jwt_token",
|
||||
"set_current_llm_config",
|
||||
"get_current_llm_config",
|
||||
]
|
||||
Reference in new issue
Block a user