add word logic