Skip to content

AI report example: explore nested under context: #9849

Description

@dfliess

I've noticed that the AI report example in the reports reference
nests the explore under context::

data:
  ai:
    prompt: "Analyze key metrics and identify significant changes"
    context:
      explore: my_explore

But the AI resolver doesn't seem to have that property, aiProps
declares explore as a top-level field, and anything else lands in UnusedFields. When I deployed the documented example it reconciled clean and ran fine, so at first I assumed it worked. It doesn't: the explore is dropped, and unknown resolver properties are downgraded to a warning unless StrictResolverProps is set
(resolver.go), so nothing surfaces it.

I’m not sure this is purely cosmetic, though. It seems the explore is what ties the time range to the data.
With it, latest resolves against the metrics view
(ai.go#L311-L315).
Without it, latest falls back to the report's execution time
(ai.go#L318-L336).
So 1M as of latest/M quietly stops meaning "the last complete month of data" and starts
meaning "the last complete month by the clock".

Am I reading this right?

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions