December 2013 Technology for Education (T4E) Conference Sumit Gulwani Affiliations: Microsoft Research Adjunct Faculty.

Slides:



Advertisements
Similar presentations
2.1 Program Construction In Java
Advertisements

From Verification to Synthesis Sumit Gulwani Microsoft Research, Redmond August 2013 Marktoberdorf Summer School Lectures: Part 1.
Semantics Static semantics Dynamic semantics attribute grammars
February 26, 2015Applied Discrete Mathematics Week 5: Mathematical Reasoning 1 Addition of Integers Example: Add a = (1110) 2 and b = (1011) 2. a 0 + b.
Synthesizing Geometry Constructions Sumit Gulwani MSR, Redmond Vijay Korthikanti UIUC Ashish Tiwari SRI.
Constraint Based Synthesis for Beginners PSY 2012 Armando Solar-Lezama.
Automated Grading of DFA Constructions Rajeev Alur (Penn), Loris D’Antoni (Penn), Sumit Gulwani (MSR), Bjoern Hartmann (Berkeley), Dileep Kini (UIUC),
1 1 CDT314 FABER Formal Languages, Automata and Models of Computation Lecture 3 School of Innovation, Design and Engineering Mälardalen University 2012.
Teaching Finite Automata with AutomataTutor Rajeev Alur (Penn), Loris D’Antoni (Penn), Sumit Gulwani (MSR), Bjoern Hartmann (Berkeley), Dileep Kini (UIUC),
(non-programmers with access to computers)
Dimensions in Synthesis Part 2: Applications (Intelligent Tutoring Systems) Sumit Gulwani Microsoft Research, Redmond May 2012.
Lecture3: Algorithm Analysis Bohyung Han CSE, POSTECH CSED233: Data Structures (2014F)
Programming in Visual Basic
Complexity Analysis (Part I)
Syllabus Every Week: 2 Hourly Exams +Final - as noted on Syllabus
CSE 830: Design and Theory of Algorithms
Chapter 2 The Algorithmic Foundations of Computer Science
Usable Synthesis Sumit Gulwani Microsoft Research, Redmond Usable Verification Workshop November 2010 MSR Redmond.
Lecture 19 Exam: Tuesday June15 4-6pm Overview. General Remarks Expect more questions than before that test your knowledge of the material. (rather then.
Program Synthesis for Automating Education Sumit Gulwani Microsoft Research, Redmond.
About the Presentations The presentations cover the objectives found in the opening of each chapter. All chapter objectives are listed in the beginning.
Problem Generation & Feedback Generation Invited ASSESS 2014 Workshop collocated with KDD 2014 Sumit Gulwani Microsoft Research, Redmond.
Proof by Deduction. Deductions and Formal Proofs A deduction is a sequence of logic statements, each of which is known or assumed to be true A formal.
Synthesis of Loop-free Programs Sumit Gulwani (MSR), Susmit Jha (UC Berkeley), Ashish Tiwari (SRI) and Ramarathnam Venkatesan(MSR) Susmit Jha 1.
Chapter 2: Algorithm Discovery and Design
Chapter 2: Algorithm Discovery and Design
Dimensions in Synthesis Sumit Gulwani Microsoft Research, Redmond May 2012.
Relational Verification to SIMD Loop Synthesis Mark Marron – IMDEA & Microsoft Research Sumit Gulwani – Microsoft Research Gilles Barthe, Juan M. Crespo,
February 25, 2002Applied Discrete Mathematics Week 5: Mathematical Reasoning 1 Addition of Integers How do we (humans) add two integers? Example: 7583.
Chapter 2: Algorithm Discovery and Design Invitation to Computer Science, C++ Version, Third Edition.
Goals of Course Introduction to the programming language C Learn how to program Learn ‘good’ programming practices.
DEPARTMENT OF COMPUTER SCIENCE & TECHNOLOGY FACULTY OF SCIENCE & TECHNOLOGY UNIVERSITY OF UWA WELLASSA 1 CST 221 OBJECT ORIENTED PROGRAMMING(OOP) ( 2 CREDITS.
Deduction, Proofs, and Inference Rules. Let’s Review What we Know Take a look at your handout and see if you have any questions You should know how to.
Programming by Examples Marktoberdorf Lectures August 2015 Sumit Gulwani.
Dimensions in Synthesis Part 3: Ambiguity (Synthesis from Examples & Keywords) Sumit Gulwani Microsoft Research, Redmond May 2012.
1 Inference Rules and Proofs (Z); Program Specification and Verification Inference Rules and Proofs (Z); Program Specification and Verification.
My talk describes how the detailed error diagnosis and the automatic solution procedure of problem solving environment T-algebra can be used for automatic.
Input, Output, and Processing
ENM 503 Lesson 1 – Methods and Models The why’s, how’s, and what’s of mathematical modeling A model is a representation in mathematical terms of some real.
1 Sections 1.5 & 3.1 Methods of Proof / Proof Strategy.
COP 4620 / 5625 Programming Language Translation / Compiler Writing Fall 2003 Lecture 3, 09/11/2003 Prof. Roy Levow.
Copyright © 2012 Pearson Education, Inc. Publishing as Pearson Addison-Wesley C H A P T E R 2 Input, Processing, and Output.
Execution of an instruction
Lexical Analysis: Finite Automata CS 471 September 5, 2007.
Formal Methods in Invited CBSoft Sep 2015 Sumit Gulwani Data Wrangling & Education.
1 CD5560 FABER Formal Languages, Automata and Models of Computation Lecture 3 Mälardalen University 2010.
Hazırlayan DISCRETE COMPUTATIONAL STRUCTURES Propositional Logic PROF. DR. YUSUF OYSAL.
Chapter 3 Part II Describing Syntax and Semantics.
Data Structures and Algorithm Analysis Introduction Lecturer: Ligang Dong, egan Tel: , Office: SIEE Building.
1 / 48 Formal a Language Theory and Describing Semantics Principles of Programming Languages 4.
Automating String Processing in Spreadsheets using Input-Output Examples Sumit Gulwani Microsoft Research, Redmond.
Compositional Program Synthesis from Natural Language and Examples Mohammad Raza, Sumit Gulwani & Natasa Milic-Frayling Microsoft.
Programming Fundamentals. Overview of Previous Lecture Phases of C++ Environment Program statement Vs Preprocessor directive Whitespaces Comments.
Moodle Quizes Staff Guide. Creating Quizzes Click Add an Activity or Resource With the course in editing mode...
Static Techniques for V&V. Hierarchy of V&V techniques Static Analysis V&V Dynamic Techniques Model Checking Simulation Symbolic Execution Testing Informal.
CS104:Discrete Structures Chapter 2: Proof Techniques.
Onlinedeeneislam.blogspot.com1 Design and Analysis of Algorithms Slide # 1 Download From
Chapter 2: Algorithm Discovery and Design Invitation to Computer Science.
1 Propositional Proofs 1. Problem 2 Deduction In deduction, the conclusion is true whenever the premises are true.  Premise: p Conclusion: (p ∨ q) 
Complexity Analysis (Part I)
Knowledge Representation and Reasoning
Input Space Partition Testing CS 4501 / 6501 Software Testing
Courtsey & Copyright: DESIGN AND ANALYSIS OF ALGORITHMS Courtsey & Copyright:
Recognizer for a Language
CS201: Data Structures and Discrete Mathematics I
4b Lexical analysis Finite Automata
4b Lexical analysis Finite Automata
CS201: Data Structures and Discrete Mathematics I
Complexity Analysis (Part I)
Complexity Analysis (Part I)
Presentation transcript:

December 2013 Technology for Education (T4E) Conference Sumit Gulwani Affiliations: Microsoft Research Adjunct IIT Kanpur Example-based Learning in Computer-aided Education

1 Reference Example-based Learning in Computer-aided STEM Education MSR Technical Report MSR-TR To appear in CACM

Human learning is often structured around examples. –Students master various concepts using examples. –Teachers guess student misconceptions from erroneous demonstrations or provide feedback using counter-examples. Example-based reasoning also used in Computer-aided Programming (CAP). –Program analysis: test input generation for bug finding –Program synthesis: programming by example e.g., Flash Fill: an Excel 2013 feature [POPL 2011, CACM 2012] Example-based reasoning techniques developed in CAP community can help automate several tasks in Education. –Implications: CAP research can fuel research in Computer-aided Education & vice versa. 2 Example-based Learning

Various tasks Problem Generation Solution Generation Feedback Generation Various subject-domains Arithmetic, Algebra, Geometry Programming, Automata, Logic Language Learning... 3 Computer-aided Education

Procedural –Mathematical Procedures Addition, Long division, GCD/LCM, Gaussian Elimination –Algorithmic Procedures Students asked to show understanding of classical algorithms on specific inputs. –BFS, insertion sort, shortest path –translating regular expression into an automaton. Conceptual –Proofs Algebraic theorems, Natural deduction, Non-regularity –Constructions Geometric ruler/compass based constructions, Automata constructions, Algorithms 4 Content Classification

Problem Generation

Motivation Problems similar to a given problem. –Avoid copyright issues –Prevent cheating in MOOCs (Unsynchronized instruction) Problems of a given difficulty level and concept usage. –Generate progressions –Generate personalized workflows Key Ideas  Procedural Content: Test input generation techniques 6 Problem Generation

Concept Single digit addition Multiple digit w/o carry Single carry Two single carries Double carry Triple carry Extra digit in i/p & new digit in o/p 7 Problem Generation: Addition Procedure Reference: A Trace-based Framework for Analyzing and Synthesizing Educational Progressions; CHI 2013; Andersen, Gulwani, Popovic.

ConceptTrace Characteristic Single digit additionL Multiple digit w/o carryLL+ Single carryL* (LC) L* Two single carriesL* (LC) L+ (LC) L* Double carryL* (LCLC) L* Triple carryL* (LCLCLCLC) L* Extra digit in i/p & new digit in o/pL* CLDCE 8 Problem Generation: Addition Procedure Reference: A Trace-based Framework for Analyzing and Synthesizing Educational Progressions; CHI 2013; Andersen, Gulwani, Popovic.

ConceptTrace CharacteristicSample Input Single digit additionL3+2 Multiple digit w/o carryLL Single carryL* (LC) L* Two single carriesL* (LC) L+ (LC) L* Double carryL* (LCLC) L* Triple carryL* (LCLCLCLC) L* Extra digit in i/p & new digit in o/pL* CLDCE Problem Generation: Addition Procedure Reference: A Trace-based Framework for Analyzing and Synthesizing Educational Progressions; CHI 2013; Andersen, Gulwani, Popovic.

Motivation Problems similar to a given problem. –Avoid copyright issues –Prevent cheating in MOOCs (Unsynchronized instruction) Problems of a given difficulty level and concept usage. –Generate progressions –Generate personalized workflows Key Ideas Procedural Content: Test input generation techniques Conceptual Content  Template based generalization 10 Problem Generation

11 Trigonometry Problem Reference: Automatically generating algebra problems; AAAI 2012; Rohit Singh, Sumit Gulwani, Sriram Rajamani.

12 Trigonometry Problem Reference: Automatically generating algebra problems; AAAI 2012; Rohit Singh, Sumit Gulwani, Sriram Rajamani.

13 Limits/Series Problem

14 Integration Problem

15 Determinant Problem

16 Randomized Identity Testing

Motivation Problems similar to a given problem. –Avoid copyright issues –Prevent cheating in MOOCs (Unsynchronized instruction) Problems of a given difficulty level and concept usage. –Generate progressions –Generate personalized workflows Key Ideas Procedural Content: Test input generation techniques Conceptual Content  Template based generalization 17 Problem Generation

1.The principal characterized his pupils as _________ because they were pampered and spoiled by their indulgent parents. 2.The commentator characterized the electorate as _________ because it was unpredictable and given to constantly shifting moods. (a) cosseted (b) disingenuous (c) corrosive (d) laconic (e) mercurial One of the problems is a real problem from SAT (standardized US exam), while the other one was automatically generated! From problem 1, we generate template T 1 : * 1 characterized * 2 as * 3 because * 4 We specialize T 1 to template T 2 : * 1 characterized * 2 as mercurial because * 4 Problem 2 is an instance of T 2. Problem Generation: Sentence Completion

Motivation Problems similar to a given problem. –Avoid copyright issues –Prevent cheating in MOOCs (Unsynchronized instruction) Problems of a given difficulty level and concept usage. –Generate progressions –Generate personalized workflows Key Ideas Procedural Content: Test input generation techniques Conceptual Content –Template based generalization  Symbolic methods (solution generation in reverse) 19 Problem Generation

Inference RulePremisesConclusion Modus Ponens (MP) Hypothetical Syllogism (HS) Disjunctive Syllogism (DS) Simplification (Simp) 20 Natural Deduction Replacement RulePropositionEquiv. Proposition Distribution Double Negation Implication Equivalence Reference: Automatically Generating Problems and Solutions for Natural Deduction IJCAI 2013; Umair Ahmed, Sumit Gulwani, Amey Karkare

Premise 1Premise 2Premise 3Conclusion 21 Similar Problem Generation: Natural Deduction Premise 1Premise 2Premise 3Conclusion Similar Problems Similar Problems = those that have a minimal proof with the same sequence of inference rules as used by a minimal proof of given problem.

22 Parameterized Problem Generation: Natural Deduction Premise 1Premise 2Premise 3Conclusion Parameterized Problems

Solution Generation

Motivation Generate sample solutions to new problems. Generate customized solutions or complete unfinished ones. Inform solution characteristics during problem generation. Key Ideas  Procedural Content: Programming by Demonstration 24 Solution Generation

25 Solution Generation: GCF Computation Time-stamped sequence of (location, value) pairs Spreadsheet Program Programming by Demonstration Can also be used to synthesize incorrect procedures from buggy traces! Reference: Programming by Demonstration framework applied to procedural math problems; Technical Report; Andersen, Gulwani, Popovic.

Motivation Generate sample solutions to new problems. Generate customized solutions or complete unfinished ones. Inform solution characteristics during problem generation. Key Ideas Procedural Content: Programming by Demonstration  Conceptual Content –Perform reasoning over models (vs. abstract symbolic reasoning). –Reduce solution space to solutions with small length. 26 Solution Generation

Given a triangle XYZ, construct circle C such that C passes through X, Y, and Z. 27 Ruler/Compass based Geometry Constructions X Z Y L1 L2 N C Reference: Synthesizing Geometry Constructions PLDI 2011; Gulwani, Korthikanti, Tiwari

Draw a regular hexagon given a side. Given 3 parallel lines, draw an equilateral triangle whose vertices lie on the parallel lines. Given 4 points, draw a square whose sides contain those points. 28 Other Examples of Geometry Constructions

Types: Point, Line, Circle Methods: Ruler(Point, Point) -> Line Compass(Point, Point) -> Circle Intersect(Circle, Circle) -> Pair of Points Intersect(Line, Circle) -> Pair of Points Intersect(Line, Line) -> Point Geometry Program: A straight-line composition of the above methods. 29 A Geometry Construction is a straight-line program!

Given a triangle XYZ, construct circle C such that C passes through X, Y, and Z. 30 Example: Geometry Program 1.C1 = Compass(X,Y); 2.C2 = Compass(Y,X); 3. = Intersect(C1,C2); 4.L1 = Ruler(P1,P2); 5.D1 = Compass(Z,X); 6.D2 = Compass(X,Z); 7. = Intersect(D1,D2); 8.L2 = Ruler(R1,R2); 9.N = Intersect(L1,L2); 10.C = Compass(N,X); X Z Y C1 C2 P1 P2 L1 D2 D1 R1 R2 L2 N C

Spec = (Precondition, Postcondition), where each is an equality/inequality predicate over distance/slope constructs. Example: Given a triangle XYZ, construct circle C such that C passes through X, Y, and Z. Precondition: Slope(X,Y)  Slope(X,Z) Æ Slope(X,Y)  Slope(Z,X) Postcondition: LiesOn(X,C) Æ LiesOn(Y,C) Æ LiesOn(Z,C) where LiesOn(X,C) ´ Distance(X,Center(C)) = Radius(C) Specification for Geometry Constructions 31

Synthesis Algorithm: // First obtain a random input-output example. 1.Choose I’ randomly from the set { I | Pre(I) }. 2.Compute O’ s.t. Post(I’,O’) using numerical methods. // Now obtain a construction that can generate O’ from I’ (using exhaustive search). 3.S := I’; 4.While (S does not contain O’) 5. S := S [ { M(O 1,O 2 ) | O i 2 S, M 2 Methods } 6.Output construction steps for O’. 32 Idea 1: Search using random concrete models

Given a triangle XYZ, construct circle C such that C passes through X, Y, and Z. 33 Idea 2: Use high-level abstractions to reduce size 1.C1 = Compass(X,Y); 2.C2 = Compass(Y,X); 3. = Intersect(C1,C2); 4.L1 = Ruler(P1,P2); 5.D1 = Compass(Z,X); 6.D2 = Compass(X,Z); 7. = Intersect(D1,D2); 8.L2 = Ruler(R1,R2); 9.N = Intersect(L1,L2); 10.C = Compass(N,X); 1.L1 = PBisector(X,Y); 2.L2 = PBisector(X,Z); 3.N = Intersect(L1,L2); 4.C = Compass(N,X);

34 Feedback Generation

Motivation Makes teachers more effective. –Saves them time. –Provides immediate insights on where students are struggling. Can enable rich interactive experience for students. –Generation of hints. –Pointer to simpler problems depending on kind of mistake. Key Ideas:  Procedural Content: Use PBE techniques to learn buggy procedures in a student’s mind. 35 Feedback Generation

Ashlock identified buggy computational patterns for various procedures. Following are some bugs for addition. –Add each column and write the sum below each column, even if it is greater than nine. –Add each column, from left to right. If the sum > 9, write the tens digit beneath the column and the ones digit above the column to the right. Van Lehn identified >100 bugs in subtraction alone. Key Idea: Use Programming by Demonstration technology (also used for solution synthesis for procedural problems) for synthesizing such buggy procedures. 36 Feedback Generation for Procedural Problems

Motivation Makes teachers more effective. –Saves them time. –Provides immediate insights on where students are struggling. Can enable rich interactive experience for students. –Generation of hints. –Pointer to simpler problems depending on kind of mistake. Key Ideas: Procedural Content: Use PBE techniques to learn buggy procedures in a student’s mind. Conceptual Content: Various feedback metrics  Counterexamples: Inputs on which the solution is not correct 37 Feedback Generation

38 Counterexample based Feedback: PexForFun

using System; public class Program { public static int[] Puzzle(int[] a) { int[] b = new int[a.Length]; int count = 0; for(int i=a.Length; i < a.Length; i--) { b[count] = a[i]; count++; } return b; } 39 Buggy Program for Array Reverse 6:28::50 AM

using System; public class Program { public static int[] Puzzle(int[] a) { int[] b = new int[a.Length]; int count = 0; for(int i=a.Length-1; i < a.Length-1; i--) { b[count] = a[i]; count++; } return b; } 40 Buggy Program for Array Reverse 6:32::01 AM

using System; public class Program { public static int[] Puzzle(int[] a) { int[] b = new int[a.Length]; int count = 0; for(int i=a.Length-1; i < a.Length-1; i--) { b[count] = a[i]; count++; } return b; } 41 Buggy Program for Array Reverse 6:32::32 AM No change! Sign of Frustation?

using System; public class Program { public static int[] Puzzle(int[] a) { int[] b = new int[a.Length]; int count = 0; for(int i=a.Length; i <= a.Length; i--) { b[count] = a[i]; count++; } return b; } 42 Buggy Program for Array Reverse 6:33::19 AM

using System; public class Program { public static int[] Puzzle(int[] a) { int[] b = new int[a.Length]; int count = 0; for(int i=a.Length; i < a.Length; i--) {Console.Writeline(i); b[count] = a[i]; count++; } return b; } 43 Buggy Program for Array Reverse 6:33::55 AM Same as initial attempt except Console.Writeline!

using System; public class Program { public static int[] Puzzle(int[] a) { int[] b = new int[a.Length]; int count = 0; for(int i=a.Length; i < a.Length; i--) {Console.Writeline(i); b[count] = a[i]; count++; } return b; } 44 Buggy Program for Array Reverse 6:34::06 AM No change! Sign of Frustation?

using System; public class Program { public static int[] Puzzle(int[] a) { int[] b = new int[a.Length]; int count = 0; for(int i=a.Length; i <= a.Length; i--) {Console.Writeline(i); b[count] = a[i]; count++; } return b; } 45 Buggy Program for Array Reverse 6:34::56 AM The student has tried this before!

using System; public class Program { public static int[] Puzzle(int[] a) { int[] b = new int[a.Length]; int count = 0; for(int i=a.Length; i < a.Length; i--) { b[count] = a[i]; count++; } return b; } 46 Buggy Program for Array Reverse 6:36::24 AM Same as initial attempt!

using System; public class Program { public static int[] Puzzle(int[] a) { int[] b = new int[a.Length]; int count = 0; for(int i=a.Length-1; i < a.Length-1; i--) { b[count] = a[i]; count++; } return b; } 47 Buggy Program for Array Reverse 6:37::39 AM The student has tried this before!

using System; public class Program { public static int[] Puzzle(int[] a) { int[] b = new int[a.Length]; int count = 0; for(int i=a.Length; i > 0; i--) { b[count] = a[i]; count++; } return b; } 48 Buggy Program for Array Reverse 6:38::11 AM Almost correct! (a[i-1] instead of a[i] in loop body)

using System; public class Program { public static int[] Puzzle(int[] a) { int[] b = new int[a.Length]; int count = 0; for(int i=a.Length; i >= 0; i--) { b[count] = a[i]; count++; } return b; } 49 Buggy Program for Array Reverse 6:38::44 AM Student going in wrong direction!

using System; public class Program { public static int[] Puzzle(int[] a) { int[] b = new int[a.Length]; int count = 0; for(int i=a.Length; i < a.Length; i--) { b[count] = a[i]; count++; } return b; } 50 Buggy Program for Array Reverse 6:39::33 AM Back to bigger error!

using System; public class Program { public static int[] Puzzle(int[] a) { int[] b = new int[a.Length]; int count = 0; for(int i=a.Length; i < a.Length; i--) { b[count] = a[i]; count++; } return b; } 51 Buggy Program for Array Reverse 6:39::45 AM No change! Frustation!

using System; public class Program { public static int[] Puzzle(int[] a) { int[] b = new int[a.Length]; int count = 0; for(int i=a.Length; i < a.Length; i--) { b[count] = a[i]; count++; } return b; } 52 Buggy Program for Array Reverse 6:40::27 AM No change! More Frustation!!

using System; public class Program { public static int[] Puzzle(int[] a) { int[] b = new int[a.Length]; int count = 0; for(int i=a.Length; i < a.Length; i--) { b[count] = a[i]; count++; } return b; } 53 Buggy Program for Array Reverse 6:40::57 AM No change! Too Frustated now!!! Gives up.

"Not only did it take 1-2 weeks to grade problem, but the comments were entirely unhelpful in actually helping us fix our errors. …. Apparently they don't read the code -- they just ran their tests and docked points mercilessly. What if I just had a simple typo, but my algorithm was fine?....“ - Student Feedback from MIT 6.00 course, Counterexamples are not sufficient!

Motivation Makes teachers more effective. –Saves them time. –Provides immediate insights on where students are struggling. Can enable rich interactive experience for students. –Generation of hints. –Pointer to simpler problems depending on kind of mistake. Key Ideas: Procedural Content: Use PBE techniques to learn buggy procedures in a student’s mind. Conceptual Content: Various feedback metrics –Counterexamples: Inputs on which the solution is not correct.  Edit distance to a nearest correct solution. 55 Feedback Generation

Array Index: v[a] -> v[{a+1, a-1}] Increment: v++ -> { ++v, v--, --v } Conditional: a op b -> a ops b where ops = {, =, ==, != } Initialization: v=n -> v={n+1, n-1, 0} Return Value: return v -> return ?v Key Idea: Finding minimal set of such changes that convert a buggy solution into a correct one is phrased as a sketch problem. 56 Correction Model for Programming Assignments Reference: Automated Feedback Generation for Introductory Programming Assignments; PLDI 2013; Singh, Gulwani, Solar-Lezama

Array Reverse i = 1 i <= a.Length --back front <= back

13,365 incorrect attempts for 13 Python problems. (obtained from Introductory Programming course at MIT and its MOOC version on the EdX platform) Average time for feedback = 10 seconds Feedback generated for 64% of those attempts. Reasons for failure to generate feedback –Completely incorrect solutions –Big conceptual errors –Timeout (4 min) 58 Experimental Results Tool accessible at:

Motivation Makes teachers more effective. –Saves them time. –Provides immediate insights on where students are struggling. Can enable rich interactive experience for students. –Generation of hints. –Pointer to simpler problems depending on kind of mistake. Key Ideas: Procedural Content: Use PBE techniques to learn buggy procedures in a student’s mind. Conceptual Content: Various feedback metrics –Counterexamples: Inputs on which the solution is not correct. –Edit distance to a nearest correct solution.  Edit distance to the problem description (of a nearest corresponding problem description). 59 Feedback Synthesis

60 Finite State Automata Draw a DFA that accepts: { s | ‘ab’ appears in s exactly 2 times } Grade: 6/10 Feedback: The DFA is incorrect on the string ‘ababb’ Grade: 9/10 Feedback: One more state should be made final Grade: 5/10 Feedback: The DFA accepts {s | ‘ab’ appears in s at least 2 times} Attempt 3 Attempt 1 Attempt 2 Based on Edit-distance to a correct solution Based on counterexamples Based on Edit-distance to the problem description Reference: Automated Grading of DFA Constructions, IJCAI 2013; Alur, d’Antoni, Gulwani, Kini, Viswanathan

800+ attempts to 6 automata problems (obtained from automata course at UIUC) graded by tool and 2 instructors. Out of 131 attempts for one of those problems: –6 attempts: instructors were incorrect (gave full marks to an incorrect attempt) –20 attempts: instructors were inconsistent (gave different marks to syntactically equivalent attempts) –34 attempts: >= 3 point discrepancy between instructor and tool; in 20 of those, instructor agreed that tool was more fair. More agreement between instructor/tool than instructors. Instructors concluded that tool should be preferred over humans for consistency & scalability. 61 Experimental Results Tool accessible at:

Technical Perspective –Aspects: Problem/Solution/Feedback Generation –Domains: Math, Programming, Logic, Language Learning,... Inter-disciplinary research area –Computer-aided Programming techniques –Natural language processing (for word problems) –Machine learning (leverage large amounts of student data) –HCI (leverage large populations of students and teachers) Value Proposition: –Short term: Improve Education (personalized + interactive) –Long Term: Ultra-intelligent computer, Model of human mind, Inter-stellar travel 62 Computer Aided Education: Conclusion