Is there a way to batch find locally stored songs in Apple.Music and add them to library? Most of time I use Apple.Music for listening to music (from Mac and iPhone). Also I have locally stored music library (~1000 songs). So I want to find each local song at Apple.Music and add it to my iTunes music library. Is there a way to do it batch?
Your question isn't quite clear, so I'm making some assumptions here:
 - You're using a Mac, with iTunes.
 - You're either looking for a way to distinguish your own music from Apple Music for whatever reason (having non-DRMd versions of the songs in your own personal library)

I can't help you with the last part, but iTunes on the Mac (and I suppose Windows) stores Apple Music (extension m4p) files separately from Your music files (extension m4a, mp3, aac, etc)

Apple Stores Apple Music under the iTunes Library folder (which you can discover by going to the iTunes Preferences pane and looking at the last tab). Apple Music is typically stored under /iTunes Media/Apple Music whereas your music is stored under /iTunes Media/Music

Or you can execute a command like the following from the iTunes library folder that will list all the Apple Music files into a text document.

find . -name "*.m4p" -print &gt; textfile.txt