The definition of a screenplay is a written text that provides the basis for a film production. Screenplays usually include not only the dialogue spoken by the characters but also a shot-by-shot outline of the film’s action.
A film I think has a really good screenplay is The Silence of the Lambs as it was adopted very cleverly from a novel by Thomas Harris.