Skip to content

fix: assertion for test_find_context_attributions and range for hallucination detection#779

Open
jakelorocco wants to merge 2 commits intomainfrom
jal/ca-test
Open

fix: assertion for test_find_context_attributions and range for hallucination detection#779
jakelorocco wants to merge 2 commits intomainfrom
jal/ca-test

Conversation

@jakelorocco
Copy link
Copy Markdown
Contributor

@jakelorocco jakelorocco commented Apr 2, 2026

Misc PR

Type of PR

  • Bug Fix
  • New Feature
  • Documentation
  • Other

Description

There's some nondeterminism in the context-attributions intrinsic. Limit the check to just the first 7 results to prevent erroneous errors. There's also some nondeterminism in the output for hallucination detection. Slightly increased the range to make the tests more flexible while still ensuring they test.

Testing

  • Tests added to the respective file if code was changed
  • New code has 100% coverage if code as added
  • Ensure existing tests and github automation passes (a maintainer will kick off the github automation when the rest of the PR is populated)

@github-actions github-actions bot added the bug Something isn't working label Apr 2, 2026
@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Apr 2, 2026

The PR description has been updated. Please fill out the template for your PR to be reviewed.

@jakelorocco jakelorocco changed the title fix: assertion for test_find_context_attributions fix: assertion for test_find_context_attributions and range for hallucination detection Apr 3, 2026
@jakelorocco jakelorocco marked this pull request as ready for review April 3, 2026 13:35
@jakelorocco jakelorocco requested a review from a team as a code owner April 3, 2026 13:35
Copy link
Copy Markdown
Member

@psschwei psschwei left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

test_find_context_attributions failing due to mismatched results / expected

2 participants