Yes, if you invest in Beefy, your LP will be automatically compounded. When you deposit into a vault, the amount of BIFI you receive will increase over time, with the amount of BIFI you get increasing by 10% each time. This means that you will earn more LP as your BIFI balance grows. This is because the LP you earn is based on the amount of BIFI you hold. As your BIFI balance increases, so does the amount of LP you earn.