tweag/cooked-validators

Balancing option to leverage performance and accuracy

mmontin opened this issue · 0 comments

At the moment, there is a single behind the scene way to compute subsets of utxos to be picked for balancing. This way is optimal (in the sense it picks the subset which is the closest to the required value while costing less min ada) but is very cost-unefficient (2^n). Considering the number of handled utxos is usually small when using cooked-validators, and that this function is actually well optimized, this is acceptable. However, for cases where performance is required, we could provide a second function to compute this subset, which would be less optimal but would scale for high numbers of utxos owned by the balancing wallet.