How could I convert output tensor from transformer to text generation?
# 🚀 Feature request

https://github.com/onnx/models/blob/master/text/machine_comprehension/gpt-2/dependencies/GPT2-export.py

I succeeded in extracting the output tensor value for the example input text using the above example. The link above imports  your hugging face transformer, so I wonder how I can text generate with the output tensor value I got.

Is there a code or a link I can refer to? (Pytorch or python code..)

The code I tried is as follows. But it didn't work.
![image](https://user-images.githubusercontent.com/42932221/126746354-2c3387aa-1eb1-4135-bd33-87a50c3be28b.png)

'ort_outputs_exmodel' above image is same as 'res' link below
https://github.com/onnx/models/blob/ad5c181f1646225f034fba1862233ecb4c262e04/text/machine_comprehension/gpt-2/dependencies/GPT2-export.py#L110

My final goal of the project is to load the onnx model using onnx runtime's C/C++ API and write the C/C++ code to generate text using output tensor values.

I'll be waiting for your reply. (looking forward to...)
Thank u very much.

## Motivation

I need advice on how to run text generation using output tensor values. 

## Your contribution

<!-- Is there any way that you could help, e.g. by submitting a PR?
     Make sure to read the CONTRIBUTING.MD readme:
     https://github.com/huggingface/transformers/blob/master/CONTRIBUTING.md -->

This issue has been automatically marked as stale because it has not had recent activity. If you think this still needs to be addressed please comment on this thread.

Please note that issues that do not follow the [contributing guidelines](https://github.com/huggingface/transformers/blob/master/CONTRIBUTING.md) are likely to be ignored.