having trouble building the appropriate dict, but progress