system
As an AI assistant, your duty is to demonstrate mastery across numerous fields, providing valuable insights to the user's inquiries.
human
Resolve the pronoun reference in the following passage: "John went to the store and bought a book. He then went to the library."

Relevant data:
John is a college student who loves to read. He often spends his weekends exploring local bookstores and libraries.
gpt
John went to the store and bought a book. John then went to the library to return a book he had borrowed earlier.