<p>there is an issue out discussing the strategies for the autopilot (c.f.: <a href="https://github.com/lightningnetwork/lnd/issues/677" rel="nofollow noreferrer">https://github.com/lightningnetwork/lnd/issues/677</a> ) there it is stated that it currently uses a constrained barabasi albert model or preferential attachment ( <a href="https://en.wikipedia.org/wiki/Barab%C3%A1si%E2%80%93Albert_model" rel="nofollow noreferrer">https://en.wikipedia.org/wiki/Barab%C3%A1si%E2%80%93Albert_model</a> ) this means that it will look at the topology of the network and randomly select nodes to connect to. However the probability distribution is not uniformly distributed but weighted by the node degree (meaning the numbers of channels a node has) of the nodes resulting to the fact that the autopiolot is more likely to connect to nodes which are already highly connected. </p>

<p>the model is constrained because currently nodes that are too big ( I think having more than 5k channels) will be excluded.</p>

CC BY-SA 4.0
2022-05-01T11:06:32.153Z
please extend post by config, see https://www.reddit.com/r/lightningnetwork/comments/gvrpvg/struggling_with_lnd_autopilot/
droid192
CC BY-SA 4.0
2018-08-12T09:39:53.713Z
2018-08-12T09:39:53.713Z
Rene Pickhardt
<p>Autopilot automatically connects to peers in order to establish a p2p network. I didn't find however a complete explanation of its motivation and logic.</p>

CC BY-SA 4.0
2018-05-13T16:03:39.397Z
I suggest that you read the code (which is well commented): https://github.com/lightningnetwork/lnd/tree/master/autopilot
Ava Chow
<lightning-network><lightning-network-daemon><lightning-routing><lightning-autopilot>
How does lnd's autopilot feature work?
ripper234
# How does lnd's autopilot feature work?

(Asked by: username_0 on 2018-05-13)

Autopilot automatically connects to peers in order to establish a p2p network. I didn't find however a complete explanation of its motivation and logic.

**Tags:** lightning-network, lightning-network-daemon, lightning-routing, lightning-autopilot

> **Comments:**
> **username_1**: I suggest that you read the code (which is well commented): https://github.com/lightningnetwork/lnd/tree/master/autopilot  

---

## 1 answers

### Answer by username_2 on 2018-08-12. Score: 2

there is an issue out discussing the strategies for the autopilot (c.f.: <https://github.com/lightningnetwork/lnd/issues/677> ) there it is stated that it currently uses a constrained barabasi albert model or preferential attachment ( <https://en.wikipedia.org/wiki/Barab%C3%A1si%E2%80%93Albert_model> ) this means that it will look at the topology of the network and randomly select nodes to connect to. However the probability distribution is not uniformly distributed but weighted by the node degree (meaning the numbers of channels a node has) of the nodes resulting to the fact that the autopiolot is more likely to connect to nodes which are already highly connected.

the model is constrained because currently nodes that are too big ( I think having more than 5k channels) will be excluded.

> **Comments:**
> **username_3**: please extend post by config, see https://www.reddit.com/r/lightningnetwork/comments/gvrpvg/struggling_with_lnd_autopilot/  

---

