diff --git a/frontend/src/lib/constants.ts b/frontend/src/lib/constants.ts index 4b74a5db..df1aaad1 100644 --- a/frontend/src/lib/constants.ts +++ b/frontend/src/lib/constants.ts @@ -21,7 +21,7 @@ export const DEFAULT_KNOWLEDGE_SETTINGS = { * UI Constants */ export const UI_CONSTANTS = { - MAX_SYSTEM_PROMPT_CHARS: 2000, + MAX_SYSTEM_PROMPT_CHARS: 4000, } as const; export const ANIMATION_DURATION = 0.4; diff --git a/src/services/flows_service.py b/src/services/flows_service.py index 429eabe7..b684deb8 100644 --- a/src/services/flows_service.py +++ b/src/services/flows_service.py @@ -622,11 +622,9 @@ class FlowsService: if not LANGFLOW_CHAT_FLOW_ID: raise ValueError("LANGFLOW_CHAT_FLOW_ID is not configured") - # Determine target component IDs based on provider - target_agent_id = self._get_provider_component_ids(provider)[1] - + # The system_prompt field is in the Agent component, not the Language Model component await self._update_flow_field(LANGFLOW_CHAT_FLOW_ID, "system_prompt", system_prompt, - node_display_name=target_agent_id) + node_display_name="Agent") async def update_flow_docling_preset(self, preset: str, preset_config: dict): """Helper function to update docling preset in the ingest flow"""