Gauging the personality of male bettas is usually pretty easy before you take them home. If they're going to have problems with another fish, they'll show it immediately. The females are the ones that tend to be deceptive and randomly snap at their tank mates...
If you're at a LFS
that keeps bettas in those cups (assuming you're getting a male), take the cup over to a tank with similar fish in it to the kinds of fish he'll be living with. Hold the cup next to the glass and see how he reacts to them. If he flares immediately, it's likely a more aggressive betta. If he shows interest, but no flaring, that's fine, he's likely just curious and will probably do fine. If he shies away and cowers in the back of the cup, then the activity of the smaller fish may stress him out too much to live happily in a community. If he just kinda chills and doesn't change what he's doing but has no obvious signs of fin damage/illness, he's probably mellow enough to be fine no matter where you put him, be it on his own or in a community.
If you're lucky enough to be at a LFS
that keeps their bettas in the normal tanks alongside other fish, they've already done the work for you at figuring his personality out
I've been keeping bettas alongside just about every kind of community fish successfully for the last 15 years, even with ones that traditionally people tell you they'll attack on sight like guppies and gourami. It's all about being able to figure out the betta's personality, introducing it properly (typically I add them last, and sometimes even float them in a breeder box for a few days first), watching everyone like a hawk for the first week, and having a backup plan if it ends up not working out.