dictionary and distribution extraction