There appears to be a version conflict with safe and transformers v5.
File ".../autohyp/molgen/genmol/utils.py", line 6, in <module>
import safe as sf
^^^^^^^^^^^^
File ".../env/lib/python3.12/site-packages/safe/__init__.py", line 4, in <module>
from .sample import SAFEDesign
^^^^^^^^^^^^^^^^^
File ".../env/lib/python3.12/site-packages/safe/sample.py", line 17, in <module>
from transformers.generation import DisjunctiveConstraint, PhrasalConstraint
^^^^^^^^^^^^^^^^^
ImportError: cannot import name 'DisjunctiveConstraint' from 'transformers.generation' (.../env/lib/python3.12/site-packages/transformers/generation/__init__.py)
It can be fixed by reducing the transformers version to "transformers<5", and I'd suggest updating the pyproject.toml accordingly. I haven't yet worked out what changes to make to the imports within safe.
There appears to be a version conflict with safe and transformers v5.
It can be fixed by reducing the transformers version to "transformers<5", and I'd suggest updating the pyproject.toml accordingly. I haven't yet worked out what changes to make to the imports within safe.