The summary should be completed towards the end; when you are able to overview your project as a whole.
It is nevertheless a good idea to work on a draft continuously.
Make a list of what is interesting about your topic.
Are there any current events it relates to or controversies associated with it that might be interesting for your introduction?
Having a brief introduction that sets the direction will help you a lot as you write.
Waiting to write the introduction until the end can leave you with a poorly written setup to an otherwise well-written paper.
Also, starting with a broader statement will appeal to a wider audience.
Consider who the paper is aimed at informing and then think of something that would grab their attention.
The amount of background information required will depend on the topic.
There should be enough background information so you don't have to spend too much time with it in the body of the thesis, but not so much that it becomes uninteresting.