Updated demo
Browse files
README.md
CHANGED
|
@@ -1,37 +1,13 @@
|
|
| 1 |
---
|
| 2 |
-
title: Demo
|
| 3 |
-
emoji:
|
| 4 |
-
colorFrom:
|
| 5 |
-
colorTo:
|
| 6 |
sdk: streamlit
|
| 7 |
app_file: app.py
|
| 8 |
-
pinned:
|
| 9 |
---
|
| 10 |
|
| 11 |
-
#
|
| 12 |
|
| 13 |
-
|
| 14 |
-
Display title for the Space
|
| 15 |
-
|
| 16 |
-
`emoji`: _string_
|
| 17 |
-
Space emoji (emoji-only character allowed)
|
| 18 |
-
|
| 19 |
-
`colorFrom`: _string_
|
| 20 |
-
Color for Thumbnail gradient (red, yellow, green, blue, indigo, purple, pink, gray)
|
| 21 |
-
|
| 22 |
-
`colorTo`: _string_
|
| 23 |
-
Color for Thumbnail gradient (red, yellow, green, blue, indigo, purple, pink, gray)
|
| 24 |
-
|
| 25 |
-
`sdk`: _string_
|
| 26 |
-
Can be either `gradio` or `streamlit`
|
| 27 |
-
|
| 28 |
-
`sdk_version` : _string_
|
| 29 |
-
Only applicable for `streamlit` SDK.
|
| 30 |
-
See [doc](https://hf.co/docs/hub/spaces) for more info on supported versions.
|
| 31 |
-
|
| 32 |
-
`app_file`: _string_
|
| 33 |
-
Path to your main application file (which contains either `gradio` or `streamlit` Python code).
|
| 34 |
-
Path is relative to the root of the repository.
|
| 35 |
-
|
| 36 |
-
`pinned`: _boolean_
|
| 37 |
-
Whether the Space stays on top of your list.
|
|
|
|
| 1 |
---
|
| 2 |
+
title: HuSpaCy Demo
|
| 3 |
+
emoji: 🚀
|
| 4 |
+
colorFrom: indigo
|
| 5 |
+
colorTo: gray
|
| 6 |
sdk: streamlit
|
| 7 |
app_file: app.py
|
| 8 |
+
pinned: true
|
| 9 |
---
|
| 10 |
|
| 11 |
+
# 🚀 HuSpacy Demo
|
| 12 |
|
| 13 |
+
This repository contains an app demonstrating the capabilities of [HuSpaCy](https://github.com/spacy-hu/spacy-hungarian-models). The demo is available at [Hugging Face Spaces](https://huggingface.co/spaces/huspacy/demo)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
app.py
CHANGED
|
@@ -1,5 +1,18 @@
|
|
| 1 |
import spacy_streamlit
|
| 2 |
|
| 3 |
-
|
| 4 |
-
|
| 5 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
import spacy_streamlit
|
| 2 |
|
| 3 |
+
|
| 4 |
+
models = {"hu_core_news_lg": "hu_core_news_lg"}
|
| 5 |
+
|
| 6 |
+
default_text = """Újraoltatta magát Szputnyik Light vakcinával a Covid-19 ellen Vlagyimir Putyin orosz elnök.
|
| 7 |
+
Itt az újabb kamatdöntés napja. Az MNB adhat irányt a forintnak."""
|
| 8 |
+
|
| 9 |
+
spacy_streamlit.visualize(
|
| 10 |
+
models,
|
| 11 |
+
default_text,
|
| 12 |
+
["parser", "ner", "tokens", "similarity"],
|
| 13 |
+
show_json_doc = False,
|
| 14 |
+
sidebar_title = "🚀 HuSpaCy",
|
| 15 |
+
sidebar_description = "Industrial strength Hungarian NLP",
|
| 16 |
+
similarity_texts = ("kifli", "zsemle"),
|
| 17 |
+
show_logo = False
|
| 18 |
+
)
|