Auto cutting alternate video for an existing video clip

Is anyone aware of a workflow that can scan a video file and find identical clips contained in another video? Ideally, I’d like to be able to take something like say a 480p compilation, point to a higher resolution video (or folder of the same source content) and have it output a re-cut version of the starting file. I’d like to have the choice of matching via either visual frame hashing or audio fingerprinting. Secondarilly, having something spit out just the matching timestamps to a text file or something would still be very useful to me.

I want a tool that will save a bunch of time restoring mult-video compilations or even edit’s of single videos.

Existing tools seem to mostly compare full videos. You could vibecode a solution using PySceneDetect and Videohash.

The closest I could find in short notice, but would probably require a pipeline around it: