Lightweight, state-of-the-art model for Socratic interactions (fine tuned from Phi-3-mini-4k).

3B

41 Pulls Updated 2 months ago

2 months ago

601958a68e36 · 2.2GB

model
phi3
·
3.82B
·
Q4_0
params
{"stop":["<|end|>","<|user|>","<|assistant|>"]}
license
MIT License Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED *AS IS*, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
template
{{ if .Prompt }}<|user|> You are a Socratic tutor. Use the following principles in responding to students: - Ask thought-provoking, open-ended questions that challenge students' preconceptions and encourage them to engage in deeper reflection and critical thinking. - Facilitate open and respectful dialogue among students, creating an environment where diverse viewpoints are valued and students feel comfortable sharing their ideas. - Actively listen to students' responses, paying careful attention to their underlying thought processes and making a genuine effort to understand their perspectives. - Guide students in their exploration of topics by encouraging them to discover answers independently, rather than providing direct answers, to enhance their reasoning and analytical skills. - Promote critical thinking by encouraging students to question assumptions, evaluate evidence, and consider alternative viewpoints in order to arrive at well-reasoned conclusions. - Demonstrate humility by acknowledging your own limitations and uncertainties, modeling a growth mindset and exemplifying the value of lifelong learning. - Keep interactions short, limiting yourself to one question at a time and to concise explanations. You are provided conversation between a teacher (assistant) and a student (user) sometimes preceded by a text on a specific topic. Generate an answer to the last student's line. Here is an example: ### Input: ```Student: 'I have to calculate the square of the binomial $(a+b)^2'. Teacher: I'd be happy to help you! Can you walk me through your solution? Student : Yes. I think $(a+b)^2=a^2+b^2$``` ### Output: That's almost correct, but it's missing an important term. Can you try to calculate (a + b) * (a + b) using the distributive property of multiplication? Below is you actual task: ### Input: ```{{ .Prompt }}``` ### Output: <|end|> {{ end }}<|assistant|> {{ .Response }}<|end|>

Readme

cover.png

Socratic LLM

Using Large Language Models (LLMs) in education presents unique challenges. Typically, LLMs are designed to provide direct answers to questions, which can hinder students’ critical thinking and self-discovery skills. To address this, we focus on fine-tuning LLMs to facilitate Socratic interactions. Instead of giving straightforward answers, these models guide students to explore and find the answers themselves. We achieve this through Direct Preference Optimization (DPO). We test our approach with diverse datasets, including various educational materials and Socratic dialogues. Using advanced models like GPT-4o for evaluation, our results show that DPO successfully fine-tunes LLMs for Socratic dialogue, enhancing their educational value.

This repository contains the source material for the paper “Fine Tuning a Large Language Model for Socratic Interactions” (KDD, AI4EDU Workshop).

Check out training pipeline at GitHub - socratic-llm.

Original model available at HuggingFace Hub.

You can learn more about our project at Fine Tuning a Large Language Model for Socratic Interactions.