← Back to Pull requests

docs: Refactor Presto C++ documentation #28680

Merged
steveburnett merged 3 files (808 lines) on Oct 19, 2026 20:20 UTC
View on GitHub
steveburnett steveburnett commented on Oct 19, 2026 16:31 UTC
Author

Description


After discussion with @aditi-pandit, I have done the following:

moved the text in https://github.com/prestodb/presto/blob/master/presto-docs/src/main/sphinx/presto_cpp/limitations.rst#functions to a new page https://prestodb.io/docs/current/presto_cpp/functions.html
removed the table of contents from https://github.com/prestodb/presto/blob/master/presto-docs/src/main/sphinx/presto_cpp/limitations.rst because it only had a single heading so a ToC was unneeded

  • removed the heading "General Limitations" from the page, as it's now redundant with the title
  • Motivation and Context


    Readers who read the Limitations page were reported as being distracted by the length of the page which implies that Presto C++ is less capable than it currently is.

    In discussion with @aditi-pandit, we realized that the Functions content was more like "this is how the function works in Presto C++", and that grouping this descriptive documentation as a limitation was inappropriate. Moving the functions documentation to a separate page helps deliver relevant doc to readers based on the page names in the table of contents.

    Impact


    Documentation.

    Test Plan


    Local doc builds.

    build succeeded.
    
    The HTML pages are in target/html.
    

    Screenshots:

    Limitations page
    <img width="850" height="835" alt="Screenshot 2026-10-19 at 12 29 04 PM" src="https://github.com/user-attachments/assets/c6b8bea1-c844-4529-b8a2-7e7190111b4e" />

    Functions page
    <img width="851" height="830" alt="Screenshot 2026-10-19 at 12 29 12 PM" src="https://github.com/user-attachments/assets/bea25f91-70a5-41e3-9b6f-dc44f11b7206" />

    Contributor checklist

  • Please make sure your submission complies with our contributing guide, in particular code style and commit standards.

  • PR description addresses the issue accurately and concisely. If the change is non-trivial, a GitHub Issue is referenced.

  • Documented new properties (with its default value), SQL syntax, functions, or other functionality.

  • If release notes are required, they follow the release notes guidelines.

  • Adequate tests were added if applicable.

  • CI passed.

  • If adding new dependencies, verified they have an OpenSSF Scorecard score of 5.0 or higher (or obtained explicit TSC approval for lower scores).
  • Release Notes

    == NO RELEASE NOTE ==
    

    Summary by Sourcery

    Separate Presto C++ function documentation from limitations to make the documentation structure clearer for readers.

    New Features:

  • Add a dedicated Presto C++ Functions documentation page containing the function behavior reference previously included under limitations.
  • Enhancements:

  • Refocus the Presto C++ Limitations page by removing the relocated functions content, redundant heading, and unnecessary table of contents.
  • Documentation:

  • Reorganize Presto C++ documentation so function descriptions and limitations are presented as separate topics.
  • Diff: 808 lines (+400 / -408) across 3 files Reviewer: aditi-pandit Review duration: 229m
    All Vouch review confidence checks passed
    Residual risk 0.04 = Change Risk (0.46) × (1 − Review Confidence (0.92)). Review depth and reviewer attention state are adequate.
    Model 1 · Change Risk (XGBoost)
    Score: 0.46 · 808 lines diff across 3 files
    0.46
    Model 2 · Review Depth (DistilBERT)
    Depth Score: 0.93 · 4 substantive comment(s)
    0.93
    Model 3 · Review Timing & Attention
    Session adequacy: 100% · Reviewer familiarity: 50%
    92%
    Bedrock Claude 3 · Risk Narration
    (disconnected)
    Groq
    Groq Risk Narration
    AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
    Model 1 · Change Risk Attribution
    SHAP Weights
    Diff Size diff_size
    0.400
    Real PR Conversation Timeline
    8 items
    sourcery-ai[bot] sourcery-ai[bot] commented on Oct 19, 2026 16:31 UTC
    Bot

    <!-- Generated by sourcery-ai[bot]: start review_guide -->

    <details>
    <summary>Reviewer's guide (collapsed on small PRs)</summary>

    Reviewer's Guide

    Refactors the Presto C++ documentation by moving descriptive function behavior into a new Functions page, linking it from the documentation navigation, and simplifying the Limitations page so it no longer presents function documentation or redundant structure.

    File-Level Changes

    | Change | Details | Files |
    | ------ | ------- | ----- |
    | Separates Presto C++ function documentation from the limitations page and exposes it as its own documentation page. | <ul><li>Moves the Functions content into a new standalone page.</li><li>Adds the new page to the Presto C++ documentation navigation.</li><li>Removes the redundant Functions section from the limitations page.</li></ul> | presto-docs/src/main/sphinx/presto_cpp/functions.rst<br/>presto-docs/src/main/sphinx/presto_cpp/limitations.rst<br/>presto-docs/src/main/sphinx/presto-cpp.rst |
    | Simplifies the limitations page presentation to reflect its focused scope. | <ul><li>Removes the single-entry table of contents.</li><li>Removes the redundant General Limitations heading.</li></ul> | presto-docs/src/main/sphinx/presto_cpp/limitations.rst |

    </details>

    ---

    <details>
    <summary>Tips and commands</summary>

    Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.

  • Continue discussions: Reply directly to Sourcery's review comments.

  • Generate a GitHub issue from a review comment: Ask Sourcery to create an

  • issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull

  • request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in

  • the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull

  • request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the

  • pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull

  • request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!

    Customizing Your Experience

    Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request

  • summary, the reviewer's guide, and others.
  • Change the review language.

  • Add, remove or edit custom review instructions.

  • Adjust other review settings.
  • Getting Help

  • [Contact our support team](mailto:support@sourcery.ai) for questions or feedback.

  • Visit our documentation for detailed guides and information.

  • Keep in touch with the Sourcery team by following us on X/Twitter, LinkedIn or GitHub.
  • </details>

    <!-- Generated by sourcery-ai[bot]: end review_guide -->

    sourcery-ai[bot] sourcery-ai[bot] commented on Oct 19, 2026 16:31 UTC
    Reviewer

    Hey - I've reviewed your changes and they look great!

    ***

    <details>
    <summary>Sourcery is free for open source - if you like our reviews please consider sharing them ✨</summary>

  • X

  • Mastodon

  • LinkedIn

  • Facebook
  • </details>

    aditi-pandit aditi-pandit commented on code on Oct 19, 2026 17:08 UTC
    Code Review
    presto-docs/src/main/sphinx/presto_cpp/functions.rst:1
    @@ -0,0 +1,394 @@
    +====================
    +Presto C++ Functions
    +====================
    +

    Add a blurb here stating the purpose of this document : to outline the cases in which Presto C++ function behavior diverges from Presto Java and the reasoning for the same.

    Lets also scan the rest of the writing to keep the phrasing uniform illustrating the difference in behavior.

    aditi-pandit aditi-pandit commented on Oct 19, 2026 17:21 UTC
    Reviewer

    Thanks @steveburnett for reorganizing this page. The separation looks more clean now.

    steveburnett steveburnett commented on code on Oct 19, 2026 17:38 UTC
    Code Review
    presto-docs/src/main/sphinx/presto_cpp/functions.rst:1
    @@ -0,0 +1,394 @@
    +====================
    +Presto C++ Functions
    +====================
    +

    Add a blurb here stating the purpose of this document : to outline the cases in which Presto C++ function behavior diverges from Presto Java and the reasoning for the same.

    Done! Added this sentence at the top of the page:

    This document describes how, and why, Presto C++ functions differ from Presto functions.
    

    Lets also scan the rest of the writing to keep the phrasing uniform illustrating the difference in behavior.

    I had intended to only refactor the documentation in this PR to merge this quickly, then open a new PR to revise the functions content - like the other PR we talked about to rewrite the Limitations heading. But if you like, we can revise the Functions doc in this one. I took a quick look and did not notice anything notable. I can look again, and if you have suggestions please let me know!

    aditi-pandit aditi-pandit approved these changes on Oct 19, 2026 20:15 UTC
    Approved Reviewer

    Thanks @steveburnett

    steveburnett steveburnett commented on Oct 19, 2026 20:27 UTC
    Author

    Thanks @steveburnett

    You're welcome @aditi-pandit! I will follow up with you about rewriting the functions doc, as you recommend, for more uniform phrasing. (Also, I think the TIMESTAMP section might need updating and it's not the only part that could be out of date.)

    We talked about the changes you want to make to the Limitations page (and I agree with all of them) so I will leave the Limitations page alone and let you open the docs PR to revise the Limitations list. However, if you want to send me a draft of the Limitations instead, I am happy to open the PR for you.

    Reviewers
    Assignees
    steveburnett steveburnett
    Labels
    risk: low confidence: 92.2% reviewed
    Vouch Risk Breakdown
    AI-powered review risk analysis
    Change Risk
    Change Risk · Model 1 (XGBoost)
    Predicted defect probability (0.00–1.00) based on diff churn, modified sensitive files, and author risk history.
    Score: 45.9% (MEDIUM) · Higher = larger blast radius
    45.9%
    Review Confidence
    Review Confidence · Models 2 & 3
    Scrutiny score (0.00–1.00) combining DistilBERT semantic review depth with reviewer familiarity and session dwell time.
    Score: 92.2% · Lower = rushed or shallow review
    92.2%
    Residual Risk
    Residual Risk · Core Equation
    Residual = Change × (1 − Confidence)
    Unmitigated risk surviving review. ≥ 0.65 triggers an automated re-queue to protect production.
    Score: 3.6% · Safe to merge
    3.6%