Skip to content

docs: add documentation comments to JSON schema types#1756

Closed
ivan-aksamentov wants to merge 17 commits intomasterfrom
docs/schema-docs
Closed

docs: add documentation comments to JSON schema types#1756
ivan-aksamentov wants to merge 17 commits intomasterfrom
docs/schema-docs

Conversation

@ivan-aksamentov
Copy link
Copy Markdown
Member

Add comprehensive doc comments to Rust structs used for JSON schema generation, improving documentation quality for pathogen.json configuration, dataset index structures, QC rules, output formats, and Auspice tree extensions. The doc comments propagate to generated JSON/YAML schema files via schemars, making schemas self-documenting for dataset authors and API consumers.

  • Add doc comments to output structs (NextcladeOutputs, ResultsJson, NextcladeErrorOutputs)
  • Add doc comments to QC config and result structs
  • Add doc comments to dataset index types with examples
  • Add doc comments to tree and Auspice extension types
  • Add doc comments to gene, CDS, and annotation types
  • Add doc comments to mutation types (substitutions, deletions, insertions)
  • Add doc comments to pathogen config and phenotype types
  • Add doc comments to alignment parameter types
  • Fix documentation errors (wrong enum values, stale TODOs, missing fields)
  • Regenerate JSON schema files

…esultsJson, NextcladeErrorOutputs

- Add field-level doc comments to all ~40 NextcladeOutputs fields, PeptideWarning, PhenotypeValue
- Add field-level doc comments to ResultsJson fields
- Add struct and field doc comments to NextcladeErrorOutputs
- Regenerate JSON/YAML schema files with new description fields
- QcStatus, QcResult, QcResultMissingData, QcResultMixedSites
- QcResultPrivateMutations, QcResultSnpClusters, ClusteredSnp
- QcResultFrameShifts, QcResultStopCodons
- Fix `//` to `///` on QcRulesConfigMixedSites so description propagates to schema
- Add field-level doc comments to all QC config structs: QcRulesConfigMissingData, QcRulesConfigMixedSites, QcRulesConfigPrivateMutations, QcRulesConfigSnpClusters, QcRulesConfigFrameShifts, QcRulesConfigStopCodons, FrameShiftLocation, StopCodonLocation, QcConfig
geneName was renamed to cdsName in the v2-to-v3 migration.
- Add aaMutLabelMap example to mutLabels JSON snippet
- Fix pathogenJson -> pathogen.json typo
- Clarify files field is required for datasets, not by schema
- Add includeNearestNodeInfo to generalParams
- Add deletion weight fields to privateMutations example
- Document alignmentPreset field and fix missing closing parenthesis
- Change qry and node from "object" to "array of objects" per schema
- Add [] notation to sub-field paths for consistency
- Document qry[].name field
@ivan-aksamentov ivan-aksamentov deleted the docs/schema-docs branch March 5, 2026 02:42
@github-actions
Copy link
Copy Markdown

github-actions bot commented Mar 5, 2026

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant