Commit ·
7cd2a55
1
Parent(s): aa11860
refactor(ui): drop v16 legacy tab
Browse filesKeep only the v24 (new) feedback tab and the title proofreading sandbox.
v16 prompts/pipelines stay in the repo but are no longer surfaced in
the UI. _v16_prompt resolution removed from app.py.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
app.py
CHANGED
|
@@ -3,7 +3,6 @@
|
|
| 3 |
Tabs:
|
| 4 |
- v24 (new): solar-pro3 with FT + self-consistency × 2 + tool-calling
|
| 5 |
judge. paragraph F1 47.04 (vs solar-pro2 prod_251231 mean 44.86).
|
| 6 |
-
- v16 (legacy): solar-pro3 with the 260408_v16 single-pass pipeline.
|
| 7 |
- 제목 교열 (sandbox): solar-pro2 vs solar-pro3 side-by-side comparison
|
| 8 |
for newspaper title proofreading (default prompt hidden in UI).
|
| 9 |
"""
|
|
@@ -28,7 +27,7 @@ _vocab_path = os.path.join(os.path.dirname(__file__), "data", "vocabulary.csv")
|
|
| 28 |
vocabulary = load_vocabulary(_vocab_path)
|
| 29 |
|
| 30 |
|
| 31 |
-
prompt_choices = list_prompts() or ["
|
| 32 |
|
| 33 |
|
| 34 |
def _default_prompt(preferred_prefix: str, fallback: str) -> str:
|
|
@@ -38,7 +37,6 @@ def _default_prompt(preferred_prefix: str, fallback: str) -> str:
|
|
| 38 |
return fallback
|
| 39 |
|
| 40 |
|
| 41 |
-
_v16_prompt = _default_prompt("dev_260408_v16", prompt_choices[-1])
|
| 42 |
_v24_prompt = _default_prompt("dev_260429_v24", "dev_260429_v24")
|
| 43 |
|
| 44 |
with gr.Blocks(title="Chosun 교정교열 데모") as demo:
|
|
@@ -53,14 +51,6 @@ with gr.Blocks(title="Chosun 교정교열 데모") as demo:
|
|
| 53 |
elem_id_prefix="v24",
|
| 54 |
)
|
| 55 |
|
| 56 |
-
with gr.Tab("v16 (legacy · 260408)"):
|
| 57 |
-
build_feedback_tab(
|
| 58 |
-
client=client,
|
| 59 |
-
vocabulary=vocabulary,
|
| 60 |
-
pipeline_config=("260408_v16", "solar-pro3", _v16_prompt),
|
| 61 |
-
elem_id_prefix="v16",
|
| 62 |
-
)
|
| 63 |
-
|
| 64 |
with gr.Tab("제목 교열 (sandbox)"):
|
| 65 |
build_title_proofread_tab(client=client)
|
| 66 |
|
|
@@ -72,7 +62,7 @@ with gr.Blocks(title="Chosun 교정교열 데모") as demo:
|
|
| 72 |
document.addEventListener('keydown', (e) => {
|
| 73 |
if (!((e.metaKey || e.ctrlKey) && e.key === 'Enter')) return;
|
| 74 |
// Pick the run button on the *visible* tab (others' buttons are hidden).
|
| 75 |
-
const ids = ['title-proofread-run-btn', 'v24-run-btn'
|
| 76 |
for (const id of ids) {
|
| 77 |
const root = document.getElementById(id);
|
| 78 |
if (!root) continue;
|
|
|
|
| 3 |
Tabs:
|
| 4 |
- v24 (new): solar-pro3 with FT + self-consistency × 2 + tool-calling
|
| 5 |
judge. paragraph F1 47.04 (vs solar-pro2 prod_251231 mean 44.86).
|
|
|
|
| 6 |
- 제목 교열 (sandbox): solar-pro2 vs solar-pro3 side-by-side comparison
|
| 7 |
for newspaper title proofreading (default prompt hidden in UI).
|
| 8 |
"""
|
|
|
|
| 27 |
vocabulary = load_vocabulary(_vocab_path)
|
| 28 |
|
| 29 |
|
| 30 |
+
prompt_choices = list_prompts() or ["dev_260429_v24"]
|
| 31 |
|
| 32 |
|
| 33 |
def _default_prompt(preferred_prefix: str, fallback: str) -> str:
|
|
|
|
| 37 |
return fallback
|
| 38 |
|
| 39 |
|
|
|
|
| 40 |
_v24_prompt = _default_prompt("dev_260429_v24", "dev_260429_v24")
|
| 41 |
|
| 42 |
with gr.Blocks(title="Chosun 교정교열 데모") as demo:
|
|
|
|
| 51 |
elem_id_prefix="v24",
|
| 52 |
)
|
| 53 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 54 |
with gr.Tab("제목 교열 (sandbox)"):
|
| 55 |
build_title_proofread_tab(client=client)
|
| 56 |
|
|
|
|
| 62 |
document.addEventListener('keydown', (e) => {
|
| 63 |
if (!((e.metaKey || e.ctrlKey) && e.key === 'Enter')) return;
|
| 64 |
// Pick the run button on the *visible* tab (others' buttons are hidden).
|
| 65 |
+
const ids = ['title-proofread-run-btn', 'v24-run-btn'];
|
| 66 |
for (const id of ids) {
|
| 67 |
const root = document.getElementById(id);
|
| 68 |
if (!root) continue;
|