SlideShare a Scribd company logo
Pythia Reloaded: An Intelligent
Unit Testing-Based Code Grader for Education
Dr Sébastien Combéfis 1,2 Alexis Paques 2
1École Centrale des Arts et Métiers (ECAM)
2Computer Science and IT in Education (CSITEd)
July 14, 2015
[CHESE 2015, Baltimore, MD, USA]
Ce(tte) œuvre est mise à disposition selon les termes de la Licence Creative Commons
Attribution – Pas d’Utilisation Commerciale – Pas de Modification 4.0 International.
Context
Automatic assessment of codes
Programming learning platforms, MOOCs,
higher education courses, competitions...
Two major kinds of code assessment
Unit testing frameworks
Competition graders
Platform for automatic assessment and “intelligent” feedback
Suited for education and that helps learners
3
Pythia framework
Released as an open-source project
http://www.pythia-project.org
A unit testing framework...
Functional tests on learners’ code
...and a competition grader
Sandboxed environment with execution constraints
Prototyped in 2012, used for a MOOC in Spring 2014
4
Architecture
The Pythia framework consists in three layers
System layer Safe execution of jobs
Task layer Feedbacks
Problem layer Context and input/output structure
Problem layer
Task layer
System layer
5
System layer
Front-ends communicate with the outside world
Pools manage the safe execution of jobs
Front-end
Front-end
Front-end
Queue
Pool
Pool
6
Job execution
Sandbox uses UML with trimmed-down version of ArchLinux
The VM boots in under one second
A job has an environment and a task filesystem
Constraints can be added to the VM (time, memory and output)
{
"environment": "python",
"taskfs": "hello-world-python.sfs",
"limits": {
"time": 60,
"memory": 32,
"disk": 50,
"output": 1024
}
}
7
Problem example
A problem combines several tasks and adds a context
8
Pythia LMS
9
Unit Testing-Based Grading
Different kinds of tasks are possible
Examine stdout, evaluate time complexity, run unit tests...
Unit testing is for developers
Feedback is related to the specification of the function
Feedback for learners is related to the problem to be solved
10
Main executable I
1 Preprocess
Integrates code snippets from learners into skeletons
2 Compile
Analyses statically the code and compiles it
3 Generate
Generates tests sets and saves them to a file
11
Main executable II
4 Execute
Executes learner’s code against tests sets, generates data
5 Postprocess
Analyses generated data, and produces analysis results
6 Feedback
Generates feedbacks
12
Configuration-based definition
{
"q1": {
"argc": 2,
"predefined": {
"argv": [{
"data": "(10, 5)",
"feedback": {
"10": "Have you summed the 2nd parameter?",
"5": "Have you summed the 1st parameter?"
}
}, {
"data": "(7, 15)"
}, {
"data": "(-1, 2)",
"feedback": {
"*": "Have considered negative parameter?",
}
}, {
"data": "(12, 0)"
}]
},
"random": {
"n": 10,
"args": ["int(-20,20)", "int(-20,20)"]
},
"code": "def sum(a, b):n return a + b"
}
} 13
Importance of feedback
Predefined tests must cover errors often made by learners
Feedback should be related to the problem being solved
“Your code failed for the input a = 10, b = 5.
The expected result is 15 and your code produced 10.
Have you summed the 2nd parameter?”
14
Visual feedback
Visual feedback to be interpreted by the learner
15
Conclusion
Pythia is an open-source platform containing
a unit testing-based grader specifically designed for education
Ongoing work
Definition and specification of new kinds of tasks
Development of Pythia Studio and Pythia LMS
Future work
Explore use of other kinds of code checks
Mining code to identify common errors to extract feedback
16

More Related Content

DOC
Test Engine
PPTX
Club of anonimous developers "Refactoring: Legacy code"
PDF
Java Programming - 03 java control flow
PPTX
Pro typescript.ch03.Object Orientation in TypeScript
PDF
Welcome to Modern C++
PPT
data Structure Lecture 1
PDF
Java Programming - 04 object oriented in java
PPTX
модели акторов в с++ миф или реальность
Test Engine
Club of anonimous developers "Refactoring: Legacy code"
Java Programming - 03 java control flow
Pro typescript.ch03.Object Orientation in TypeScript
Welcome to Modern C++
data Structure Lecture 1
Java Programming - 04 object oriented in java
модели акторов в с++ миф или реальность

What's hot (20)

PPTX
Java concurrency
PPTX
Byte code field report
PDF
Virtual Separation of Concerns
PDF
Java Fundamentals
PPTX
More on Classes and Objects
PPSX
C# 6.0 - April 2014 preview
PDF
Lambda Functions in Java 8
PPSX
Java Tutorial
PPTX
Lecture 7, c++(complete reference,herbet sheidt)chapter-17.
PPTX
Java Notes
PPT
Presentation to java
PDF
Java Programming - 05 access control in java
PPTX
Operator overload rr
PDF
Shiksharth com java_topics
PPTX
Clean code slide
PPTX
clean code book summary - uncle bob - English version
PPTX
Java 10, Java 11 and beyond
PPTX
Virtual Separation of Concerns (2011 Update)
PPT
E:\Plp 2009 2\Plp 9
PPTX
The definitive guide to java agents
Java concurrency
Byte code field report
Virtual Separation of Concerns
Java Fundamentals
More on Classes and Objects
C# 6.0 - April 2014 preview
Lambda Functions in Java 8
Java Tutorial
Lecture 7, c++(complete reference,herbet sheidt)chapter-17.
Java Notes
Presentation to java
Java Programming - 05 access control in java
Operator overload rr
Shiksharth com java_topics
Clean code slide
clean code book summary - uncle bob - English version
Java 10, Java 11 and beyond
Virtual Separation of Concerns (2011 Update)
E:\Plp 2009 2\Plp 9
The definitive guide to java agents
Ad

Similar to Pythia Reloaded: An Intelligent Unit Testing-Based Code Grader for Education (20)

PPTX
Upstate CSCI 540 Unit testing
PDF
Python - code quality and production monitoring
ODT
Testing in-python-and-pytest-framework
PDF
Write unit test from scratch
PDF
Unit Testing in Python
PDF
Test your code
PDF
pytest로 파이썬 코드 테스트하기
PPTX
Unit/Integration Testing using Spock
PPTX
Introduction to unit testing in python
PDF
Debug - MITX60012016-V005100
PPTX
Workshop: Unit Testing in Python
PDF
Software Testing:
 A Research Travelogue 
(2000–2014)
PPTX
Unit testing and mocking in Python - PyCon 2018 - Kenya
PPTX
2.Python_Testing_Using_PyUnit_PyTest.pptx
PDF
Presentation on Unit Test with Python and Pytest
PDF
Test and refactoring
PDF
IRJET- Online Programming Assessment and Evaluation Platform in Education System
PDF
Py.test
PPTX
The UX of CI: DevOpsDays Galway 2019
PPTX
2.Python_Unit _Testing_Using_PyUnit_Pytest.pptx
Upstate CSCI 540 Unit testing
Python - code quality and production monitoring
Testing in-python-and-pytest-framework
Write unit test from scratch
Unit Testing in Python
Test your code
pytest로 파이썬 코드 테스트하기
Unit/Integration Testing using Spock
Introduction to unit testing in python
Debug - MITX60012016-V005100
Workshop: Unit Testing in Python
Software Testing:
 A Research Travelogue 
(2000–2014)
Unit testing and mocking in Python - PyCon 2018 - Kenya
2.Python_Testing_Using_PyUnit_PyTest.pptx
Presentation on Unit Test with Python and Pytest
Test and refactoring
IRJET- Online Programming Assessment and Evaluation Platform in Education System
Py.test
The UX of CI: DevOpsDays Galway 2019
2.Python_Unit _Testing_Using_PyUnit_Pytest.pptx
Ad

More from ECAM Brussels Engineering School (20)

