Here's an example of how to obtain dissonance curves from live input, either by triggering or through onset detection.
There are a few methods added to DissonanceLib that aid in converting FFT data, such as the one obtained from a buffer with the help of PV_FreqBuffer and PV_MagBuffer (from JoshUgens in sc3-plugins), into n-highest partials in arrays of frequency and amplitude pairs.
These methods are additions to Array: -maxima and Array: -findNlargest.
A more complete example that calculates a dissonance curve from the fft: