Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mismatch between TokenAttributions model and UI #1248

Closed
dcfidalgo opened this issue Mar 11, 2022 · 1 comment · Fixed by #1424
Closed

Mismatch between TokenAttributions model and UI #1248

dcfidalgo opened this issue Mar 11, 2022 · 1 comment · Fixed by #1424
Assignees
Labels
area: ui Indicates that an issue or pull request is related to the User Interface (UI) type: bug Indicates an unexpected problem or unintended behavior
Projects

Comments

@dcfidalgo
Copy link
Contributor

Describe the bug
The TokenAttributions model accepts multiple label-attribution pairs, while the UI can only handle one.

To Reproduce
Steps to reproduce the behavior:

import rubrix as rb

record = rb.TextClassificationRecord(
    inputs="mock",
    prediction=[("POSITIVE", 0.9), ("NEGATIVE", 0.1)],
    explanation={"text": [
        rb.TokenAttributions(
            token="mock", attributions={"POSITIVE": 0.5, "NEGATIVE": -0.5}
        )
    ]},
)

Expected behavior
Maybe for now the model should only accept one label-attribution pair, or the UI should be able to handle various.

Environment (please complete the following information):

  • OS [e.g. iOS]: Ubuntu
  • Browser [e.g. chrome, safari]: firefox
  • Rubrix Version [e.g. 0.10.0]: master
  • ElasticSearch Version [e.g. 7.10.2]: 7.10.2
  • Docker Image (optional) [e.g. rubrix:v0.10.0]:
@dcfidalgo dcfidalgo added the type: bug Indicates an unexpected problem or unintended behavior label Mar 11, 2022
@dcfidalgo
Copy link
Contributor Author

@frascuchon @leiyre

@dcfidalgo dcfidalgo added this to Backlog in Release via automation Mar 11, 2022
@frascuchon frascuchon moved this from Backlog to Planified in Release Mar 14, 2022
@frascuchon frascuchon added the area: ui Indicates that an issue or pull request is related to the User Interface (UI) label Mar 31, 2022
leiyre added a commit that referenced this issue Apr 20, 2022
fix #1248

This PR gets prediction from label attribution list to display the explain
@frascuchon frascuchon moved this from Planified to In progress in Release Apr 20, 2022
@frascuchon frascuchon moved this from In progress to Pending Review in Release Apr 20, 2022
Release automation moved this from Pending Review to Ready to DEV QA Apr 21, 2022
@frascuchon frascuchon moved this from Ready to DEV QA to Ready to Release QA in Release Apr 25, 2022
frascuchon pushed a commit that referenced this issue Apr 25, 2022
@leiyre leiyre moved this from Ready to Release QA to Approved Release QA in Release Apr 26, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: ui Indicates that an issue or pull request is related to the User Interface (UI) type: bug Indicates an unexpected problem or unintended behavior
Projects
No open projects
Release
Approved Release QA
Development

Successfully merging a pull request may close this issue.

3 participants