Dynamic audio rendering with tone.js

Sorry for the trivial question, but I’m struggling in finding the correct/best method that I should use to achieve this simple task using Tone.js (and/or a clear example):

  • I would like to create a “stereo audio stream” (don’t know what’s the correct name in Tone.js, AudioWorklet??) and connect it to the default output

  • set a callback function that is called whenever the “audio stream” needs more audio data, and I can fill two float buffers (left and right) with my own data (a buffer should be an array of 2048 floats)

I also would like to be able to connect it to a chain of effects (reverb and/or delay) implemented in Tone.js.

I found something with “createScriptProcessor” but it seems deprecated and not in the Tone.js framework.

Thank you in advance.