Custom fairseq training input

hi everyone, i’m working with pytorch/fairseq. I have a project that need to build a Encoder Decoder that can receive src language, target language and pos tag of src language. I’ve read some fairseq code and it kinda complicated. So how to customize fairseq that can make it read the file of src language and pos tag them. Then encoder can receive the tensor of training data consists of words_embedding and tags_embedding.