Homework Help? Python in Jupyter Lab

I am in a digital humanities class that is barely doing any coding with python through jupyter lab.
My code wasn’t working. I went to my teacher. She fixed it. But I’m dumb and didn’t save it and now its gone. I understand what she did but I know how she did it.

so this the assignment. it may be a little tweaked.
digital-history/hist3368-week9-named-entity-recognition-congress-workhorse.ipynb at master · stephbuon/digital-history · GitHub

so I’m trying to create a graph of the most used words (geopolitical entities) in congress in speeches in 1989. I want it to be per month. I think this image of code is what she put in or what she tried before the last autosave. or what i messed up. i just cannot figure out how to to make this code not be in error and then the next set of code show a graph with the x axis being 1/1989-12/1989. or however it is easier to format it.

I would greatly appreciate any help!!