37 Followers
36 Following
839 Posts

Retired software architect.
Linux and C++

Enjoy impossible software projects.

The rule text generation is now working.

This was a practice run to get familiar with the generated data structures for the rules.

An aside:
One of the interesting features of the SASSY rule engine is that its rules are stored as RDF data. Since the purpose of the rule engine is to modify RDF data, it follows that it can modify its own rules.

The next step is to adapt the previously written classes that make up the rule interpreter. These were originally derived from the generated code, but will now be independent of it.

#SASSY

An update on the SASSY project.

I have been attempting to use its rule engine to create a document from some RDF data. The data is the quality attribute descriptions. This has not been going well, and the log messages tend to indicate that something is seriously awry.

The rule engine has several components that support editing and running the rules. Two of these use generated code that converts an RDF schema into C++ structures. One then creates a text file for editing the rules; the other creates the execution model that runs the rules.

The original idea was to derive implementation classes from the generated classes. This seems to mostly work, but things get complicated if you try to access a parent class, since the derived classes no longer have a proper parent relationship.

Fortunately the code generator can also create code that is intended to use the visitor pattern. The plan is to re-implement these two parts of the rule engine using that design pattern.

#SASSY

Project Maven and the bombing of the girls school in Iran
https://substack.com/home/post/p-191689642

#palantir #ai #sensorfusion

Kill Chain

On the automated bureaucratic machinery that killed 175 children

Artificial Bureaucracy

The problem with being a long term Green supporter is that I cannot change my vote away from the ALP to express my dissatisfaction.

#AUSPOL

RE: https://norden.social/@wackJackle/116200267162290355

I did not know this history of the printing press—really worth the minutes!

Well that makes a successful day 😃

Added a few fixes to the rule engine and it now works as intended.

Nice to press a button to run the rules, then another to run the document generation, and see the test PDF change to include some text from the QA data set.

Next task is to add more templates and rules to get it to build the complete document.

#SASSY

Oops, I seem to have ventured out into the land of the great untested, where the dreaded SIGSEGV roams free.

And it all begins to unravel...

Add a log message and exception to avoid the seg fault. It fails to compile.

The errors are in generated code. It appears to be from a no longer supported version of the code generator.

Seems like a thorough revisiting of the rule engine is called for.

#SASSY #programming

2/2

The expert system mode combined with rules that replace one macro with data and other macros can build arbitrarily complex documents.

The first step is to make a skeleton document with whatever boilerplate is desired. This is then extended with some primary macros, and a copy made (otherwise we only get to do it once ).

Note that "macro" is actually just some more RDF statements describing what to do.

The primary rules will each search for a particular macro. The rule will remove the macro and call another rule with the location in the document as a parameter.

The secondary rule will search the data and add its results into the document, followed by any applicable macros.

#SASSY

Some thoughts on SASSY

I have finally worked out how this template macro system is going to work. I knew it could be done, but the details were rather undefined.

Some background on my rule engine is probably necessary.

Each rule starts with a SPARQL query that binds values from the RDF data to variables.

Each set of values is then optionally passed to some filters (calls to plug-in library functions) and then (optionally) to an iterator that cycles over any RDF sequences or lists.

Next they are passed to the execution section where the values are used to create new RDF statements, delete existing ones, or be passed to functions (also in plug-in libraries) or used to create a call to another rule.

The system has three modes of operation: either a single rule (which can still call other rules); a sequence of rules that are each run once; or an expert system mode where the sequence of rules are executed until one does something, and then the sequence resets and starts over. This repeats until nothing is done.

1/2

#SASSY

Slowly getting back into the SASSY project. It does take a while to pick up the threads after a 6 month break.

The current primary task is part of the bootstrapping process. It involves creating some rules that replace template "macros" in a document with data extracted from another RDF data set.

On inspection of the RDF for the base document I noted it was full of statements that should not have been there. This was the side effect of a bug, that has already been fixed.

My RDFGUI program can remove statements from a model, but it takes three mouse clicks for every one, and there are hundreds to be deleted. A multi-statement delete is on the TODO list, so it was time to implement it.

That change has just been completed, tested and checked into the SourceForge repository.

Now I can clean up the data, and actually start developing these rules.

#SASSY