streamlit-octostar-utils 0.1.7a4__py3-none-any.whl → 0.1.7a5__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -32,7 +32,7 @@ REGEX_NER_MODELS = {
32
32
  }
33
33
 
34
34
  BASE_TO_ONTONOTES_LABELMAP = {"PER": "PERSON"}
35
- BASE_ALLOWED_LABELS = ["PERSON", "ORG", "LOC", "NORP", "GPE", "PRODUCT", "DATE", "TIME", "PHONE"]
35
+ BASE_ALLOWED_LABELS = ["PERSON", "ORG", "LOC", "NORP", "GPE", "PRODUCT", "DATE", "TIME", "PHONE", "IP_ADDRESS", "EMAIL"]
36
36
 
37
37
 
38
38
  def _sumy__get_best_sentences(sentences, rating, *args, **kwargs):
@@ -96,6 +96,7 @@ class NERObject(object):
96
96
  }
97
97
  if self.sources:
98
98
  data["sources"] = self.sources
99
+ return data
99
100
 
100
101
  def __repr__(self):
101
102
  return f"NERObject(label={self.label},name={self.name})"
@@ -284,13 +285,4 @@ def get_ner_handler(language, fast=False, compression_ratio="auto"):
284
285
 
285
286
  @st.cache_resource
286
287
  def get_cached_ner_handler(language, fast):
287
- return get_ner_handler(language, fast)
288
-
289
-
290
- def test():
291
- text = """My name is Valerio Simoni, and I live in NYC. I love the Colosseum, and my phone is +123 456 789.
292
- my email is aaa@ggg.com, but my ip address is secret! 123.123.123.0:1111"""
293
- entities = get_ner_handler("english", True)(text)
294
- print(entities)
295
-
296
- test()
288
+ return get_ner_handler(language, fast)
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: streamlit-octostar-utils
3
- Version: 0.1.7a4
3
+ Version: 0.1.7a5
4
4
  Summary:
5
5
  License: MIT
6
6
  Author: Octostar
@@ -22,7 +22,7 @@ streamlit_octostar_utils/core/timestamp.py,sha256=a3s4xfm1nctLzYsHOJxqoWIDTdbNY_
22
22
  streamlit_octostar_utils/hello.py,sha256=JVeug8fnyYYf_qw6eeMDBrdqsSkiwnSHdPvb9puEGdA,69
23
23
  streamlit_octostar_utils/nlp/__init__.py,sha256=BtlYDZK_xaEbc7Ju_7MznXbCVPZcdLn26xwR9qf_UhM,336
24
24
  streamlit_octostar_utils/nlp/language.py,sha256=13f6kAALYjC3EclBzcyKPd4GlIeIR1mWPu3S6d-z814,549
25
- streamlit_octostar_utils/nlp/ner.py,sha256=mMCbUydVDkjl2seB5dlp5NXSqi3-hemurk1OexNJZzE,11611
25
+ streamlit_octostar_utils/nlp/ner.py,sha256=N9Y0d-DU55kb3WY0z3f44IX_eIXhD_jVH8tnuStffyY,11366
26
26
  streamlit_octostar_utils/octostar/__init__.py,sha256=AbpHGcgLb-kRsJGnwFEktk7uzpZOCcBY74-YBdrKVGs,1
27
27
  streamlit_octostar_utils/octostar/client.py,sha256=29tA1LY9ndLzAMR_KlL7Jb071YNAanubsppzy2BXb1E,1779
28
28
  streamlit_octostar_utils/octostar/context.py,sha256=TpucK48EbeVy4vDqKd9UULEtr1JOY-_4nBs-rXZzESw,212
@@ -37,7 +37,7 @@ streamlit_octostar_utils/threading/__init__.py,sha256=AbpHGcgLb-kRsJGnwFEktk7uzp
37
37
  streamlit_octostar_utils/threading/async_task_manager.py,sha256=q7N6YZwUvIYMzkSHmsJNheNVCv93c03H6Hyg9uH8pvk,4747
38
38
  streamlit_octostar_utils/threading/session_callback_manager.py,sha256=LvZVP4g6tvKtYmI13f2j1sX_7hm61Groqp5xJine9_k,3973
39
39
  streamlit_octostar_utils/threading/session_state_hot_swapper.py,sha256=6eeCQI6A42hp4DmW2NQw2rbeR-k9N8DhfBKQdN_fbLU,811
40
- streamlit_octostar_utils-0.1.7a4.dist-info/LICENSE,sha256=dkwVPyV03fPHHtERnF6RnvRXcll__tud9gWca1RcgnQ,1073
41
- streamlit_octostar_utils-0.1.7a4.dist-info/METADATA,sha256=qyNzLU0FuRUB0VI7RY6F3xXPH5in1Iv_pNr9kZobyho,2267
42
- streamlit_octostar_utils-0.1.7a4.dist-info/WHEEL,sha256=fGIA9gx4Qxk2KDKeNJCbOEwSrmLtjWCwzBz351GyrPQ,88
43
- streamlit_octostar_utils-0.1.7a4.dist-info/RECORD,,
40
+ streamlit_octostar_utils-0.1.7a5.dist-info/LICENSE,sha256=dkwVPyV03fPHHtERnF6RnvRXcll__tud9gWca1RcgnQ,1073
41
+ streamlit_octostar_utils-0.1.7a5.dist-info/METADATA,sha256=rhcd3gLwh_hMQ0UBj2Z7ggHpPuhyvfey6wxKe8OUvU4,2267
42
+ streamlit_octostar_utils-0.1.7a5.dist-info/WHEEL,sha256=fGIA9gx4Qxk2KDKeNJCbOEwSrmLtjWCwzBz351GyrPQ,88
43
+ streamlit_octostar_utils-0.1.7a5.dist-info/RECORD,,