| ### Finetuned Academic Question-Answering Model for ICSE Physics (Class 9 & 10) | |
| This specialized large language model (LLM) is finetuned to provide precise and accurate answers to ICSE Physics questions for Classes 9 and 10. It is designed to assist students, educators, and content creators in understanding and exploring fundamental physics concepts aligned with the ICSE curriculum. | |
| ## Key Features | |
| # 📚 Curriculum-Specific Training | |
| Focused exclusively on ICSE Class 9 and 10 Physics topics, such as: | |
| Motion | |
| Work, Energy, and Power | |
| Heat and Thermodynamics | |
| Electricity and Magnetism | |
| Light (Reflection and Refraction) | |
| Sound | |
| Modern Physics | |
| # 🎯 Accurate and Concise Answers | |
| Trained to deliver curriculum-aligned, student-friendly responses. | |
| # Contextual Understanding | |
| Handles specific and multi-part questions effectively, ensuring relevance and precision. | |
| Example Usage | |
| python | |
| Copy code | |
| from transformers import pipeline | |
| # Load the model from Hugging Face | |
| ```python | |
| import torch | |
| from transformers import AutoModelForCausalLM, AutoTokenizer | |
| model = AutoModelForCausalLM.from_pretrained( | |
| "pitangent-ds/academic_phy", | |
| load_in_4bit=True, # Quantized model | |
| device_map="auto", | |
| # llm_int8_enable_fp32_cpu_offload=True | |
| ) | |
| tokenizer = AutoTokenizer.from_pretrained("pitangent-ds/academic_phy") | |
| ``` | |
| # Perform inference | |
| ```python | |
| text = "What are units ?" | |
| inputs = tokenizer(text, return_tensors="pt") | |
| outputs = model.generate(**inputs) | |
| decoded_output = tokenizer.decode(outputs[0], skip_special_tokens=True) | |
| print(decoded_output) | |
| ``` | |
| # Training Details | |
| Dataset: Curated ICSE Physics content for Classes 9 and 10 textbooks | |
| Loss Function: Cross-entropy loss | |
| Final Training Loss: 0.88 | |
| Training Framework: PyTorch, Hugging Face Transformers | |