The expansions generating that code look something like this. #suetum #versu #praxis

Well, even though I was working on SelanĂ­a too these days, I've been able to get to the end of the expansion mechanism too! Now I can write stuff like

```
Have you heard of what [Gossippee.subj] said yesterday?
No! What did [Gossippee.subj] do?
Well, you know, someone gave [Gossippee.obj] the excuse to...
```

And have it expand to

```
Have you heard of what Mary said yesterday?
No! What did she do?
Well, you know, someone gave her the excuse to...
```

#suetum #versu #praxis

In order to expand strings like
"Hello, [greeting.towards.Person]."
I must know context about Person (like: do I hate them? I love them? I'm neutral?), which means that intelligent expansions must be used (context free grammars with conditions from the current state of the game, in practice), which means that they are not just syntactic replacement but need the whole machinery of the runtime engine, which means moving lots of code... AAAAA xD

#Suetum #versu #praxis

Parsing code + test suite done, so now I can go on with the compilation and then execution of the expansion! #suetum #versu #praxis
ok, after some bugfix I reached the astronomical amount of...
(drumrolls)
48 lines of antlr4 parser.
i love so much when i can code less O_O
#suetum #praxis #versu
Lots of thinking, and then the grammar for the expansion construct is so embarrassingly simple đŸ¥¹ #Suetum #versu #praxis

Fixed also the last bug regarding axiom/rules exploration. Which allows you to drill-down in axiom expansions, and sub-axiom expansions and so on.

Now, in the space between the work on Selanìa, I can get to attack (my version of) Prolog's definite clause grammars.

It will probably be a more pragmatic approach, strongly oriented towards the narrative usages, with dedicated syntax, although it will be 100% based on exclusion logic like the rest.

#Suetum #versu #praxis

Big commit on #Suetum to improve axioms (rules). Now you can write mutually recursive rules, and Habitus is also kind-of able to show them (there are still cases in which it can't expand an axiom, in case the very first rule of the axiom already fails)!

https://codeberg.org/owofgames/suetum/commit/d90f8f4d2a5fa3db54c0a8448a28724833798874

#praxis #versu

This #Suetum program is doing like a thousand more computations than it should to check a condition, but at least the indented logger produces a very pleasing minimap on the right of the editor.

#versu #praxis

I kind of, sort of forgot that axioms are parts of the system, and right now they are completely opaque to the debugger.

So! Let's expand the system the allows for notifications during the unification of logic clauses to work also on axioms, and track a "stack" of the resolution.

This was quite tricky, and revealed a bug in recursive axiom applications, but: it's done! Now, how to properly display it...

#Suetum #versu #praxis