Add support of lua mode