Added adaptive template