| 1 | !7 | 
| 2 | |
| 3 | sS defs = [[ | 
| 4 | A cup of water = A cup with water inside | 
| 5 | A cup of Peter = A cup that belongs to Peter | 
| 6 | A cup of glass = A cup that consists of glass | 
| 7 | A cup of style = A cup that has a lot of style | 
| 8 | a $a with $b inside = [implies] $b is smaller than a $a | 
| 9 | a $a that belongs to $b = [implies] $b is a person | 
| 10 | a $a that consists of $b = [implies] $b is a material | 
| 11 | a $a that has a lot of $b = [implies] $b is a property | 
| 12 | Joe = a person | 
| 13 | ]]; | 
| 14 | |
| 15 | sclass Confirmed(Statement st) {}
 | 
| 16 | sclass Rejected(Statement st) {}
 | 
| 17 | |
| 18 | p-exp {
 | 
| 19 | new ThoughtSpace1 ts; | 
| 20 |   ts.objects.add(Input("a cup of joe"));
 | 
| 21 | |
| 22 | ts.addDefinitions(defs); | 
| 23 | ts.think(false); | 
| 24 | |
| 25 |   for (Definition d : ts.definitionsForInput()) {
 | 
| 26 |     print("\nTrying definition " + sfu(d));
 | 
| 27 | new ThoughtSpace1 ts2; | 
| 28 | ts2.objects.add(Input((S) d.rhs)); | 
| 29 | ts2.addDefinitions(defs); | 
| 30 |     ts2.steppers.add(voidfunc(ThoughtSpace1 ts) {
 | 
| 31 | for (ts.list(Statement)) | 
| 32 | })); | 
| 33 | ts2.think(false); | 
| 34 | ts2.removeInitialObjects(); | 
| 35 | |
| 36 | pnlStruct(ts2.statements()); | 
| 37 | } | 
| 38 | } | 
Began life as a copy of #1017041
download show line numbers debug dex old transpilations
Travelled to 14 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, irmadwmeruwu, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt
No comments. add comment
| Snippet ID: | #1017042 | 
| Snippet name: | Patterns Step 3 [dev.] | 
| Eternal ID of this version: | #1017042/1 | 
| Text MD5: | f6d1752d27c9cf1e2c243ff468f8b2a1 | 
| Author: | stefan | 
| Category: | javax / a.i. | 
| Type: | JavaX source code (desktop) | 
| Public (visible to everyone): | Yes | 
| Archived (hidden from active list): | No | 
| Created/modified: | 2018-07-11 13:24:13 | 
| Source code size: | 1046 bytes / 38 lines | 
| Pitched / IR pitched: | No / No | 
| Views / Downloads: | 742 / 1037 | 
| Referenced in: | [show references] |