Free Will. Someone might say: "If all phenomena are conditionally arisen, then Buddhism is a form of fatalism, for we have no free will to control our destiny." Such a statement would not be correct. Will is volition (cetanaa), a mental state, determined ethically by its root condition (hetu paccaya). If the root is unwholesome, we can either restrain or indulge the volition; if the root is wholesome, we can encourage it or neglect it. In this exercise of will lies our freedom to guide our destiny.
https://www.accesstoinsight.org/lib/authors/mendis/wheel322.htmlThis is how there's free will in the midst of causality. At the same time, the pattern in the way intentions lead to results allows us to learn from past mistakes. This freedom within a pattern opens the way to a path of mental training that can lead to the end of suffering. We practice generosity, virtue, and meditation to learn the power of our intentions and in particular to see what happens as our intentions grow more skillful, so skillful that present intentions actually stop. Only when they stop can you prove for yourself how powerful they've been. And the spot where they stop is where the unconditioned — the end of suffering — is found. From there you can return to intentions, but you're no longer their captive or slave.