A rate "lock" or "commitment" is a lender's promise to hold a certain interest rate and a specific number of points for you for a certain period of time during your application process. This prevents you from going through your entire application process and discovering at the end that the interest rate has gone up.
Although there are various lengths of rate lock periods (from 15 to 60 days), the extended ones are usually more expensive. The lender will agree to freeze an interest rate and points for a longer span of time, say sixty days, but in exchange, the rate (and sometimes points) will be higher than that of a rate lock of fewer days.
There are more ways to get a low rate, besides going with a shorter rate lock period. The bigger the down payment, the lower the interest rate will be, as you will have more equity from the start. You may choose to pay points to lower your rate over the loan term, meaning you pay more up front. For a lot of people, this makes sense and is a good deal..