From 32a8564c79dd9cbee00992b0f07ad5decb4b4dca Mon Sep 17 00:00:00 2001 From: Matthew Honnibal Date: Tue, 17 Oct 2017 18:20:24 +0200 Subject: [PATCH] Fix doc pickling --- spacy/tokens/doc.pyx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/spacy/tokens/doc.pyx b/spacy/tokens/doc.pyx index 5681df030..158cb9220 100644 --- a/spacy/tokens/doc.pyx +++ b/spacy/tokens/doc.pyx @@ -919,7 +919,7 @@ cdef int set_children_from_heads(TokenC* tokens, int length) except -1: def pickle_doc(doc): - bytes_data = doc.to_bytes(exclude='vocab') + bytes_data = doc.to_bytes(vocab=False) return (unpickle_doc, (doc.vocab, doc.user_data, bytes_data))