fix spacy and en_core_web_sm errors
Browse files- Dockerfile +4 -0
Dockerfile
CHANGED
@@ -13,6 +13,10 @@ RUN python -m spacy download en_core_web_sm
|
|
13 |
RUN sed -i 's/from pydantic import ConstrainedStr/from pydantic.v1 import ConstrainedStr/' \
|
14 |
/usr/local/lib/python3.10/site-packages/spacy/schemas.py
|
15 |
|
|
|
|
|
|
|
|
|
16 |
# Copy the local en_core_web_sm-3.0.0.tar.gz file into the container
|
17 |
# COPY ./en_core_web_sm-3.0.0.tar.gz /models/en_core_web_sm-3.0.0.tar.gz
|
18 |
|
|
|
13 |
RUN sed -i 's/from pydantic import ConstrainedStr/from pydantic.v1 import ConstrainedStr/' \
|
14 |
/usr/local/lib/python3.10/site-packages/spacy/schemas.py
|
15 |
|
16 |
+
|
17 |
+
# Install Pydantic v1 and SpaCy explicitly to prevent version conflicts
|
18 |
+
RUN pip install pydantic==1.10.12 spacy==3.5.3
|
19 |
+
|
20 |
# Copy the local en_core_web_sm-3.0.0.tar.gz file into the container
|
21 |
# COPY ./en_core_web_sm-3.0.0.tar.gz /models/en_core_web_sm-3.0.0.tar.gz
|
22 |
|