1D anyons in relativistic field theory