Generate query/aggregation suggests database level operators

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Unresolved
    • Priority: Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • Environment:
      OS:
      node.js / npm versions:
      Additional info:
    • 3
    • None
    • None
    • Developer Tools

      Prompts like:
      > Create a pipeline to generate 20 documents that describe different roasted coffee beans. Things like origin, date, weight, roast, etc
      Or
      > Create a pipeline that $out to this collection to generate 20 documents, that describe different alien, UFO, dragon, and wizard sighting events. Have fields like amount of witnesses, coordinates, time of day, scale, photographic evidence.

      Generate pipelines that use $documents. This'll be confusing to a user and won't work as $documents is a database level aggregation. It'll error with:
      > '$documents' can only be run with {aggregate: 1}

      In this ticket let's update the generative ai prompting to not suggest $documents, or database level aggregations as we don't handle them currently.
      Let's also not provide autocomplete for $documents or other database level operators in the text editor. Two part ticket. 

       

            Assignee:
            Ivan Medina
            Reporter:
            Rhys Howell
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: