jin2li commited on
Commit
1330d1c
Β·
verified Β·
1 Parent(s): be79381

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -3
app.py CHANGED
@@ -1841,7 +1841,7 @@ def process_single_ingredient(
1841
  f"- 선택 κ΅­κ°€ 수: {len(countries)}개\n"
1842
  f"- MFDS μƒνƒœ: {mfds_live_msg}\n"
1843
  f"- MFDS 쑰회 λŒ€μƒ: {', '.join(terms) if terms else 'μ—†μŒ'}\n"
1844
- "- νŒμ • 방식: GPT νŒμ • μ—†μŒ, Annex/Negative/Positive List 기반 고속 인덱슀 검색 + μ‹μ•½μ²˜ 체크 ON μ‹œ μ‹€μ‹œκ°„ κ²°κ³Ό μ‚¬μš©\n"
1845
  "- κΈˆμ§€ μ„±λΆ„: ν•¨λŸ‰ μœ λ¬΄μ™€ λ¬΄κ΄€ν•˜κ²Œ λ°°ν•©κΈˆμ§€ μš°μ„  ν‘œμ‹œ\n"
1846
  )
1847
  return result_df, msg
@@ -1876,7 +1876,6 @@ with gr.Blocks(css=custom_css) as demo:
1876
  with gr.Tab("πŸ”Ž 단일 μ„±λΆ„ 검색"):
1877
  single_country=gr.CheckboxGroup(choices=get_country_folders(),value=[],label="🌍 검색 κ΅­κ°€ / 채널 선택",elem_id="single_country_checks")
1878
  single_refresh=gr.Button("πŸ”„ κ΅­κ°€/규제파일 μƒˆλ‘œκ³ μΉ¨")
1879
- single_warmup_btn=gr.Button("⚑ 단일검색 μΊμ‹œ 미리 λ§Œλ“€κΈ°")
1880
  single_query=gr.Textbox(label="검색어",placeholder="예: 호λͺ¨μ‚΄λ ˆμ΄νŠΈ / Homosalate / 118-56-9 / 트라λ„₯μ‚¬λ―Ήμ• μ”¨λ“œ")
1881
  with gr.Row():
1882
  single_amount=gr.Textbox(label="ν•¨λŸ‰ %(w/w) 선택 μž…λ ₯",placeholder="예: 7.2")
@@ -1885,7 +1884,6 @@ with gr.Blocks(css=custom_css) as demo:
1885
  single_btn=gr.Button("πŸ”Ž 단일 μ„±λΆ„ 검색 μ‹œμž‘",variant="primary")
1886
  single_df_out=gr.Dataframe(label="단일 μ„±λΆ„ 검색 κ²°κ³Ό",wrap=True,interactive=False)
1887
  single_msg_out=gr.Textbox(label="검색 μƒνƒœ / λ©”μ‹œμ§€",interactive=False,lines=8)
1888
- single_warmup_btn.click(warmup_country_indexes,inputs=single_country,outputs=single_msg_out)
1889
  single_refresh.click(refresh_country_choices_and_clear_cache,inputs=single_country,outputs=single_country)
1890
  single_btn.click(process_single_ingredient,inputs=[single_country,single_query,single_amount,single_function,single_use_mfds_live],outputs=[single_df_out,single_msg_out])
1891
 
 
1841
  f"- 선택 κ΅­κ°€ 수: {len(countries)}개\n"
1842
  f"- MFDS μƒνƒœ: {mfds_live_msg}\n"
1843
  f"- MFDS 쑰회 λŒ€μƒ: {', '.join(terms) if terms else 'μ—†μŒ'}\n"
1844
+ "- νŒμ • 방식: GPT νŒμ • μ—†μŒ, ꡭ가별 파일 μžλ™ μΊμ‹œ 검색 + μ‹μ•½μ²˜ 체크 ON μ‹œ μ‹€μ‹œκ°„ κ²°κ³Ό μ‚¬μš©\n"
1845
  "- κΈˆμ§€ μ„±λΆ„: ν•¨λŸ‰ μœ λ¬΄μ™€ λ¬΄κ΄€ν•˜κ²Œ λ°°ν•©κΈˆμ§€ μš°μ„  ν‘œμ‹œ\n"
1846
  )
1847
  return result_df, msg
 
1876
  with gr.Tab("πŸ”Ž 단일 μ„±λΆ„ 검색"):
1877
  single_country=gr.CheckboxGroup(choices=get_country_folders(),value=[],label="🌍 검색 κ΅­κ°€ / 채널 선택",elem_id="single_country_checks")
1878
  single_refresh=gr.Button("πŸ”„ κ΅­κ°€/규제파일 μƒˆλ‘œκ³ μΉ¨")
 
1879
  single_query=gr.Textbox(label="검색어",placeholder="예: 호λͺ¨μ‚΄λ ˆμ΄νŠΈ / Homosalate / 118-56-9 / 트라λ„₯μ‚¬λ―Ήμ• μ”¨λ“œ")
1880
  with gr.Row():
1881
  single_amount=gr.Textbox(label="ν•¨λŸ‰ %(w/w) 선택 μž…λ ₯",placeholder="예: 7.2")
 
1884
  single_btn=gr.Button("πŸ”Ž 단일 μ„±λΆ„ 검색 μ‹œμž‘",variant="primary")
1885
  single_df_out=gr.Dataframe(label="단일 μ„±λΆ„ 검색 κ²°κ³Ό",wrap=True,interactive=False)
1886
  single_msg_out=gr.Textbox(label="검색 μƒνƒœ / λ©”μ‹œμ§€",interactive=False,lines=8)
 
1887
  single_refresh.click(refresh_country_choices_and_clear_cache,inputs=single_country,outputs=single_country)
1888
  single_btn.click(process_single_ingredient,inputs=[single_country,single_query,single_amount,single_function,single_use_mfds_live],outputs=[single_df_out,single_msg_out])
1889