j-higgins commited on
Commit
5ce8e7b
·
unverified ·
1 Parent(s): 3491122

Update app.py

Browse files

fixed import statements for Render

Files changed (1) hide show
  1. app.py +9 -9
app.py CHANGED
@@ -1,25 +1,25 @@
1
- import pandas as pd
2
  import dash
 
 
 
 
 
 
 
 
 
3
  from dash import dcc, html
4
  from dash.dash_table import DataTable
5
  from dash.dependencies import Output, Input, State
6
  import plotly.express as px
7
- import dash_bootstrap_components as dbc
8
  import spacy
9
  from sentence_transformers import SentenceTransformer
10
  from sklearn.metrics.pairwise import cosine_similarity
11
  from gliner_spacy.pipeline import GlinerSpacy
12
  import warnings
13
  import threading
14
-
15
  warnings.filterwarnings("ignore", message="The sentencepiece tokenizer")
16
 
17
- # Initialize Dash app with Bootstrap theme and Font Awesome
18
- external_stylesheets = [dbc.themes.DARKLY, 'https://use.fontawesome.com/releases/v5.8.1/css/all.css']
19
- app = dash.Dash(__name__, external_stylesheets=external_stylesheets)
20
-
21
- server = app.server
22
-
23
  # Configuration for GLiNER integration
24
  custom_spacy_config = {
25
  "gliner_model": "urchade/gliner_small-v2.1",
 
 
1
  import dash
2
+ import dash_bootstrap_components as dbc
3
+
4
+ # Initialize Dash app with Bootstrap theme and Font Awesome
5
+ app = dash.Dash(__name__, external_stylesheets=[dbc.themes.DARKLY, 'https://use.fontawesome.com/releases/v5.8.1/css/all.css'])
6
+
7
+ # Create server variable
8
+ server = app.server
9
+
10
+ import pandas as pd
11
  from dash import dcc, html
12
  from dash.dash_table import DataTable
13
  from dash.dependencies import Output, Input, State
14
  import plotly.express as px
 
15
  import spacy
16
  from sentence_transformers import SentenceTransformer
17
  from sklearn.metrics.pairwise import cosine_similarity
18
  from gliner_spacy.pipeline import GlinerSpacy
19
  import warnings
20
  import threading
 
21
  warnings.filterwarnings("ignore", message="The sentencepiece tokenizer")
22
 
 
 
 
 
 
 
23
  # Configuration for GLiNER integration
24
  custom_spacy_config = {
25
  "gliner_model": "urchade/gliner_small-v2.1",