Skip to content

feat(scholar): Add comprehensive citation style management #141

@ywatanabe1989

Description

@ywatanabe1989

Summary

Add comprehensive citation style management to scitex.scholar module for formatting paper metadata in various academic citation styles.

Current State

  • Work.citation(style='apa') method exists in crossref_scitex but limited
  • No centralized citation formatting utilities
  • Relies on local crossref database which may not always be available

Proposed Features

1. Citation Style Support

Support common academic citation styles:

  • APA (7th edition) - Psychology, Education, Social Sciences
  • MLA (9th edition) - Humanities
  • Chicago (Author-Date) - Sciences, Social Sciences
  • IEEE - Engineering, Computer Science
  • Vancouver - Medicine, Biology
  • Harvard - General academic

2. API Design

from scitex.scholar import citation

# Format from DOI
citation.format("10.1038/nature12373", style="apa")
# Output: "Author, A. B., & Author, C. D. (2023). Title of article. Journal Name, 12(3), 45-67. https://doi.org/10.1038/nature12373"

# Format from Work object
work = crossref_scitex.get("10.1038/nature12373")
citation.format(work, style="ieee")

# Batch formatting
citations = citation.format_batch(doi_list, style="vancouver")

# List available styles
citation.list_styles()  # ['apa', 'mla', 'chicago', 'ieee', 'vancouver', 'harvard']

3. Integration Points

  • crossref_scitex.Work.citation() - already exists, enhance it
  • openalex_scitex - add same functionality
  • stx.scholar.Paper - unify citation formatting

Use Cases

  1. Publications page on scitex-cloud needs consistent citation display
  2. Manuscript writing with proper bibliography formatting
  3. Export citations for reference managers

Related

  • Used by: scitex-cloud/apps/public_app/views/pages.py (publications page)
  • Module: scitex.scholar.local_dbs.crossref_scitex

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions