Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -53,7 +53,7 @@ def process_files_fixed(image_path, page_identifier, error_pages):
|
|
53 |
error_pages.append(page_identifier)
|
54 |
return []
|
55 |
|
56 |
-
prompt = """Perform OCR on this image. Analyze the table in the provided image, focusing on the first seven columns labeled S.No, Admission No.,Date of Admission,Name of Student,Father's Name,Date of Birth
|
57 |
|
58 |
Return the response in the following JSON response format:
|
59 |
{
|
@@ -65,7 +65,12 @@ Return the response in the following JSON response format:
|
|
65 |
"Name of Student" : "Maham Tariq",
|
66 |
"Father's Name" : "Tariq Mehman",
|
67 |
"Date of Birth" : "12-05-12",
|
68 |
-
"Telephone No." : "03125350838"
|
|
|
|
|
|
|
|
|
|
|
69 |
|
70 |
},
|
71 |
...
|
|
|
53 |
error_pages.append(page_identifier)
|
54 |
return []
|
55 |
|
56 |
+
prompt = """Perform OCR on this image. Analyze the table in the provided image, focusing on the first seven columns labeled S.No, Admission No.,Date of Admission,Name of Student,Father's Name,Date of Birth ,Telephone No., Address, F.CNIC, S.CNIC and M.Name . Get the Telephone No. from the last column ignore office and residence column under it and for F.CNIC, S.CNIC and M.Name you will find this under REMARKS column I don't want any mistakes in the obtained data. In case the table headers are not visible or not present, assume the mentioned order for the columns. Extract and list the data only from these columns, omitting any additional columns that may be present. But DO NOT skip any row from the table, extract all the rows present in the table. Verify both for better ocr in integers.
|
57 |
|
58 |
Return the response in the following JSON response format:
|
59 |
{
|
|
|
65 |
"Name of Student" : "Maham Tariq",
|
66 |
"Father's Name" : "Tariq Mehman",
|
67 |
"Date of Birth" : "12-05-12",
|
68 |
+
"Telephone No." : "03125350838",
|
69 |
+
"Address" : "Dewan- e. umar Masjid F1014",
|
70 |
+
"F. CNIC" : "61101-9729652-7",
|
71 |
+
"S.CNIC" : "61101-8018797-4",
|
72 |
+
"M.Name" : "Nasira"
|
73 |
+
|
74 |
|
75 |
},
|
76 |
...
|