Spaces:
Runtime error
Runtime error
fastapi
Browse filesFiles changed (2)
- Dockerfile+2-1
- app/nltk.py+1-2
5 unmodified lines678910111212135 unmodified lines
RUN pip install --upgrade pipRUN pip install -r /code/app/requirements.txtRUN python /code/app/nltk.py
EXPOSE 7860
CMD python app/nltk.py && uvicorn app.main:app --host 0.0.0.0 --port 7860CMD ["uvicorn", "app.main:app", "--host", "0.0.0.0", "--port", "7860"]112354567# app/prepare_nltk.pyimport osimport nltk
NLTK_DATA_DIR = "/home/user/app/nltk_data"NLTK_DATA_DIR = "/code/nltk_data" # aman dan bisa ditulisos.makedirs(NLTK_DATA_DIR, exist_ok=True)nltk.data.path.append(NLTK_DATA_DIR)
Dockerfile+2-1
app/nltk.py+1-2