Publish and manage research papers on Hugging Face Hub. Supports creating paper pages, linking papers to models/datasets, claiming authorship, and generating professional markdown-based research articles.
Add this skill
npx mdskills install huggingface/hugging-face-paper-publisherComprehensive research paper publishing toolset with clear instructions and multiple integrated workflows
1---2name: hugging-face-paper-publisher3description: Publish and manage research papers on Hugging Face Hub. Supports creating paper pages, linking papers to models/datasets, claiming authorship, and generating professional markdown-based research articles.4---56# Overview7This skill provides comprehensive tools for AI engineers and researchers to publish, manage, and link research papers on the Hugging Face Hub. It streamlines the workflow from paper creation to publication, including integration with arXiv, model/dataset linking, and authorship management.89## Integration with HF Ecosystem10- **Paper Pages**: Index and discover papers on Hugging Face Hub11- **arXiv Integration**: Automatic paper indexing from arXiv IDs12- **Model/Dataset Linking**: Connect papers to relevant artifacts through metadata13- **Authorship Verification**: Claim and verify paper authorship14- **Research Article Template**: Generate professional, modern scientific papers1516# Version171.0.01819# Dependencies20- huggingface_hub>=0.26.021- pyyaml>=6.0.322- requests>=2.32.523- markdown>=3.5.024- python-dotenv>=1.2.12526# Core Capabilities2728## 1. Paper Page Management29- **Index Papers**: Add papers to Hugging Face from arXiv30- **Claim Authorship**: Verify and claim authorship on published papers31- **Manage Visibility**: Control which papers appear on your profile32- **Paper Discovery**: Find and explore papers in the HF ecosystem3334## 2. Link Papers to Artifacts35- **Model Cards**: Add paper citations to model metadata36- **Dataset Cards**: Link papers to datasets via README37- **Automatic Tagging**: Hub auto-generates arxiv:<PAPER_ID> tags38- **Citation Management**: Maintain proper attribution and references3940## 3. Research Article Creation41- **Markdown Templates**: Generate professional paper formatting42- **Modern Design**: Clean, readable research article layouts43- **Dynamic TOC**: Automatic table of contents generation44- **Section Structure**: Standard scientific paper organization45- **LaTeX Math**: Support for equations and technical notation4647## 4. Metadata Management48- **YAML Frontmatter**: Proper model/dataset card metadata49- **Citation Tracking**: Maintain paper references across repositories50- **Version Control**: Track paper updates and revisions51- **Multi-Paper Support**: Link multiple papers to single artifacts5253# Usage Instructions5455The skill includes Python scripts in `scripts/` for paper publishing operations.5657### Prerequisites58- Install dependencies: `uv add huggingface_hub pyyaml requests markdown python-dotenv`59- Set `HF_TOKEN` environment variable with Write-access token60- Activate virtual environment: `source .venv/bin/activate`6162> **All paths are relative to the directory containing this SKILL.md63file.**64> Before running any script, first `cd` to that directory or use the full65path.666768### Method 1: Index Paper from arXiv6970Add a paper to Hugging Face Paper Pages from arXiv.7172**Basic Usage:**73```bash74uv run scripts/paper_manager.py index \75 --arxiv-id "2301.12345"76```7778**Check If Paper Exists:**79```bash80uv run scripts/paper_manager.py check \81 --arxiv-id "2301.12345"82```8384**Direct URL Access:**85You can also visit `https://huggingface.co/papers/{arxiv-id}` directly to index a paper.8687### Method 2: Link Paper to Model/Dataset8889Add paper references to model or dataset README with proper YAML metadata.9091**Add to Model Card:**92```bash93uv run scripts/paper_manager.py link \94 --repo-id "username/model-name" \95 --repo-type "model" \96 --arxiv-id "2301.12345"97```9899**Add to Dataset Card:**100```bash101uv run scripts/paper_manager.py link \102 --repo-id "username/dataset-name" \103 --repo-type "dataset" \104 --arxiv-id "2301.12345"105```106107**Add Multiple Papers:**108```bash109uv run scripts/paper_manager.py link \110 --repo-id "username/model-name" \111 --repo-type "model" \112 --arxiv-ids "2301.12345,2302.67890,2303.11111"113```114115**With Custom Citation:**116```bash117uv run scripts/paper_manager.py link \118 --repo-id "username/model-name" \119 --repo-type "model" \120 --arxiv-id "2301.12345" \121 --citation "$(cat citation.txt)"122```123124#### How Linking Works125126When you add an arXiv paper link to a model or dataset README:1271. The Hub extracts the arXiv ID from the link1282. A tag `arxiv:<PAPER_ID>` is automatically added to the repository1293. Users can click the tag to view the Paper Page1304. The Paper Page shows all models/datasets citing this paper1315. Papers are discoverable through filters and search132133### Method 3: Claim Authorship134135Verify your authorship on papers published on Hugging Face.136137**Start Claim Process:**138```bash139uv run scripts/paper_manager.py claim \140 --arxiv-id "2301.12345" \141 --email "your.email@institution.edu"142```143144**Manual Process:**1451. Navigate to your paper's page: `https://huggingface.co/papers/{arxiv-id}`1462. Find your name in the author list1473. Click your name and select "Claim authorship"1484. Wait for admin team verification149150**Check Authorship Status:**151```bash152uv run scripts/paper_manager.py check-authorship \153 --arxiv-id "2301.12345"154```155156### Method 4: Manage Paper Visibility157158Control which verified papers appear on your public profile.159160**List Your Papers:**161```bash162uv run scripts/paper_manager.py list-my-papers163```164165**Toggle Visibility:**166```bash167uv run scripts/paper_manager.py toggle-visibility \168 --arxiv-id "2301.12345" \169 --show true170```171172**Manage in Settings:**173Navigate to your account settings → Papers section to toggle "Show on profile" for each paper.174175### Method 5: Create Research Article176177Generate a professional markdown-based research paper using modern templates.178179**Create from Template:**180```bash181uv run scripts/paper_manager.py create \182 --template "standard" \183 --title "Your Paper Title" \184 --output "paper.md"185```186187**Available Templates:**188- `standard` - Traditional scientific paper structure189- `modern` - Clean, web-friendly format inspired by Distill190- `arxiv` - arXiv-style formatting191- `ml-report` - Machine learning experiment report192193**Generate Complete Paper:**194```bash195uv run scripts/paper_manager.py create \196 --template "modern" \197 --title "Fine-Tuning Large Language Models with LoRA" \198 --authors "Jane Doe, John Smith" \199 --abstract "$(cat abstract.txt)" \200 --output "paper.md"201```202203**Convert to HTML:**204```bash205uv run scripts/paper_manager.py convert \206 --input "paper.md" \207 --output "paper.html" \208 --style "modern"209```210211### Paper Template Structure212213**Standard Research Paper Sections:**214```markdown215---216title: Your Paper Title217authors: Jane Doe, John Smith218affiliations: University X, Lab Y219date: 2025-01-15220arxiv: 2301.12345221tags: [machine-learning, nlp, fine-tuning]222---223224# Abstract225Brief summary of the paper...226227# 1. Introduction228Background and motivation...229230# 2. Related Work231Previous research and context...232233# 3. Methodology234Approach and implementation...235236# 4. Experiments237Setup, datasets, and procedures...238239# 5. Results240Findings and analysis...241242# 6. Discussion243Interpretation and implications...244245# 7. Conclusion246Summary and future work...247248# References249```250251**Modern Template Features:**252- Dynamic table of contents253- Responsive design for web viewing254- Code syntax highlighting255- Interactive figures and charts256- Math equation rendering (LaTeX)257- Citation management258- Author affiliation linking259260### Commands Reference261262**Index Paper:**263```bash264uv run scripts/paper_manager.py index --arxiv-id "2301.12345"265```266267**Link to Repository:**268```bash269uv run scripts/paper_manager.py link \270 --repo-id "username/repo-name" \271 --repo-type "model|dataset|space" \272 --arxiv-id "2301.12345" \273 [--citation "Full citation text"] \274 [--create-pr]275```276277**Claim Authorship:**278```bash279uv run scripts/paper_manager.py claim \280 --arxiv-id "2301.12345" \281 --email "your.email@edu"282```283284**Manage Visibility:**285```bash286uv run scripts/paper_manager.py toggle-visibility \287 --arxiv-id "2301.12345" \288 --show true|false289```290291**Create Research Article:**292```bash293uv run scripts/paper_manager.py create \294 --template "standard|modern|arxiv|ml-report" \295 --title "Paper Title" \296 [--authors "Author1, Author2"] \297 [--abstract "Abstract text"] \298 [--output "filename.md"]299```300301**Convert Markdown to HTML:**302```bash303uv run scripts/paper_manager.py convert \304 --input "paper.md" \305 --output "paper.html" \306 [--style "modern|classic"]307```308309**Check Paper Status:**310```bash311uv run scripts/paper_manager.py check --arxiv-id "2301.12345"312```313314**List Your Papers:**315```bash316uv run scripts/paper_manager.py list-my-papers317```318319**Search Papers:**320```bash321uv run scripts/paper_manager.py search --query "transformer attention"322```323324### YAML Metadata Format325326When linking papers to models or datasets, proper YAML frontmatter is required:327328**Model Card Example:**329```yaml330---331language:332 - en333license: apache-2.0334tags:335 - text-generation336 - transformers337 - llm338library_name: transformers339---340341# Model Name342343This model is based on the approach described in [Our Paper](https://arxiv.org/abs/2301.12345).344345## Citation346347```bibtex348@article{doe2023paper,349 title={Your Paper Title},350 author={Doe, Jane and Smith, John},351 journal={arXiv preprint arXiv:2301.12345},352 year={2023}353}354```355```356357**Dataset Card Example:**358```yaml359---360language:361 - en362license: cc-by-4.0363task_categories:364 - text-generation365 - question-answering366size_categories:367 - 10K<n<100K368---369370# Dataset Name371372Dataset introduced in [Our Paper](https://arxiv.org/abs/2301.12345).373374For more details, see the [paper page](https://huggingface.co/papers/2301.12345).375```376377The Hub automatically extracts arXiv IDs from these links and creates `arxiv:2301.12345` tags.378379### Integration Examples380381**Workflow 1: Publish New Research**382```bash383# 1. Create research article384uv run scripts/paper_manager.py create \385 --template "modern" \386 --title "Novel Fine-Tuning Approach" \387 --output "paper.md"388389# 2. Edit paper.md with your content390391# 3. Submit to arXiv (external process)392# Upload to arxiv.org, get arXiv ID393394# 4. Index on Hugging Face395uv run scripts/paper_manager.py index --arxiv-id "2301.12345"396397# 5. Link to your model398uv run scripts/paper_manager.py link \399 --repo-id "your-username/your-model" \400 --repo-type "model" \401 --arxiv-id "2301.12345"402403# 6. Claim authorship404uv run scripts/paper_manager.py claim \405 --arxiv-id "2301.12345" \406 --email "your.email@edu"407```408409**Workflow 2: Link Existing Paper**410```bash411# 1. Check if paper exists412uv run scripts/paper_manager.py check --arxiv-id "2301.12345"413414# 2. Index if needed415uv run scripts/paper_manager.py index --arxiv-id "2301.12345"416417# 3. Link to multiple repositories418uv run scripts/paper_manager.py link \419 --repo-id "username/model-v1" \420 --repo-type "model" \421 --arxiv-id "2301.12345"422423uv run scripts/paper_manager.py link \424 --repo-id "username/training-data" \425 --repo-type "dataset" \426 --arxiv-id "2301.12345"427428uv run scripts/paper_manager.py link \429 --repo-id "username/demo-space" \430 --repo-type "space" \431 --arxiv-id "2301.12345"432```433434**Workflow 3: Update Model with Paper Reference**435```bash436# 1. Get current README437huggingface-cli download username/model-name README.md438439# 2. Add paper link440uv run scripts/paper_manager.py link \441 --repo-id "username/model-name" \442 --repo-type "model" \443 --arxiv-id "2301.12345" \444 --citation "Full citation for the paper"445446# The script will:447# - Add YAML metadata if missing448# - Insert arXiv link in README449# - Add formatted citation450# - Preserve existing content451```452453### Best Practices4544551. **Paper Indexing**456 - Index papers as soon as they're published on arXiv457 - Include full citation information in model/dataset cards458 - Use consistent paper references across related repositories4594602. **Metadata Management**461 - Add YAML frontmatter to all model/dataset cards462 - Include proper licensing information463 - Tag with relevant task categories and domains4644653. **Authorship**466 - Claim authorship on papers where you're listed as author467 - Use institutional email addresses for verification468 - Keep paper visibility settings updated4694704. **Repository Linking**471 - Link papers to all relevant models, datasets, and Spaces472 - Include paper context in README descriptions473 - Add BibTeX citations for easy reference4744755. **Research Articles**476 - Use templates consistently within projects477 - Include code and data links in papers478 - Generate web-friendly HTML versions for sharing479480### Advanced Usage481482**Batch Link Papers:**483```bash484# Link multiple papers to one repository485for arxiv_id in "2301.12345" "2302.67890" "2303.11111"; do486 uv run scripts/paper_manager.py link \487 --repo-id "username/model-name" \488 --repo-type "model" \489 --arxiv-id "$arxiv_id"490done491```492493**Extract Paper Info:**494```bash495# Get paper metadata from arXiv496uv run scripts/paper_manager.py info \497 --arxiv-id "2301.12345" \498 --format "json"499```500501**Generate Citation:**502```bash503# Create BibTeX citation504uv run scripts/paper_manager.py citation \505 --arxiv-id "2301.12345" \506 --format "bibtex"507```508509**Validate Links:**510```bash511# Check all paper links in a repository512uv run scripts/paper_manager.py validate \513 --repo-id "username/model-name" \514 --repo-type "model"515```516517### Error Handling518519- **Paper Not Found**: arXiv ID doesn't exist or isn't indexed yet520- **Permission Denied**: HF_TOKEN lacks write access to repository521- **Invalid YAML**: Malformed metadata in README frontmatter522- **Authorship Failed**: Email doesn't match paper author records523- **Already Claimed**: Another user has claimed authorship524- **Rate Limiting**: Too many API requests in short time525526### Troubleshooting527528**Issue**: "Paper not found on Hugging Face"529- **Solution**: Visit `hf.co/papers/{arxiv-id}` to trigger indexing530531**Issue**: "Authorship claim not verified"532- **Solution**: Wait for admin review or contact HF support with proof533534**Issue**: "arXiv tag not appearing"535- **Solution**: Ensure README includes proper arXiv URL format536537**Issue**: "Cannot link to repository"538- **Solution**: Verify HF_TOKEN has write permissions539540**Issue**: "Template rendering errors"541- **Solution**: Check markdown syntax and YAML frontmatter format542543### Resources and References544545- **Hugging Face Paper Pages**: [hf.co/papers](https://huggingface.co/papers)546- **Model Cards Guide**: [hf.co/docs/hub/model-cards](https://huggingface.co/docs/hub/en/model-cards)547- **Dataset Cards Guide**: [hf.co/docs/hub/datasets-cards](https://huggingface.co/docs/hub/en/datasets-cards)548- **Research Article Template**: [tfrere/research-article-template](https://huggingface.co/spaces/tfrere/research-article-template)549- **arXiv Format Guide**: [arxiv.org/help/submit](https://arxiv.org/help/submit)550551### Integration with tfrere's Research Template552553This skill complements [tfrere's research article template](https://huggingface.co/spaces/tfrere/research-article-template) by providing:554555- Automated paper indexing workflows556- Repository linking capabilities557- Metadata management tools558- Citation generation utilities559560You can use tfrere's template for writing, then use this skill to publish and link the paper on Hugging Face Hub.561562### Common Patterns563564**Pattern 1: New Paper Publication**565```bash566# Write → Publish → Index → Link567uv run scripts/paper_manager.py create --template modern --output paper.md568# (Submit to arXiv)569uv run scripts/paper_manager.py index --arxiv-id "2301.12345"570uv run scripts/paper_manager.py link --repo-id "user/model" --arxiv-id "2301.12345"571```572573**Pattern 2: Existing Paper Discovery**574```bash575# Search → Check → Link576uv run scripts/paper_manager.py search --query "transformers"577uv run scripts/paper_manager.py check --arxiv-id "2301.12345"578uv run scripts/paper_manager.py link --repo-id "user/model" --arxiv-id "2301.12345"579```580581**Pattern 3: Author Portfolio Management**582```bash583# Claim → Verify → Organize584uv run scripts/paper_manager.py claim --arxiv-id "2301.12345"585uv run scripts/paper_manager.py list-my-papers586uv run scripts/paper_manager.py toggle-visibility --arxiv-id "2301.12345" --show true587```588589### API Integration590591**Python Script Example:**592```python593from scripts.paper_manager import PaperManager594595pm = PaperManager(hf_token="your_token")596597# Index paper598pm.index_paper("2301.12345")599600# Link to model601pm.link_paper(602 repo_id="username/model",603 repo_type="model",604 arxiv_id="2301.12345",605 citation="Full citation text"606)607608# Check status609status = pm.check_paper("2301.12345")610print(status)611```612613### Future Enhancements614615Planned features for future versions:616- Support for non-arXiv papers (conference proceedings, journals)617- Automatic citation formatting from DOI618- Paper comparison and versioning tools619- Collaborative paper writing features620- Integration with LaTeX workflows621- Automated figure and table extraction622- Paper metrics and impact tracking623
Full transparency — inspect the skill content before installing.