You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
4. install flagembedding package in development mode: `pip install -e .`
17
+
18
+
Then run the tests using pytest:
19
+
20
+
```bash
21
+
# Run all tests
22
+
pytest tests/
23
+
24
+
# Run a specific test file
25
+
pytest tests/test_imports_v5.py
26
+
27
+
# Run with verbose output
28
+
pytest -v tests/
29
+
```
30
+
31
+
## Transformers 5.0 Compatibility
32
+
33
+
The tests verify that FlagEmbedding works with Transformers 5.0, which removed the `is_torch_fx_available` function.
34
+
The compatibility layer in `FlagEmbedding/utils/transformers_compat.py` provides this function for backward compatibility.
35
+
36
+
**Note:** Transformers 5.0 requires Python 3.10 or higher. If you're using Python 3.9 or lower, you'll need to upgrade your Python version to test with Transformers 5.0.
37
+
38
+
To test with a specific version of transformers (with Python 3.10+):
0 commit comments