Offsets in original text from tokenizers
## 🚀 Feature

A new method for tokenizers: tokenize_with_offsets. In addition to returning the tokens, it returns the spans in the original text that the tokens correspond to.
After
tokens, offsets = tokenizer.tokenize_with_offsets(text)
then
tokens[i] maps to text[offsets[i, 0]:offsets[i, 1]]

## Motivation

I find it useful to be able to get the spans in the original text where the tokens come from. This is useful for example in extractive question answering, where the model predicts a sequence of tokens, but the user would like to see a highlighted passage.

## Additional context

I have a version of this in a fork: https://github.com/michaelrglass/pytorch-transformers
There is a test (regression_test_tokenization_with_offsets) that verifies the tokenization with offsets gives the same tokenization for many models - still working on XLM.
The test data I used is available from https://ibm.box.com/s/228183fe95ptn8eb9n0zq4i2y7picq4r

Since this touches several files, and works for the majority (but not all) of the tokenizers, I thought creating an issue for discussion would be better than an immediate pull request.
I am glad to see someone is working on this and really appreciate your work.
Currently I'm using LCS the original xlnet also uses to align the token and raw input to extract the answer highlighting.
This is really painful as it's slow and may fail at some corner case.
Can't wait to see your pulled feature merged!<|||||>Commenting in #1274 thread<|||||>This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
