Add decodeTask fn