Task Model and some fixes