Bastiaan Heeren
Open University
Network
Latest external collaboration on country level. Dive into details by clicking on the dots.
Publication
Featured researches published by Bastiaan Heeren.
symposium/workshop on haskell | 2003
Bastiaan Heeren; Daan Leijen; Arjan van IJzendoorn
Helium is a user-friendly compiler designed especially for learning the functional programming language Haskell. The quality of the error messages has been the main concern both in the choice of the language features and in the implementation of the compiler. Helium implements almost full Haskell, where the most notable difference is the absence of type classes. Our goal is to let students learn functional programming more quickly and with more fun. The compiler has been successfully employed in two introductory programming courses at Utrecht University.
international conference on functional programming | 2003
Bastiaan Heeren; Jurriaan Hage; S. Doaitse Swierstra
To improve the quality of type error messages in functional programming languages,we propose four techniques which influence the behaviour of constraint-based type inference processes. These techniques take the form of externally supplied type inference directives, precluding the need to make any changes to the compiler. A second advantage is that the directives are automatically checked for soundness with respect to the underlying type system. We show how the techniques can be used to improve the type error messages reported for a combinator library. More specifically, how they can help to generate error messages which are conceptually closer to the domain for which the library was developed. The techniques have all been incorporated in the Helium compiler, which implements a large subset of Haskell.
implementation and application of functional languages | 2006
Jurriaan Hage; Bastiaan Heeren
Type error messages that are reported for incorrect functional programs can be difficult to understand. The reason for this is that most type inference algorithms proceed in a mechanical, syntax-directed way, and are unaware of inference techniques used by experts to explain type inconsistencies. We formulate type inference as a constraint problem, and analyze the collected constraints to improve the error messages (and, as a result, programming efficiency). A special data structure, the type graph, is used to detect global properties of a program, and furthermore enables us to uniformly describe a large collection of heuristics which embed expert knowledge in explaining type errors. Some of these also suggest corrections to the programmer. Our work has been fully implemented and is used in practical situations, showing that it scales up well. We include a number of statistics from actual use of the compiler showing us the frequency with which heuristics are used, and the kind and number of suggested corrections.
integrating technology into computer science education | 2012
Alex Gerdes; Johan Jeuring; Bastiaan Heeren
We introduce an interactive tutor that supports the stepwise development of simple functional programs. Using this tutor, students receive feedback about whether or not they are on the right track, can ask for a hint when they are stuck, and get suggestions about how to refactor their program. Our tutor generates this semantically rich feedback from model solutions, using advanced concepts from software technology. We show how a teacher can add an exercise to the tutor, and fine-tune feedback. We report on an experiment in which we used our tutor.
Mathematics in Computer Science | 2010
Bastiaan Heeren; Johan Jeuring; Alex Gerdes
Strategies specify how a wide range of exercises can be solved incrementally, such as bringing a logic proposition to disjunctive normal form, reducing a matrix, or calculating with fractions. In this paper we introduce a language for specifying strategies for solving exercises. This language makes it easier to automatically calculate feedback, for example when a user makes an erroneous step in a calculation. We can automatically generate worked-out examples, track the progress of a student by inspecting submitted intermediate answers, and report back suggestions in case the student deviates from the strategy. Thus it becomes less labor-intensive and less ad-hoc to specify new exercise domains and exercises within that domain. A strategy describes valid sequences of rewrite rules, which turns tracking intermediate steps into a parsing problem. This is a promising view at interactive exercises because it allows us to take advantage of many years of experience in parsing sentences of context-free languages, and transfer this knowledge and technology to the domain of stepwise solving exercises. In this paper we work out the similarities between parsing and solving exercises incrementally, we discuss generating feedback on strategies, and the implementation of a strategy recognizer.
practical aspects of declarative languages | 2005
Bastiaan Heeren; Jurriaan Hage
The goal of this paper is to improve the type error messages in the presence of Haskell 98 type classes, in particular for the non-expert user. As a language feature, type classes are very pervasive, and strongly influence what is reported and when, even in relatively simple programs. We propose four type class directives, and specialized type rules, to lend high-level support to compilers to improve the type error messages. Both have been implemented, and can be used to easily modify the behavior of the type inference process.
artificial intelligence and symbolic computation | 2008
Bastiaan Heeren; Johan Jeuring; Arthur van Leeuwen; Alex Gerdes
The feedback given by e-learning tools that support incrementally solving problems in mathematics, logic, physics, etc. is limited, or laborious to specify. In this paper we introduce a language for specifying strategies for solving exercises. This language makes it easier to automatically calculate feedback when users make erroneous steps in a calculation. Although we need the power of a full programming language to specify strategies, we carefully distinguish between context-free and non-context-free sublanguages of our strategy language. This separation is the key to automatically calculating all kinds of desirable feedback.
Electronic Notes in Theoretical Computer Science | 2009
Jurriaan Hage; Bastiaan Heeren
Turning type and effect deduction systems into an algorithm is a tedious and error-prone job, and usually results in an implementation that leaves no room to modify the solving strategy, without actually changing it. We employ constraints to declaratively specify the rules of a type system. Starting from a constraint based formulation of a type system, we introduce special combinators in the type rules to specify in which order constraints may be solved. A solving strategy can then be chosen by giving a particular interpretation to these combinators, and the resulting list of constraints can be fed into a constraint solver; thus the gap between the declarative specification and the deterministic implementation is bridged. This design makes the solver simpler and easier to reuse. Our combinators have been used in the development of a real-life compiler.
Science of Computer Programming | 2014
Bastiaan Heeren; Johan Jeuring
Abstract Advanced learning environments such as intelligent tutoring systems for algebra, logic, programming, physics, etc. let a student practice with stepwise exercises, and support a student solving such exercises by providing feedback. These environments usually provide various types of feedback, for example about the correctness of a step, common errors, hints about how to proceed, or complete worked-out solutions. Calculating feedback is generally delegated to a dedicated expert knowledge module, also known as a domain reasoner. Existing architectural descriptions of learning environments do not precisely specify the interaction between this module and the rest of the learning system. We propose a design based on the stateless client–server architecture that clearly decouples the expert knowledge module from the learning environment. We describe a set of feedback services that support the inner (interactions within an exercise) and outer (over a collection of exercises) loops of a learning system, and that provide meta-information about a class of exercises, such as solving quadratic equations, or performing Gaussian elimination. The feedback services do not depend on a particular domain and are based on the various feedback types described in the literature. The paper analyzes which domain-specific knowledge about an exercise class is needed for implementing the feedback services. Based on this analysis, we developed a framework for implementing domain reasoners that offers generic functionality such as rewriting, simplifying, and comparing terms. We have implemented several domain reasoners in this framework, both for external learning environments and for simple prototypes. The proposed design is evaluated with these implementations, and we reflect on our experience with developing domain reasoners.
artificial intelligence in education | 2017
Alex Gerdes; Bastiaan Heeren; Johan Jeuring; L. Thomas van Binsbergen
Ask-Elle is a tutor for learning the higher-order, strongly-typed functional programming language Haskell. It supports the stepwise development of Haskell programs by verifying the correctness of incomplete programs, and by providing hints. Programming exercises are added to Ask-Elle by providing a task description for the exercise, one or more model solutions, and properties that a solution should satisfy. The properties and model solutions can be annotated with feedback messages, and the amount of flexibility that is allowed in student solutions can be adjusted. The main contribution of our work is the design of a tutor that combines (1) the incremental development of different solutions in various forms to a programming exercise with (2) automated feedback and (3) teacher-specified programming exercises, solutions, and properties. The main functionality is obtained by means of strategy-based model tracing and property-based testing. We have tested the feasibility of our approach in several experiments, in which we analyse both intermediate and final student solutions to programming exercises, amongst others.