When Bilam attempts to curse the Jews, he is foiled, and attempts to bless them, which is accepted.
It is not clear why his failed curse compels him to bless them. Rashi explains Bilam’s situation with a metaphor – it is best to avoid a bee’s sting and it’s honey too. The parable and dialogue are not readily understood; honey is great if you can avoid getting stung! What is wrong with his blessing?
The Giznei Yosef explains that people’s speech is powerful. A righteous person’s speech is potent, but an evil persons too, albeit for a different reason. Rivka was blessed by Lavan to have many descendants – and she became barren. An evil person’s blessings are not only not fulfilled, but as a result are potentially a curse.
This is the metaphor of the bee. Bilam’s blessing was not as noble as it seems – it had a “sting” in its tail. This sheds light on the dialogue. Hashem had already chosen and blessed them, so Bilam‘s “blessing” couldn’t not supersede it or take affect.
This sheds light on what Hashem had told him at the outset:
לֹא תָאֹר אֶת-הָעָם, כִּי בָרוּךְ הוּא – Do not curse this people, for they are blessed.
It was not a warning – it simply noted the futility of the journey. The sting and the honey were of no use!