Added xml sequence template deserialiser and fixed template loader