added method to find set of applicable phrases and fleshed out beam class