Repository: graphistry/pygraphistry

Issue:
[FEA] predicates dont translate from json to python
```
import graphistry
from graphistry import n, e_forward, is_in

chain_operations = graphistry.Chain([n(name="is_carib_bank_origin"),e_forward(hops=1, edge_match={"originator_bank_country": is_in(options=["Cayman Islands", "Bermuda", "Virgin Islands British", "British Virgin Islands", "Bahamas", "Panama", "Barbados"])}),
])

graphistry.Chain.from_json(chain_operations.to_json())
```

this doesnt work

Discussion:

Patch:
diff --git a/CHANGELOG.md b/CHANGELOG.md
index ea4821ae..e2ab8fa7 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -7,6 +7,12 @@ This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.htm
 
 ## [Development]
 
+## [0.33.8 - 2024-04-30]
+
+### Added
+
+* Fix from_json when json object contains predicates.
+
 ## [0.33.7 - 2024-04-06]
 
 * Fix refresh() for SSO
diff --git a/graphistry/compute/ast.py b/graphistry/compute/ast.py
index c1e7b4e0..d478c23f 100644
--- a/graphistry/compute/ast.py
+++ b/graphistry/compute/ast.py
@@ -10,6 +10,8 @@ from graphistry.compute.ASTSerializable import ASTSerializable
 from graphistry.util import setup_logger
 from graphistry.utils.json import JSONVal, is_json_serializable
 from .predicates.ASTPredicate import ASTPredicate
+from .predicates.from_json import from_json as predicates_from_json
+
 from .predicates.is_in import (
     is_in, IsIn
 )
@@ -100,7 +102,7 @@ def maybe_filter_dict_from_json(d: Dict, key: str) -> Optional[Dict]:
         return None
     if key in d and isinstance(d[key], dict):
         return {
-            k: ASTPredicate.from_json(v) if isinstance(v, dict) else v
+            k: predicates_from_json(v) if isinstance(v, dict) else v
             for k, v in d[key].items()
         }
     elif key in d and d[key] is not None:


Test patch:
diff --git a/graphistry/tests/compute/test_chain.py b/graphistry/tests/compute/test_chain.py
index c685edb8..ea3fb232 100644
--- a/graphistry/tests/compute/test_chain.py
+++ b/graphistry/tests/compute/test_chain.py
@@ -44,6 +44,19 @@ def test_chain_serialization_multi():
     o2 = d.to_json()
     assert o == o2
 
+def test_chain_serialization_pred():
+    o = Chain([n(query='zzz', name='abc', filter_dict={'a': is_in(options=['a', 'b', 'c'])}),
+               e(edge_query='zzz', name='abc', edge_match={'b': is_in(options=['a', 'b', 'c'])})]).to_json()
+    d = Chain.from_json(o)
+    assert isinstance(d.chain[0], ASTNode)
+    assert d.chain[0].query == 'zzz'
+    assert d.chain[0]._name == 'abc'
+    assert isinstance(d.chain[1], ASTEdge)
+    assert d.chain[1].edge_query == 'zzz'
+    assert d.chain[1]._name == 'abc'
+    o2 = d.to_json()
+    assert o == o2
+
 def test_chain_simple_cudf_pd():
     nodes_df = pd.DataFrame({'id': [0, 1, 2], 'label': ['a', 'b', 'c']})
     edges_df = pd.DataFrame({'src': [0, 1, 2], 'dst': [1, 2, 0]})