@@ -12,7 +12,7 @@ node app.js
12
12
13
13
### First Example
14
14
15
- The first example demonstrates forward-chaining. To use the example, provide the following inputs as an example:
15
+ The first example demonstrates forward-chaining. To use the example, provide the following example inputs below.
16
16
17
17
```
18
18
stem
@@ -23,9 +23,21 @@ one main trunk
23
23
yes
24
24
broad and flat
25
25
no
26
+ <press enter two times>
26
27
```
27
28
28
- You should see the output:
29
+ You should see the following output.
30
+
31
+ ``` js
32
+ [ { attribute: ' stem' , value: ' woody' },
33
+ { attribute: ' position' , value: ' upright' },
34
+ { attribute: ' one main trunk' , value: ' yes' },
35
+ { attribute: ' broad and flat' , value: ' no' },
36
+ { attribute: ' type' , value: ' tree' },
37
+ { attribute: ' class' , value: ' gymnosperm' } ]
38
+ ```
39
+
40
+ The first 4 items are our provided inputs. The second two are new attributes deduced from the knowledge-base.
29
41
30
42
```
31
43
type is tree
@@ -36,7 +48,7 @@ Why? The first output of `tree` is because of the original input attributes all
36
48
37
49
### Second Example
38
50
39
- The second example demonstrates backward-chaining. To use the example, provide the following inputs as an example:
51
+ The second example demonstrates backward-chaining. To use the example, provide the following example inputs below.
40
52
41
53
```
42
54
class
0 commit comments