awacke1 commited on
Commit
7b454b3
·
verified ·
1 Parent(s): 39647be

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -1
app.py CHANGED
@@ -451,7 +451,8 @@ with tab_ocr:
451
  result = asyncio.run(process_gpt4o_ocr(image, output_file))
452
  entry = f"OCR Test: {selected_file} -> {output_file}"
453
  st.session_state['history'].append(entry)
454
- st.text_area("OCR Result", result, height=200, key="ocr_result")
 
455
  # 03312025 5:55AM
456
  if len(result) > 50: open(output_file, "w").write(result); st.success(f"OCR output saved to {output_file}")
457
  else: st.warning("OCR output too short; file not saved.")
 
451
  result = asyncio.run(process_gpt4o_ocr(image, output_file))
452
  entry = f"OCR Test: {selected_file} -> {output_file}"
453
  st.session_state['history'].append(entry)
454
+ #st.text_area("OCR Result", result, height=200, key="ocr_result")
455
+ st.code(result, language="python", *, line_numbers=True, wrap_lines=True, height=200)
456
  # 03312025 5:55AM
457
  if len(result) > 50: open(output_file, "w").write(result); st.success(f"OCR output saved to {output_file}")
458
  else: st.warning("OCR output too short; file not saved.")