human
Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. 
###Database Schema: No. in Series, No. in Season, Title, Directed by, Written by, Original air date, U.S. viewers (millions)
###Question: Who wrote the episode whose director is Karen Gaviola?
gpt
SELECT Written by FROM table WHERE Directed by = Karen Gaviola