{"id":167,"date":"2019-03-06T13:07:08","date_gmt":"2019-03-06T13:07:08","guid":{"rendered":"https:\/\/dectau.uclm.es\/bousi-prolog\/?p=167"},"modified":"2025-04-10T12:14:01","modified_gmt":"2025-04-10T12:14:01","slug":"release-notes","status":"publish","type":"post","link":"https:\/\/dectau.uclm.es\/bousi-prolog\/2019\/03\/06\/release-notes\/","title":{"rendered":"RELEASE NOTES"},"content":{"rendered":"<hr \/>\n<p><span style=\"color: #ff00ff\"><strong>BPL version 4.0 \u00a0<\/strong>(April, 7th 2025)<\/span><\/p>\n<hr \/>\n<p>The main contribution of this major version is the incorporation of the hypothetical mode. To achieve the ability to reason hypothetically, it was necessary to thoroughly revise the system, particularly its handling of higher-order predicates and negation.<\/p>\n<p>With respect to former version 3.6.1, the present version 4.0 adds the following:<\/p>\n<p><strong>Enhancements<\/strong>:<\/p>\n<p style=\"padding-left: 30px\"><strong><span style=\"color: #993366\">* Higher order:<\/span><\/strong><\/p>\n<p style=\"padding-left: 30px\">&#8211; Approximation degree calculation for higher order predicates:<br \/>\n&#8211; <strong>call\/1<\/strong>, <strong>once\/1<\/strong>, <strong>ignore\/1<\/strong>, <strong>time\/1<\/strong><br \/>\n&#8211; <strong>apply\/2<\/strong>, <strong>maplist\/2<\/strong><br \/>\n&#8211; <strong>catch\/3<\/strong><\/p>\n<p style=\"padding-left: 30px\">&#8211; Higher order calls with runtime compilations when needed:<br \/>\n&#8211; <strong>not\/1<\/strong>, <strong>(\\+)\/1<\/strong><br \/>\n&#8211; <strong>=&gt;\/2<\/strong><br \/>\n&#8211; <strong>call\/1<\/strong>, <strong>once\/1<\/strong>, <strong>ignore\/1<\/strong>, <strong>time\/1<\/strong><br \/>\n&#8211; <strong>apply\/2<\/strong>, <strong>maplist\/2<\/strong><br \/>\n&#8211; <strong>catch\/3<\/strong><\/p>\n<p style=\"padding-left: 30px\">&#8211; Higher order built-in predicates and operators admit partial goals, delaying the compilation until run-time, including all previous higher order hypothetical calls plus:<br \/>\n&#8211; <strong>truth_degree\/2<\/strong><br \/>\n&#8211; <strong>forall\/2<\/strong><br \/>\n&#8211; <strong>findall\/3<\/strong><br \/>\n&#8211; <strong>bagof\/3<\/strong><br \/>\n&#8211; <strong>setof\/3<\/strong><\/p>\n<p style=\"padding-left: 30px\">&#8211; Dynamic database predicates accept partial rules, which will be compiled at run-time:<br \/>\n&#8211; <strong>assert\/1<\/strong><br \/>\n&#8211; <strong>retract\/1<\/strong><\/p>\n<p style=\"padding-left: 30px\">&#8211; Variables are allowed as goals.<\/p>\n<p style=\"padding-left: 30px\">&#8211; Higher order goals can be any compound goal, not only an atom as in previous version.<\/p>\n<p style=\"padding-left: 30px\"><strong><span style=\"color: #993366\">* Hypothetical reasoning:<\/span><\/strong><\/p>\n<p style=\"padding-left: 30px\">&#8211; Hypothetical reasoning following:<\/p>\n<p style=\"padding-left: 30px\"><span style=\"color: #993366\">&#8220;Planning for an Efficient Implementation of Hypothetical <\/span><br \/>\n<span style=\"color: #993366\"> Bousi-Prolog&#8221;, <\/span><br \/>\n<span style=\"color: #993366\"> P. Julian-Iranzo and F. Saenz-Perez, <\/span><br \/>\n<span style=\"color: #993366\"> Theory and Practice of Logic Programming, 21(5), pp. 680-697, <\/span><br \/>\n<span style=\"color: #993366\"> Special Issue, 2021<\/span>.<\/p>\n<p style=\"padding-left: 30px\">&#8211; Interactive assumptions at the system prompt.<\/p>\n<p style=\"padding-left: 30px\">&#8211; Program directive<strong> :- hypothetical(&lt;Boolean&gt;)<\/strong> for enabling or disabling hypothetical mode.<\/p>\n<p style=\"padding-left: 30px\">&#8211; Command <strong>hy &lt;Boolean&gt;<\/strong> for changing between normal and hypothetical reasoning modes.<\/p>\n<p style=\"padding-left: 30px\"><strong><span style=\"color: #993366\">* Other enhancements:<\/span><\/strong><\/p>\n<p style=\"padding-left: 30px\">&#8211; Added higher order predicate <strong>truth_degree(+Goal, -Degree)<\/strong> to accessing the approximation degree of each solution of the goal. If <strong>Goal<\/strong> fails, <strong>Degree<\/strong> is 0.<\/p>\n<p style=\"padding-left: 30px\">&#8211; Added 150 new tests for higher order calls, hypothetical reasoning programs, goals and commands (from 830 to 980).<\/p>\n<p style=\"padding-left: 30px\">&#8211; Crisp (<strong>\\+<\/strong>) and fuzzy (<strong>not<\/strong>) negations are also allowed as prefix operators.<\/p>\n<p style=\"padding-left: 30px\">&#8211; Under the filtering optimisation, unification problems for single-occurrence variables at the head are not built, therefore saving one unification problem for multiple-occurrence variables at the head.<\/p>\n<p style=\"padding-left: 30px\">&#8211; <strong>Assert<\/strong> and <strong>retract<\/strong> also accept rules, not only facts.<\/p>\n<p style=\"padding-left: 30px\">&#8211; Command <strong>st<\/strong> for displaying the current status of Bousi~Prolog.<\/p>\n<p style=\"padding-left: 30px\">&#8211; Command <strong>sp &lt;predicate&gt;<\/strong> (intended for system implementors) sets a spy point on the given Prolog predicate for debugging the Bousi-Prolog system implementation.<\/p>\n<p style=\"padding-left: 30px\">&#8211; Extended set of SWI-Prolog built-in predicates are detected.<\/p>\n<p style=\"padding-left: 30px\">&#8211; The command <strong>ts<\/strong> includes the tests &#8220;additional queries&#8221; in its final statistics.<\/p>\n<p style=\"padding-left: 30px\">&#8211; Weak unification built-in predicates now support degree accumulator optimization.<\/p>\n<p style=\"padding-left: 30px\">&#8211; Simplified implementation for both weak and crisp negations.<\/p>\n<p style=\"padding-left: 30px\">&#8211; <strong>not\/1<\/strong> enhanced to deliver as many solutions as can be derived. For example, for the program:<\/p>\n<pre style=\"padding-left: 30px\"><strong>\u00a0 \u00a0 \u00a0p with 0.3. \r\n \u00a0 \u00a0 p with 0.4.<\/strong><\/pre>\n<p style=\"padding-left: 30px\">the following is the new result:<\/p>\n<pre style=\"padding-left: 30px\"><strong>\u00a0 \u00a0 \u00a0BPL&gt; not(p)\r\n \u00a0 \u00a0 true\r\n \u00a0 \u00a0 With approximation degree: 0.7 ;\r\n \u00a0 \u00a0 true\r\n \u00a0 \u00a0 With approximation degree: 0.6.<\/strong><\/pre>\n<p style=\"padding-left: 30px\">while for the last version, only one solution was found:<\/p>\n<pre style=\"padding-left: 30px\"><strong>\u00a0 \u00a0 \u00a0BPL&gt; not(p)\r\n \u00a0 \u00a0 true\r\n \u00a0 \u00a0 With approximation degree: 0.7.<\/strong><\/pre>\n<p><strong>Changes:<\/strong><\/p>\n<p style=\"padding-left: 30px\">&#8211; Block identifiers start with 0 for the Prolog-based implementation to match the C-based implementation.<\/p>\n<p><strong>Fixed bugs:<\/strong><\/p>\n<p style=\"padding-left: 30px\">&#8211; Sometimes, &#8220;<strong>With approximation degree: 1<\/strong>&#8221; was displayed instead of simply &#8220;<strong>true<\/strong>&#8220;.<\/p>\n<p style=\"padding-left: 30px\">&#8211; Negation did not appropriately communicate the block constraints as in the following program:<\/p>\n<pre style=\"padding-left: 30px\"><strong>\u00a0 \u00a0 \u00a0a ~ b = 0.3.\r\n \u00a0 \u00a0 b ~ c = 0.5.\r\n \u00a0 \u00a0 eq(X,X).\r\n \u00a0 \u00a0 p :- not(eq(a,b)), eq(b,c).<\/strong><\/pre>\n<p style=\"padding-left: 30px\">with the goal <strong>p<\/strong>, which should fail and it succeeded otherwise. While <strong>not(eq(a,b))<\/strong> succeeds, a-b is in a block. Next, <strong>eq(b,c)<\/strong> should not succeed because it would be forming another block b-c, so that b would be in two different blocks, which is not allowed.<\/p>\n<p style=\"padding-left: 30px\">&#8211; Unsupported interactive action responses at the top-level gave an error.<\/p>\n<p style=\"padding-left: 30px\">&#8211; <strong>sim\/4<\/strong> entries for unification algorithm<strong> a3<\/strong> were not retracted when computing the new ones.<\/p>\n<p style=\"padding-left: 30px\">&#8211; Recomputing block constraints could yield different block identifiers. While the process was correct, recomputing during a derivation might lead to incorrect unification results.<\/p>\n<p style=\"padding-left: 30px\">&#8211; The name of an undefined predicate name might be incorrectly returned when its name starts with the program prefix (file name without extension).<\/p>\n<p style=\"padding-left: 30px\">&#8211; The expansion of rules for unification algorithm <strong>a3<\/strong> was incomplete: it only used the first entry in RB.<\/p>\n<p style=\"padding-left: 30px\">&#8211; Translations of rules with disjunctions did not appropriately connect degree and constraint variables in the expanded program.<\/p>\n<p>&nbsp;<\/p>\n<hr \/>\n<p><span style=\"color: #ff00ff\"><strong>BPL version 3.6.1 \u00a0<\/strong>(June, 25th 2022)<\/span><\/p>\n<hr \/>\n<p>With respect to former version 3.6, the present version 3.6.1 adds the following:<\/p>\n<p><strong>Enhancements:<\/strong><br \/>\n&#8211; 64 bit BPL installer released for Windows (tested on Windows 10). See README.txt for requirements.<\/p>\n<p><strong>Fixed bugs:<\/strong><br \/>\n&#8211; When degree accumulator optimization was enabled, there was two bad expansions: one for the infix operator ~~, and the other for a goal with linearised weak unifications.<br \/>\n&#8211; BPL 3.6 distributions for Mac included a non-updated version of the external library extern.so, precluding the use of some syntax changes that were made.<\/p>\n<hr \/>\n<p><span style=\"color: #ff00ff\"><strong>BPL version 3.6 \u00a0<\/strong>(January, 3rd 2021)<\/span><\/p>\n<hr \/>\n<p>The main contribution of this version is the incorporation of novel implementation techniques for improving the efficiency of the BPL system. With respect to former version 3.5, the present version 3.6 adds the following:<\/p>\n<p><strong>Enhancements:<\/strong><\/p>\n<p style=\"padding-left: 30px\">1) Syntax extended with DCG grammar rules.<\/p>\n<p style=\"padding-left: 30px\">2) Added t-norms <strong>drastic<\/strong>, <strong>nilpotent<\/strong> and <strong>hamacher<\/strong>.<\/p>\n<p style=\"padding-left: 30px\">3) Numbers are not weak unified anymore.<\/p>\n<p style=\"padding-left: 30px\">4) <strong>Indexing optimization<\/strong>: symbols which are not similar to any other under the current lambda-cut are not weak unified. This allows for taking advantage of the host Prolog system indexing (both multiargument and deep indexing). As a novelty, facts can result from BPL to TPL translations (when no weak unification is involved).<\/p>\n<p style=\"padding-left: 30px\">5) A new directive <strong>:-indexing(+Boolean)<\/strong> is provided for either enabling or disabling indexing optimization. By default, it is enabled (<strong>Boolean=true<\/strong>).<\/p>\n<p style=\"padding-left: 30px\">6) <strong>Tail recursion optimisation<\/strong> (TRO) is kept for translated BPL programs, which is possible by adding an accumulator argument for degree compositions.<\/p>\n<p style=\"padding-left: 30px\">7) A new directive <strong>:-degree_accumulator(+Boolean)<\/strong> is provided for either enabling or disabling degree accumulator translation. Enabling this translation implies not breaking TRO in BPL programs. By default, it is enabled (<strong>Boolean=true<\/strong>).<\/p>\n<p style=\"padding-left: 30px\">8) Included filenames can be specified without the <strong>.bpl<\/strong> extension.<\/p>\n<p style=\"padding-left: 30px\">9) New command <strong>ti<\/strong> for enabling or disabling time statistics for each input.<\/p>\n<p style=\"padding-left: 30px\">10) Improved parser can handle bigger BPL programs.<\/p>\n<p style=\"padding-left: 30px\">11) Added a message indicating the end of parsing to the command <strong>ld<\/strong>.<\/p>\n<p><strong>Changes:<\/strong><\/p>\n<p style=\"padding-left: 30px\">1)\u00a0Under the new indexing optimization, it may be the case that logical view update is lost when retracting facts.<\/p>\n<p><strong>Fixed bugs:<\/strong><\/p>\n<p style=\"padding-left: 30px\">1) Atoms were not quoted when needed upon displaying solutions.<\/p>\n<p style=\"padding-left: 30px\">2) Propositional predicates could not be asserted (non-termination).<\/p>\n<p style=\"padding-left: 30px\">3) Weighted rules below lambda-cut were not rejected when filtering was enabled. This might deal to answers below the lambda-cut for the G\u00f6edel t-norm (though worked for others).<\/p>\n<p style=\"padding-left: 30px\">4) The final lambda-cut test (<strong>over_lambdacut<\/strong>) in the expanded clauses was omitted when filtering was disabled for the G\u00f6edel t-norm. This might deal to answers below the lambda-cut for the G\u00f6edel t-norm.<\/p>\n<p style=\"padding-left: 30px\">5) Rules below the lambda cut were discarded when filtering was disabled.<\/p>\n<p style=\"padding-left: 30px\">6) Workaround for a possibly SWI-Prolog bug when changing the lambda cut and filtering enabled.<\/p>\n<p>&nbsp;<\/p>\n<hr \/>\n<p><span style=\"color: #ff00ff\"><strong>BPL version 3.5.1 \u00a0<\/strong>(July, 23rd 2020)<\/span><\/p>\n<hr \/>\n<p>With respect to former version 3.5, the present version 3.5.1 adds the following:<\/p>\n<p><strong>Enhancements:<\/strong><\/p>\n<p style=\"padding-left: 30px\">1) Checking for cycles in WordNet hierarchies to avoid non-termination.<\/p>\n<p>&nbsp;<\/p>\n<hr \/>\n<p><span style=\"color: #ff00ff\"><strong>BPL version 3.5 \u00a0<\/strong>(January, 28th 2020)<\/span><\/p>\n<hr \/>\n<p>With respect to former version 3.4, the present version 3.5 adds the following:<\/p>\n<p><strong>Enhancements:<\/strong><\/p>\n<p style=\"padding-left: 30px\">1) Graded rules. Fuzzy rules can be graded with an approximation degree with the following syntax:<br \/>\n<strong>Head :- Body with Degree.<\/strong><br \/>\nwhere &#8216;<strong>:- true<\/strong>&#8216; can be omitted in the case of a rule with a true body (i.e., a fact). During a resolution step, <strong>Degree<\/strong> is composed with the resulting approximation degree obtained when weakly unifying <strong>Head<\/strong> and the current goal.<\/p>\n<p style=\"padding-left: 30px\">2) Closing the Windows application does no longer display a confirmation dialog box.<\/p>\n<p><strong>Fixed bugs:<\/strong><\/p>\n<p style=\"padding-left: 30px\">1) The t-norm used when composing unification degrees was always min, instead of the selected one.<br \/>\n2) Upon file reloading, some predicates were incorrectly identified as built-ins.<\/p>\n<hr \/>\n<p><span style=\"color: #ff00ff\"><strong>BPL version 3.4 \u00a0<\/strong>(July, 30th 2019)<\/span><\/p>\n<hr \/>\n<p>With respect to former version 3.3, the present version 3.4 adds the following:<\/p>\n<p><strong>Enhancements:<\/strong><\/p>\n<p style=\"padding-left: 30px\">1) New explicit weak unification operator ~~. It enables expressing the weak unification of two terms, giving their approximation degree as an implicit result. Note that ~~ differs from the operator ~, which is a crisp one. For example, assuming the proximity equation a~b=0.5, the goal p(a)~p(b) succeeds with approximation degree 0.5. Note that the goal p(a)~p(b) is a syntactic sugaring for p(a)~p(b)&gt;0, so that ~ cannot be used for explicit weak unification, and it returns an approximation degree of 1.0.<\/p>\n<p style=\"padding-left: 30px\">2) The compiled BPL file does not include the extension of sim\/3 when either the algorithm A2 or A3 is selected. This reduces the size of the compilation of sim roughly to a half.<\/p>\n<p style=\"padding-left: 30px\">3) New command tm Input, which displays the execution time for Input by using the SWI-Prolog predicate time\/1.<\/p>\n<p style=\"padding-left: 30px\">4) Optimized translation of rules:<\/p>\n<p style=\"padding-left: 30px\">\u00a0 \u00a0 \u00a0 + \u00a0 A goal degree_composition([],Degree) at the end of a clause is removed.<\/p>\n<p style=\"padding-left: 30px\">\u00a0 \u00a0 \u00a0 + \u00a0 A goal degree_composition([InDegree],OutDegree) at the end of a clause is replaced by the binding OutDegree &lt;- InDegree.<\/p>\n<p><strong>Changes:<\/strong><\/p>\n<p style=\"padding-left: 30px\">1) Reflexivity of ~ is removed from the TPL file and it is made implicit in the BPL code.<\/p>\n<p style=\"padding-left: 30px\">2) Answers are more akin to SWI-Prolog:<\/p>\n<p style=\"padding-left: 30px\">\u00a0 \u00a0 \u00a0 + \u00a0Instead of &#8216;Yes&#8217;, &#8216;true&#8217; is displayed for goals solved with no bindings.<\/p>\n<p style=\"padding-left: 30px\">\u00a0 \u00a0 \u00a0 + \u00a0When a goal cannot be proved for the first time, &#8216;false&#8217; is displayed.<\/p>\n<p style=\"padding-left: 30px\">\u00a0 \u00a0 \u00a0 + \u00a0If no more solutions are proved to exist, the user is not asked for an action.<\/p>\n<p style=\"padding-left: 30px\">\u00a0 \u00a0 \u00a0 + \u00a0Bindings are separated by commas.<\/p>\n<p style=\"padding-left: 30px\">\u00a0 \u00a0 \u00a0 + \u00a0A crisp result is not accompanied by &#8220;With approximation degree: 1&#8221; anymore.<\/p>\n<p style=\"padding-left: 30px\">\u00a0 \u00a0 \u00a0 + \u00a0The last answer of a goal is not accompanied by &#8220;No answer&#8221; anymore.<\/p>\n<p><strong>Fixed bugs:<\/strong><\/p>\n<p style=\"padding-left: 30px\">1) Predicate names were not taken into account for weak unification of a proximity relation. So, some goals might incorrectly succeed.<br \/>\n2) The default t-norm for ~ was not predefined before loading a program.<\/p>\n<hr \/>\n<p><span style=\"color: #ff00ff\"><strong>BPL version 3.3 \u00a0<\/strong>(June, 13th 2019)<\/span><\/p>\n<hr \/>\n<p>This release incorporates improvements in the operational mechanism and full access to WordNet through wide repertoire of built-in predicates.<\/p>\n<p>More detailed, with respect to former version 3.2, the present version 3.3 adds the following:<\/p>\n<p><strong>Enhancements:<\/strong><\/p>\n<p style=\"padding-left: 30px\">1)\u00a0Improved performance for the proximity-based unification algorithm (A3-C \u00a0&#8212; \u00a0i.e., A3 with external computation of extended proximity relation RB)<\/p>\n<p style=\"padding-left: 30px\">2) Reduced size of TPL file for A3 algorithm<\/p>\n<p style=\"padding-left: 30px\">3) Access to wn_connect public predicates from BPL programs and goals. For using them as (sub)goals in the top-level, use either ensure_loaded(wn(wn_connect)) or previously load a program with the :- wn_connect directive.<\/p>\n<p style=\"padding-left: 30px\">4) \u00a0New directives for controlling compilation warnings:<\/p>\n<p style=\"padding-left: 30px\">\u00a0 \u00a0 \u00a0 + \u00a0 <strong>\u00a0:- filtering_warning(+Boolean).<\/strong><br \/>\nIf <strong>Boolean<\/strong>=true, then warn if an equation is filtered<br \/>\nduring parsing; otherwise, do not.<\/p>\n<p style=\"padding-left: 30px\">+ \u00a0 \u00a0<strong>:- ontology_warning(+Boolean).<\/strong><br \/>\nIf <strong>Boolean<\/strong>=true, then warn if the loaded program does<br \/>\nnot contain rules; otherwise, do not.<\/p>\n<p style=\"padding-left: 30px\">5) Completed extended help on the &#8216;ts&#8217; command.<\/p>\n<p><strong>Changes:<\/strong><\/p>\n<p style=\"padding-left: 30px\">1) Removed error messages from wn-connect public predicates. An error implies a failure now.<\/p>\n<p style=\"padding-left: 30px\">2) Slight changes in the system banner.<\/p>\n<p><strong>Fixed bugs:<\/strong><\/p>\n<p style=\"padding-left: 30px\">1) Filtering was always made irrespective of the filtering command or directive.<br \/>\n2) Computations were pruned for a degree less **or equal** than the lambda-cut value.<br \/>\n3) In rules with only built-ins in the body, constraint stores were not correctly linked durint translation for A3 algorithm.<br \/>\n4) Algorithm A2 left extra choice-points.<br \/>\n5) Loading a file left extra choice-points.<\/p>\n<p>&nbsp;<\/p>\n<hr \/>\n<p><span style=\"color: #ff00ff\"><strong>BPL version 3.2 \u00a0<\/strong>(April 2019)<\/span><\/p>\n<hr \/>\n<p>With respect to former version 3.1.1, the present version 3.2 adds the following:<\/p>\n<p><strong>Enhancements:<\/strong><\/p>\n<p style=\"padding-left: 30px\">1) Modifiers on predicate symbols are allowed for flexible building of fuzzy relations.<br \/>\n2) Equations in both programs and ontologies can be filtered by lambda-cut. As well, those resulting from computing the closure are filtered by the lambda-cut. To change this behaviour, a new command &#8216;fl&#8217; and a new directive &#8216;filtering&#8217; to enable and disable filtering are added. Filtering may hugely prune the search space, reducing memory consumption and enhancing performance.<br \/>\n3) Fully automated tests (no need for user inputs).<br \/>\n4) Other minor enhancements are:<\/p>\n<p style=\"padding-left: 60px\">+ Void input (Intro) does no longer generate an error message.<br \/>\n+ An equation between two elements with a lower degree than an existing one is filtered in advance.<\/p>\n<p><strong>Fixed bugs:<\/strong><\/p>\n<p style=\"padding-left: 30px\">1) When loading a program, previous sim equations were not cleared.<br \/>\n2) A comment at the last line without an ending new-line made the parsing to fail.<br \/>\n3) Incorrect error message for lambda_cut directive.<br \/>\nThe transitivity directive might misbehave in specific situations.<\/p>\n<p>&nbsp;<\/p>\n<hr \/>\n<p><span style=\"color: #ff00ff\"><strong>BPL version 3.1.1 \u00a0<\/strong>(March 2019)<\/span><\/p>\n<hr \/>\n<p>With respect to former version 3.1, the present version 3.1.1 adds the following:<\/p>\n<p>1) Fixes a bug for the external computation of block equations (they were not updated correctly after submitting a goal containing fuzzy sets).<\/p>\n<p>2) A host safe mode for web deployment: it minimizes the risks of external attacks to a web-based interface to the BPL system.<\/p>\n<p>3) A folder with examples and a paper explaining them.<\/p>\n<p>&nbsp;<\/p>\n<hr \/>\n<p><span style=\"color: #ff00ff\"><strong>BPL version 3.1 \u00a0<\/strong>(January 2019)<\/span><\/p>\n<hr \/>\n<p>With respect to former version 3.0, the present version 3.1 enables access to WordNet, with the following new features:<\/p>\n<p>1) Following the tool WordNet::Similarity, three similarity measures based on path lengths between concepts (PATH, WUP and LCH), and three based on information content (RES, JCN and LIN) have been implemented in BPL.<\/p>\n<p>2) New directives:<br \/>\n<strong>:- wn_connect.<\/strong><br \/>\nThis directive performs the necessary actions to connect Bousi~Prolog to the WordNet resources. It must occur before any other access to WordNet, and it assumes that the environment variable WNDB has been set to the OS directory in which the WordNet database is stored.<br \/>\nThere is an alternative to this directive if the environment variable cannot be set or the user simply does not want to:<\/p>\n<p><strong>:- wn_connect(+Directory).<\/strong><br \/>\nWhere <strong>Directory<\/strong> is the directory in which the WordNet database is located (the symbol + indicates that this argument is required).<\/p>\n<p><strong>:- wn_gen_prox_equations(+Measure, +ListOfListsOfPatterns)<\/strong><br \/>\nWhere <strong>Measure<\/strong> is the similarity measure which can have any of the following constant values: path, wup, lch, res, jcn and lin. The second argument <strong>ListOfListsOfPatterns<\/strong> is a list for which each element is another list containing the patterns that must be related by proximity equations. The pattern can be either a word or the structure <strong>Word:Type:Sense<\/strong>, where Word is the word, Type is its type (either n for noun or v for verb), and Sense is the sense number in its synset. If the pattern is simply a word, then a sense number of 1 is assumed, and its type is made to match all other words in the same list.<\/p>\n<p>&nbsp;<\/p>\n<hr \/>\n<p><span style=\"color: #ff00ff\"><strong>BPL version 3.0 \u00a0<\/strong>(May 2018)<\/span><\/p>\n<hr \/>\n<p>This release incorporates an efficient proximity-based unification algorithm for the first time.<\/p>\n<p>The present release ver. 3.0 incorporates new functionalities with respect to ver. 2.01:<\/p>\n<p>1) Three different weak unification algorithms:<\/p>\n<p style=\"padding-left: 30px\">(<strong>a1<\/strong>) The similarity-based unification algorithm proposed by Maria Sessa [Ses2002], which is only adequate for similarity relations (i.e., transitive proximities). Note that Sessa&#8217;s weak unification algorithm turns incomplete when it works with proximity relations that do not fulfil the transitive property. Then, use it when you work exclusively with similarity relations.<\/p>\n<p style=\"padding-left: 30px\">(<strong>a2<\/strong>) The original proximity-based unification algorithm that was defined in our 2015 FSS paper [JR2015], which uses &#8220;proximity constraints&#8221;. This algorithm is inefficient, therefore we do not recommend to use it.<\/p>\n<p style=\"padding-left: 30px\">(<strong>a3<\/strong>) A new reformulation of the proximity-based unification algorithm, which uses the new concept of &#8220;block constraint&#8221; (see our 2018 FuzzIEEE paper [JS2018]). It can be executed efficiently and we recommend this option when you use proximity relations; otherwise, the system becomes unsound.<br \/>\nThese algorithms can be activated by means of the directive:<\/p>\n<p style=\"padding-left: 30px\"><strong>:- weak_unification(Alg).<\/strong><\/p>\n<p style=\"padding-left: 30px\">where the parameter <strong>Alg<\/strong> is one of the constants {<strong>a1<\/strong>,<strong>a2<\/strong>,<strong>a3<\/strong>}. By default, the weak unification algorithm a1 is activated.<\/p>\n<p>2) The weak unification algorithm relies on the proximity blocks of a proximity relation, in order to weak the notion of syntactic equality. Two symbols are approximate (i.e., considered equals) if they belong to the same proximity block.<\/p>\n<p>The BPL system may compute proximity blocks by means of two different types of predicates: a foreign predicate, named &#8220;<strong>ext_block_equs<\/strong>&#8220;, implemented in C to obtain greater efficiency, as well as an internal predicate implemented in Prolog.<\/p>\n<p>Proximity blocks are computed at compile time. The directive:<\/p>\n<p><strong>:- ext_block_equs(Boolean).<\/strong><\/p>\n<p>specifies if the proximity blocks are computed either by means of the foreign predicate (when <strong>Boolean<\/strong>\u00a0is &#8220;true&#8221;), or by means of the internal predicate (when <strong>Boolean<\/strong>\u00a0is &#8220;false&#8221;).<\/p>\n<p>3) Former versions of the BPL system propagated truth degrees in a derivation by compounding the approximation degrees obtained in each step using a minimum t-norm exclusively. In the present implementation, it is possible to choose other t-norms, different of minimum t-norm. The directive:<\/p>\n<p><strong>:- fuzzy_logic(TNorm).<\/strong><\/p>\n<p>where the parameter <strong>TNorm<\/strong> is one of the following constants: <strong>min<\/strong>, <strong>product<\/strong>, <strong>luka<\/strong>, <strong>drastic<\/strong>, <strong>nilpotent<\/strong>, and <strong>hamacher<\/strong>.<\/p>\n<p>Note that this new functionality can be understood as the way the conjunction symbol (&#8220;,&#8221;) in the body of a rule or in a goal is interpreted. For instance, if we choose &#8220;hamacher&#8221; as the value of the parameter &#8220;TNorm&#8221;, the conjunction &#8220;,&#8221; will be interpreted as a Hamacher t-norm.<\/p>\n<p>&nbsp;<\/p>\n<hr \/>\n<p><strong><span style=\"color: #ff00ff\">BPL version 2.0.1 \u00a0<\/span><\/strong><span style=\"color: #ff00ff\">(<\/span><span style=\"color: #ff00ff\">April 2018)<\/span><\/p>\n<hr \/>\n<p>The present release ver. 2.01 does not incorporate new functionalities with regard to ver. 2.0, but it incorporates adaptations to permit the execution of Bousi~Prolog on the last version 7.6.4 of SWI-Prolog.<\/p>\n<p>&nbsp;<\/p>\n<hr \/>\n<p><strong><span style=\"color: #ff00ff\">BPL version 2.0 \u00a0<\/span><\/strong><span style=\"color: #ff00ff\">(<\/span><span style=\"color: #ff00ff\">September, 2011)<\/span><\/p>\n<hr \/>\n<p>This is the first BPL version where programs are not meta-interpreted. Instead, BPL programs are translated to standard Prolog code able to simulate the weak operational semantics. The weak unification process still relays on Sessa&#8217;s similarity-based unification algorithm.<\/p>\n<p>The present release ver. 2.0 incorporates new features with respect to ver. 1.07:<\/p>\n<p>1) A new lexical, syntactic and semantic analysis of BPL programs.<\/p>\n<p>2) A compiler able of translating Bousi\u223cProlog programs into intermediate structures that can be used later by a Prolog interpreter.<\/p>\n<p>3) A renewed command processor that allows loading and executing BPL programs using the compiler and interpreter previously mentioned.<\/p>\n<p>4) Support for fuzzy sets and linguistic variables:<br \/>\nThe domain directive allows to declare and define the universe of discourse associated to a linguistic variable. We only deal with domains of the real interval. The concrete syntax of this directive is<br \/>\n<strong> :-domain(Dom_Name,n,m,Magnitude).<\/strong><br \/>\nwhere, <strong>Dom_Name<\/strong> is the name of the domain, <strong>n<\/strong> and <strong>m<\/strong> (with n &lt; m) are the lower and upper bounds of the real subinterval [n, m], and <strong>Magnitude<\/strong> is the name of the unit wherein the domain elements are measured.<br \/>\nExample: \u00a0 \u00a0<strong>:-domain(age,0,100,years)<\/strong><\/p>\n<p>The fuzzy set directive allows to declare and define a list of fuzzy subsets (which are associated to the primary terms of a linguistic variable) on a predefined domain. The concrete syntax of this directive is:<br \/>\n<strong>\u00a0 \u00a0 \u00a0:-fuzzy_set(Dom_Name,[Set1(a1,b1,c1[,d1]), &#8230;, SetN(aN,bN,cN[,dN]]). <\/strong><br \/>\nFuzzy subsets are defined by indicating their name, <strong>Set_i<\/strong>, and membership function type. At this time, it is possible to define two types of membership functions: either a trapezoidal function (if four arguments are used for defining the fuzzy subset) or a triangular function (if three arguments are used).<br \/>\nExample:<br \/>\n<strong>:-fuzzy_set(age, [young(0,0,30,50), middle(20,40,60,80), old(50,80,100,100)]).<\/strong><\/p>\n<p>Operator <strong>#<\/strong> for the generation of composite terms (e.g. very#young, more_or_less#middle or extremely#old), domain points (e.g. <strong>age#22<\/strong>, <strong>about#age#22<\/strong>) and domain ranges (e.g. <strong>age#20#30<\/strong>, <strong>about#age#20#30<\/strong>).<\/p>\n<p>5) Access to all repertory of standard SWI-Prolog predicates.<\/p>\n<p>&nbsp;<\/p>\n<hr \/>\n<p><strong><span style=\"color: #ff00ff\">BPL version 1.07 <\/span><\/strong><span style=\"color: #ff00ff\">(<\/span><span style=\"color: #ff00ff\">November, 2009)<\/span><\/p>\n<hr \/>\n<p>BPL version 1.07 was the first publicly available BPL release based on a high level implementation.<br \/>\nThe BPL system (versions 1 to 1.07) was a prototype, written on top of SWI-Prolog. The parser and translator module translated (compiled) rules and facts of the source BPL code into an intermediate Prolog code representation which was called \u201cTPL code\u201d (Translated BPL code). Then, following standard techniques, a meta-interpreter executed the TPL code according to the weak SLD resolution principle.<\/p>\n<p>For that version BPL essentially provides:<\/p>\n<p>1) An implementation of Sessa&#8217;s weak unification algorithm which operates on the basis of a similarity relation (a fuzzy binary relation holding the reflexive, symmetric and transitive properties) on a syntactic domain.<\/p>\n<p style=\"text-align: left\">2) Automatic generation of a similarity relation starting from an ordinary fuzzy binary relation on a set of first order symbols of a BPL program. The arbitrary fuzzy binary relation R is represented by a set of proximity equations of the form<br \/>\n<strong>\u00a0symbol ~ symbol = degree<\/strong><br \/>\nA proximity equation \u201ca ~ b = degree\u201d is representing the entry \u201cR(a,b)=degree\u201d of the relation R. The user supplies an initial subset of similarity equations and then, the system automatically generates a reflexive, symmetric, transitive closure to obtain a similarity relation. The transitivity\/1 directive can alter this default behavior.<\/p>\n<p>A foreign module, written in the C programming language, implemented the algorithm for the construction of the similarity relation.<\/p>\n<p>3) BPL directives:<br \/>\n<strong>:- transitivity(&lt;option&gt;).<\/strong><br \/>\ndepending on the &lt;<strong>option<\/strong>&gt; (yes or no) it activates or deactivates the generation of the transitive closure of the fuzzy relation.<\/p>\n<p><strong>:- lambda_cut(&lt;degree&gt;).<\/strong><br \/>\nimposes a &lt;<strong>degree<\/strong>&gt; limit to the expansion of the search space in a computation.<\/p>\n<p>4) BPL operators: weak unification operator (<strong>\u223c\u223c<\/strong>) ; crisp negation as failure (<strong>\\+<\/strong>) and weak negation as failure (<strong>not<\/strong>).<\/p>\n<p>5) Access to the main repertory of standard Prolog predicates: arithmetic and comparison operators; syntactic unification; list manipulation; predicates for analysing and constructing terms and strings; Edinburgh-style I\/O and control predicates.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>BPL version 4.0 \u00a0(April, 7th 2025) The main contribution of this major version is the incorporation of the hypothetical mode. To achieve the ability to reason hypothetically, it was necessary to thoroughly revise the system, particularly its handling of higher-order predicates and negation. With respect to former version 3.6.1, the present version 4.0 adds the &hellip; <\/p>\n<p class=\"link-more\"><a href=\"https:\/\/dectau.uclm.es\/bousi-prolog\/2019\/03\/06\/release-notes\/\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;RELEASE NOTES&#8221;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-167","post","type-post","status-publish","format-standard","hentry","category-sin-categoria"],"_links":{"self":[{"href":"https:\/\/dectau.uclm.es\/bousi-prolog\/wp-json\/wp\/v2\/posts\/167","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/dectau.uclm.es\/bousi-prolog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/dectau.uclm.es\/bousi-prolog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/dectau.uclm.es\/bousi-prolog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/dectau.uclm.es\/bousi-prolog\/wp-json\/wp\/v2\/comments?post=167"}],"version-history":[{"count":27,"href":"https:\/\/dectau.uclm.es\/bousi-prolog\/wp-json\/wp\/v2\/posts\/167\/revisions"}],"predecessor-version":[{"id":404,"href":"https:\/\/dectau.uclm.es\/bousi-prolog\/wp-json\/wp\/v2\/posts\/167\/revisions\/404"}],"wp:attachment":[{"href":"https:\/\/dectau.uclm.es\/bousi-prolog\/wp-json\/wp\/v2\/media?parent=167"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/dectau.uclm.es\/bousi-prolog\/wp-json\/wp\/v2\/categories?post=167"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/dectau.uclm.es\/bousi-prolog\/wp-json\/wp\/v2\/tags?post=167"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}