Thanks for the help. Nicd points out the thing I was missing in that patterns aren’t first class.
Anyone who comes here in the future who wants to have a function with a dynamic match this is how I ended up doing it
def get_items(filters \\ %{}) do
filters = MapSet.new(filters)
for item <- get_all_items(),
MapSet.subset?(filters, MapSet.new(item)),
do: item
end


















