title: Mongo Query: GraphLookup or Aggregate
body: <p>Looking for some direction on how to construct a mongo query for a graph network visualization.</p>
  
  <p>I have a data model that looks like this:</p>
  
  <pre><code>stories[
  {
    story: "story 1",
    theme_ids: [1,2,3],
    author_ids: [a,b,c]
  },
  {
    story: "story 2",
    theme_ids: [4],
    author_ids: [a]
  }
  ...
  ]
  </code></pre>
  
  <p>I would like the result of the query to grab all of the pairs of themes and authors like so:</p>
  
  <pre><code>[
  {from: 1, to: a},
  {from: 1, to: b},
  {from: 1, to: c},
  {from: 2, to: a},
  {from: 2, to: b},
  {from: 2, to: c},
  {from: 3, to: a},
  {from: 3, to: b},
  {from: 3, to: c},
  {from: 4, to: a}
  ]
  </code></pre>
  
  <p>Thank you!  MongoDB v3.4</p>