Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -292,18 +292,23 @@ def create_deployment_instructions():
|
|
| 292 |
# Create Gradio interface
|
| 293 |
with gr.Blocks(title="StyleForge Lite", theme=gr.themes.Soft()) as app:
|
| 294 |
gr.Markdown("# 🔬 StyleForge Lite")
|
| 295 |
-
gr.Markdown(
|
|
|
|
|
|
|
| 296 |
style_profile_state = gr.State("")
|
| 297 |
|
| 298 |
with gr.Tab("Style Analysis & Rewrite"):
|
| 299 |
with gr.Row():
|
| 300 |
with gr.Column(scale=1):
|
| 301 |
abstracts_input = gr.Textbox(
|
| 302 |
-
label="📝 Paste 3
|
| 303 |
-
placeholder="Paste
|
| 304 |
lines=10,
|
| 305 |
max_lines=15
|
| 306 |
)
|
|
|
|
|
|
|
|
|
|
| 307 |
|
| 308 |
original_text_input = gr.Textbox(
|
| 309 |
label="📄 Original Text to Rewrite",
|
|
@@ -318,10 +323,8 @@ with gr.Blocks(title="StyleForge Lite", theme=gr.themes.Soft()) as app:
|
|
| 318 |
rewrite_saved_btn = gr.Button("✍️ Rewrite Using Saved Profile", variant="secondary")
|
| 319 |
|
| 320 |
with gr.Column(scale=1):
|
| 321 |
-
|
| 322 |
-
|
| 323 |
-
value="",
|
| 324 |
-
)
|
| 325 |
rewritten_output = gr.Textbox(
|
| 326 |
label="✨ Rewritten Text",
|
| 327 |
lines=12,
|
|
|
|
| 292 |
# Create Gradio interface
|
| 293 |
with gr.Blocks(title="StyleForge Lite", theme=gr.themes.Soft()) as app:
|
| 294 |
gr.Markdown("# 🔬 StyleForge Lite")
|
| 295 |
+
gr.Markdown(
|
| 296 |
+
"Use 'Analyze Style' once to learn your style (abstracts optional), then 'Rewrite Using Saved Profile' for repeated rewrites."
|
| 297 |
+
)
|
| 298 |
style_profile_state = gr.State("")
|
| 299 |
|
| 300 |
with gr.Tab("Style Analysis & Rewrite"):
|
| 301 |
with gr.Row():
|
| 302 |
with gr.Column(scale=1):
|
| 303 |
abstracts_input = gr.Textbox(
|
| 304 |
+
label="📝 Optional: Paste 3–8 Abstracts (leave empty to use built‑in profile)",
|
| 305 |
+
placeholder="Paste 3–8 abstracts to learn YOUR style, or leave empty to use the embedded Dr. Banaganapalli style and examples.",
|
| 306 |
lines=10,
|
| 307 |
max_lines=15
|
| 308 |
)
|
| 309 |
+
gr.Markdown(
|
| 310 |
+
"Tip: Click 'Analyze Style' to generate a 10‑point profile. The profile is saved for this session."
|
| 311 |
+
)
|
| 312 |
|
| 313 |
original_text_input = gr.Textbox(
|
| 314 |
label="📄 Original Text to Rewrite",
|
|
|
|
| 323 |
rewrite_saved_btn = gr.Button("✍️ Rewrite Using Saved Profile", variant="secondary")
|
| 324 |
|
| 325 |
with gr.Column(scale=1):
|
| 326 |
+
gr.Markdown("### 🧬 Style Profile")
|
| 327 |
+
profile_md = gr.Markdown("")
|
|
|
|
|
|
|
| 328 |
rewritten_output = gr.Textbox(
|
| 329 |
label="✨ Rewritten Text",
|
| 330 |
lines=12,
|