GFQL Edge Matchers#
e_forward#
- graphistry.compute.ast.e_forward = <class 'graphistry.compute.ast.ASTEdgeForward'>#
Internal, not intended for use outside of this module.
- Parameters:
edge_match (dict | None)
hops (int | None)
min_hops (int | None)
max_hops (int | None)
output_min_hops (int | None)
output_max_hops (int | None)
label_node_hops (str | None)
label_edge_hops (str | None)
label_seeds (bool)
source_node_match (dict | None)
destination_node_match (dict | None)
to_fixed_point (bool)
name (str | None)
source_node_query (str | None)
destination_node_query (str | None)
edge_query (str | None)
- e_forward
Primary alias for the
graphistry.compute.ast.ASTEdgeForwardclass.Note
While e_forward is the preferred alias for this class, the methods and attributes are defined under
graphistry.compute.ast.ASTEdgeForward.
- class graphistry.compute.ast.ASTEdgeForward(edge_match=None, hops=1, min_hops=None, max_hops=None, output_min_hops=None, output_max_hops=None, label_node_hops=None, label_edge_hops=None, label_seeds=False, source_node_match=None, destination_node_match=None, to_fixed_point=False, name=None, source_node_query=None, destination_node_query=None, edge_query=None)#
Bases:
ASTEdgeInternal, not intended for use outside of this module.
- Parameters:
edge_match (dict | None)
hops (int | None)
min_hops (int | None)
max_hops (int | None)
output_min_hops (int | None)
output_max_hops (int | None)
label_node_hops (str | None)
label_edge_hops (str | None)
label_seeds (bool)
source_node_match (dict | None)
destination_node_match (dict | None)
to_fixed_point (bool)
name (str | None)
source_node_query (str | None)
destination_node_query (str | None)
edge_query (str | None)
- direction: Literal['forward', 'reverse', 'undirected']#
- classmethod from_json(d, validate=True)#
Given c.to_json(), hydrate back c
- Args:
d: Dictionary from to_json() validate: If True (default), validate after parsing
- Returns:
Hydrated AST object
- Raises:
GFQLValidationError: If validate=True and validation fails
- Parameters:
d (dict)
validate (bool)
- Return type:
- reserved_fields = ['type']#
- to_json(validate=True)#
Returns JSON-compatible dictionry {“type”: “ClassName”, “arg1”: val1, …} Emits all non-reserved instance fields
- Return type:
dict
- validate(collect_all=False)#
Validate this AST node.
- Args:
- collect_all: If True, collect all errors instead of raising on first.
If False (default), raise on first error.
- Returns:
If collect_all=True: List of validation errors (empty if valid) If collect_all=False: None if valid
- Raises:
GFQLValidationError: If collect_all=False and validation fails
- Parameters:
collect_all (bool)
- Return type:
List[GFQLValidationError] | None
e_reverse#
- graphistry.compute.ast.e_reverse = <class 'graphistry.compute.ast.ASTEdgeReverse'>#
Internal, not intended for use outside of this module.
- Parameters:
edge_match (dict | None)
hops (int | None)
min_hops (int | None)
max_hops (int | None)
output_min_hops (int | None)
output_max_hops (int | None)
label_node_hops (str | None)
label_edge_hops (str | None)
label_seeds (bool)
source_node_match (dict | None)
destination_node_match (dict | None)
to_fixed_point (bool)
name (str | None)
source_node_query (str | None)
destination_node_query (str | None)
edge_query (str | None)
- e_reverse
Primary alias for the
graphistry.compute.ast.ASTEdgeReverseclass.Note
While e_reverse is the preferred alias for this class, the methods and attributes are defined under
graphistry.compute.ast.ASTEdgeReverse.
- class graphistry.compute.ast.ASTEdgeReverse(edge_match=None, hops=1, min_hops=None, max_hops=None, output_min_hops=None, output_max_hops=None, label_node_hops=None, label_edge_hops=None, label_seeds=False, source_node_match=None, destination_node_match=None, to_fixed_point=False, name=None, source_node_query=None, destination_node_query=None, edge_query=None)#
Bases:
ASTEdgeInternal, not intended for use outside of this module.
- Parameters:
edge_match (dict | None)
hops (int | None)
min_hops (int | None)
max_hops (int | None)
output_min_hops (int | None)
output_max_hops (int | None)
label_node_hops (str | None)
label_edge_hops (str | None)
label_seeds (bool)
source_node_match (dict | None)
destination_node_match (dict | None)
to_fixed_point (bool)
name (str | None)
source_node_query (str | None)
destination_node_query (str | None)
edge_query (str | None)
- direction: Literal['forward', 'reverse', 'undirected']#
- classmethod from_json(d, validate=True)#
Given c.to_json(), hydrate back c
- Args:
d: Dictionary from to_json() validate: If True (default), validate after parsing
- Returns:
Hydrated AST object
- Raises:
GFQLValidationError: If validate=True and validation fails
- Parameters:
d (dict)
validate (bool)
- Return type:
- reserved_fields = ['type']#
- to_json(validate=True)#
Returns JSON-compatible dictionry {“type”: “ClassName”, “arg1”: val1, …} Emits all non-reserved instance fields
- Return type:
dict
- validate(collect_all=False)#
Validate this AST node.
- Args:
- collect_all: If True, collect all errors instead of raising on first.
If False (default), raise on first error.
- Returns:
If collect_all=True: List of validation errors (empty if valid) If collect_all=False: None if valid
- Raises:
GFQLValidationError: If collect_all=False and validation fails
- Parameters:
collect_all (bool)
- Return type:
List[GFQLValidationError] | None
e#
- graphistry.compute.ast.e = <class 'graphistry.compute.ast.ASTEdgeUndirected'>#
Internal, not intended for use outside of this module.
- Parameters:
edge_match (dict | None)
hops (int | None)
min_hops (int | None)
max_hops (int | None)
output_min_hops (int | None)
output_max_hops (int | None)
label_node_hops (str | None)
label_edge_hops (str | None)
label_seeds (bool)
source_node_match (dict | None)
destination_node_match (dict | None)
to_fixed_point (bool)
name (str | None)
source_node_query (str | None)
destination_node_query (str | None)
edge_query (str | None)
- e
Primary alias for the
graphistry.compute.ast.ASTEdgeUndirectedclass.Note
While e is the preferred alias for this class, the methods and attributes are defined under
graphistry.compute.ast.ASTEdgeUndirected.- e_undirected
Secondary alias for the
graphistry.compute.ast.ASTEdgeUndirectedclass.
- class graphistry.compute.ast.ASTEdgeUndirected(edge_match=None, hops=1, min_hops=None, max_hops=None, output_min_hops=None, output_max_hops=None, label_node_hops=None, label_edge_hops=None, label_seeds=False, source_node_match=None, destination_node_match=None, to_fixed_point=False, name=None, source_node_query=None, destination_node_query=None, edge_query=None)#
Bases:
ASTEdgeInternal, not intended for use outside of this module.
- Parameters:
edge_match (dict | None)
hops (int | None)
min_hops (int | None)
max_hops (int | None)
output_min_hops (int | None)
output_max_hops (int | None)
label_node_hops (str | None)
label_edge_hops (str | None)
label_seeds (bool)
source_node_match (dict | None)
destination_node_match (dict | None)
to_fixed_point (bool)
name (str | None)
source_node_query (str | None)
destination_node_query (str | None)
edge_query (str | None)
- direction: Literal['forward', 'reverse', 'undirected']#
- classmethod from_json(d, validate=True)#
Given c.to_json(), hydrate back c
- Args:
d: Dictionary from to_json() validate: If True (default), validate after parsing
- Returns:
Hydrated AST object
- Raises:
GFQLValidationError: If validate=True and validation fails
- Parameters:
d (dict)
validate (bool)
- Return type:
- reserved_fields = ['type']#
- to_json(validate=True)#
Returns JSON-compatible dictionry {“type”: “ClassName”, “arg1”: val1, …} Emits all non-reserved instance fields
- Return type:
dict
- validate(collect_all=False)#
Validate this AST node.
- Args:
- collect_all: If True, collect all errors instead of raising on first.
If False (default), raise on first error.
- Returns:
If collect_all=True: List of validation errors (empty if valid) If collect_all=False: None if valid
- Raises:
GFQLValidationError: If collect_all=False and validation fails
- Parameters:
collect_all (bool)
- Return type:
List[GFQLValidationError] | None