aiondemand / AIOD-rest-api

A containerized application using FastAPI and SQLAlchemy connected to a MySQL database.
MIT License
10 stars 7 forks source link

Invalid platform_resource_identifier error for some huggingface datasets (when using GET endpoint) #318

Closed Taniya-Das closed 1 month ago

Taniya-Das commented 2 months ago

Using GET /platforms/{platform}/datasets/v1 end point of REST API, some hugging face datasets produce a validation error:

'{"detail":"Unexpected exception while processing your request. Please contact the maintainers: 1 validation error for DatasetRead\\nplatform_resource_identifier\\n The platform_resource_identifier for HuggingFace should be a valid repo_id. A repo_id should be between 1 and 96 characters. (type=value_error)"}'.

Taniya-Das commented 2 months ago

There is an error in our implementation of hugging face validator, clarified here - https://github.com/huggingface/huggingface_hub/issues/2289 The 96-characters limit is on the repo name, not the repo id. In general, the repo_id is composed of "namespace/repo_name.

Taniya-Das commented 1 month ago

Resolved in https://github.com/aiondemand/AIOD-rest-api/pull/330