I recently noticed there was a "delete duplicate frames" option added to SVP at some point so that compelled me to give this frame replacement feature another attempt. After an hour of looking through the avisynth wiki I came up with this code for "generate.js":
if(profile.delete_dupe_frames)
{
AVS.push("ConditionalFilter(last, last.DeleteFrame(), last, "YDifferenceToNext()", "==", "0");
AVS.push("");
}
Unfortunately I get an error message: "Plane Difference: This filter can only be used within run-time filters". My limited understanding is that ConditionalFilter is a run-time filter so I don't know why I'm getting this error and I don't know how to fix it.