-
Notifications
You must be signed in to change notification settings - Fork 3
/
constants.lisp
36 lines (30 loc) · 1.03 KB
/
constants.lisp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
(in-package #:vivace-graph)
(cffi:defctype size :unsigned-int)
;; Prolog constants and specials
(defconstant +unbound+ :unbound)
(ignore-errors (defconstant +no-bindings+ '((t . t))))
(defconstant +fail+ nil)
;; Certainty factors
(defconstant +cf-true+ 1.0)
(defconstant +cf-false+ -1.0)
(defconstant +cf-unknown+ 0.0)
(defconstant +needs-lookup+ :needs-lookup)
;; User-defined type identifiers for serializing. Start at 100
(defconstant +triple+ 101)
;;(defconstant +node+ 102)
(defconstant +predicate+ 103)
(defconstant +rule+ 105)
;; Tags for sorting entry types in tokyo cabinet
(defconstant +triple-key+ 201)
;;(defconstant +node-key+ 202)
(defconstant +predicate-key+ 209)
(defconstant +triple-subject+ 203)
(defconstant +triple-predicate+ 204)
(defconstant +triple-object+ 205)
(defconstant +triple-subject-predicate+ 206)
(defconstant +triple-subject-object+ 207)
(defconstant +triple-predicate-object+ 208)
;;(defconstant +node-ref-count+ 209)
(defconstant +deleted-triple-key+ 210)
(defconstant +text-index+ 211)
(defconstant +rule-key+ 212)