The speaker's horse is probably pulling a sleigh and knows a regular route that the owner takes; therefore, when the man stops in a deserted woodland, she gives the sleigh bells a shake in order to express her wonder at the owner's action since he has deviated from the routes usually taken (horses have excellent memories). Perhaps, then, the speaker is shaken from his reflections and reminds himself of his obligations, repeating the phrase "And miles to go before I sleep" once as a reminder and again in order to encourage himself to continue on his way.
In this famous poem of Robert Frost, there is much of the poet. According to Arthur Bleau, a young man who attended a reading by Frost at Bowdoin College in 1947, Frost revealed that one Christmas season he realized that he could not afford to buy presents for his children; so, he took what produce he could spare and attempted to sell it in order to purchase presents. However, his efforts failed. On his way home, he stopped in a man's woodland, feeling the draw of a death wish. But, when his little mare Eunice shook the sleigh bells, he realized his obligations to his family. Thus, the repetition of the line "And miles to go before I sleep" as a reminder of his obligations:
But I have promises to keep,
And miles to go before I sleep;
And miles to go before I sleep.
The speaker has his marital vows to keep and children to care for before he can rest, and he has many obligations to follow before he can die.
Still another interpretation of the speaker's halting in the woods can reflect the profound sense of alienation sensed by many Americans after World War II. More and more people were coming off farms and working in factories where they sold their lives, rather than products of the earth, as they worked twelve and fourteen hours a day. The repetition of the final line of Frost's poem, then, can reflect the double disgrace of workers who renounce nature at the same time that they sell their labor and lives all day.