AI-trainer1 commited on
Commit
393c185
·
verified ·
1 Parent(s): dae8a2c

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -5
app.py CHANGED
@@ -23,9 +23,9 @@ class PDFQAProcessor:
23
 
24
  llm = ChatGroq(
25
  # model_name="deepseek-r1-distill-llama-70b",
26
- model_name="llama3-70b-8192",
27
  temperature=0.1,
28
- max_tokens=3000,
29
  api_key = os.getenv('GROQ_API_KEY')
30
  )
31
 
@@ -46,8 +46,8 @@ class PDFQAProcessor:
46
  # )
47
 
48
  embeddings = GoogleGenerativeAIEmbeddings(model="models/embedding-001")
49
- CHUNK_SIZE = 700
50
- CHUNK_OVERLAP = 150
51
  text_splitter = RecursiveCharacterTextSplitter(chunk_size=CHUNK_SIZE,chunk_overlap = CHUNK_OVERLAP)
52
  # persist_directory="./chroma_db"
53
 
@@ -81,7 +81,7 @@ class PDFQAProcessor:
81
  splits,
82
  self.embeddings
83
  )
84
- self.retriever = self.vectorstore.as_retriever(search_kwargs={"k": 10})
85
  return "PDFs processed successfully! Ask your questions now."
86
 
87
  except Exception as e:
 
23
 
24
  llm = ChatGroq(
25
  # model_name="deepseek-r1-distill-llama-70b",
26
+ model_name="llama-3.3-70b-versatile",
27
  temperature=0.1,
28
+ max_tokens=8000,
29
  api_key = os.getenv('GROQ_API_KEY')
30
  )
31
 
 
46
  # )
47
 
48
  embeddings = GoogleGenerativeAIEmbeddings(model="models/embedding-001")
49
+ CHUNK_SIZE = 550
50
+ CHUNK_OVERLAP = 80
51
  text_splitter = RecursiveCharacterTextSplitter(chunk_size=CHUNK_SIZE,chunk_overlap = CHUNK_OVERLAP)
52
  # persist_directory="./chroma_db"
53
 
 
81
  splits,
82
  self.embeddings
83
  )
84
+ self.retriever = self.vectorstore.as_retriever(search_kwargs={"k": 18})
85
  return "PDFs processed successfully! Ask your questions now."
86
 
87
  except Exception as e: