Adding FromServicesAttribute.

Make calculator consume logging and register a singleton.