<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def searchForGroups(self, name, limit=10):
 """ Find and get group thread by its name :param name: Name of the group thread :param limit: The max. amount of groups to fetch :return: :class:`models.Group` objects, ordered by relevance :rtype: list :raises: FBchatException if request failed """

        params = {"search": name, "limit": limit}
        j = self.graphql_request(GraphQL(query=GraphQL.SEARCH_GROUP, params=params))

        return [Group._from_graphql(node) for node in j["viewer"]["groups"]["nodes"]]