From aee55bcb6d41de1b1f40027208a7cbb41e6e1d76 Mon Sep 17 00:00:00 2001 From: savini98 Date: Mon, 29 Jul 2024 21:57:54 +0530 Subject: [PATCH] Update white space errorrs --- examples/canonirag/final_impl/app.jac | 4 ++-- examples/canonirag/final_impl/rag.jac | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/examples/canonirag/final_impl/app.jac b/examples/canonirag/final_impl/app.jac index cb33d6bc6..953aab97e 100644 --- a/examples/canonirag/final_impl/app.jac +++ b/examples/canonirag/final_impl/app.jac @@ -163,9 +163,9 @@ walker save_data { can main { :g: state ; - + :g: RagEngine ; - + gui.page_build(); if state == PR_states.init_PR { # Import the data from JSON file diff --git a/examples/canonirag/final_impl/rag.jac b/examples/canonirag/final_impl/rag.jac index 2d331e97d..3b800e378 100644 --- a/examples/canonirag/final_impl/rag.jac +++ b/examples/canonirag/final_impl/rag.jac @@ -43,7 +43,7 @@ obj rag_engine { can add_chunk_id(chunks: str) { last_page_id = None; current_chunk_index = 0; - + for chunk in chunks { source = chunk.metadata.get('source'); page = chunk.metadata.get('page'); @@ -70,11 +70,11 @@ obj rag_engine { embedding_function=self.get_embedding_function() ); chunks_with_ids = self.add_chunk_id(chunks);#Chunk ID Calculation - + #Adding and Updating the documents existing_items = db.get(include=[]); existing_ids = set(existing_items['ids']); - + #Only adding new documents that does not exist in the database new_chunks = []; for chunk in chunks_with_ids {