I hear a lot of people in mainland China use the former (never from Taiwanese Mandarin) when saying a phrase as a sort of command, but I'm still not sure about why someone would say it.
When having a very casual communication.– Joseph S WUFeb 23, 2014 at 23:33
Their meanings are somewhat different. In a few situations, they are interchangeable, but there are many others where you can only use one and not the other. The key difference is that 呗 is much more assertive, even rhetorical, whereas 吧 can be used to express doubt or uncertainty as well. For completeness I'll cover them all.
Definitions taken from zdic.net
(1) 用在句末,表示恳求、提议、请求、命令等语气 [(used at the end of a sentence) indicating entreaty, suggestion, command, etc.]。如:派六个人不够吧,我的意见派十个人;你说给大家听听吧!
(2) 用在句末,表示同意、认可的语气 [indicating agreement or acknowledgment]。如:好吧,我一定去;就这样执行吧
(3) 用在句末,表示疑问语气,带有揣度的意味 [indicating doubt]。如:他现在赞同了吧?你弄通了吧?
(4) 用在句末,表示估量、推测语气 [indicating uncertainty]。如:他自己总该知道吧;老王会到这边来吧
(5) 用在句中,表示停顿,带假设语气,并带有列举性质 [indicating a pause]。如:说吧,不好;不说吧,也不好
When expressing a foregone or obvious conclusion, you can only use 呗. Let's examine the example:
Here the speaker is saying that the solution, to learn how to ride a bike, is obvious, and doesn't need asking, as if the question was rhetorical. If you change the 呗 to a 吧, then the implication changes:
Here the solution of learning to ride a bike is more of a suggestion, and that other solutions may also be valid.
When expressing reluctant agreement, use 呗, although 吧 can also be used. Let's examine this:
Here the speaker is expressing reluctance that "you" have to go. The speaker could replace it with 吧:
But unless expressed elsewhere with tone or context, the tone of this sentence is ambiguous, and not necessarily reluctant.
When used as a suggestion or command, you can use either 吧 or 呗:
When expressing agreement or acknowledgement, you would use 吧. Sometimes you can use 呗 as well, but watch out for its more assertive tone:
When used to indicate doubt or uncertainty, you can only use 吧:
There's another special use of 吧, as a pause in speech. In this manner, it is interchangeable with characters like 呢. 呗 doesn't have this usage.
Always use 吧. This is standard/proper Mandarin.
唄 is used in regional dialects.
口 mouth radical indicates the character is meaningless and used purely phonetically. The pronunciation is indicated by the character on the right 贝 (bèi) and 巴 (bā).
I got a downvote with no explanation. 唄 is not proper Mandarin. It's not even pronounced "bei" but "beh". This usage is already in the realm of a Mandarin dialect rather than proper Mandarin usage.– amateurFeb 24, 2014 at 15:50
1I wasn't the one who downvoted you, but I suspect it's because your answer didn't really answer the question. This site isn't limited to only standard Mandarin, and there will often be questions regarding how people use the language, even when such usages are non-standard.– ClawMar 14, 2014 at 19:52
Simple answer, use 吧 anytime you want, and if you want to impressive your colleges, you can use 呗.