Author: Stefan Richter 2021-11-15 19:38:14
Published on: 2021-11-15T19:38:14+00:00
In Lightning pathfinding, routing fees and reliability are the two main variables to optimize for. Routing fee is a concrete amount paid when a payment succeeds while reliability is a probability of a route being successful. Comparing route options involves comparing these two variables against each other. To offer this trade-off to the user in a simple way, a single [0,1] value that controls the selection process may be used where 0 optimizes only for fees and 1 optimizes only for reliability. However, choosing between routes for values somewhere in between 0 and 1 can be challenging. The linear weighted sum method often used to combine features may not always work well with selected features. An alternative approach is to use the harmonic mean which has been shown to outperform the linear sum in practice. In conclusion, there is no universal truth to situations like this and only tests and experience will help make good decisions.
Updated on: 2023-06-03T06:32:02.256687+00:00