Describe the bug
OpenAI assistant may find multiple references in the same file. However we currently just support a single file reference. This causes an issue where we may see [1][1] in the output.
5. **Output Generation**: The final output for each input element is computed as a weighted sum of the value vectors, using the attention weights. This produces an output that reflects the relevant contexts derived from all elements in the sequence[1][1].
To Reproduce
Generate a message which cites multiple sections of the same document
Expected behavior
There should be a single document-level citation for a chunk of text
Environment
Additional context / Screenshots
This is a little tricky to resolve because we only see one at a time during streaming. We only see this after the text has been collected. Using regex may have unintended consequences. May need to explore more advanced processing in the stream handler.
Describe the bug
OpenAI assistant may find multiple references in the same file. However we currently just support a single file reference. This causes an issue where we may see
[1][1]in the output.To Reproduce
Generate a message which cites multiple sections of the same document
Expected behavior
There should be a single document-level citation for a chunk of text
Environment
Additional context / Screenshots
This is a little tricky to resolve because we only see one at a time during streaming. We only see this after the text has been collected. Using regex may have unintended consequences. May need to explore more advanced processing in the stream handler.