mirror of
https://github.com/langgenius/dify.git
synced 2026-08-31 13:06:11 +08:00
1. DSL Import fix: change self._session.commit() to self._session.flush() in app_dsl_service.py _create_or_update_app() to avoid "closed transaction" error. DSL import now works: export agent app -> import -> new app created. 2. Memory loading attempt: added _load_memory_messages() to AgentV2Node that loads TokenBufferMemory from conversation history. However, chatflow engine manages conversations differently from easy-UI (conversation may not be in DB at query time, or uses ConversationVariablePersistenceLayer instead of Message table). Memory needs further investigation. Test results: - Multi-turn memory: Turn 1 OK, Turn 2 LLM doesn't see history (needs deeper fix) - Service API with API Key: PASSED (answer="Sixteen" for 8+8) - DSL Import: PASSED (status=completed, new app created) - Token aggregation: PASSED (node=49, workflow=49) Known: memory in multi-turn chatflow needs to use graphon's built-in memory mechanism (MemoryConfig on node + ConversationVariablePersistenceLayer) rather than direct DB query. Made-with: Cursor |
||
|---|---|---|
| .. | ||
| nodes | ||
| __init__.py | ||
| file_reference.py | ||
| human_input_compat.py | ||
| human_input_forms.py | ||
| node_factory.py | ||
| node_runtime.py | ||
| system_variables.py | ||
| template_rendering.py | ||
| variable_pool_initializer.py | ||
| variable_prefixes.py | ||
| workflow_entry.py | ||
| workflow_run_outputs.py | ||