title: Run python program within a JS file
body: <p>I have a website where I can execute search queries. Afterwards, a search request over an API is generated, where the search query is saved in a variable called <code>query</code>:</p>
  <pre><code>    const { query, ...optionsFromState } = adaptRequest({
    ...state,
    ...(current !== undefined &amp;&amp; { current }),
    ...(filters !== undefined &amp;&amp; { filters }),
    ...(resultsPerPage !== undefined &amp;&amp; { resultsPerPage }),
    ...(sortDirection !== undefined &amp;&amp; { sortDirection }),
    ...(sortField !== undefined &amp;&amp; { sortField })
  });
  </code></pre>
  <p>Now, I want to use query and transform it with a python script. Let's say the script is called <code>transformation.py</code> and consists of a function, that takes the query and sends it to a neural network, which will result in some output. To simplify it, let's say inside the python script is a function, that produces <code>output = function(query)</code>. I then want to take that output and give it to some variable <code>output</code> within my original .js file. To conclude, I want to do something like this within my .js file:</p>
  <pre><code>send query as function parameter to transformation.py
  output = output from transformation.py
  </code></pre>
  <p>How would I do that?</p>
  <p>Thank you very much for your help!</p>