def from_schema(cls, schema, handlers={}, **kwargs):
        """
        Construct a resolver from a JSON schema object.
        """
        return cls(
            schema.get('$id', schema.get('id', '')) if isinstance(schema, dict) else '',
            schema,
            handlers=handlers,
            **kwargs
        )
Construct a resolver from a JSON schema object.