openedx / openedx/openedx-ai-extensions

Fix: Reconstruct chat thread based on chat history saved in submissions

Open
#238 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
17
Forks
11
Avg merge
5h 33m
Merged PRs (30d)
4

Description

Currently OpenAI (And some other providers) have previous_response_id which we can keep the thread of the conversation, but this id has expiration of 30 days, the idea of this fix is first check if the key expired. if do, reconstruct the whole conversation in input_messages and store the new response_id.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by locating the provider code that handles previous_response_id and the submission data containing chat history. Trace how expiration is detected and how input_messages and the new response_id are stored; done means expired threads are reconstructed from saved history while valid threads continue normally.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
ai, backend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
58/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.