mistralai / mistral-common

Apache License 2.0
467 stars 36 forks source link

Make assistant tokenization error message more specific #4

Open patrickvonplaten opened 2 months ago

patrickvonplaten commented 2 months ago

Most tokenizer exception arguably come from the message being empty. Currently this gives the following error message:

'Invalid assistant message: '

which looks a bit incomplete. I think it'd be better to throw:

'Empty assistant message.'