上传学习进度
This commit is contained in:
@@ -10,7 +10,7 @@ from ..function_tools import judge
|
||||
from ..function_tools import next_chapter
|
||||
from ..services.backboard_service import realtime_response
|
||||
from ..services.markdown_service import load_full_markdown_file
|
||||
from ..services.course_service import save_learning_progress
|
||||
from ..services.course_service import save_learning_progress, upload_learning_progress_to_cloud
|
||||
from ..extension_ase.ase_client import HSAEngineClient
|
||||
from ..services.user_service import get_or_load_current_user
|
||||
from ..services.course_service import load_learning_progress
|
||||
@@ -97,6 +97,7 @@ class AgentNamespace(Namespace):
|
||||
# 恢复当前章节链
|
||||
if 'chapter_chain_now' in progress:
|
||||
chatmanager.chapter_chain_now = progress['chapter_chain_now']
|
||||
upload_learning_progress_to_cloud(progress)
|
||||
else:
|
||||
chatmanager.chat_historys = []
|
||||
chatmanager.scores = []
|
||||
@@ -306,6 +307,7 @@ class AgentNamespace(Namespace):
|
||||
if chatmanager:
|
||||
save_result = save_learning_progress(uuid, chatmanager, user_id)
|
||||
print(f"保存学习进度结果: {save_result}, user_uuid={uuid}")
|
||||
|
||||
except Exception as e:
|
||||
print(f"保存学习进度时发生异常: {str(e)}")
|
||||
|
||||
|
||||
Reference in New Issue
Block a user