Spaces:
Sleeping
Sleeping
Update ragout.py
Browse files
ragout.py
CHANGED
|
@@ -40,5 +40,27 @@ Answer:"""
|
|
| 40 |
return "⚠️ Couldn't generate a good answer. Try again."
|
| 41 |
except Exception as e:
|
| 42 |
return f"⚠️ API Error: {e}"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 43 |
|
| 44 |
|
|
|
|
| 40 |
return "⚠️ Couldn't generate a good answer. Try again."
|
| 41 |
except Exception as e:
|
| 42 |
return f"⚠️ API Error: {e}"
|
| 43 |
+
DOCUMENTS = {
|
| 44 |
+
"Newton's Laws": "Newton's Laws describe the relationship between a body and the forces acting upon it.",
|
| 45 |
+
"Kinematics": "Kinematics studies motion without considering its causes.",
|
| 46 |
+
"Dynamics": "Dynamics concerns forces and their effect on motion.",
|
| 47 |
+
"Work and Energy": "Work is force applied over a distance. Energy is the capacity to do work.",
|
| 48 |
+
"Thermodynamics": "Study of heat, energy, and the transformation between them.",
|
| 49 |
+
"Electric Circuits": "Circuits allow current to flow through a closed loop of conductors.",
|
| 50 |
+
"Magnetism": "Magnetism arises from the motion of electric charges.",
|
| 51 |
+
"Waves and Oscillations": "Waves transport energy through space without transport of matter.",
|
| 52 |
+
"Optics": "Optics is the study of light and its interactions with materials.",
|
| 53 |
+
"Special Relativity": "Relativity describes how time and space are linked for objects moving at constant speeds.",
|
| 54 |
+
"Calculus": "Calculus is the study of continuous change through derivatives and integrals.",
|
| 55 |
+
"Algebra": "Algebra involves solving equations and finding unknowns.",
|
| 56 |
+
"Geometry": "Geometry studies the properties of shapes and spaces.",
|
| 57 |
+
"Probability and Statistics": "Probability measures chance, and statistics analyze data.",
|
| 58 |
+
"Vectors and Scalars": "Scalars have magnitude; vectors have magnitude and direction.",
|
| 59 |
+
"Gravitation": "Gravity is the force that attracts two bodies toward each other.",
|
| 60 |
+
"Fluid Mechanics": "Fluids exert forces and flows that follow physical laws.",
|
| 61 |
+
"Quantum Mechanics": "Quantum physics studies very small particles and probabilities.",
|
| 62 |
+
"Nuclear Physics": "Nuclear physics studies atomic nuclei and their properties.",
|
| 63 |
+
"Modern Physics": "Modern physics explores theories beyond classical mechanics.",
|
| 64 |
+
}
|
| 65 |
|
| 66 |
|