Created factory for creating user agents