Skip to content

Conversation

@jenningsanderson
Copy link
Collaborator

@jenningsanderson jenningsanderson commented Aug 13, 2025

Moving to Pydantic!

This PR updates and simplifies the docs to show easier, table-based schema docs.

Enhancements to docs code:

  1. Removes Docusaurus JSON Schema Plugin.
  2. Enables faster docusaurus builds.
  3. No more serving of any raw YAML files.

/schema/reference Updates:

Today, everything available under docs.overturemaps.org/schema lives here: https://github.com/OvertureMaps/schema/tree/dev/docs/schema. When docusaurus builds the docs, it fetches the .mdx, schema, and examples from the schema repo. This is a lot of moving parts and kind of ugly.

This PR removes that requirement in favor of simple, machine-readable markdown files that can be self-generated by the schema and used by documentation. To that end, the content available here: https://github.com/OvertureMaps/docs/tree/injectable-schema-refs/docs/schema is the new docs.overturemaps.org/schema/.

TODO (before merging):

  1. Everything in codegen (a placeholder name, should probably be renamed to reference) was generated by the new pydantic schema codegen utility. The actual organization of the files isn't perfect yet, and likely needs to be hand-curated a bit (just this time, we can keep perfecting the schema codegen utility to produce the exact markdown we want in the meantime).
  2. Much of the stuff in concepts is redundant and can either be deleted (such as names, which should be covered in the codegen output) or should be moved into the data guides (Transportation concepts, such as Shape and Lane Connectivity).
  3. Resolve all broken links so that this branch can actually build a valid version of the docs (much of this will be fixed by (2)).

TODO (after merging, moving forward with the new Pydantic schema):

  1. Delete the docs/ in the schema repo.
  2. All "schema reference documentation" should be self-contained in the models themselves to keep documentation as close to the schema code as possible.
  3. Improve the codegen capabilities to generate and publish markdown files as artifacts with each schema release.
    • The output should be a complete set of markdown files that fully describe the schema and are machine-readable.
    • Docusaurus can then fetch these markdown files and inject them into docs/schema at build time.

New:
image

Docs Preview:

Click the most recent "View Deployment"

All Staging Deployments

initial build of docs with schema reference from pydantic models.
@danabauer danabauer self-assigned this Sep 17, 2025
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.

2 participants