# Week 3 Assignment 3 (Question Answering) Exercise 3 "answer_question" unit testing doesn't work

I’m working the very last part of the assignment of C4W3. I was facing the problem as indicated in the following screenshot and has been debugged for days, but such error just happened recurrently.

Any tips/suggestions would be greatly appreciated, thanks in advance!

1 Like

The inputs to this function transformer_utils.next_word are probably not right, check them above and also in other parts of the assignment if they are present.

Thank you, I tried to change the arguments order of next_word = transformer_utils.next_word(model, padded_question, tokenized_answer), but it still returns errors indicating dtype mismatch.

I’ve figured it out, thanks for your tips!

1 Like

Can I ask how you solved it in the end? I can’t really figure out what is wrong with that input, I am getting the same error

Hi Alhepburn,
You can see that from the previous example the model should be at the latest like transformer. Thus, the arrange ment should be question–>ANS–> Model etc.

1 Like