Fixed bugs and ctd impl pipeline