Spaces:
Runtime error
Runtime error
change model for text summary
Browse files- Dockerfile +1 -1
- app.py +1 -1
Dockerfile
CHANGED
@@ -18,5 +18,5 @@ RUN mkdir -p /app/.cache && chmod -R 777 /app/.cache
|
|
18 |
ENV TRANSFORMERS_CACHE=/app/.cache
|
19 |
ENV HF_HOME=/app/.cache
|
20 |
|
21 |
-
# EXPOSE
|
22 |
CMD ["uvicorn", "app:app", "--reload", "--host", "0.0.0.0", "--port", "7860"]
|
|
|
18 |
ENV TRANSFORMERS_CACHE=/app/.cache
|
19 |
ENV HF_HOME=/app/.cache
|
20 |
|
21 |
+
# EXPOSE 7860
|
22 |
CMD ["uvicorn", "app:app", "--reload", "--host", "0.0.0.0", "--port", "7860"]
|
app.py
CHANGED
@@ -100,7 +100,7 @@ async def upload_image(image: UploadFile = File(...)):
|
|
100 |
text_summary = pipe(raw_text,do_sample=False)
|
101 |
summary_text_image =text_summary[0].get('summary_text')
|
102 |
return {
|
103 |
-
|
104 |
# "len":len(preprocessed_text),
|
105 |
"summary":summary_text_image,
|
106 |
"len summary":len(summary_text_image)
|
|
|
100 |
text_summary = pipe(raw_text,do_sample=False)
|
101 |
summary_text_image =text_summary[0].get('summary_text')
|
102 |
return {
|
103 |
+
"Text preprocessing": preprocessed_text,
|
104 |
# "len":len(preprocessed_text),
|
105 |
"summary":summary_text_image,
|
106 |
"len summary":len(summary_text_image)
|