support dict pattern