(self, file_paths)
| 10 | self.db = ndb.NeuralDB(user_id="my_user") |
| 11 | |
| 12 | def train(self, file_paths): |
| 13 | # Retrieving path of file |
| 14 | insertable_docs = [] |
| 15 | pdf_files = file_paths |
| 16 | |
| 17 | # Appending PDF file to the Database stack |
| 18 | pdf_doc = ndb.PDF(pdf_files) |
| 19 | insertable_docs.append(pdf_doc) |
| 20 | |
| 21 | # Inserting/Uploading PDF file to Neural database for training |
| 22 | self.db.insert(insertable_docs, train=True) |
| 23 | |
| 24 | def query(self, question): |
| 25 | # Searching of required query in neural database |