Intermediate
Open
Pro
Classify 5,000-Token Documents With a 512-Token Encoder
You must classify customer email threads into 12 categories. Threads average 5,000 tokens: a long quoted history, with the customer's newest message at the end and an automatic header at the top. A DeBERTa-class encoder fine-tuned on the first 512 tokens scores far below your TF-IDF baseline on the validation set.
- Explain what likely went wrong, with arithmetic on how much of each thread the model sees.
- List three truncation or chunking strategies with their cost in tokens, and say which you would try first and why.
- Describe how you would aggregate predictions over windows, and one failure mode of each aggregation.
- Say how you would check, before building anything, where the evidence lives.
- Give two alternatives that avoid a long encoder altogether.
Share this question