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

ML Hub models api calls #364

Merged
merged 16 commits into from
Apr 26, 2024
Merged

ML Hub models api calls #364

merged 16 commits into from
Apr 26, 2024

Conversation

dhannywi
Copy link
Collaborator

Overview:

Related Github Issues:

Summary of Changes:

Created API calls in tapis-api and hooks in tapis-hooks for the following functionalities:

  • listing 100 top downloaded ML models
  • detailed info on a specific model
  • inference server availability for a given model
  • list models by author
  • list models by tasks
  • generate download links for a model
  • search using query
  • list models by trained datasets
  • list models by libraries
  • list models by languages

Testing Steps:

UI Photos:

Notes:

@dhannywi dhannywi requested a review from nathandf April 26, 2024 14:36
@dhannywi dhannywi self-assigned this Apr 26, 2024
Copy link
Collaborator

Choose a reason for hiding this comment

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

Can we rename this file something semantically closer to the purpose of this function ( fetching inference server details for a given model) and/or what it returns? 1. inferenceAvailable sounds like it should return a boolean value. 2. Knowing whether an inference server is available is secondary information that we can derive from the value of the result. I recommend something like src/tapis-api/models/inference-servers/details.ts

import { Models } from '@tapis/tapis-typescript';
import { apiGenerator, errorDecoder } from 'tapis-api/utils';

const downloadLinks = (
Copy link
Collaborator

Choose a reason for hiding this comment

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

Same as the comment above, this should be called something like details. The name of the function should be the same as the name of the file.

const QueryKeys = {
list: 'ml-hub/models/list',
details: 'ml-hub/models/details',
downloadLinks: 'ml-hub/models/downloadLinks',
Copy link
Collaborator

Choose a reason for hiding this comment

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

Perhaps inferenceServerDetails: 'ml-hub/models/inferenceServerDetails'

@nathandf nathandf merged commit 4d9f73b into dev Apr 26, 2024
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants