Skip to content

chore(docs/reference/sql): Migrate function documentation defined in Rust into Markdown#616

Open
paleolimbot wants to merge 15 commits intoapache:mainfrom
paleolimbot:docs-add-from-rust
Open

chore(docs/reference/sql): Migrate function documentation defined in Rust into Markdown#616
paleolimbot wants to merge 15 commits intoapache:mainfrom
paleolimbot:docs-add-from-rust

Conversation

@paleolimbot
Copy link
Member

@paleolimbot paleolimbot commented Feb 13, 2026

This PR removes documentation defined in rust/sedona-functions and places it in docs/reference/sql (as the one source of truth for function documentation).

This was done by a combination of Opus and Codex, although I had to review all the descriptions to ensure we didn't have trivially repeated sections and the examples ran.

I am not sure I'll get there before 0.3 is released, but I'll open a follow-up to add sedona-function-definitions, which can do cross checking and make the documentation available from SQL.

After this PR we can canonically add function documentation to docs/reference/sql when adding functions rather than the Rust source code.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR migrates SQL function documentation from Rust UDF metadata (Documentation) into Quarto Markdown pages under docs/reference/sql, making the docs directory the primary source of truth for function reference material.

Changes:

  • Removed Rust-side Documentation builders from many scalar/aggregate UDF definitions and adjusted metadata tests accordingly.
  • Added/updated Quarto (.qmd) function pages under docs/reference/sql, including new pages for functions previously only documented in Rust.
  • Reformatted and expanded SQL examples and descriptions across multiple function docs.

Reviewed changes

