Skip to content

Regenerate API documentation and standardise Google-style docstrings#283

Merged
harryswift01 merged 4 commits intomainfrom
282-docs-regenerate-documentation
Feb 26, 2026
Merged

Regenerate API documentation and standardise Google-style docstrings#283
harryswift01 merged 4 commits intomainfrom
282-docs-regenerate-documentation

Conversation

@harryswift01
Copy link
Member

Summary

This PR regenerates the API documentation following the recent internal restructuring of CodeEntropy and standardises all docstrings to Google-style format. It also resolves multiple Sphinx build warnings and introduces tooling to prevent future documentation regressions.

Changes

Documentation Regeneration

  • Regenerated autosummary API documentation to reflect the new package structure.
  • Replaced legacy docs/api.rst with generated docs/api/ module pages.
  • Updated index.rst and FAQ references to align with the new layout.

Docstring Standardisation

  • Migrated docstrings across core modules to Google-style format.
  • Fixed reStructuredText formatting issues causing Sphinx warnings:
    • bullet list spacing
    • literal block indentation
    • definition list termination
    • unexpected indentation errors
  • Updated documentation across:
    • entropy modules
    • levels modules
    • molecules
    • workflow
    • results reporting

Tooling & CI Improvements

  • Updated conf.py to fully support Google-style docstrings via napoleon.
  • Added rstcheck to pre-commit for docstring validation.
  • Configured pre-push Sphinx build to fail on warnings.
  • Updated CI docs job to enforce warnings-as-errors.
  • Ensured Ruff compatibility with formatted docstring blocks.

Impact

  • Documentation now builds cleanly without warnings.
  • API docs are aligned with the current internal architecture.
  • Future documentation formatting regressions are caught locally before push.
  • CI now enforces documentation correctness as a quality gate.

@harryswift01 harryswift01 added this to the v1.1.0 milestone Feb 26, 2026
@harryswift01 harryswift01 requested a review from jimboid February 26, 2026 13:59
@harryswift01 harryswift01 self-assigned this Feb 26, 2026
@harryswift01 harryswift01 added bug Something isn't working documentation Improvements or additions to documentation labels Feb 26, 2026
@harryswift01 harryswift01 linked an issue Feb 26, 2026 that may be closed by this pull request
@harryswift01 harryswift01 changed the title docs: regenerate API docs and fix Google-style docstrings for Sphinx Regenerate API documentation and standardise Google-style docstrings Feb 26, 2026
Copy link
Member

@jimboid jimboid left a comment

Choose a reason for hiding this comment

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

An important iteration on the API, keeping it updated with the codebase until we redesign the interface later. The docstrings being standardised is a great step to keeping the code in a maintainable state. The proper naming of CI is a nice addition here too which helps to keep things understandable in the process side of things. Please go ahead and merge.

@harryswift01 harryswift01 merged commit ce4a101 into main Feb 26, 2026
25 of 26 checks passed
@harryswift01 harryswift01 deleted the 282-docs-regenerate-documentation branch February 26, 2026 16:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working documentation Improvements or additions to documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Docs]: Regenerate Documentation Following Package Refactor

2 participants