Improved assembly scanner that skips irrelevant files

also, the logic is put in `AssemblyScanner` only

for #1289