Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 16 additions & 0 deletions docs/hub/api.md
Original file line number Diff line number Diff line change
Expand Up @@ -462,6 +462,22 @@ Get the daily papers curated by AK and the community. It's the equivalent of [ht

To filter on a particular date, simply pass the date like so: https://huggingface.co/api/daily_papers?date=2025-03-31.

Other keywords that are supported:

1. `limit` - the number of pages returned
Copy link
Contributor

Choose a reason for hiding this comment

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

as in length of the paper or number of papers returned?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Oops, yeah that's what it should say.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I updated it

2. `p` - the page number, for paging through results
3. `submitter` - to filter by summitter
4. `date`, `week`, `month` - for filtering by date range
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
4. `date`, `week`, `month` - for filtering by date range
4. `date`, `week`, `month` - for filtering by date range

of the paper release dates?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I didn't create the API, and it's not clear to me from the openapi docs. It could be either the paper release date, or the day it was featured on Daily Papers.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

According to DeepWiki

The date parameter refers to when the paper was included in the daily papers on the Hub, not when it was written or originally submitted to arXiv. hf_api.py:1527-1528

This is confirmed by the PaperInfo dataclass, which has two distinct date fields:

published_at: The date the paper was published (on arXiv) hf_api.py:1513-1514
submitted_at: The date the paper appeared in daily papers on the Hub hf_api.py:1527-1528|

I will update it according to that.

Copy link
Member

Choose a reason for hiding this comment

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

I can confirm it's the publishedAt property (internal link). Somewhat related PR: #1878.

5. `sort` - to specify how results are sorted.
Copy link
Contributor

Choose a reason for hiding this comment

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

how can they be sorted? by date or?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

From the openapi docs:

sortCopy link to sort
enum
default: 
"publishedAt"
publishedAt
trending

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I updated this as well


See the [OpenAPI Playground for Daily Papers](https://huggingface-openapi.hf.space/#tag/papers) for the full list of params.

### GET /api/papers/search

Search the daily papers by keyword:

1. `q` - the keyword to search
Copy link
Contributor

Choose a reason for hiding this comment

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

this seems standalone so no need to number I think

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Agreed


## Collections API

Use Collections to group repositories from the Hub (Models, Datasets, Spaces and Papers) on a dedicated page.
Expand Down