Add sort by likesRecent to improve discoverability

#1
by multimodalart HF staff - opened
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -66,7 +66,7 @@ async def upload_resize_image_url(session, image_url):
66
 
67
  def fetch_models(page=0):
68
  response = requests.get(
69
- f'https://huggingface.co/models-json?pipeline_tag=text-to-image&p={page}')
70
  data = response.json()
71
  return {
72
  "models": [model for model in data['models'] if not model['private']],
 
66
 
67
  def fetch_models(page=0):
68
  response = requests.get(
69
+ f'https://huggingface.co/models-json?pipeline_tag=text-to-image&sort=likesRecent&p={page}')
70
  data = response.json()
71
  return {
72
  "models": [model for model in data['models'] if not model['private']],