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

Display instrument to instrument similarities in front end #43

Open
woodthom2 opened this issue Jan 25, 2025 · 2 comments
Open

Display instrument to instrument similarities in front end #43

woodthom2 opened this issue Jan 25, 2025 · 2 comments
Labels
enhancement New feature or request good first issue Good for newcomers

Comments

@woodthom2
Copy link
Contributor

Description

The API is now calculating an instrument to instrument similarity. e.g. the GAD-7 is e.g. 60% similar to the PHQ-9
See this PR for more details: harmonydata/harmony#81

Please can we display them in a nice way in the UI

You can see this in the call to /text/match, e.g.:

curl -X 'POST' \
  'http://localhost:8000/text/match?include_catalogue_matches=false&is_negate=true' \
  -H 'accept: application/json' \
  -H 'Content-Type: application/json' \
  -d '{
  "instruments": [
    {
      
      "questions": [
        {
          "question_text": "Feeling nervous, anxious, or on edge"
        },
        {
          "question_text": "Not being able to stop or control worrying"
        }
      ]
    },
    {
      "questions": [
        {
          "question_text": "Sentir-se nervoso/a, ansioso/a ou muito tenso/a"
        },
        {
          "question_text": " Não ser capaz de impedir ou de controlar as preocupações"
        }
      ]
    }
  ]
}'
{
  "instruments": [
  
///... ///
    }
  ],
   "instrument_to_instrument_similarities": [
    {
      "instrument_1_idx": 0,
      "instrument_2_idx": 1,
      "instrument_1_name": "GAD-7 English",
      "instrument_2_name": "GAD-7 Portuguese",
      "precision": 1,
      "recall": 1,
      "f1": 1
    }
  ],
...

Rationale

Many users have requested this feature.

@ronnyTodgers
Copy link
Collaborator

Looks really good! so we'd want an instrument view displaying instrument to instrument, should this be primary do you think?

@woodthom2
Copy link
Contributor Author

woodthom2 commented Jan 25, 2025 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

2 participants