PDF
Introduction à la formation Digitalent
PDF
Programmation de systèmes embarqués : Internet of Things : système connecté e...
PDF
Programmation de systèmes embarqués : Systèmes temps réel et PRUSS
PDF
Programmation de systèmes embarqués : Bus et périphériques de communication
PDF
Programmation de systèmes embarqués : BeagleBone Black et Linux embarqué
PDF
Programmation de systèmes embarqués : Introduction aux systèmes embarqués
PDF
Laboratoire de transmission numérique : Présentation du projet
PDF
Johnny-Five : Robotique et IoT en JavaScript
PDF
Introduction à LaTeX : le système de composition professionnel
PDF
Outils de gestion de projets
PDF
Développement informatique : Programmation graphique
PDF
Développement informatique : Algorithmique II : Techniques de recherche en in...
PDF
Intelligence Artificielle : Introduction à l'intelligence artificielle
PDF
Développement informatique : Programmation fonctionnelle, décorateur et génér...
PDF
Développement informatique : Programmation concurrente
PDF
Développement informatique : Algorithmique I : Récursion et arbre
PDF
Développement informatique : Chaines de caractères et expressions regulières
PDF
Développement informatique : Programmation réseau
PDF
Développement informatique : Gestion de projet, versioning, debugging, testin...
PDF
Python avancé : Qualité de code et convention de codage
Introduction à la formation Digitalent
Programmation de systèmes embarqués : Internet of Things : système connecté e...
Programmation de systèmes embarqués : Systèmes temps réel et PRUSS
Programmation de systèmes embarqués : Bus et périphériques de communication
Programmation de systèmes embarqués : BeagleBone Black et Linux embarqué
Programmation de systèmes embarqués : Introduction aux systèmes embarqués
Laboratoire de transmission numérique : Présentation du projet
Johnny-Five : Robotique et IoT en JavaScript
Introduction à LaTeX : le système de composition professionnel
Outils de gestion de projets
Développement informatique : Programmation graphique
Développement informatique : Algorithmique II : Techniques de recherche en in...
Intelligence Artificielle : Introduction à l'intelligence artificielle
Développement informatique : Programmation fonctionnelle, décorateur et génér...
Développement informatique : Programmation concurrente
Développement informatique : Algorithmique I : Récursion et arbre
Développement informatique : Chaines de caractères et expressions regulières
Développement informatique : Programmation réseau
Développement informatique : Gestion de projet, versioning, debugging, testin...
Python avancé : Qualité de code et convention de codage

Recently uploaded (20)

PPTX
Cloud computing and distributed systems.
PPTX
sap open course for s4hana steps from ECC to s4
PPTX
Spectroscopy.pptx food analysis technology
PPTX
Understanding_Digital_Forensics_Presentation.pptx
PDF
Per capita expenditure prediction using model stacking based on satellite ima...
PPTX
MYSQL Presentation for SQL database connectivity
PDF
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
PDF
How UI/UX Design Impacts User Retention in Mobile Apps.pdf
PDF
Diabetes mellitus diagnosis method based random forest with bat algorithm
PDF
Advanced methodologies resolving dimensionality complications for autism neur...
PDF
NewMind AI Weekly Chronicles - August'25 Week I
PDF
Architecting across the Boundaries of two Complex Domains - Healthcare & Tech...
PDF
Building Integrated photovoltaic BIPV_UPV.pdf
PPTX
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
PDF
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
PPTX
Detection-First SIEM: Rule Types, Dashboards, and Threat-Informed Strategy
PDF
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
PDF
Unlocking AI with Model Context Protocol (MCP)
PDF
MIND Revenue Release Quarter 2 2025 Press Release
PDF
Review of recent advances in non-invasive hemoglobin estimation
Cloud computing and distributed systems.
sap open course for s4hana steps from ECC to s4
Spectroscopy.pptx food analysis technology
Understanding_Digital_Forensics_Presentation.pptx
Per capita expenditure prediction using model stacking based on satellite ima...
MYSQL Presentation for SQL database connectivity
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
How UI/UX Design Impacts User Retention in Mobile Apps.pdf
Diabetes mellitus diagnosis method based random forest with bat algorithm
Advanced methodologies resolving dimensionality complications for autism neur...
NewMind AI Weekly Chronicles - August'25 Week I
Architecting across the Boundaries of two Complex Domains - Healthcare & Tech...
Building Integrated photovoltaic BIPV_UPV.pdf
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
Detection-First SIEM: Rule Types, Dashboards, and Threat-Informed Strategy
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
Unlocking AI with Model Context Protocol (MCP)
MIND Revenue Release Quarter 2 2025 Press Release
Review of recent advances in non-invasive hemoglobin estimation

