From 89dcafd3111ddaeaa2340b38b6f1034a00f91666 Mon Sep 17 00:00:00 2001 From: Austin Godber Date: Tue, 16 Sep 2025 08:12:36 -0700 Subject: [PATCH] ruff --- src/embeddingbuddy/app.py | 23 +++++------------ src/embeddingbuddy/ui/components/about.py | 31 +++++++++++------------ src/embeddingbuddy/ui/layout.py | 9 ++++--- 3 files changed, 28 insertions(+), 35 deletions(-) diff --git a/src/embeddingbuddy/app.py b/src/embeddingbuddy/app.py index 5bbf165..ac99c58 100644 --- a/src/embeddingbuddy/app.py +++ b/src/embeddingbuddy/app.py @@ -25,32 +25,23 @@ def create_app(): meta_tags=[ { "name": "description", - "content": "Interactive embedding visualization tool for exploring high-dimensional vectors through dimensionality reduction techniques like PCA, t-SNE, and UMAP." - }, - { - "name": "author", - "content": "EmbeddingBuddy" + "content": "Interactive embedding visualization tool for exploring high-dimensional vectors through dimensionality reduction techniques like PCA, t-SNE, and UMAP.", }, + {"name": "author", "content": "EmbeddingBuddy"}, { "name": "keywords", - "content": "embeddings, visualization, dimensionality reduction, PCA, t-SNE, UMAP, machine learning, data science" - }, - { - "name": "viewport", - "content": "width=device-width, initial-scale=1.0" + "content": "embeddings, visualization, dimensionality reduction, PCA, t-SNE, UMAP, machine learning, data science", }, + {"name": "viewport", "content": "width=device-width, initial-scale=1.0"}, { "property": "og:title", - "content": "EmbeddingBuddy - Interactive Embedding Visualization" + "content": "EmbeddingBuddy - Interactive Embedding Visualization", }, { "property": "og:description", - "content": "Explore and visualize embedding vectors through interactive 2D/3D plots with multiple dimensionality reduction techniques." + "content": "Explore and visualize embedding vectors through interactive 2D/3D plots with multiple dimensionality reduction techniques.", }, - { - "property": "og:type", - "content": "website" - } + {"property": "og:type", "content": "website"}, ], ) diff --git a/src/embeddingbuddy/ui/components/about.py b/src/embeddingbuddy/ui/components/about.py index 78e166c..5720e09 100644 --- a/src/embeddingbuddy/ui/components/about.py +++ b/src/embeddingbuddy/ui/components/about.py @@ -38,20 +38,19 @@ EmbeddingBuddy is a modular Python Dash web application for interactive explorat dbc.ModalTitle("About EmbeddingBuddy"), close_button=True, ), - dbc.ModalBody([ - dcc.Markdown( - self._get_about_content(), - className="mb-0" - ) - ]), - dbc.ModalFooter([ - dbc.Button( - "Close", - id="about-modal-close", - color="secondary", - n_clicks=0 - ) - ]), + dbc.ModalBody( + [dcc.Markdown(self._get_about_content(), className="mb-0")] + ), + dbc.ModalFooter( + [ + dbc.Button( + "Close", + id="about-modal-close", + color="secondary", + n_clicks=0, + ) + ] + ), ], id="about-modal", is_open=False, @@ -65,5 +64,5 @@ EmbeddingBuddy is a modular Python Dash web application for interactive explorat color="outline-info", size="sm", n_clicks=0, - className="ms-2" - ) \ No newline at end of file + className="ms-2", + ) diff --git a/src/embeddingbuddy/ui/layout.py b/src/embeddingbuddy/ui/layout.py index 3958537..963086e 100644 --- a/src/embeddingbuddy/ui/layout.py +++ b/src/embeddingbuddy/ui/layout.py @@ -24,13 +24,16 @@ class AppLayout: [ html.Div( [ - html.H1("EmbeddingBuddy", className="text-center mb-4 d-inline"), + html.H1( + "EmbeddingBuddy", + className="text-center mb-4 d-inline", + ), html.Div( [self.about.create_about_button()], - className="float-end" + className="float-end", ), ], - className="d-flex justify-content-between align-items-center" + className="d-flex justify-content-between align-items-center", ), # Load Transformers.js from CDN html.Script(