How large is the library in iCloud?
Your optimized photo library on the iPhone is also smaller on the Mac, because the display is smaller and the optimized versions on the iPhone can be smaller. Also Photos for Mac needs a bit more storage for working copies because it can do more than the than Photos for iOS, for example create smart albums. And the sandboxes for third party editors are stored inside the Photos Library package.When I let the Mac optimize the library fully by downloading a fresh copy of the library from iCloud (as described in the post by G0lfPr0_28, the library will temporarily shrink down to roughly 20% of the size in iCloud, but no less, because only the full size originals can be get rid off, but not the cached working copies for browsing and the internal databases, describing the albums and other relations between images.