I have use your library to my text summarize model, and i got error like the error message bellow.
I just make different thing in the token, where i turn <UNK> to unk, <s> to sostok, and </s> to eostok, to follow my vocab dictionary.
AttributeError Traceback (most recent call last)
Input In [111], in <cell line: 7>()
4 input_text = "Hello World !"
5 X = [encoder_vocabulary.get(t, encoder_vocabulary['unk']) for t in input_text.split()]
----> 7 hypotheses = beam_search(model.initial_state_function, model.generate_function, X, decoder_vocabulary['sostok'], decoder_vocabulary['eostok'])
9 for hypothesis in hypotheses:
11 generated_indices = hypothesis.to_sequence_of_values()
AttributeError: 'Functional' object has no attribute 'initial_state_function'
I have use your library to my text summarize model, and i got error like the error message bellow.
I just make different thing in the token, where i turn <UNK> to unk, <s> to sostok, and </s> to eostok, to follow my vocab dictionary.