iCog-Labs-Dev / metta-moses

Meta Optimization Semantic Evolutionary Search
3 stars 14 forks source link

Implements Cut unnecessary OR transformation #147

Closed BrookFeleke closed 2 weeks ago

BrookFeleke commented 2 weeks ago

Description

Implemented the cut unnecessary or transformation in the cut-unnecessary-or.metta file and added tests to test it in the tests director, cut-unnecessary-or-test.metta.

Motivation and Context

It is one of the transformations that takes place during Reduce to Elegance. It's purpose is to remove redundant OR (or nodes with a single child).

How Has This Been Tested?

Added only two files, the orCut implementation and a test file to test that function in the tests directory. No other changes were made to existing files. The test file for the orCut function passes all tests.

Types of changes

Checklist:

Yagth commented 2 weeks ago

@BrookFeleke, sorry but the implementation has already been done in a more readable way on PR #145. It has just been completed, which is why I didn't tell you earlier.