The process of creating a screenplay or teleplay, including format, structure, and character development.