What is this attachment that is connected to my home's main water line?
Looks like a valve installed to tap off of your main line for an irrigation system, then either abandoned or never used. The part on the far left is a knurled knob with a slot in it, probably designed for using a special "keyed" handle so that it could not be accidentally turned off and have your landscaping die. The seals likely failed from never being used, then managed to re-seal when you turned off the pressure. Expect it to fail again now, sooner than later. You should have it replaced or removed if you are never going to use it.