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

Support calculating X annotations over Y datasets in the v2 api #1333

Open
jgadling opened this issue Nov 7, 2024 · 0 comments
Open

Support calculating X annotations over Y datasets in the v2 api #1333

jgadling opened this issue Nov 7, 2024 · 0 comments
Labels
backend P2 Could have

Comments

@jgadling
Copy link
Contributor

jgadling commented Nov 7, 2024

The frontend needs to display a statistic that calculates the number of datasets that have annotations for a given deposition. Right now the frontend is using this query:

query MyQuery {
  depositions {
    num_per_dataset: annotationsAggregate {
      aggregate {
        count
        groupBy {
          run {
            dataset {
              id
            }
          }
        }
      }
    }
  }
}

and uses aggregate.length to get the necessary, but we should determine if there's a better way to support this feature. Can/should we add more powerful aggregate functionality to the api in general? Should we make this a one-off special case?

@manasaV3 manasaV3 added the P2 Could have label Nov 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backend P2 Could have
Projects
None yet
Development

No branches or pull requests

2 participants