Sasiraj01 commited on
Commit
f5f051d
·
verified ·
1 Parent(s): 81c2bbd

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -29,9 +29,9 @@ def multimodal_rag(image, question):
29
  context = query_engine.query(question)
30
 
31
  # Step 2: Process with LLaVA
32
- prompt = f"Context: {context}\n\nQuestion: {question}"
33
 
34
- Question: {question}"
35
  inputs = processor(prompt, image, return_tensors="pt").to(model.device)
36
  output = model.generate(**inputs, max_new_tokens=100)
37
  answer = processor.decode(output[0], skip_special_tokens=True)
 
29
  context = query_engine.query(question)
30
 
31
  # Step 2: Process with LLaVA
32
+ prompt = f"""Context: {context}
33
 
34
+ Question: {question}"""
35
  inputs = processor(prompt, image, return_tensors="pt").to(model.device)
36
  output = model.generate(**inputs, max_new_tokens=100)
37
  answer = processor.decode(output[0], skip_special_tokens=True)