Fix to save organic results to conversation context in DB

This bug was introduced in 05d4e19cb, version 1.42.2, during migration
to save deeply typed ChatMessageModel. As the ChatMessageModel did
not use the right field name for organic results (since the start).

Previously it did not matter as it was storing to DB irrespective but
now the mapping of dictionary to ChatMessageModel drops that field
before save to conversation in DB.

This was resulting in organic context being lost on page reload and
only being shown on first response.
This commit is contained in:
Debanjum
2025-06-11 10:43:17 -07:00
parent 30ced1d86c
commit 4946ea1668

View File

@@ -85,7 +85,7 @@ class OnlineContext(PydanticBaseModel):
answerBox: Optional[AnswerBox] = None
peopleAlsoAsk: Optional[List[PeopleAlsoAsk]] = None
knowledgeGraph: Optional[KnowledgeGraph] = None
organicContext: Optional[List[OrganicContext]] = None
organic: Optional[List[OrganicContext]] = None
class Intent(PydanticBaseModel):