Describing a Lesson
For years, I’ve been searching for a high-level notation for modeling and describing lessons. My search is inspired by things like flowcharts and UML diagrams, which should also inspire caution, since most programmers don’t use them unless they’re forced to. One reason, I think, has been tooling: graphical notations don’t lend themselves to version control, and as soon as you start editing the Java or C++ spat out by code generators, you realize that “round trip” is a myth.
I’ve always found concept maps very useful for designing lessons or giving people an overview of what they contain. What I’ve struggled with is:
-
managing them with version control tools, which still insist that the whole world be expressed as punchcards (i.e., lines of text), and
-
keeping the diagrams in sync with the lessons they summarize and vice versa.
So, here are some concept maps I use in my lesson on basic SQL, along with textual descriptions similar to those used by graphviz and Mermaid. I’d like to know:
-
Can an LLM compare the concept map’s textual description with the lesson it summarizes and report inconsistencies and omissions?
-
Can it report changes such as, “The latest change to the text introduces another connection between A and B,” or, “The latest change breaks that connection”?
-
Is some other textual representation of the concept map provably better for these purposes? Here, “provably better” means “you can describe a set of empirical studies that will convince me that your proposed notation improves the efficiency and accuracy of both human users and LLMs”.
-
If the answers to the previous questions are “yes”, can the notation and graphical representation be extended to represent things like clusters of concepts, the order in which things should be taught, and other things I haven’t even though of?
-
Most importantly, what can we learn from this exercise about using higher-level abstractions to communicate simultaneously with people and machines?
If you’re a grad student looking for a project, or if something like this already exists, please get in touch.
Introduction
database -- contains -> information
database -- managed by -> DBMS
DBMS -- can be implemented as -> {library, server}
database -- can be -> {NoSQL, relational}
NoSQL -- manages -> something else
information -- stored as -> {something else, tables}
relational -- manages -> tables
relational -- queried with -> SQL
Basic Selection
select -- chooses -> {rows, columns}
rows -- can be paged with -> {limit, offset}
{rows, columns} -- from -> table
columns -- specified by -> {names, calculations, * (for all)}
table -> specified by -> name
Filtering
filter -- specifies -> condition
condition -- must be -> Boolean
condition -- evaluated for each -> rows
filter -- does not modify -> columns
filter -- keeps some -> rows
rows -- from -> table
table -- has -> columns
Grouping and Aggregation
group by -- specifies -> columns
group by <- usually used with -> aggregation
aggregation -- specifies -> {column, function}
column -- usually not one of -> columns
function -- combines values from -> rows
Nulls
null -- produces itself in -> {arithmetic, comparison}
null -- represents -> {"I don't know"}
null -- is not -> {false, empty string, (un)equal to itself, zero}
null -- ignored in -> aggregation
null -- checked using -> {is null, is not null}
Joins
join -- can be -> {left join, inner join, outer join}
join -- usually uses -> condition
condition -- selects rows of -> temporary table
join -- combines rows from {left table, right table}
{left table, right table} -- to create -> temporary table
Keys
tables -- can have -> {primary key, foreign key}
primary key -- is -> {unique, not null}
foreign key -- refers to -> primary key
{primary key, foreign key} -- used in -> join
foreign key -- expresses -> {one-to-many, many-to-many}
relationship -- can be -> {one-to-many, many-to-many}
tables -- can be -> join tables
join tables -- capture -> many-to-many
Subqueries
CTE <- alternative to -> subquery
{CTE, subquery} – is a -> complete query
CTE – defines a -> temporary table
{CTE, subquery} – often used for -> negation
subquery – evaluated before -> outer query
outer query – uses result of -> subquery
Modifying Data
tables -- defined with -> {names, rows}
rows -- can be -> {created, updated, deleted, copied to other tables}
rows -- must have -> {names, types}
types -- may be -> {integer, text, real, blob}
rows -- may have -> constraint
constraint -- may be -> {unique, primary key, autoincrement, not null}