"개하고 도서관에 다녀요."
Translation:Let's go to the library with the dog.
If I recall correctly, a noun ending with -하고 always means "with" if it's at the end of the only noun or the last noun in a sentence (if that makes sense). So 나는 개하고 다녀요 would be "I go with the dog" while 나하고 개를 다녀요 would be "I and the dog go". But in this context "Go with me and the dog" might be more correct.