make extraction a bit smarter for multiple instances