The meanings of these two words are different.
Written by: The drafter (author) of this couplet focuses on the content rather than the writing form.
Title: It can be the author of the content or the writer, including content creation and inscription.
If the content and words are all written by one person, the title can also be used, or "compiled and written".