bitcoinops/bitcoinops.github.io

Missing entries around payment flows in the Topics list

renepickhardt opened this issue · 2 comments

Hey everyone I am currently writing a blog article / research paper and I was linking to redundant overpayments (also listed on the topics page as stuckless payments). I also wanted to link to a glossary entry for payment flows but I realized despite optech having covered my results frequently that there is no particular topic for payment flows.

Of course multipath payments exists which from a mathematical perspective is a payment flow and I can agree that we can stick with the historically used term of multipart payments. However in that case the topic page of multipath payments is lacking some explaination of what a payment flow is and how it is related to the splitting problem and also some links to news letters covering a lot of the theory that we know these days. For example:

If you like I will be happy to refactor the topics around payment flows for the topic page but wanted to ask for your thoughts first.

Partial duplicate of #721 (comment)

I'm almost finished addressing the above issue, which will add a pathfinding topic page[1]. I'm not sure about having a separate page for the specific topic of payment flows separate from the more general problem of pathfinding, but I'm certainly open to both. Our (soft) rule is to create a topic page once we've covered something three times, and if we expect to cover it again in the future, and that criteria is met for the payment flows work.

[1] I think you may have some suggestions for alternative naming to "pathfinding", which are welcome here or in that PR when it gets opened (if you don't object, I'll tag you there when it's opened).

Thanks for the explanation, ideas and invitation to participate. I will try my best so please accept the following as a constructive approach even though it may look like a wall of text.

I'm not sure about having a separate page for the specific topic of payment flows separate from the more general problem of pathfinding, but I'm certainly open to both.

I think from a math perspective it is exactly the other way around. Every path is a payment flow but not every payment flow is a path. Thus I think payment flow is the general concept and path finding the specific topic.

We had a similar problem when writing Mastering the Lightning Network. Chapter 12 is called Pathfinding and Payment Delivery. It was a compromise agreement as historically speaking the term path finding was mainly used and is what most people think of. I think there are strong arguments for keeping the term and strong arguments for removing it which I will list:

Arguments for keeping the term Pathfinding

  • The routing layer and transport of onions in its current form thinks from the perspective of a payment path
  • The term is widely used and people associate the related topics and techniques with that term

Arguments for replacing the term Pathfinding

  • The term is misleading. In reality sending Sats from one node to another one is a transportation problem through a network. Which generally is a Network Flow or a Min Cost flow Problem
  • MPP is often overloaded as people are uncertain weather it stands for multi part payments or multi path payments. The reality is that MPP corresponds directly to a payment flow.
  • Currently the philiosophy in payment planning is to focus on path finding and if amounts are to large split them and use the path finding logic. However Splitting the amount in a reasonable way is a problem of its own c.f. (1, 2, 3 and 4)

Conclusion and recommendation for Naming

I would suggest to use the following terms on 3 pages.

  • Payment Routing for the transport layer and the way how we use htlcs and transport them via onion that are transported via update_add_htlc and settled / removed in the respective messages. This would be used for low level BOLT protocol relevant topics. (For example upfront fees, channel chamming, PTLCs....)
  • Payment Planning or Payment Delivery for the class of optimization problems that are being solved and computed to plan payments. This could be for example solving a minimum cost flow or solving path finding problems. Also the allocation of amounts for various paths or flows and thus the splitting could be summerized under this term. I assume this page would enlist all the stuff that you had in mind for the pathfinding topic page that you planned (pun intended) to add to the topic list.
  • Payment flow as the most general concept of optimization problem that is being solved in order to conduct Payment Planning As every MPP is a payment flow I would rename the MPP page to payment flow

While I think the proposed terminology and separation of topics is semantically reasonable I do see how this is a pretty severe change and would not even mean that people would intuitively understand and adopt this. For example I am not even sure if the line between the 2nd and 3rd topic is not to blurry. For example I kind or argued why splitting is part of MPP / flow but suggested to have this under planning.