The National Guard personnel were there under the command of the law enforcement and not under military command authority. The military in the U.S. is prohibited from conducting operations domestically unless under a presidential order.
US Civil and US Military Command structures should be quite separate (responsibility and traceable command authority) but they seem to have become blurred and relatively indistinguishable with command structures such NORTHCOM (Command is mostly ex SFs) and its subordinate commands such as Joint Task Force Civil Support (JTF-CS) with expertise in CBRNE
http://www.northcom.mil/About/index.html#JTFCSRedactedI saw the Secret Service involvement and even Diplomatic Security service involved in the Boston event. Exactly where the buck stopped and who actually had overall command authority whether it was military i.e. National Guard, NORTHCOM Joint Task Force Civil Support, or Civil command such as Secret Service, DHS ATF, Sheriffs department, Boston Police, State Police or FBI JTTF or what other alphabet soup agency was calling the shots was a little unclear.