Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
math_tutor_dev
public_math_tutor
Commits
325e6061
Commit
325e6061
authored
Feb 13, 2026
by
Kantz
Browse files
es wird der erste und nicht der letzte Input für die Zusammenfassung genutzt.
parent
c10aed50
Changes
1
Show whitespace changes
Inline
Side-by-side
math-tutor/backend/app/deterministic_services/session_store.py
View file @
325e6061
...
@@ -49,7 +49,7 @@ def archive_chat(messages: list[dict[str, Any]], draft: str | None = None) -> st
...
@@ -49,7 +49,7 @@ def archive_chat(messages: list[dict[str, Any]], draft: str | None = None) -> st
def
_summarize_record
(
record
:
dict
[
str
,
Any
])
->
dict
[
str
,
Any
]:
def
_summarize_record
(
record
:
dict
[
str
,
Any
])
->
dict
[
str
,
Any
]:
history
=
record
.
get
(
"history"
,
[])
history
=
record
.
get
(
"history"
,
[])
preview
=
""
preview
=
""
for
entry
in
reversed
(
history
)
:
for
entry
in
history
:
if
entry
.
get
(
"role"
)
==
"user"
and
entry
.
get
(
"content"
):
if
entry
.
get
(
"role"
)
==
"user"
and
entry
.
get
(
"content"
):
preview
=
entry
[
"content"
][:
120
]
preview
=
entry
[
"content"
][:
120
]
break
break
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment