def sign_book(self, author, title):
        book = self._setup_book()
        if book is None:
            return False
        book.nbt["author"] = nbt.TagString(author)
        book.nbt["title"] = nbt.TagString(title)
        # TODO: don't use hard coded id
        book.item_id = 387  # written book
        self.channels.send("MC|BSign", self._pack_book(book))
Sign current book in hand
dataset/ETHPy150Open SpockBotMC/SpockBot/spockbot/plugins/helpers/interact.py/InteractPlugin.sign_book