You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Bug: response_end span in granite33 uses full response length instead of sentence length #843
response_text is the individual sentence associated with this citation (looked up from response_sents_by_citation_id)
response_text_without_citations is the entire response with all citation tags stripped
index is where the individual sentence starts within the full response
So response_end ends up being (start of sentence) + (length of entire response), which will always overshoot past the end of the actual sentence — potentially past the end of the string entirely.
Impact: Every citation span in granite 3.3 output will have a response_end that points to roughly the end of the full response rather than the end of the cited sentence. Downstream consumers that slice response[begin:end] would get a much larger substring than intended.
The granite32 equivalent at granite3/granite32/output.py:292-293 is correct and can be used as reference. Add a regression test in test/formatters/granite/test_granite33_output.py.
Activity
planetf1 commentedon Apr 13, 2026
Fix reference for agents:
mellea/formatters/granite/granite3/granite33/output.py:227— change:to:
The granite32 equivalent at
granite3/granite32/output.py:292-293is correct and can be used as reference. Add a regression test intest/formatters/granite/test_granite33_output.py.fix: granite33 response_end span uses sentence length not full respon…
fix: granite33 response_end span uses sentence length not full respon…
test: add regression tests for granite33 citation response_end span (…
fix: granite33 response_end span uses sentence length not full respon… (
fix: granite33 response_end span uses sentence length not full respon… (