Spaces:
Runtime error
Runtime error
Update backup/backup.py
Browse files6 unmodified lines789101112131415161718192043 unmodified lines6465666768697071727374756 unmodified linestext = """lenskart m: (0)9428002330 Lenskart Store,Surat m: (0)9723817060) e:lenskartsurat@gmail.com Store Address UG-4.Ascon City.Opp.Maheshwari Bhavan,Citylight,Surat-395007"""# Labels for entity prediction# # Most GLiNER models should work best when entity types are in lower case or title case# labels = ["Person", "Mail", "Number", "Address", "Organization","Designation"]# # Perform entity prediction# entities = model.predict_entities(text, labels, threshold=0.5)def NER_Model(text):labels = ["Person", "Mail", "Number", "Address", "Organization","Designation","Link"]43 unmodified linesprocessed_data['Address']=[', '.join(processed_data['Address'])]processed_data['extracted_text']=[text]return processed_data# result=NER_Model(text)# print(result)6 unmodified lines78910111243 unmodified lines565758596 unmodified linestext = """lenskart m: (0)9428002330 Lenskart Store,Surat m: (0)9723817060) e:lenskartsurat@gmail.com Store Address UG-4.Ascon City.Opp.Maheshwari Bhavan,Citylight,Surat-395007"""def NER_Model(text):labels = ["Person", "Mail", "Number", "Address", "Organization","Designation","Link"]43 unmodified linesprocessed_data['Address']=[', '.join(processed_data['Address'])]processed_data['extracted_text']=[text]return processed_data
backup/backup.py+1-17