Copilot reviewed 156 out of 157 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
rust/sedona-raster-functions/src/rs_worldcoordinate.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-raster-functions/src/rs_srid.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-raster-functions/src/rs_size.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-raster-functions/src/rs_rastercoordinate.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-raster-functions/src/rs_geotransform.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-raster-functions/src/rs_example.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-raster-functions/src/rs_envelope.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-raster-functions/src/rs_convexhull.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-functions/src/st_zmflag.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-functions/src/st_xyzm_minmax.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-functions/src/st_xyzm.rs Drop Rust UDF documentation and update doc-related tests to expect None.
rust/sedona-functions/src/st_union_agg.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-functions/src/st_translate.rs Drop Rust UDF documentation and update doc-related tests to expect None.
rust/sedona-functions/src/st_transform.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-functions/src/st_start_point.rs Drop Rust UDF documentation and update doc-related tests to expect None.
rust/sedona-functions/src/st_srid.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-functions/src/st_setsrid.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-functions/src/st_scale.rs Drop Rust UDF documentation and update doc-related tests to expect None.
rust/sedona-functions/src/st_rotate.rs Drop Rust UDF documentation and update doc-related tests to expect None.
rust/sedona-functions/src/st_reverse.rs Drop Rust UDF documentation (keeps implementation unchanged).
rust/sedona-functions/src/st_polygonize_agg.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-functions/src/st_pointzm.rs Drop Rust UDF documentation and update doc-related tests to expect None.
rust/sedona-functions/src/st_points.rs Drop Rust UDF documentation and update doc-related tests to expect None.
rust/sedona-functions/src/st_pointn.rs Drop Rust UDF documentation and update doc-related tests to expect None.
rust/sedona-functions/src/st_point.rs Drop Rust UDF documentation and update doc-related tests to expect None.
rust/sedona-functions/src/st_perimeter.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-functions/src/st_numgeometries.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-functions/src/st_makeline.rs Drop Rust UDF documentation and update doc-related tests to expect None.
rust/sedona-functions/src/st_line_merge.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-functions/src/st_length.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-functions/src/st_isempty.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-functions/src/st_iscollection.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-functions/src/st_isclosed.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-functions/src/st_intersection_agg.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-functions/src/st_interiorringn.rs Drop Rust UDF documentation.
rust/sedona-functions/src/st_haszm.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-functions/src/st_geomfromwkt.rs Drop Rust UDF documentation (incl. EWKT UDF) and update doc-related tests.
rust/sedona-functions/src/st_geomfromwkb.rs Drop Rust UDF documentation and update doc-related tests; minor comment cleanup needed.
rust/sedona-functions/src/st_geomfromewkb.rs Drop Rust UDF documentation and update doc-related tests.
rust/sedona-functions/src/st_geometrytype.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-functions/src/st_geometryn.rs Drop Rust UDF documentation.
rust/sedona-functions/src/st_force_dim.rs Drop Rust UDF documentation and update doc-related tests to expect None.
rust/sedona-functions/src/st_flipcoordinates.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-functions/src/st_envelope_agg.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-functions/src/st_envelope.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-functions/src/st_dwithin.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-functions/src/st_dump.rs Drop Rust UDF documentation and update doc-related tests to expect None.
rust/sedona-functions/src/st_dimension.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-functions/src/st_concavehull.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-functions/src/st_collect_agg.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-functions/src/st_centroid.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-functions/src/st_buffer.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-functions/src/st_azimuth.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-functions/src/st_astext.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-functions/src/st_asgeojson.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-functions/src/st_asewkb.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-functions/src/st_asbinary.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-functions/src/st_area.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-functions/src/st_analyze_agg.rs Drop Rust UDF documentation.
rust/sedona-functions/src/st_affine.rs Drop Rust UDF documentation and update doc-related tests to expect None.
rust/sedona-functions/src/sd_order.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-functions/src/sd_format.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-functions/src/referencing.rs Drop Rust UDF documentation and relax doc-related tests.
rust/sedona-functions/src/predicates.rs Simplify predicate stub helpers and drop Rust docs; relax doc-related tests.
rust/sedona-functions/src/overlay.rs Simplify overlay stub helpers and drop Rust docs; relax doc-related tests.
rust/sedona-functions/src/distance.rs Simplify distance stub helpers and drop Rust docs; relax doc-related tests.
rust/sedona-functions/src/barrier.rs Drop Rust UDF documentation and relax doc-related tests.
docs/reference/sql/st_z.qmd Add/expand description content.
docs/reference/sql/st_y.qmd Add/expand description content.
docs/reference/sql/st_x.qmd Add/expand description and example output note.
docs/reference/sql/st_within.qmd Add description and format example.
docs/reference/sql/st_union_agg.qmd Fix example formatting/terminator.
docs/reference/sql/st_union.qmd Reformat example for readability.
docs/reference/sql/st_translate.qmd Add description.
docs/reference/sql/st_touches.qmd Add description and reformat example.
docs/reference/sql/st_symdifference.qmd Reformat example.
docs/reference/sql/st_startpoint.qmd Reformat example.
docs/reference/sql/st_simplify.qmd Add description and reformat example.
docs/reference/sql/st_scale.qmd New page for ST_Scale.
docs/reference/sql/st_rotate.qmd New page for ST_Rotate.
docs/reference/sql/st_rotatex.qmd New page for ST_RotateX.
docs/reference/sql/st_rotatey.qmd New page for ST_RotateY.
docs/reference/sql/st_reverse.qmd Update example.
docs/reference/sql/st_point.qmd Add description + SRID example (frontmatter needs overload metadata).
docs/reference/sql/st_overlaps.qmd Add description and reformat example.
docs/reference/sql/st_npoints.qmd Add description and update example.
docs/reference/sql/st_maxdistance.qmd Refine description wording.
docs/reference/sql/st_m.qmd Add description and extra example.
docs/reference/sql/st_line_merge.qmd New page for ST_LineMerge.
docs/reference/sql/st_knn.qmd Expand frontmatter argument docs and add description (frontmatter currently inconsistent).
docs/reference/sql/st_isvalidreason.qmd Add description.
docs/reference/sql/st_isvalid.qmd Add description.
docs/reference/sql/st_issimple.qmd Add description and reformat example.
docs/reference/sql/st_isring.qmd Fix description grammar, add description section, reformat example.
docs/reference/sql/st_isempty.qmd Add additional example.
docs/reference/sql/st_isclosed.qmd Add description and add examples.
docs/reference/sql/st_intersects.qmd Reformat example.
docs/reference/sql/st_intersection_agg.qmd New page for ST_Intersection_Agg.
docs/reference/sql/st_hasz.qmd Update examples.
docs/reference/sql/st_hasm.qmd Update examples.
docs/reference/sql/st_geomfromwkt.qmd Expand signature docs and examples with SRID/CRS overload.
docs/reference/sql/st_geomfromwkb.qmd Expand signature docs/examples (frontmatter SRID/CRS typing needs alignment).
docs/reference/sql/st_geomfromewkt.qmd New page for ST_GeomFromEWKT.
docs/reference/sql/st_geomfromewkb.qmd New page for ST_GeomFromEWKB.
docs/reference/sql/st_geometrytype.qmd Add description and example.
docs/reference/sql/st_geometryn.qmd Add description and reformat example.
docs/reference/sql/st_geogpoint.qmd Add description (frontmatter needs overload metadata).
docs/reference/sql/st_geogfromwkb.qmd Reformat example literal.
docs/reference/sql/st_flipcoordinates.qmd Add geography kernel signature.
docs/reference/sql/st_equals.qmd Add description and update example.
docs/reference/sql/st_envelope_agg.qmd Add description and update example.
docs/reference/sql/st_envelope.qmd Add description and extra example.
docs/reference/sql/st_endpoint.qmd Minor example formatting change.
docs/reference/sql/st_distance.qmd New page for ST_Distance.
docs/reference/sql/st_disjoint.qmd Add description and reformat example.
docs/reference/sql/st_dimension.qmd Add description and extra example.
docs/reference/sql/st_difference.qmd Add description.
docs/reference/sql/st_crs.qmd Add description and normalize example formatting.
docs/reference/sql/st_crosses.qmd Add description and update example.
docs/reference/sql/st_covers.qmd Add description and update example.
docs/reference/sql/st_coveredby.qmd Add description and reformat example.
docs/reference/sql/st_convexhull.qmd Add description and reformat example.
docs/reference/sql/st_contains.qmd Add description and update example.
docs/reference/sql/st_concavehull.qmd New page for ST_ConcaveHull.
docs/reference/sql/st_collect_agg.qmd Add description and update example query style.
docs/reference/sql/st_closestpoint.qmd Add geography kernel signature and update example.
docs/reference/sql/st_centroid.qmd Reformat example.
docs/reference/sql/st_boundary.qmd Add description.
docs/reference/sql/st_azimuth.qmd Add description.
docs/reference/sql/st_asgeojson.qmd New page for ST_AsGeoJSON.
docs/reference/sql/st_asewkb.qmd New page for ST_AsEWKB.
docs/reference/sql/st_affine.qmd New page for ST_Affine.
docs/reference/sql/st_force2d.qmd New page for ST_Force2D.
docs/reference/sql/st_force3d.qmd New page for ST_Force3D.
docs/reference/sql/sd_order.qmd New page for SD_Order.
docs/reference/sql/sd_format.qmd New page for SD_Format.
docs/reference/sql/rs_worldtorastercoordy.qmd New page for RS_WorldToRasterCoordY.
docs/reference/sql/rs_worldtorastercoordx.qmd New page for RS_WorldToRasterCoordX.
docs/reference/sql/rs_worldtorastercoord.qmd New page for RS_WorldToRasterCoord.
docs/reference/sql/rs_width.qmd New page for RS_Width.
docs/reference/sql/rs_upperlefty.qmd New page for RS_UpperLeftY.
docs/reference/sql/rs_upperleftx.qmd New page for RS_UpperLeftX.
docs/reference/sql/rs_srid.qmd New page for RS_SRID.
docs/reference/sql/rs_skewy.qmd New page for RS_SkewY.
docs/reference/sql/rs_skewx.qmd New page for RS_SkewX.
docs/reference/sql/rs_scaley.qmd New page for RS_ScaleY.
docs/reference/sql/rs_scalex.qmd New page for RS_ScaleX.
docs/reference/sql/rs_rotation.qmd New page for RS_Rotation.
docs/reference/sql/rs_rastertoworldcoordy.qmd New page for RS_RasterToWorldCoordY.
docs/reference/sql/rs_rastertoworldcoordx.qmd New page for RS_RasterToWorldCoordX.
docs/reference/sql/rs_rastertoworldcoord.qmd New page for RS_RasterToWorldCoord.
docs/reference/sql/rs_height.qmd New page for RS_Height.
docs/reference/sql/rs_example.qmd New page for RS_Example.
docs/reference/sql/rs_envelope.qmd New page for RS_Envelope.
docs/reference/sql/rs_crs.qmd New page for RS_CRS.
docs/reference/sql/rs_convexhull.qmd New page for RS_ConvexHull.
docs/reference/sql/barrier.qmd New page for barrier().

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@paleolimbot paleolimbot marked this pull request as ready for review February 14, 2026 14:51
@yutannihilation
Copy link
Contributor

Sorry for making a conflict on st_force_dim.rs. I created a pull request to resolve (but feel free to ignore if it's easier to do by yourself).

paleolimbot#1

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