FROM python:3.11.2 RUN apt-get update && apt-get install -y \ git \ libaspell-dev \ aspell-es \ python3-dev \ build-essential \ pkg-config \ && rm -rf /var/lib/apt/lists/* WORKDIR /app COPY requirements.txt . COPY app.py . RUN pip install --upgrade pip && \ pip install --no-cache-dir -r requirements.txt && \ python -m spacy download es_core_news_sm RUN git clone https://github.com/WojciechMula/aspell-python.git && \ cd aspell-python && \ python3 setup.3.py build && \ python3 setup.3.py install && \ cd .. && rm -rf aspell-python RUN git clone --filter=blob:none --no-checkout https://github.com/google-research-datasets/C4_200M-synthetic-dataset-for-grammatical-error-correction.git && \ cd C4_200M-synthetic-dataset-for-grammatical-error-correction && \ git sparse-checkout init --cone && \ git sparse-checkout set multilingual && \ git checkout EXPOSE 7860 CMD ["python3", "app.py"]