Pythia Reloaded: An Intelligent Unit Testing-Based Code Grader for Education

  • 1. Pythia Reloaded: An Intelligent Unit Testing-Based Code Grader for Education Dr Sébastien Combéfis 1,2 Alexis Paques 2 1École Centrale des Arts et Métiers (ECAM) 2Computer Science and IT in Education (CSITEd) July 14, 2015 [CHESE 2015, Baltimore, MD, USA]
  • 2. Ce(tte) œuvre est mise à disposition selon les termes de la Licence Creative Commons Attribution – Pas d’Utilisation Commerciale – Pas de Modification 4.0 International.
  • 3. Context Automatic assessment of codes Programming learning platforms, MOOCs, higher education courses, competitions... Two major kinds of code assessment Unit testing frameworks Competition graders Platform for automatic assessment and “intelligent” feedback Suited for education and that helps learners 3
  • 4. Pythia framework Released as an open-source project http://www.pythia-project.org A unit testing framework... Functional tests on learners’ code ...and a competition grader Sandboxed environment with execution constraints Prototyped in 2012, used for a MOOC in Spring 2014 4
  • 5. Architecture The Pythia framework consists in three layers System layer Safe execution of jobs Task layer Feedbacks Problem layer Context and input/output structure Problem layer Task layer System layer 5
  • 6. System layer Front-ends communicate with the outside world Pools manage the safe execution of jobs Front-end Front-end Front-end Queue Pool Pool 6
  • 7. Job execution Sandbox uses UML with trimmed-down version of ArchLinux The VM boots in under one second A job has an environment and a task filesystem Constraints can be added to the VM (time, memory and output) { "environment": "python", "taskfs": "hello-world-python.sfs", "limits": { "time": 60, "memory": 32, "disk": 50, "output": 1024 } } 7
  • 8. Problem example A problem combines several tasks and adds a context 8
  • 10. Unit Testing-Based Grading Different kinds of tasks are possible Examine stdout, evaluate time complexity, run unit tests... Unit testing is for developers Feedback is related to the specification of the function Feedback for learners is related to the problem to be solved 10
  • 11. Main executable I 1 Preprocess Integrates code snippets from learners into skeletons 2 Compile Analyses statically the code and compiles it 3 Generate Generates tests sets and saves them to a file 11
  • 12. Main executable II 4 Execute Executes learner’s code against tests sets, generates data 5 Postprocess Analyses generated data, and produces analysis results 6 Feedback Generates feedbacks 12
  • 13. Configuration-based definition { "q1": { "argc": 2, "predefined": { "argv": [{ "data": "(10, 5)", "feedback": { "10": "Have you summed the 2nd parameter?", "5": "Have you summed the 1st parameter?" } }, { "data": "(7, 15)" }, { "data": "(-1, 2)", "feedback": { "*": "Have considered negative parameter?", } }, { "data": "(12, 0)" }] }, "random": { "n": 10, "args": ["int(-20,20)", "int(-20,20)"] }, "code": "def sum(a, b):n return a + b" } } 13
  • 14. Importance of feedback Predefined tests must cover errors often made by learners Feedback should be related to the problem being solved “Your code failed for the input a = 10, b = 5. The expected result is 15 and your code produced 10. Have you summed the 2nd parameter?” 14
  • 15. Visual feedback Visual feedback to be interpreted by the learner 15
  • 16. Conclusion Pythia is an open-source platform containing a unit testing-based grader specifically designed for education Ongoing work Definition and specification of new kinds of tasks Development of Pythia Studio and Pythia LMS Future work Explore use of other kinds of code checks Mining code to identify common errors to extract feedback 16