├── doc ├── overview-swclos.html ├── overview-RDF.html ├── overview-RDFS.html ├── overview-NTriple.html ├── overview.css └── overview.html ├── ELW2009.ppt ├── OWLFull2.ppt ├── RDF ├── RDF.asdf ├── RdfReader.cl ├── RDFsys.cl ├── rdferror.cl ├── Literal.cl ├── overview.css ├── README.html ├── packages.cl ├── 22-rdf-syntax-ns.ttl ├── RDF.lpr ├── node.cl └── 22-rdf-syntax-ns.rdf ├── SWCLOS.asdf ├── SWCLOSsys.cl ├── ACLinstall.htm ├── MOPinSWCLOS.doc ├── OWL ├── OWLsys.cl ├── owlkernel.cl ├── overview.css ├── README.html ├── OWL.asdf ├── OWL.lpr └── NNF.cl ├── RDFS ├── GxType.cl ├── RDFS.asdf ├── rdfwriter.cl ├── DomainRange.cl ├── RdfsKernel.cl ├── RdfsObjects.cl ├── IntroExample │ ├── Example.cl │ ├── CLOSexample.cl │ ├── addFormexample.cl │ ├── addObjectexample.cl │ ├── addInstancexample.cl │ ├── ExmampleNT.cl │ ├── Example.rdf │ └── Example.nt ├── JenaEx.nt ├── JenaEx.rdf ├── Intro.rdf ├── Lang63.rdf ├── overview.css ├── RDFSsys.cl ├── README.html ├── RDFS.lpr ├── rdf-querysample.rdf ├── rdf-schema.ttl └── rdf-schema.rdf ├── FIGURES ├── BagEx.PNG ├── FIG1.PNG ├── FIG1.PPT ├── FIG2.PNG ├── FIG2.PPT ├── FIG3.PPT ├── FIG4.PNG ├── FIG4.PPT ├── FIG5.PNG ├── FIG5.PPT ├── FIG6.PNG ├── FIG6.PPT ├── Thumbs.db ├── ACLFree1.JPG ├── ACLFree2.JPG ├── ACLFree3.JPG ├── ACLFree4.JPG ├── ACLFree5.JPG ├── ACLFree6.JPG ├── ACLFree7.JPG ├── ACLFree8.JPG ├── ACLFree9.jpg ├── WineRDF.JPG ├── WineRDF.PNG ├── unionOf.bmp ├── ACLPatches.JPG ├── ACLInstalling.JPG ├── ListStructure.png ├── RDFSHierarchy.PNG ├── SubClassGraph.PNG ├── SubClassGraph.bmp ├── RDFGraphExample.png ├── RDFS Hierarchy.ppt ├── intersectionOf.bmp └── DatatypeHierarchy.ppt ├── Manual ├── cover.JPG ├── 02Basics.htm ├── 14OWLAPIs.htm ├── 03Resource.htm ├── 12OWLSWCLOS.htm ├── 01Introduction.htm ├── FIGURES │ ├── BagEx.PNG │ ├── FIG1.PNG │ ├── FIG1.PPT │ ├── FIG2.PNG │ ├── FIG2.PPT │ ├── FIG3.PPT │ ├── FIG4.PNG │ ├── FIG4.PPT │ ├── FIG5.PNG │ ├── FIG5.PPT │ ├── FIG6.PNG │ ├── FIG6.PPT │ ├── Thumbs.db │ ├── WineRDF.JPG │ ├── WineRDF.PNG │ ├── caution.PNG │ ├── ornament.gif │ ├── unionOf.bmp │ ├── ListStructure.png │ ├── RDFSHierarchy.PNG │ ├── SubClassGraph.PNG │ ├── SubClassGraph.bmp │ ├── RDFGraphExample.png │ ├── RDFS Hierarchy.ppt │ ├── intersectionOf.bmp │ └── DatatypeHierarchy.ppt ├── SWCLOS User's Manual.html ├── MANUAL2.CSS ├── MANUAL.CSS └── index.htm ├── Manual-ja ├── cover.JPG ├── index.htm ├── 02Basics.htm ├── 03Resource.htm ├── 12OWLSWCLOS.htm ├── 14OWLAPIs.htm ├── FIGURES │ ├── BagEx.PNG │ ├── FIG1.PNG │ ├── FIG1.PPT │ ├── FIG2.PNG │ ├── FIG2.PPT │ ├── FIG3.PPT │ ├── FIG4.PNG │ ├── FIG4.PPT │ ├── FIG5.PNG │ ├── FIG5.PPT │ ├── FIG6.PNG │ ├── FIG6.PPT │ ├── Thumbs.db │ ├── WineRDF.JPG │ ├── WineRDF.PNG │ ├── caution.PNG │ ├── ornament.gif │ ├── unionOf.bmp │ ├── ListStructure.png │ ├── RDFSHierarchy.PNG │ ├── SubClassGraph.PNG │ ├── SubClassGraph.bmp │ ├── RDFGraphExample.png │ ├── RDFS Hierarchy.ppt │ ├── intersectionOf.bmp │ └── DatatypeHierarchy.ppt ├── 01Introduction.htm ├── SWCLOS User's Manual.html ├── MANUAL2.CSS └── MANUAL.CSS ├── NTriple ├── ntparser.cl ├── ntriple.cl ├── ntwriter.cl ├── JenaEx.nt ├── overview.css ├── README.html └── NTriple.lpr ├── SWCLOS2tutorial.ppt ├── SWCLOStutorial.ppt ├── SWCLOS2tutorialAD.ppt ├── ACLインストール.files ├── Thumbs.db ├── ACLAgree.jpg ├── ACLFree1.jpg ├── ACLFree2.jpg ├── ACLFree3.jpg ├── ACLFree4.jpg ├── ACLFree5.jpg ├── ACLFree6.jpg ├── ACLFree7.jpg ├── ACLFree8.jpg ├── ACLPatches.jpg ├── ACLSetup.JPG ├── ACLUpgrade.JPG ├── ACLInstalling.jpg ├── ACLPachInstall.JPG ├── ACLPachReminder.jpg ├── ACLProxySetting.JPG ├── ACLInstallFolder.JPG └── ACLInstallCompleted.JPG ├── ACLinstall.files ├── ACLAgree.jpg ├── ACLSetup.jpg ├── ACLUpgrade.jpg ├── ACLInstalling.jpg ├── ACLPachInstall.jpg ├── ACLInstallFolder.jpg ├── ACLPachReminder.jpg ├── ACLProxySetting.jpg └── ACLInstallCompleted.jpg ├── README.md ├── utilities ├── README.html ├── overview.css ├── infix.cl └── infix.lisp ├── HowToUseDocGeneration.txt ├── WineFood └── WineFood.cl ├── LICENCE.TXT ├── overview.css ├── ReadMe.txt ├── install.html ├── SWCLOS.lpr └── swclos.cl /doc/overview-swclos.html: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /ELW2009.ppt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/ELW2009.ppt -------------------------------------------------------------------------------- /OWLFull2.ppt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/OWLFull2.ppt -------------------------------------------------------------------------------- /RDF/RDF.asdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/RDF/RDF.asdf -------------------------------------------------------------------------------- /SWCLOS.asdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/SWCLOS.asdf -------------------------------------------------------------------------------- /SWCLOSsys.cl: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/SWCLOSsys.cl -------------------------------------------------------------------------------- /ACLinstall.htm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/ACLinstall.htm -------------------------------------------------------------------------------- /MOPinSWCLOS.doc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/MOPinSWCLOS.doc -------------------------------------------------------------------------------- /OWL/OWLsys.cl: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/OWL/OWLsys.cl -------------------------------------------------------------------------------- /RDFS/GxType.cl: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/RDFS/GxType.cl -------------------------------------------------------------------------------- /RDFS/RDFS.asdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/RDFS/RDFS.asdf -------------------------------------------------------------------------------- /FIGURES/BagEx.PNG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/FIGURES/BagEx.PNG -------------------------------------------------------------------------------- /FIGURES/FIG1.PNG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/FIGURES/FIG1.PNG -------------------------------------------------------------------------------- /FIGURES/FIG1.PPT: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/FIGURES/FIG1.PPT -------------------------------------------------------------------------------- /FIGURES/FIG2.PNG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/FIGURES/FIG2.PNG -------------------------------------------------------------------------------- /FIGURES/FIG2.PPT: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/FIGURES/FIG2.PPT -------------------------------------------------------------------------------- /FIGURES/FIG3.PPT: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/FIGURES/FIG3.PPT -------------------------------------------------------------------------------- /FIGURES/FIG4.PNG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/FIGURES/FIG4.PNG -------------------------------------------------------------------------------- /FIGURES/FIG4.PPT: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/FIGURES/FIG4.PPT -------------------------------------------------------------------------------- /FIGURES/FIG5.PNG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/FIGURES/FIG5.PNG -------------------------------------------------------------------------------- /FIGURES/FIG5.PPT: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/FIGURES/FIG5.PPT -------------------------------------------------------------------------------- /FIGURES/FIG6.PNG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/FIGURES/FIG6.PNG -------------------------------------------------------------------------------- /FIGURES/FIG6.PPT: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/FIGURES/FIG6.PPT -------------------------------------------------------------------------------- /FIGURES/Thumbs.db: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/FIGURES/Thumbs.db -------------------------------------------------------------------------------- /Manual/cover.JPG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual/cover.JPG -------------------------------------------------------------------------------- /OWL/owlkernel.cl: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/OWL/owlkernel.cl -------------------------------------------------------------------------------- /RDF/RdfReader.cl: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/RDF/RdfReader.cl -------------------------------------------------------------------------------- /RDFS/rdfwriter.cl: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/RDFS/rdfwriter.cl -------------------------------------------------------------------------------- /FIGURES/ACLFree1.JPG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/FIGURES/ACLFree1.JPG -------------------------------------------------------------------------------- /FIGURES/ACLFree2.JPG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/FIGURES/ACLFree2.JPG -------------------------------------------------------------------------------- /FIGURES/ACLFree3.JPG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/FIGURES/ACLFree3.JPG -------------------------------------------------------------------------------- /FIGURES/ACLFree4.JPG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/FIGURES/ACLFree4.JPG -------------------------------------------------------------------------------- /FIGURES/ACLFree5.JPG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/FIGURES/ACLFree5.JPG -------------------------------------------------------------------------------- /FIGURES/ACLFree6.JPG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/FIGURES/ACLFree6.JPG -------------------------------------------------------------------------------- /FIGURES/ACLFree7.JPG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/FIGURES/ACLFree7.JPG -------------------------------------------------------------------------------- /FIGURES/ACLFree8.JPG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/FIGURES/ACLFree8.JPG -------------------------------------------------------------------------------- /FIGURES/ACLFree9.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/FIGURES/ACLFree9.jpg -------------------------------------------------------------------------------- /FIGURES/WineRDF.JPG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/FIGURES/WineRDF.JPG -------------------------------------------------------------------------------- /FIGURES/WineRDF.PNG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/FIGURES/WineRDF.PNG -------------------------------------------------------------------------------- /FIGURES/unionOf.bmp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/FIGURES/unionOf.bmp -------------------------------------------------------------------------------- /Manual-ja/cover.JPG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual-ja/cover.JPG -------------------------------------------------------------------------------- /Manual-ja/index.htm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual-ja/index.htm -------------------------------------------------------------------------------- /Manual/02Basics.htm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual/02Basics.htm -------------------------------------------------------------------------------- /Manual/14OWLAPIs.htm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual/14OWLAPIs.htm -------------------------------------------------------------------------------- /NTriple/ntparser.cl: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/NTriple/ntparser.cl -------------------------------------------------------------------------------- /NTriple/ntriple.cl: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/NTriple/ntriple.cl -------------------------------------------------------------------------------- /NTriple/ntwriter.cl: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/NTriple/ntwriter.cl -------------------------------------------------------------------------------- /RDFS/DomainRange.cl: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/RDFS/DomainRange.cl -------------------------------------------------------------------------------- /RDFS/RdfsKernel.cl: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/RDFS/RdfsKernel.cl -------------------------------------------------------------------------------- /RDFS/RdfsObjects.cl: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/RDFS/RdfsObjects.cl -------------------------------------------------------------------------------- /SWCLOS2tutorial.ppt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/SWCLOS2tutorial.ppt -------------------------------------------------------------------------------- /SWCLOStutorial.ppt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/SWCLOStutorial.ppt -------------------------------------------------------------------------------- /FIGURES/ACLPatches.JPG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/FIGURES/ACLPatches.JPG -------------------------------------------------------------------------------- /Manual-ja/02Basics.htm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual-ja/02Basics.htm -------------------------------------------------------------------------------- /Manual/03Resource.htm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual/03Resource.htm -------------------------------------------------------------------------------- /Manual/12OWLSWCLOS.htm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual/12OWLSWCLOS.htm -------------------------------------------------------------------------------- /SWCLOS2tutorialAD.ppt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/SWCLOS2tutorialAD.ppt -------------------------------------------------------------------------------- /doc/overview-RDF.html: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/doc/overview-RDF.html -------------------------------------------------------------------------------- /doc/overview-RDFS.html: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/doc/overview-RDFS.html -------------------------------------------------------------------------------- /ACLインストール.files/Thumbs.db: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/ACLインストール.files/Thumbs.db -------------------------------------------------------------------------------- /FIGURES/ACLInstalling.JPG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/FIGURES/ACLInstalling.JPG -------------------------------------------------------------------------------- /FIGURES/ListStructure.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/FIGURES/ListStructure.png -------------------------------------------------------------------------------- /FIGURES/RDFSHierarchy.PNG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/FIGURES/RDFSHierarchy.PNG -------------------------------------------------------------------------------- /FIGURES/SubClassGraph.PNG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/FIGURES/SubClassGraph.PNG -------------------------------------------------------------------------------- /FIGURES/SubClassGraph.bmp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/FIGURES/SubClassGraph.bmp -------------------------------------------------------------------------------- /Manual-ja/03Resource.htm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual-ja/03Resource.htm -------------------------------------------------------------------------------- /Manual-ja/12OWLSWCLOS.htm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual-ja/12OWLSWCLOS.htm -------------------------------------------------------------------------------- /Manual-ja/14OWLAPIs.htm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual-ja/14OWLAPIs.htm -------------------------------------------------------------------------------- /Manual/01Introduction.htm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual/01Introduction.htm -------------------------------------------------------------------------------- /Manual/FIGURES/BagEx.PNG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual/FIGURES/BagEx.PNG -------------------------------------------------------------------------------- /Manual/FIGURES/FIG1.PNG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual/FIGURES/FIG1.PNG -------------------------------------------------------------------------------- /Manual/FIGURES/FIG1.PPT: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual/FIGURES/FIG1.PPT -------------------------------------------------------------------------------- /Manual/FIGURES/FIG2.PNG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual/FIGURES/FIG2.PNG -------------------------------------------------------------------------------- /Manual/FIGURES/FIG2.PPT: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual/FIGURES/FIG2.PPT -------------------------------------------------------------------------------- /Manual/FIGURES/FIG3.PPT: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual/FIGURES/FIG3.PPT -------------------------------------------------------------------------------- /Manual/FIGURES/FIG4.PNG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual/FIGURES/FIG4.PNG -------------------------------------------------------------------------------- /Manual/FIGURES/FIG4.PPT: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual/FIGURES/FIG4.PPT -------------------------------------------------------------------------------- /Manual/FIGURES/FIG5.PNG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual/FIGURES/FIG5.PNG -------------------------------------------------------------------------------- /Manual/FIGURES/FIG5.PPT: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual/FIGURES/FIG5.PPT -------------------------------------------------------------------------------- /Manual/FIGURES/FIG6.PNG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual/FIGURES/FIG6.PNG -------------------------------------------------------------------------------- /Manual/FIGURES/FIG6.PPT: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual/FIGURES/FIG6.PPT -------------------------------------------------------------------------------- /Manual/FIGURES/Thumbs.db: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual/FIGURES/Thumbs.db -------------------------------------------------------------------------------- /doc/overview-NTriple.html: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/doc/overview-NTriple.html -------------------------------------------------------------------------------- /FIGURES/RDFGraphExample.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/FIGURES/RDFGraphExample.png -------------------------------------------------------------------------------- /FIGURES/RDFS Hierarchy.ppt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/FIGURES/RDFS Hierarchy.ppt -------------------------------------------------------------------------------- /FIGURES/intersectionOf.bmp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/FIGURES/intersectionOf.bmp -------------------------------------------------------------------------------- /Manual-ja/FIGURES/BagEx.PNG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual-ja/FIGURES/BagEx.PNG -------------------------------------------------------------------------------- /Manual-ja/FIGURES/FIG1.PNG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual-ja/FIGURES/FIG1.PNG -------------------------------------------------------------------------------- /Manual-ja/FIGURES/FIG1.PPT: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual-ja/FIGURES/FIG1.PPT -------------------------------------------------------------------------------- /Manual-ja/FIGURES/FIG2.PNG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual-ja/FIGURES/FIG2.PNG -------------------------------------------------------------------------------- /Manual-ja/FIGURES/FIG2.PPT: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual-ja/FIGURES/FIG2.PPT -------------------------------------------------------------------------------- /Manual-ja/FIGURES/FIG3.PPT: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual-ja/FIGURES/FIG3.PPT -------------------------------------------------------------------------------- /Manual-ja/FIGURES/FIG4.PNG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual-ja/FIGURES/FIG4.PNG -------------------------------------------------------------------------------- /Manual-ja/FIGURES/FIG4.PPT: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual-ja/FIGURES/FIG4.PPT -------------------------------------------------------------------------------- /Manual-ja/FIGURES/FIG5.PNG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual-ja/FIGURES/FIG5.PNG -------------------------------------------------------------------------------- /Manual-ja/FIGURES/FIG5.PPT: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual-ja/FIGURES/FIG5.PPT -------------------------------------------------------------------------------- /Manual-ja/FIGURES/FIG6.PNG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual-ja/FIGURES/FIG6.PNG -------------------------------------------------------------------------------- /Manual-ja/FIGURES/FIG6.PPT: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual-ja/FIGURES/FIG6.PPT -------------------------------------------------------------------------------- /Manual-ja/FIGURES/Thumbs.db: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual-ja/FIGURES/Thumbs.db -------------------------------------------------------------------------------- /Manual/FIGURES/WineRDF.JPG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual/FIGURES/WineRDF.JPG -------------------------------------------------------------------------------- /Manual/FIGURES/WineRDF.PNG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual/FIGURES/WineRDF.PNG -------------------------------------------------------------------------------- /Manual/FIGURES/caution.PNG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual/FIGURES/caution.PNG -------------------------------------------------------------------------------- /Manual/FIGURES/ornament.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual/FIGURES/ornament.gif -------------------------------------------------------------------------------- /Manual/FIGURES/unionOf.bmp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual/FIGURES/unionOf.bmp -------------------------------------------------------------------------------- /ACLinstall.files/ACLAgree.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/ACLinstall.files/ACLAgree.jpg -------------------------------------------------------------------------------- /ACLinstall.files/ACLSetup.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/ACLinstall.files/ACLSetup.jpg -------------------------------------------------------------------------------- /ACLインストール.files/ACLAgree.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/ACLインストール.files/ACLAgree.jpg -------------------------------------------------------------------------------- /ACLインストール.files/ACLFree1.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/ACLインストール.files/ACLFree1.jpg -------------------------------------------------------------------------------- /ACLインストール.files/ACLFree2.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/ACLインストール.files/ACLFree2.jpg -------------------------------------------------------------------------------- /ACLインストール.files/ACLFree3.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/ACLインストール.files/ACLFree3.jpg -------------------------------------------------------------------------------- /ACLインストール.files/ACLFree4.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/ACLインストール.files/ACLFree4.jpg -------------------------------------------------------------------------------- /ACLインストール.files/ACLFree5.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/ACLインストール.files/ACLFree5.jpg -------------------------------------------------------------------------------- /ACLインストール.files/ACLFree6.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/ACLインストール.files/ACLFree6.jpg -------------------------------------------------------------------------------- /ACLインストール.files/ACLFree7.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/ACLインストール.files/ACLFree7.jpg -------------------------------------------------------------------------------- /ACLインストール.files/ACLFree8.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/ACLインストール.files/ACLFree8.jpg -------------------------------------------------------------------------------- /ACLインストール.files/ACLPatches.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/ACLインストール.files/ACLPatches.jpg -------------------------------------------------------------------------------- /ACLインストール.files/ACLSetup.JPG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/ACLインストール.files/ACLSetup.JPG -------------------------------------------------------------------------------- /ACLインストール.files/ACLUpgrade.JPG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/ACLインストール.files/ACLUpgrade.JPG -------------------------------------------------------------------------------- /FIGURES/DatatypeHierarchy.ppt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/FIGURES/DatatypeHierarchy.ppt -------------------------------------------------------------------------------- /Manual-ja/01Introduction.htm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual-ja/01Introduction.htm -------------------------------------------------------------------------------- /Manual-ja/FIGURES/WineRDF.JPG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual-ja/FIGURES/WineRDF.JPG -------------------------------------------------------------------------------- /Manual-ja/FIGURES/WineRDF.PNG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual-ja/FIGURES/WineRDF.PNG -------------------------------------------------------------------------------- /Manual-ja/FIGURES/caution.PNG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual-ja/FIGURES/caution.PNG -------------------------------------------------------------------------------- /Manual-ja/FIGURES/ornament.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual-ja/FIGURES/ornament.gif -------------------------------------------------------------------------------- /Manual-ja/FIGURES/unionOf.bmp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual-ja/FIGURES/unionOf.bmp -------------------------------------------------------------------------------- /RDFS/IntroExample/Example.cl: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/RDFS/IntroExample/Example.cl -------------------------------------------------------------------------------- /ACLinstall.files/ACLUpgrade.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/ACLinstall.files/ACLUpgrade.jpg -------------------------------------------------------------------------------- /Manual/FIGURES/ListStructure.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual/FIGURES/ListStructure.png -------------------------------------------------------------------------------- /Manual/FIGURES/RDFSHierarchy.PNG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual/FIGURES/RDFSHierarchy.PNG -------------------------------------------------------------------------------- /Manual/FIGURES/SubClassGraph.PNG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual/FIGURES/SubClassGraph.PNG -------------------------------------------------------------------------------- /Manual/FIGURES/SubClassGraph.bmp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual/FIGURES/SubClassGraph.bmp -------------------------------------------------------------------------------- /Manual/SWCLOS User's Manual.html: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual/SWCLOS User's Manual.html -------------------------------------------------------------------------------- /RDFS/IntroExample/CLOSexample.cl: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/RDFS/IntroExample/CLOSexample.cl -------------------------------------------------------------------------------- /ACLinstall.files/ACLInstalling.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/ACLinstall.files/ACLInstalling.jpg -------------------------------------------------------------------------------- /ACLinstall.files/ACLPachInstall.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/ACLinstall.files/ACLPachInstall.jpg -------------------------------------------------------------------------------- /ACLインストール.files/ACLInstalling.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/ACLインストール.files/ACLInstalling.jpg -------------------------------------------------------------------------------- /ACLインストール.files/ACLPachInstall.JPG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/ACLインストール.files/ACLPachInstall.JPG -------------------------------------------------------------------------------- /ACLインストール.files/ACLPachReminder.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/ACLインストール.files/ACLPachReminder.jpg -------------------------------------------------------------------------------- /ACLインストール.files/ACLProxySetting.JPG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/ACLインストール.files/ACLProxySetting.JPG -------------------------------------------------------------------------------- /Manual-ja/FIGURES/ListStructure.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual-ja/FIGURES/ListStructure.png -------------------------------------------------------------------------------- /Manual-ja/FIGURES/RDFSHierarchy.PNG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual-ja/FIGURES/RDFSHierarchy.PNG -------------------------------------------------------------------------------- /Manual-ja/FIGURES/SubClassGraph.PNG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual-ja/FIGURES/SubClassGraph.PNG -------------------------------------------------------------------------------- /Manual-ja/FIGURES/SubClassGraph.bmp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual-ja/FIGURES/SubClassGraph.bmp -------------------------------------------------------------------------------- /Manual-ja/SWCLOS User's Manual.html: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual-ja/SWCLOS User's Manual.html -------------------------------------------------------------------------------- /Manual/FIGURES/RDFGraphExample.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual/FIGURES/RDFGraphExample.png -------------------------------------------------------------------------------- /Manual/FIGURES/RDFS Hierarchy.ppt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual/FIGURES/RDFS Hierarchy.ppt -------------------------------------------------------------------------------- /Manual/FIGURES/intersectionOf.bmp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual/FIGURES/intersectionOf.bmp -------------------------------------------------------------------------------- /RDFS/IntroExample/addFormexample.cl: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/RDFS/IntroExample/addFormexample.cl -------------------------------------------------------------------------------- /ACLinstall.files/ACLInstallFolder.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/ACLinstall.files/ACLInstallFolder.jpg -------------------------------------------------------------------------------- /ACLinstall.files/ACLPachReminder.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/ACLinstall.files/ACLPachReminder.jpg -------------------------------------------------------------------------------- /ACLinstall.files/ACLProxySetting.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/ACLinstall.files/ACLProxySetting.jpg -------------------------------------------------------------------------------- /ACLインストール.files/ACLInstallFolder.JPG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/ACLインストール.files/ACLInstallFolder.JPG -------------------------------------------------------------------------------- /Manual-ja/FIGURES/RDFGraphExample.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual-ja/FIGURES/RDFGraphExample.png -------------------------------------------------------------------------------- /Manual-ja/FIGURES/RDFS Hierarchy.ppt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual-ja/FIGURES/RDFS Hierarchy.ppt -------------------------------------------------------------------------------- /Manual-ja/FIGURES/intersectionOf.bmp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual-ja/FIGURES/intersectionOf.bmp -------------------------------------------------------------------------------- /Manual/FIGURES/DatatypeHierarchy.ppt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual/FIGURES/DatatypeHierarchy.ppt -------------------------------------------------------------------------------- /RDFS/IntroExample/addObjectexample.cl: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/RDFS/IntroExample/addObjectexample.cl -------------------------------------------------------------------------------- /ACLinstall.files/ACLInstallCompleted.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/ACLinstall.files/ACLInstallCompleted.jpg -------------------------------------------------------------------------------- /ACLインストール.files/ACLInstallCompleted.JPG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/ACLインストール.files/ACLInstallCompleted.JPG -------------------------------------------------------------------------------- /Manual-ja/FIGURES/DatatypeHierarchy.ppt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/Manual-ja/FIGURES/DatatypeHierarchy.ppt -------------------------------------------------------------------------------- /RDFS/IntroExample/addInstancexample.cl: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SeijiKoide/SWCLOS/HEAD/RDFS/IntroExample/addInstancexample.cl -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | SWCLOS 2 | ====== 3 | 4 | Lisp-based OWL Full Processor on top of Common Lisp Object System (CLOS), See http://www-kasm.nii.ac.jp/~koide/SWCLOS2-en.htm 5 | -------------------------------------------------------------------------------- /NTriple/JenaEx.nt: -------------------------------------------------------------------------------- 1 | _:a001 "Smith" . 2 | _:a001 "John" . 3 | _:a001 . 4 | "John Smith" . 5 | -------------------------------------------------------------------------------- /RDFS/JenaEx.nt: -------------------------------------------------------------------------------- 1 | _:a001 "Smith" . 2 | _:a001 "John" . 3 | _:a001 . 4 | "John Smith" . 5 | -------------------------------------------------------------------------------- /RDFS/JenaEx.rdf: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | ]> 6 | 9 | 10 | John Smith 11 | 12 | 13 | Smith 14 | John 15 | 16 | 17 | 18 | 19 | -------------------------------------------------------------------------------- /RDFS/Intro.rdf: -------------------------------------------------------------------------------- 1 | 2 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /utilities/README.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | Utilities (Subsystem of Planning Code) 4 | 5 | 6 | 7 | 8 | 9 | 10 |

Utilities (Subsystem of Planning Code)

11 | 12 | The utilities system provides a set of basic functions, macros, 13 | and data types that are used throughout the other systems.
14 | 15 | This system is copied from Artificial Intelligence Modern Approach (AIMA) and 16 | modified by Seiji Koide. 17 | 18 | 19 | 20 | 21 | 22 | -------------------------------------------------------------------------------- /RDFS/Lang63.rdf: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | RDF/XML Syntax Specification (Revised) 6 | RDF/XML Syntax Specification (Revised) 7 | RDF/XML Syntax Specification (Revised) 8 | 9 | 10 | 11 | Der Baum 12 | Das Buch ist ausergewohnlich 13 | The Tree 14 | 15 | -------------------------------------------------------------------------------- /RDFS/IntroExample/ExmampleNT.cl: -------------------------------------------------------------------------------- 1 | ;; -*- mode: common-lisp; syntax: common-lisp; package: gx-user; base: 10 -*- 2 | ;; 3 | ;; This file is from the indtroductory example in http://www.w3.org/TR/2002/WD-rdf-schema-20021112/ 4 | ;; 5 | 6 | (defpackage eg 7 | (:export "Work" "Document" "Agent" "Person" "author" "Proposal" "name") 8 | (:documentation "http://somewhere-for-eg/eg")) 9 | (defpackage dc 10 | (:export "title") 11 | (:documentation "http://dublincore.org/2002/08/13/dces")) 12 | (defpackage _ 13 | (:export "a")) 14 | 15 | (in-package :gx-user) 16 | 17 | (defTriple eg:name rdfs:range rdfs:Literal) 18 | (defTriple dc:title rdfs:range rdfs:Literal) 19 | (defTriple eg:Person rdfs:subClassOf eg:Agent) 20 | (defTriple eg:Document rdfs:subClassOf eg:Work) 21 | (defTriple eg:author rdf:type rdf:Property) 22 | (defTriple eg:author rdfs:domain eg:Document) 23 | (defTriple eg:author rdfs:range eg:Person) 24 | (defTriple _:a rdf:type eg:Person) 25 | (defTriple _:a eg:name "Tim Berners-Lee") 26 | 27 | (defTriple eg:Proposal rdf:type eg:Document) 28 | (defTriple eg:Proposal eg:author _:a) 29 | (defTriple eg:Proposal dc:title "Information Management: A Proposal") 30 | 31 | #| 32 | (get-form eg:Proposal) 33 | (-> eg:Proposal eg:author eg:name) 34 | (-> eg:Proposal dc:title) 35 | (-> eg:Proposal eg:author rdf:type) 36 | |# -------------------------------------------------------------------------------- /RDFS/IntroExample/Example.rdf: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | ]> 8 | 9 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | Tim Berners-Lee 39 | 40 | 41 | Information Management: A Proposal 42 | 43 | 44 | -------------------------------------------------------------------------------- /RDFS/IntroExample/Example.nt: -------------------------------------------------------------------------------- 1 | # Since Qname syntax is not legal N-triples syntax, and in the interests of brevity and readability, 2 | # we will use the convention whereby a Qname is used without surrounding angle brackets to indicate 3 | # the corresponding uriref enclosed in angle brackets, eg the triple 4 | # 5 | # rdf:type rdfs:Property . 6 | # 7 | # should be read as an abbreviation for the N-triples syntax 8 | # 9 | # . 10 | # 11 | 12 | rdf:type rdf:Property . 13 | rdfs:subClassOf . 14 | rdfs:subClassOf . 15 | rdf:type rdf:Property . 16 | rdfs:domain . 17 | rdfs:range . 18 | rdf:type . 19 | "Information Management: A Proposal" . 20 | _:a . 21 | _:a rdf:type . 22 | _:a "Tim Berners-Lee" . 23 | -------------------------------------------------------------------------------- /HowToUseDocGeneration.txt: -------------------------------------------------------------------------------- 1 | cg-user(1): 2 | ; Fast loading C:\Documents and Settings\Seiji\My Documents\KoideHP\SWCLOS2\SWCLOSsys.fasl 3 | 4 | ;=========== System Description ================ 5 | ; System: "SWCLOS: A Semantic Web Processor on CLOS" 6 | ; default package: # 7 | ; default pathname: #P"C:\\Documents and Settings\\Seiji\\My Documents\\KoideHP\\SWCLOS2\\" 8 | ; default module class: defsystem:lisp-module 9 | ; the system contains the following modules: 10 | ; System: "RDF subsystem of SWCLOS" 11 | ; System: "RDFS subsystem of SWCLOS" 12 | ; System: "OWL subsystem of SWCLOS" 13 | ; System: "NTriple subsystem of SWCLOS" 14 | ;=============================================== 15 | 16 | ;;To recompile, execute this form: 17 | (compile-system :swclos :recompile t) 18 | 19 | ;;To load, execute this form: 20 | (load-system :swclos) 21 | cg-user(1): (compile-system :swclos :recompile t) 22 | ; Compiling system: "SWCLOS: A Semantic Web Processor on CLOS". 23 | ... 24 | 25 | cg-user(2): (load-system :swclos) 26 | ... 27 | cg-user(3): 28 | ; Fast loading C:\Documents and Settings\Seiji\My Documents\KoideHP\SWCLOS2\swclos.fasl 29 | ; Fast loading C:\Documents and Settings\Seiji\My Documents\KoideHP\SWCLOS2\utilities.fasl 30 | ; Fast loading C:\Documents and Settings\Seiji\My Documents\KoideHP\SWCLOS2\hyperspec.fasl 31 | ; Fast loading C:\Documents and Settings\Seiji\My Documents\KoideHP\SWCLOS2\index.fasl 32 | cg-user(3): (gen-index) -------------------------------------------------------------------------------- /WineFood/WineFood.cl: -------------------------------------------------------------------------------- 1 | ;;; 2 | ;;; Wine ontology in RDFS 3 | ;;; 4 | 5 | (in-package gx-user) 6 | 7 | ;; This code directly read from food and wine repository via the Internet. 8 | #| 9 | (eval-when (:execute :load-toplevel :compile-toplevel) 10 | (require :aserve) 11 | ) 12 | (multiple-value-bind (response code headers uri) 13 | ;; note that url address and ontology address in contents mismatch 14 | (net.aserve.client:do-http-request "http://www.w3.org/TR/2004/REC-owl-guide-20040210/food.rdf" 15 | :proxy "150.73.3.41") 16 | (cond ((eq code 200) 17 | (gx::read-rdf-from-string #'addRdfXml response) 18 | (values)) 19 | (t cl:nil))) 20 | (multiple-value-bind (response code headers uri) 21 | ;; note that url address and ontology address in contents mismatch 22 | (net.aserve.client:do-http-request "http://www.w3.org/TR/2004/REC-owl-guide-20040210/wine.rdf" 23 | :proxy "150.73.3.41") 24 | (cond ((eq code 200) 25 | (gx::read-rdf-from-string #'addRdfXml response) 26 | (values)) 27 | (t cl:nil))) 28 | |# 29 | #| 30 | :cd ../../allegro-projects/SWCLOS/winefood 31 | (read-rdf-file #'addRdfXml "wine.rdf") 32 | |# 33 | #| 34 | ;; This code reads from local files. 35 | (let ((*default-pathname-defaults* *load-pathname*)) 36 | (read-rdf-file #'addRdfXml "wine.rdf") 37 | (read-rdf-file #'addRdfXml "food.rdf") 38 | :done) 39 | |# 40 | #| 41 | (defIndividual Unknown (rdf:type vin:Wine) 42 | (vin:madeFromGrape vin:ZinfandelGrape)) 43 | |# 44 | (let ((*default-pathname-defaults* *load-pathname*)) 45 | (time 46 | (let ((*error-output* cl:nil)) 47 | (setq *autoepistemic-local-closed-world* cl:nil) 48 | (read-rdf-file #'addRdfXml "wine.rdf") 49 | (read-rdf-file #'addRdfXml "food.rdf") 50 | (setq *autoepistemic-local-closed-world* t) 51 | )) 52 | ) 53 | -------------------------------------------------------------------------------- /RDF/RDFsys.cl: -------------------------------------------------------------------------------- 1 | ;;; -*- Mode: common-lisp; Syntax: Common-Lisp; -*- 2 | 3 | (eval-when (:load-toplevel :execute) 4 | (defparameter *rdf-directory* 5 | (make-pathname :host (pathname-host *load-truename*) 6 | :device (pathname-device *load-truename*) 7 | :directory (pathname-directory *load-truename*))) 8 | (setf (logical-pathname-translations "RDF") 9 | `(("*.*" 10 | ,(make-pathname 11 | :host (pathname-host *rdf-directory*) 12 | :device (pathname-device *rdf-directory*) 13 | :directory (pathname-directory *rdf-directory*) 14 | :name :wild 15 | :type :wild 16 | )))) 17 | ) ; end of eval-when 18 | 19 | (excl:defsystem :rdf (:pretty-name "RDF subsystem of SWCLOS" 20 | :default-pathname #,*rdf-directory*) 21 | (:module :utils "Utils") 22 | (:module :rdfio "RdfIO") 23 | (:module :iri "IRI") 24 | (:module :rdfspackages "packages") 25 | (:module :xml "Xml" (:load-before-compile :rdfspackages)) 26 | (:module :rdferror "rdferror" (:load-before-compile :utils :rdfspackages)) 27 | (:module :namespace "NameSpace" (:load-before-compile :rdfspackages :iri)) 28 | (:module :rdfliteral "Literal" (:load-before-compile :xml)) 29 | (:module :rdfshare "RDFShare" (:load-before-compile :rdfspackages :rdfio :namespace)) 30 | (:module :rdfparser "RdfParser" (:load-before-compile :rdfspackages :namespace :rdfshare)) 31 | (:module :rdfform "RdfReader" (:load-before-compile :rdfspackages :rdfparser)) 32 | (:module :rdfnode "node" (:load-before-compile :rdfspackages :iri)) 33 | ) 34 | 35 | (format t "~%;;To recompile, execute these forms:~%~s~%" 36 | '(excl:compile-system :rdf :recompile t)) 37 | 38 | (format t "~%;;To load, execute these forms:~%~s~%" 39 | '(excl:load-system :rdf)) 40 | -------------------------------------------------------------------------------- /LICENCE.TXT: -------------------------------------------------------------------------------- 1 | Copyright (c) 2007--2011 Seiji Koide 2 | Copyright (c) 2005, 2006 Galaxy Express Corporation 3 | 4 | Galaxy Express Corporation held all copyrights and allowed anyone to use SWCLOS anyhow AS IS, 5 | except modifying the package name of gx and gx-user. 6 | 'GX' was the rocket name from GALAXY EXPRESS CORPORATION. See README file in delivery. 7 | 8 | Redistribution and use in source and binary forms, with or without modification, 9 | are permitted provided that the following conditions are met: 10 | 11 | Redistributions of source code must retain the above copyright notice, this list of conditions 12 | and the following disclaimer. 13 | Redistributions in binary form must reproduce the above copyright notice, this list of 14 | conditions and the following disclaimer in the documentation and/or other materials provided 15 | with the distribution. 16 | The name of the author may not be used to endorse or promote products derived from this software 17 | without specific prior written permission. 18 | The name of the lisp package name gx and gx-user must not be modified and deleted, but any 19 | modification may be added to the gx and gx-user package contents. 20 | 21 | This licence basically meets to the style of BSD as follows. 22 | 23 | THIS SOFTWARE IS PROVIDED BY THE FREEBSD PROJECT ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, 24 | INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A 25 | PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FREEBSD PROJECT OR CONTRIBUTORS BE 26 | LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES 27 | (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, 28 | OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 | CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF 30 | THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 31 | -------------------------------------------------------------------------------- /doc/overview.css: -------------------------------------------------------------------------------- 1 | /* Need to understand CSS2 inheritance */ 2 | 3 | body { 4 | font-family: Verdana, Arial, Helvetica, sans-serif ; 5 | font-size: 10pt ; 6 | /*line-height: 12pt ;*/ 7 | color: black; 8 | background: white ; 9 | /* text-align: justify; */ 10 | margin-left: 2%; 11 | margin-right: 2%; 12 | } 13 | 14 | code { font-family: courier } 15 | 16 | /* Broswer CSS2 table support is rather "individual" */ 17 | 18 | table { 19 | font-family: Verdana, Arial, sans-serif ; 20 | font-size: 10pt ; 21 | } 22 | 23 | 24 | .noindent { margin-left: -5% ; margin-right: -5%; } 25 | .moreindent { margin-left: 5% ; margin-right: 5%; } 26 | 27 | .box { /*margin-left : 5% ; 28 | margin-right : 7% ;*/ 29 | border: solid; 30 | border-width: 1; 31 | background-color: #F0F0F0; 32 | padding: 10; 33 | page-break-inside: avoid ; 34 | } 35 | 36 | 37 | /* Use this for the document title as displayed on the page at the top. */ 38 | 39 | h1.title { font-size: 160% ; font-weight: bold ; } 40 | h1 { font-size: 130% ; font-weight: bold ; } 41 | h2 { font-size: 105% ; font-weight: bold ; } 42 | h3 { font-size: 100% ; font-weight: bold ; } 43 | h4 { font-size: 100% ; font-style: italic ; } 44 | h5 { font-size: small-caps 100% ; } 45 | 46 | /* Same (if base font is 10pt) - but in points */ 47 | /* 48 | h1 { font-size: 16pt ; font-weight: bold ; } 49 | h2 { font-size: 13pt ; font-weight: bold ; } 50 | h3 { font-size: 11pt ; font-weight: bold ; } 51 | h4 { font-size: 10pt ; font-weight: normal ; font-style: italic ; } 52 | h5 { font-size: 10pt ; font-weight: normal; font-style: italic ; } 53 | h6 { font-size: small-caps 100% ; } 54 | */ 55 | 56 | /* These mess up Konqueror and you lose the left edge. 57 | h1 { margin-left: -4%;} 58 | h2,h3,h4,h5,h6 { margin-left: -4%; } 59 | */ 60 | 61 | ul { list-style-type: disc } 62 | dt { font-weight: bold } 63 | 64 | /* Change background/foreground colour on hover */ 65 | 66 | A:link { color: rgb(0, 0, 255) } /* for unvisited links */ 67 | A:hover { color: rgb(255, 0, 0) } /* when mouse is over link */ 68 | 69 | /* No extra space between paragraphs : inherits from body */ 70 | pre { 71 | font-family: monospace; 72 | font-size: 10pt ; 73 | margin-top: 1 ; 74 | margin-bottom: 1 ; 75 | } 76 | -------------------------------------------------------------------------------- /Manual-ja/MANUAL2.CSS: -------------------------------------------------------------------------------- 1 | /* Need to understand CSS2 inheritance */ 2 | 3 | body { 4 | font-family: Verdana, Arial, Helvetica, sans-serif ; 5 | font-size: 10pt ; 6 | /*line-height: 12pt ;*/ 7 | color: black; 8 | background: white ; 9 | /* text-align: justify; */ 10 | margin-left: 5%; 11 | margin-right: 5%; 12 | } 13 | 14 | code { font-family: courier } 15 | 16 | table { 17 | font-family: Verdana, Arial, sans-serif ; 18 | font-size: 10pt ; 19 | border-color : black ; 20 | border-collapse: collapse; 21 | border-width: 1px; 22 | } 23 | 24 | td { 25 | border-collapse: collapse; 26 | border-color : #808080 ; 27 | empty-cells: show; 28 | padding-left:5px; 29 | padding-right:5px; 30 | } 31 | 32 | 33 | th { 34 | border-width: 0px ; 35 | border-color: #808080 ; 36 | empty-cells: show; 37 | } 38 | 39 | .noindent { margin-left: -5% ; margin-right: -5%; } 40 | .moreindent { margin-left: 5% ; margin-right: 5%; } 41 | 42 | .box { /*margin-left : 5% ; 43 | margin-right : 7% ;*/ 44 | border: solid ; 45 | border-width: thin; 46 | background-color: #F0F0F0; 47 | padding: 10; 48 | page-break-inside: avoid ; 49 | } 50 | 51 | 52 | /* Use this for the document title as displayed on the page at the top. */ 53 | 54 | h1.title { font-size: 160% ; font-weight: bold ; } 55 | h1 { font-size: 130% ; font-weight: bold ; } 56 | h2 { font-size: 105% ; font-weight: bold ; } 57 | h3 { font-size: 100% ; font-weight: bold ; } 58 | h4 { font-size: 100% ; font-style: italic ; } 59 | h5 { font-size: small-caps 100% ; } 60 | 61 | /* Same (if base font is 10pt) - but in points */ 62 | /* 63 | h1 { font-size: 16pt ; font-weight: bold ; } 64 | h2 { font-size: 13pt ; font-weight: bold ; } 65 | h3 { font-size: 11pt ; font-weight: bold ; } 66 | h4 { font-size: 10pt ; font-weight: normal ; font-style: italic ; } 67 | h5 { font-size: 10pt ; font-weight: normal; font-style: italic ; } 68 | h6 { font-size: small-caps 100% ; } 69 | */ 70 | 71 | /* These mess up Konqueror and you lose the left edge. 72 | h1 { margin-left: -4%;} 73 | h2,h3,h4,h5,h6 { margin-left: -4%; } 74 | */ 75 | 76 | ul { list-style-type: disc } 77 | dt { font-weight: bold } 78 | 79 | /* Change background/foreground colour on hover */ 80 | 81 | A:link { color: rgb(0, 0, 255) } /* for unvisited links */ 82 | A:hover { color: rgb(255, 0, 0) } /* when mouse is over link */ 83 | 84 | /* No extra space between paragraphs : inherits from body */ 85 | pre { 86 | font-family: monospace; 87 | font-size: 10pt ; 88 | margin-top: 1 ; 89 | margin-bottom: 1 ; 90 | } 91 | 92 | /* Reference style by Seiji */ 93 | refhead { font-style: bold } 94 | refbody { margin-left: 10px ; } 95 | -------------------------------------------------------------------------------- /Manual/MANUAL2.CSS: -------------------------------------------------------------------------------- 1 | /* Need to understand CSS2 inheritance */ 2 | 3 | body { 4 | font-family: Verdana, Arial, Helvetica, sans-serif ; 5 | font-size: 10pt ; 6 | /*line-height: 12pt ;*/ 7 | color: black; 8 | background: white ; 9 | /* text-align: justify; */ 10 | margin-left: 5%; 11 | margin-right: 5%; 12 | } 13 | 14 | code { font-family: courier } 15 | 16 | table { 17 | font-family: Verdana, Arial, sans-serif ; 18 | font-size: 10pt ; 19 | border-color : black ; 20 | border-collapse: collapse; 21 | border-width: 1px; 22 | } 23 | 24 | td { 25 | border-collapse: collapse; 26 | border-color : #808080 ; 27 | empty-cells: show; 28 | padding-left:5px; 29 | padding-right:5px; 30 | } 31 | 32 | 33 | th { 34 | border-width: 0px ; 35 | border-color: #808080 ; 36 | empty-cells: show; 37 | } 38 | 39 | .noindent { margin-left: -5% ; margin-right: -5%; } 40 | .moreindent { margin-left: 5% ; margin-right: 5%; } 41 | 42 | .box { /*margin-left : 5% ; 43 | margin-right : 7% ;*/ 44 | border: solid ; 45 | border-width: thin; 46 | background-color: #F0F0F0; 47 | padding: 10; 48 | page-break-inside: avoid ; 49 | } 50 | 51 | 52 | /* Use this for the document title as displayed on the page at the top. */ 53 | 54 | h1.title { font-size: 160% ; font-weight: bold ; } 55 | h1 { font-size: 130% ; font-weight: bold ; } 56 | h2 { font-size: 105% ; font-weight: bold ; } 57 | h3 { font-size: 100% ; font-weight: bold ; } 58 | h4 { font-size: 100% ; font-style: italic ; } 59 | h5 { font-size: small-caps 100% ; } 60 | 61 | /* Same (if base font is 10pt) - but in points */ 62 | /* 63 | h1 { font-size: 16pt ; font-weight: bold ; } 64 | h2 { font-size: 13pt ; font-weight: bold ; } 65 | h3 { font-size: 11pt ; font-weight: bold ; } 66 | h4 { font-size: 10pt ; font-weight: normal ; font-style: italic ; } 67 | h5 { font-size: 10pt ; font-weight: normal; font-style: italic ; } 68 | h6 { font-size: small-caps 100% ; } 69 | */ 70 | 71 | /* These mess up Konqueror and you lose the left edge. 72 | h1 { margin-left: -4%;} 73 | h2,h3,h4,h5,h6 { margin-left: -4%; } 74 | */ 75 | 76 | ul { list-style-type: disc } 77 | dt { font-weight: bold } 78 | 79 | /* Change background/foreground colour on hover */ 80 | 81 | A:link { color: rgb(0, 0, 255) } /* for unvisited links */ 82 | A:hover { color: rgb(255, 0, 0) } /* when mouse is over link */ 83 | 84 | /* No extra space between paragraphs : inherits from body */ 85 | pre { 86 | font-family: monospace; 87 | font-size: 10pt ; 88 | margin-top: 1 ; 89 | margin-bottom: 1 ; 90 | } 91 | 92 | /* Reference style by Seiji */ 93 | refhead { font-style: bold } 94 | refbody { margin-left: 10px ; } 95 | -------------------------------------------------------------------------------- /RDF/rdferror.cl: -------------------------------------------------------------------------------- 1 | ;;;-*- Mode: common-lisp; syntax: common-lisp; package: gx; base: 10 -*- 2 | ;;; 3 | ;;;; Condition and Error Handling module 4 | ;;; 5 | ;;; This code is written by Seiji Koide. 6 | ;;; 7 | ;;; Copyright (c) 2007, 2010 Seiji Koide 8 | ;; 9 | ;; History 10 | ;; ------- 11 | ;; 2010.12.08 This file is copied from Xml in RDF subsystem in SWCLOS. 12 | ;; 2009.05.09 File created. 13 | ;;; ================================================================================== 14 | 15 | (cl:provide :rdferror) 16 | 17 | (eval-when (:execute :load-toplevel :compile-toplevel) 18 | (require :swclosutils) 19 | (require :swclospackages) 20 | ) ; end of eval-when 21 | 22 | (defpackage :gx 23 | (:export quiet-warning-handler with-quiet-warnings 24 | )) 25 | 26 | (in-package :gx) 27 | 28 | ;; These coding is from ANSI Common Lisp manual. 29 | (defvar *all-quiet* nil) 30 | (defvar *saved-warnings* '()) 31 | 32 | (defun quiet-warning-handler (c) 33 | (when *all-quiet* 34 | (let ((r (find-restart 'muffle-warning c))) 35 | (when r 36 | (push c *saved-warnings*) 37 | (invoke-restart r))))) 38 | 39 | (defmacro with-quiet-warnings (&body forms) 40 | `(let ((*all-quiet* t) 41 | (*saved-warnings* '())) 42 | (handler-bind ((warning #'quiet-warning-handler)) 43 | ,@forms 44 | *saved-warnings*))) 45 | #| 46 | (defvar *undo* '()) 47 | (defvar *undo-stack* '()) 48 | (defvar *undoed-operations* '()) 49 | 50 | (defun undoable-by-domain-condition-handler (condition) 51 | (declare (ignore condition)) 52 | (when *undo* 53 | (loop for undo-ope in *undo-stack* 54 | do (funcall undo-ope)))) 55 | 56 | (defmacro with-undoable (&body forms) 57 | `(let ((*undo* t) 58 | (*undo-stack* '()) 59 | (*undoed-operations* '())) 60 | (handler-bind ((invalid-slot-value-for-range #'invalid-slot-value-handler) 61 | (range-condition-unsatisfiable #'undoable-by-range-condition-handler) 62 | (domain-condition-unsatisfiable #'undoable-by-domain-condition-handler) 63 | ) 64 | ,@forms))) 65 | 66 | ;;; 67 | ;;;; Undoable Objects and Classes 68 | ;;; 69 | 70 | (defclass undoable-metaclass (cl:standard-class) 71 | () 72 | (:metaclass cl:standard-class)) 73 | 74 | (defclass undoable-class (cl:standard-object) 75 | () 76 | (:metaclass undoable-metaclass)) 77 | 78 | (defmethod shared-initialize :around ((instance undoable-class) slot-names &rest initargs) 79 | (format t "~%SHARED-INITIALIZE:AROUND(undoable-class) ~S ~S ~S" instance slot-names initargs) 80 | (when *undo* 81 | (push (apply #'make-undo-operation #'undo-shared-initialize instance slot-names initargs) 82 | *undo-stack*)) 83 | (call-next-method)) 84 | |# -------------------------------------------------------------------------------- /RDF/Literal.cl: -------------------------------------------------------------------------------- 1 | ;;;-*- Mode: common-lisp; syntax: common-lisp; package: :gx; base: 10 -*- 2 | ;;; 3 | ;;;; Literal in SWCLOS RDF Subsystem 4 | ;;; 5 | ;; History 6 | ;; ------- 7 | ;; 2010.12.08 This file is copied from Literal in SWCLOS. 8 | ;;; ================================================================================== 9 | 10 | (cl:provide :rdfliteral) 11 | 12 | (cl:eval-when (:execute :load-toplevel :compile-toplevel) 13 | (cl:require :swclospackages) 14 | 15 | ) ; end of eval-when 16 | 17 | (cl:defpackage :gx 18 | (:shadow uri ) 19 | (:use :common-lisp) 20 | (:export 21 | )) 22 | 23 | (in-package :gx) 24 | 25 | ;;; 26 | ;;;; Plane Literal 27 | ;;; 28 | ;;; A plane literal without language tag is internalized to string in lisp. 29 | ;;; A plane literal with language tag is internalized to an instance of class rdf:inLang. 30 | 31 | (defun lang? (x) 32 | " is 2-letter language code as keyword symbol, e.g., :ja for Japanese, :en for English. 33 | See http://www.loc.gov/standards/iso639-2/php/code_list.php, but :en-US also accepted." 34 | (when (symbolp x) 35 | (or (eq x :ja) 36 | (eq x :en) 37 | (eq x :fr) 38 | (eq x :de) 39 | (eq x :bg) ;Bulgarian 40 | (eq x :da) ;Danish 41 | (eq x :nl) ;Dutch 42 | (eq x :el) ;Greek 43 | (eq x :es) ;Spanish 44 | (eq x :fi) ;Finnish 45 | (eq x :it) ;Italian 46 | (eq x :ko) ;Korean 47 | (eq x :no) ;Norwegian 48 | (eq x :pl) ;Polish 49 | (eq x :pt) ;Portuguese 50 | (eq x :ru) ;Russian 51 | (eq x :sw) ;Swedish 52 | (eq x :th) ;Thai 53 | (eq x :tr) ;Turkish 54 | (eq x :zh) ;Chinese 55 | (eq x :en-us) 56 | (eq x :en-US)))) 57 | ;; See, http://www.loc.gov/standards/iso639-2/php/code_list.php 58 | 59 | ;;; 60 | ;;;; Plane Literal with Lang 61 | ;;; A Lang object has and . 62 | ;;; It is print out such as "Vine@fr". 63 | 64 | (defclass rdf:inLang () 65 | ((lang :initarg :lang :accessor lang) 66 | (content :initarg :content :accessor content))) 67 | 68 | (defmethod print-object ((object rdf:inLang) stream) 69 | (format stream "\"~A\"@~A" (content object) (lang object))) 70 | 71 | (defmethod equals ((obj1 rdf:inLang) (obj2 rdf:inLang)) 72 | "Two plane literal with lang are equal if langs are equal and contents are equal." 73 | (and (equal (lang obj1) (lang obj2)) 74 | (equal (content obj1) (content obj2)))) 75 | 76 | (defun @ (content lang) 77 | "returns an instance of rdf:inLang structure. must be a string. 78 | the string of may be any string or symbol and it must designate language tag." 79 | (assert (stringp content)) 80 | ;; lang is internalized downcased keyword 81 | (make-instance 'rdf:inLang 82 | :lang (intern (string-downcase (string lang)) :keyword) 83 | :content content)) 84 | -------------------------------------------------------------------------------- /overview.css: -------------------------------------------------------------------------------- 1 | /* Need to understand CSS2 inheritance */ 2 | 3 | body { 4 | font-family: Verdana, Arial, Helvetica, sans-serif ; 5 | font-size: 10pt ; 6 | /*line-height: 12pt ;*/ 7 | color: black; 8 | background: white ; 9 | /* text-align: justify; */ 10 | margin-left: 2%; 11 | margin-right: 2%; 12 | } 13 | 14 | code { font-family: courier } 15 | 16 | /* Broswer CSS2 table support is rather "individual" */ 17 | 18 | table { 19 | font-family: Verdana, Arial, sans-serif ; 20 | font-size: 10pt ; 21 | border-color : black ; 22 | border-collapse: collapse; 23 | border-width: 1px; 24 | border: 1; 25 | cellspacing: 0 ; 26 | cellpadding: 0 ; 27 | } 28 | 29 | td { 30 | border-width: 0px ; 31 | border-collapse: collapse; 32 | border-color : #808080 ; 33 | empty-cells: show; 34 | padding: 5 ; 35 | spacing: 0 ; 36 | vertical-align:bottom; 37 | text-align:left; 38 | } 39 | 40 | 41 | th { 42 | border-collapse: collapse; 43 | border-width: 0px ; 44 | border-color: #808080 ; 45 | empty-cells: show; 46 | padding: 5 ; 47 | vertical-align:bottom; 48 | text-align:left; 49 | } 50 | 51 | 52 | .noindent { margin-left: -5% ; margin-right: -5%; } 53 | .moreindent { margin-left: 5% ; margin-right: 5%; } 54 | 55 | .box { /*margin-left : 5% ; 56 | margin-right : 7% ;*/ 57 | border: solid ; 58 | border-width: 1; 59 | background-color: #F0F0F0; 60 | padding: 10; 61 | page-break-inside: avoid ; 62 | } 63 | 64 | 65 | /* Use this for the document title as displayed on the page at the top. */ 66 | 67 | h1.title { font-size: 160% ; font-weight: bold ; } 68 | h1 { font-size: 130% ; font-weight: bold ; } 69 | h2 { font-size: 105% ; font-weight: bold ; } 70 | h3 { font-size: 100% ; font-weight: bold ; } 71 | h4 { font-size: 100% ; font-style: italic ; } 72 | h5 { font-size: small-caps 100% ; } 73 | 74 | /* Same (if base font is 10pt) - but in points */ 75 | /* 76 | h1 { font-size: 16pt ; font-weight: bold ; } 77 | h2 { font-size: 13pt ; font-weight: bold ; } 78 | h3 { font-size: 11pt ; font-weight: bold ; } 79 | h4 { font-size: 10pt ; font-weight: normal ; font-style: italic ; } 80 | h5 { font-size: 10pt ; font-weight: normal; font-style: italic ; } 81 | h6 { font-size: small-caps 100% ; } 82 | */ 83 | 84 | /* These mess up Konqueror and you lose the left edge. 85 | h1 { margin-left: -4%;} 86 | h2,h3,h4,h5,h6 { margin-left: -4%; } 87 | */ 88 | 89 | ul { list-style-type: disc } 90 | dt { font-weight: bold } 91 | 92 | /* Change background/foreground colour on hover */ 93 | 94 | A:link { color: rgb(0, 0, 255) } /* for unvisited links */ 95 | A:hover { color: rgb(255, 0, 0) } /* when mouse is over link */ 96 | 97 | /* No extra space between paragraphs : inherits from body */ 98 | pre { 99 | font-family: monospace; 100 | font-size: 10pt ; 101 | margin-top: 1 ; 102 | margin-bottom: 1 ; 103 | } 104 | -------------------------------------------------------------------------------- /OWL/overview.css: -------------------------------------------------------------------------------- 1 | /* Need to understand CSS2 inheritance */ 2 | 3 | body { 4 | font-family: Verdana, Arial, Helvetica, sans-serif ; 5 | font-size: 10pt ; 6 | /*line-height: 12pt ;*/ 7 | color: black; 8 | background: white ; 9 | /* text-align: justify; */ 10 | margin-left: 5%; 11 | margin-right: 5%; 12 | } 13 | 14 | code { font-family: courier } 15 | 16 | /* Broswer CSS2 table support is rather "individual" */ 17 | 18 | table { 19 | font-family: Verdana, Arial, sans-serif ; 20 | font-size: 10pt ; 21 | border-color : black ; 22 | border-collapse: collapse; 23 | border-width: 1px; 24 | border: 1; 25 | cellspacing: 0 ; 26 | cellpadding: 0 ; 27 | } 28 | 29 | td { 30 | border-width: 0px ; 31 | border-collapse: collapse; 32 | border-color : #808080 ; 33 | empty-cells: show; 34 | padding: 5 ; 35 | spacing: 0 ; 36 | vertical-align:bottom; 37 | text-align:left; 38 | } 39 | 40 | 41 | th { 42 | border-collapse: collapse; 43 | border-width: 0px ; 44 | border-color: #808080 ; 45 | empty-cells: show; 46 | padding: 5 ; 47 | vertical-align:bottom; 48 | text-align:left; 49 | } 50 | 51 | 52 | .noindent { margin-left: -5% ; margin-right: -5%; } 53 | .moreindent { margin-left: 5% ; margin-right: 5%; } 54 | 55 | .box { /*margin-left : 5% ; 56 | margin-right : 7% ;*/ 57 | border: solid ; 58 | border-width: thin; 59 | background-color: #F0F0F0; 60 | padding: 10; 61 | page-break-inside: avoid ; 62 | } 63 | 64 | 65 | /* Use this for the document title as displayed on the page at the top. */ 66 | 67 | h1.title { font-size: 160% ; font-weight: bold ; } 68 | h1 { font-size: 130% ; font-weight: bold ; } 69 | h2 { font-size: 105% ; font-weight: bold ; } 70 | h3 { font-size: 100% ; font-weight: bold ; } 71 | h4 { font-size: 100% ; font-style: italic ; } 72 | h5 { font-size: small-caps 100% ; } 73 | 74 | /* Same (if base font is 10pt) - but in points */ 75 | /* 76 | h1 { font-size: 16pt ; font-weight: bold ; } 77 | h2 { font-size: 13pt ; font-weight: bold ; } 78 | h3 { font-size: 11pt ; font-weight: bold ; } 79 | h4 { font-size: 10pt ; font-weight: normal ; font-style: italic ; } 80 | h5 { font-size: 10pt ; font-weight: normal; font-style: italic ; } 81 | h6 { font-size: small-caps 100% ; } 82 | */ 83 | 84 | /* These mess up Konqueror and you lose the left edge. 85 | h1 { margin-left: -4%;} 86 | h2,h3,h4,h5,h6 { margin-left: -4%; } 87 | */ 88 | 89 | ul { list-style-type: disc } 90 | dt { font-weight: bold } 91 | 92 | /* Change background/foreground colour on hover */ 93 | 94 | A:link { color: rgb(0, 0, 255) } /* for unvisited links */ 95 | A:hover { color: rgb(255, 0, 0) } /* when mouse is over link */ 96 | 97 | /* No extra space between paragraphs : inherits from body */ 98 | pre { 99 | font-family: monospace; 100 | font-size: 10pt ; 101 | margin-top: 1 ; 102 | margin-bottom: 1 ; 103 | } 104 | -------------------------------------------------------------------------------- /RDF/overview.css: -------------------------------------------------------------------------------- 1 | /* Need to understand CSS2 inheritance */ 2 | 3 | body { 4 | font-family: Verdana, Arial, Helvetica, sans-serif ; 5 | font-size: 10pt ; 6 | /*line-height: 12pt ;*/ 7 | color: black; 8 | background: white ; 9 | /* text-align: justify; */ 10 | margin-left: 5%; 11 | margin-right: 5%; 12 | } 13 | 14 | code { font-family: courier } 15 | 16 | /* Broswer CSS2 table support is rather "individual" */ 17 | 18 | table { 19 | font-family: Verdana, Arial, sans-serif ; 20 | font-size: 10pt ; 21 | border-color : black ; 22 | border-collapse: collapse; 23 | border-width: 1px; 24 | border: 1; 25 | cellspacing: 0 ; 26 | cellpadding: 0 ; 27 | } 28 | 29 | td { 30 | border-width: 0px ; 31 | border-collapse: collapse; 32 | border-color : #808080 ; 33 | empty-cells: show; 34 | padding: 5 ; 35 | spacing: 0 ; 36 | vertical-align:bottom; 37 | text-align:left; 38 | } 39 | 40 | 41 | th { 42 | border-collapse: collapse; 43 | border-width: 0px ; 44 | border-color: #808080 ; 45 | empty-cells: show; 46 | padding: 5 ; 47 | vertical-align:bottom; 48 | text-align:left; 49 | } 50 | 51 | 52 | .noindent { margin-left: -5% ; margin-right: -5%; } 53 | .moreindent { margin-left: 5% ; margin-right: 5%; } 54 | 55 | .box { /*margin-left : 5% ; 56 | margin-right : 7% ;*/ 57 | border: solid ; 58 | border-width: thin; 59 | background-color: #F0F0F0; 60 | padding: 10; 61 | page-break-inside: avoid ; 62 | } 63 | 64 | 65 | /* Use this for the document title as displayed on the page at the top. */ 66 | 67 | h1.title { font-size: 160% ; font-weight: bold ; } 68 | h1 { font-size: 130% ; font-weight: bold ; } 69 | h2 { font-size: 105% ; font-weight: bold ; } 70 | h3 { font-size: 100% ; font-weight: bold ; } 71 | h4 { font-size: 100% ; font-style: italic ; } 72 | h5 { font-size: small-caps 100% ; } 73 | 74 | /* Same (if base font is 10pt) - but in points */ 75 | /* 76 | h1 { font-size: 16pt ; font-weight: bold ; } 77 | h2 { font-size: 13pt ; font-weight: bold ; } 78 | h3 { font-size: 11pt ; font-weight: bold ; } 79 | h4 { font-size: 10pt ; font-weight: normal ; font-style: italic ; } 80 | h5 { font-size: 10pt ; font-weight: normal; font-style: italic ; } 81 | h6 { font-size: small-caps 100% ; } 82 | */ 83 | 84 | /* These mess up Konqueror and you lose the left edge. 85 | h1 { margin-left: -4%;} 86 | h2,h3,h4,h5,h6 { margin-left: -4%; } 87 | */ 88 | 89 | ul { list-style-type: disc } 90 | dt { font-weight: bold } 91 | 92 | /* Change background/foreground colour on hover */ 93 | 94 | A:link { color: rgb(0, 0, 255) } /* for unvisited links */ 95 | A:hover { color: rgb(255, 0, 0) } /* when mouse is over link */ 96 | 97 | /* No extra space between paragraphs : inherits from body */ 98 | pre { 99 | font-family: monospace; 100 | font-size: 10pt ; 101 | margin-top: 1 ; 102 | margin-bottom: 1 ; 103 | } 104 | -------------------------------------------------------------------------------- /ReadMe.txt: -------------------------------------------------------------------------------- 1 | #| 2 | SWCLOS is an RDF(S) and OWL Full processor built on top of CLOS. Every resources in RDF, 3 | e.g., rdfs:Class, rdfs:Resource, rdf:Property, and resource instances and properties 4 | are realized as CLOS objects with straightforward-mapping RDFS classes/instances to CLOS 5 | classes/instances. Axioms and entailment rules in RDF(S) and OWL are embodied in the system 6 | so that a lisp programmer can make ontology in RDF(S) and OWL, and then use the ontology 7 | within the semantics specified by RDF(S) documents and OWL documents. 8 | 9 | The OWL semantics is implemented on top of RDF(S) as the extension and augmentation of RDF(S) 10 | semantics. In SWCLOS, every instance of owl:Thing is also an instance of rdfs:Resource, and 11 | every class of owl:Class is also a class of rdfs:Class. Therefore, any rule or method in RDF(S) 12 | works in OWL. 13 | 14 | This SWCLOS version runs on top of Allegro Common Lisp version 8.2 and 8.1. The modern version 15 | of ACL is requisite to distinguish upper and lower letter cases. 16 | 17 | In this version, asdf file and defsystem file are prepared to easy loading without IDE. 18 | 19 | * RDFS.asdf/RDFSsys.cl : Compile and load RDFS modules 20 | * OWL.asdf/OWLsys.cl : Compile and load RDFS + OWL modules 21 | * SWCLOS.asdf/SWCLOSsys.cl : Compile and load RDFS + OWL + Ntriple modules 22 | 23 | To load SWCLOS into ACL, there are three ways as follows. 24 | 25 | 1. Click `Open Project ...' item in `File' menu in the IDE environment, and select RDFS.LPR in RDFS folder 26 | or OWL.LPR in OWL folder or SWCLOS.LPR in SWCLOS folder. 27 | 28 | 2. Use RDFSsys.cl in RDFS folder, or OWLsys.cl in OWL folder, or SWCLOSsys.cl in SWCLOS fonder 29 | for ACL Defsystem. 30 | See http://www.franz.com/support/documentation/8.1/doc/defsystem.htm. 31 | 32 | 2.1 Load the file "RDFSsys.cl", or "OWLsys.cl", or "SWCLOSsys.cl". 33 | 2.2 Compile RDFS or OWL system by typing "(compile-system :rdfs)", or 34 | "(compile-system :owl)", or "(compile-system :swclos)". 35 | 2.3 Load them by typeing "(load-system :rdfs)", or "(load-system :owl), 36 | or "(laod-system :swclos)". 37 | 38 | 3. Use RDFS.asdf in RDFS folder or OWL.asdf in OWL folder for asdf Defsystem. 39 | 40 | 3.1 Load "RDFS.asdf", or "OWL.asdf", or "SWCLOS.rdfs". 41 | 3.2 Compile and Load RDFS or OWL or SWCLOS system. 42 | See http://constantly.at/lisp/asdf/ to know how to operate ASDF. 43 | 44 | After loading, use gx-user package by entering "(in-package gx-user)". 45 | 46 | PPT files are prepared for hands on tutorials. They will be good introductions for you to 47 | SWCLOS. 48 | The manual folder includes user's manual for SWCLOS users. 49 | The doc folder will help you when you read source files. 50 | 51 | Note that *reify-p* and reification function are obsolete. 52 | If you need such function, please use "collect-all-extensions-of " 53 | 54 | Seiji Koide 55 | 8, Jan., 2011 56 | National Institute of Informatics and IHI corporation 57 | |# -------------------------------------------------------------------------------- /NTriple/overview.css: -------------------------------------------------------------------------------- 1 | /* Need to understand CSS2 inheritance */ 2 | 3 | body { 4 | font-family: Verdana, Arial, Helvetica, sans-serif ; 5 | font-size: 10pt ; 6 | /*line-height: 12pt ;*/ 7 | color: black; 8 | background: white ; 9 | /* text-align: justify; */ 10 | margin-left: 5%; 11 | margin-right: 5%; 12 | } 13 | 14 | code { font-family: courier } 15 | 16 | /* Broswer CSS2 table support is rather "individual" */ 17 | 18 | table { 19 | font-family: Verdana, Arial, sans-serif ; 20 | font-size: 10pt ; 21 | border-color : black ; 22 | border-collapse: collapse; 23 | border-width: 1px; 24 | border: 1; 25 | cellspacing: 0 ; 26 | cellpadding: 0 ; 27 | } 28 | 29 | td { 30 | border-width: 0px ; 31 | border-collapse: collapse; 32 | border-color : #808080 ; 33 | empty-cells: show; 34 | padding: 5 ; 35 | spacing: 0 ; 36 | vertical-align:bottom; 37 | text-align:left; 38 | } 39 | 40 | 41 | th { 42 | border-collapse: collapse; 43 | border-width: 0px ; 44 | border-color: #808080 ; 45 | empty-cells: show; 46 | padding: 5 ; 47 | vertical-align:bottom; 48 | text-align:left; 49 | } 50 | 51 | 52 | .noindent { margin-left: -5% ; margin-right: -5%; } 53 | .moreindent { margin-left: 5% ; margin-right: 5%; } 54 | 55 | .box { /*margin-left : 5% ; 56 | margin-right : 7% ;*/ 57 | border: solid ; 58 | border-width: thin; 59 | background-color: #F0F0F0; 60 | padding: 10; 61 | page-break-inside: avoid ; 62 | } 63 | 64 | 65 | /* Use this for the document title as displayed on the page at the top. */ 66 | 67 | h1.title { font-size: 160% ; font-weight: bold ; } 68 | h1 { font-size: 130% ; font-weight: bold ; } 69 | h2 { font-size: 105% ; font-weight: bold ; } 70 | h3 { font-size: 100% ; font-weight: bold ; } 71 | h4 { font-size: 100% ; font-style: italic ; } 72 | h5 { font-size: small-caps 100% ; } 73 | 74 | /* Same (if base font is 10pt) - but in points */ 75 | /* 76 | h1 { font-size: 16pt ; font-weight: bold ; } 77 | h2 { font-size: 13pt ; font-weight: bold ; } 78 | h3 { font-size: 11pt ; font-weight: bold ; } 79 | h4 { font-size: 10pt ; font-weight: normal ; font-style: italic ; } 80 | h5 { font-size: 10pt ; font-weight: normal; font-style: italic ; } 81 | h6 { font-size: small-caps 100% ; } 82 | */ 83 | 84 | /* These mess up Konqueror and you lose the left edge. 85 | h1 { margin-left: -4%;} 86 | h2,h3,h4,h5,h6 { margin-left: -4%; } 87 | */ 88 | 89 | ul { list-style-type: disc } 90 | dt { font-weight: bold } 91 | 92 | /* Change background/foreground colour on hover */ 93 | 94 | A:link { color: rgb(0, 0, 255) } /* for unvisited links */ 95 | A:hover { color: rgb(255, 0, 0) } /* when mouse is over link */ 96 | 97 | /* No extra space between paragraphs : inherits from body */ 98 | pre { 99 | font-family: monospace; 100 | font-size: 10pt ; 101 | margin-top: 1 ; 102 | margin-bottom: 1 ; 103 | } 104 | -------------------------------------------------------------------------------- /RDFS/overview.css: -------------------------------------------------------------------------------- 1 | /* Need to understand CSS2 inheritance */ 2 | 3 | body { 4 | font-family: Verdana, Arial, Helvetica, sans-serif ; 5 | font-size: 10pt ; 6 | /*line-height: 12pt ;*/ 7 | color: black; 8 | background: white ; 9 | /* text-align: justify; */ 10 | margin-left: 5%; 11 | margin-right: 5%; 12 | } 13 | 14 | code { font-family: courier } 15 | 16 | /* Broswer CSS2 table support is rather "individual" */ 17 | 18 | table { 19 | font-family: Verdana, Arial, sans-serif ; 20 | font-size: 10pt ; 21 | border-color : black ; 22 | border-collapse: collapse; 23 | border-width: 1px; 24 | border: 1; 25 | cellspacing: 0 ; 26 | cellpadding: 0 ; 27 | } 28 | 29 | td { 30 | border-width: 0px ; 31 | border-collapse: collapse; 32 | border-color : #808080 ; 33 | empty-cells: show; 34 | padding: 5 ; 35 | spacing: 0 ; 36 | vertical-align:bottom; 37 | text-align:left; 38 | } 39 | 40 | 41 | th { 42 | border-collapse: collapse; 43 | border-width: 0px ; 44 | border-color: #808080 ; 45 | empty-cells: show; 46 | padding: 5 ; 47 | vertical-align:bottom; 48 | text-align:left; 49 | } 50 | 51 | 52 | .noindent { margin-left: -5% ; margin-right: -5%; } 53 | .moreindent { margin-left: 5% ; margin-right: 5%; } 54 | 55 | .box { /*margin-left : 5% ; 56 | margin-right : 7% ;*/ 57 | border: solid ; 58 | border-width: thin; 59 | background-color: #F0F0F0; 60 | padding: 10; 61 | page-break-inside: avoid ; 62 | } 63 | 64 | 65 | /* Use this for the document title as displayed on the page at the top. */ 66 | 67 | h1.title { font-size: 160% ; font-weight: bold ; } 68 | h1 { font-size: 130% ; font-weight: bold ; } 69 | h2 { font-size: 105% ; font-weight: bold ; } 70 | h3 { font-size: 100% ; font-weight: bold ; } 71 | h4 { font-size: 100% ; font-style: italic ; } 72 | h5 { font-size: small-caps 100% ; } 73 | 74 | /* Same (if base font is 10pt) - but in points */ 75 | /* 76 | h1 { font-size: 16pt ; font-weight: bold ; } 77 | h2 { font-size: 13pt ; font-weight: bold ; } 78 | h3 { font-size: 11pt ; font-weight: bold ; } 79 | h4 { font-size: 10pt ; font-weight: normal ; font-style: italic ; } 80 | h5 { font-size: 10pt ; font-weight: normal; font-style: italic ; } 81 | h6 { font-size: small-caps 100% ; } 82 | */ 83 | 84 | /* These mess up Konqueror and you lose the left edge. 85 | h1 { margin-left: -4%;} 86 | h2,h3,h4,h5,h6 { margin-left: -4%; } 87 | */ 88 | 89 | ul { list-style-type: disc } 90 | dt { font-weight: bold } 91 | 92 | /* Change background/foreground colour on hover */ 93 | 94 | A:link { color: rgb(0, 0, 255) } /* for unvisited links */ 95 | A:hover { color: rgb(255, 0, 0) } /* when mouse is over link */ 96 | 97 | /* No extra space between paragraphs : inherits from body */ 98 | pre { 99 | font-family: monospace; 100 | font-size: 10pt ; 101 | margin-top: 1 ; 102 | margin-bottom: 1 ; 103 | } 104 | -------------------------------------------------------------------------------- /utilities/overview.css: -------------------------------------------------------------------------------- 1 | /* Need to understand CSS2 inheritance */ 2 | 3 | body { 4 | font-family: Verdana, Arial, Helvetica, sans-serif ; 5 | font-size: 10pt ; 6 | /*line-height: 12pt ;*/ 7 | color: black; 8 | background: white ; 9 | /* text-align: justify; */ 10 | margin-left: 2%; 11 | margin-right: 2%; 12 | } 13 | 14 | code { font-family: courier } 15 | 16 | /* Broswer CSS2 table support is rather "individual" */ 17 | 18 | table { 19 | font-family: Verdana, Arial, sans-serif ; 20 | font-size: 10pt ; 21 | border-color : black ; 22 | border-collapse: collapse; 23 | border-width: 1px; 24 | border: 1; 25 | cellspacing: 0 ; 26 | cellpadding: 0 ; 27 | } 28 | 29 | td { 30 | border-width: 0px ; 31 | border-collapse: collapse; 32 | border-color : #808080 ; 33 | empty-cells: show; 34 | padding: 5 ; 35 | spacing: 0 ; 36 | vertical-align:bottom; 37 | text-align:left; 38 | } 39 | 40 | 41 | th { 42 | border-collapse: collapse; 43 | border-width: 0px ; 44 | border-color: #808080 ; 45 | empty-cells: show; 46 | padding: 5 ; 47 | vertical-align:bottom; 48 | text-align:left; 49 | } 50 | 51 | 52 | .noindent { margin-left: -5% ; margin-right: -5%; } 53 | .moreindent { margin-left: 5% ; margin-right: 5%; } 54 | 55 | .box { /*margin-left : 5% ; 56 | margin-right : 7% ;*/ 57 | border: solid ; 58 | border-width: thin; 59 | background-color: #F0F0F0; 60 | padding: 10; 61 | page-break-inside: avoid ; 62 | } 63 | 64 | 65 | /* Use this for the document title as displayed on the page at the top. */ 66 | 67 | h1.title { font-size: 160% ; font-weight: bold ; } 68 | h1 { font-size: 130% ; font-weight: bold ; } 69 | h2 { font-size: 105% ; font-weight: bold ; } 70 | h3 { font-size: 100% ; font-weight: bold ; } 71 | h4 { font-size: 100% ; font-style: italic ; } 72 | h5 { font-size: small-caps 100% ; } 73 | 74 | /* Same (if base font is 10pt) - but in points */ 75 | /* 76 | h1 { font-size: 16pt ; font-weight: bold ; } 77 | h2 { font-size: 13pt ; font-weight: bold ; } 78 | h3 { font-size: 11pt ; font-weight: bold ; } 79 | h4 { font-size: 10pt ; font-weight: normal ; font-style: italic ; } 80 | h5 { font-size: 10pt ; font-weight: normal; font-style: italic ; } 81 | h6 { font-size: small-caps 100% ; } 82 | */ 83 | 84 | /* These mess up Konqueror and you lose the left edge. 85 | h1 { margin-left: -4%;} 86 | h2,h3,h4,h5,h6 { margin-left: -4%; } 87 | */ 88 | 89 | ul { list-style-type: disc } 90 | dt { font-weight: bold } 91 | 92 | /* Change background/foreground colour on hover */ 93 | 94 | A:link { color: rgb(0, 0, 255) } /* for unvisited links */ 95 | A:hover { color: rgb(255, 0, 0) } /* when mouse is over link */ 96 | 97 | /* No extra space between paragraphs : inherits from body */ 98 | pre { 99 | font-family: monospace; 100 | font-size: 10pt ; 101 | margin-top: 1 ; 102 | margin-bottom: 1 ; 103 | } 104 | -------------------------------------------------------------------------------- /RDFS/RDFSsys.cl: -------------------------------------------------------------------------------- 1 | ;;; -*- Mode: common-lisp; Syntax: Common-Lisp; -*- 2 | 3 | (eval-when (:load-toplevel :execute) 4 | (defparameter *rdfs-directory* 5 | (make-pathname :host (pathname-host *load-truename*) 6 | :device (pathname-device *load-truename*) 7 | :directory (pathname-directory *load-truename*))) 8 | (setf (logical-pathname-translations "RDFS") 9 | `(("*.*" 10 | ,(make-pathname 11 | :host (pathname-host *rdfs-directory*) 12 | :device (pathname-device *rdfs-directory*) 13 | :directory (pathname-directory *rdfs-directory*) 14 | :name :wild 15 | :type :wild 16 | )))) 17 | ) ; end of eval-when 18 | 19 | (excl:defsystem :rdf (:pretty-name "RDF subsystem of SWCLOS" 20 | :default-pathname #,*rdfs-directory*) 21 | (:module :utils "../RDF/Utils") 22 | (:module :rdfio "../RDF/RdfIO") 23 | (:module :iri "../RDF/IRI") 24 | (:module :swclospackages "../RDF/packages") 25 | (:module :xml "../RDF/Xml" (:load-before-compile :swclospackages)) 26 | (:module :rdferror "../RDF/rdferror" (:load-before-compile :utils :swclospackages)) 27 | (:module :namespace "../RDF/NameSpace" (:load-before-compile :swclospackages :iri)) 28 | (:module :litreal "../RDF/Literal" (:load-before-compile :utils :swclospackages :xml)) 29 | (:module :rdfshare "../RDF/RDFShare" (:load-before-compile :swclospackages :rdfio :namespace)) 30 | (:module :rdfparser "../RDF/RdfParser" (:load-before-compile :swclospackages :namespace :rdfshare)) 31 | (:module :rdfform "../RDF/RdfReader" (:load-before-compile :swclospackages :rdfparser)) 32 | (:module :rdfnode "../RDF/node" ) 33 | ) 34 | 35 | (excl:defsystem :rdfs (:pretty-name "RDFS subsystem of SWCLOS" 36 | :default-pathname #,*rdfs-directory*) 37 | (:module :rdf :rdf) 38 | (:module :slotdef "SlotDef" (:load-before-compile :rdf)) 39 | (:module :rdfboot "RDFboot" (:load-before-compile :rdf :slotdef)) 40 | (:module :domainrange "DomainRange" (:load-before-compile :rdf :rdfboot)) 41 | (:module :rdfskernel "RdfsKernel" (:load-before-compile :rdf :slotdef :rdfboot)) 42 | (:module :gxtype "GxType" (:load-before-compile :rdf :slotdef :rdfboot)) 43 | (:module :rdfsobjects "RdfsObjects" (:load-before-compile :rdf :rdfboot :gxtype)) 44 | (:module :gxforwardref "GxForwardRef" (:load-before-compile :rdf :gxtype :rdfsobjects :domainrange :rdfskernel)) 45 | (:module :rdfscore "RdfsCore" (:load-before-compile :rdf :domainrange :rdfsobjects :rdfskernel)) 46 | (:module :gxutils "gxutils" (:load-before-compile :rdf :rdfscore)) 47 | (:module :rdfwriter "rdfwriter" (:load-before-compile :rdf :gxutils :gxforwardref)) 48 | ) 49 | 50 | (format t "~%;;To recompile, execute these forms:~%~s~%" 51 | '(excl:compile-system :rdfs :recompile t)) 52 | 53 | (format t "~%;;To load, execute these forms:~%~s~%" 54 | '(excl:load-system :rdfs)) 55 | -------------------------------------------------------------------------------- /OWL/README.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | OWL System 4 | 5 | 6 | 7 | 84 | 85 | 86 | 87 |

SWCLOS: A Semantic Web Reasoner on CLOS

88 |

OWL Subsystem

89 |

90 | 91 | 92 | 93 | 94 | 95 | -------------------------------------------------------------------------------- /RDFS/README.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | RDFS System 4 | 5 | 6 | 7 | 84 | 85 | 86 | 87 |

SWCLOS: A Semantic Web Reasoner on CLOS

88 |

RDFS Subsystem

89 |

90 | This subsystem provides the tools for the inference in RDFS. 91 | If you want to use NTriple and OWL, load NTriple subsystem and OWL subsystem, respectively. 92 | 93 | 94 | 95 | 96 | 97 | -------------------------------------------------------------------------------- /NTriple/README.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | RDFS System 4 | 5 | 6 | 7 | 84 | 85 | 86 | 87 |

SWCLOS: A Semantic Web Reasoner on CLOS

88 |

NTriple Subsystem

89 |

90 | 91 | 92 | 93 | 94 | 95 | -------------------------------------------------------------------------------- /Manual-ja/MANUAL.CSS: -------------------------------------------------------------------------------- 1 | /* Need to understand CSS2 inheritance */ 2 | 3 | body { 4 | font-family: Verdana, Arial, Helvetica, sans-serif ; 5 | font-size: 10pt ; 6 | /*line-height: 12pt ;*/ 7 | color: black; 8 | background: white ; 9 | text-align: justify; 10 | margin-left: 5%; 11 | margin-right: 5%; 12 | } 13 | 14 | /* code { font-family: courier } */ 15 | 16 | /* Broswer CSS2 table support is rather "individual" */ 17 | 18 | table { 19 | font-family: Verdana, Arial, sans-serif ; 20 | font-size: 10pt ; 21 | border-color : black ; 22 | border-collapse: collapse; 23 | border-width: 1px; 24 | border: 1; 25 | cellspacing: 0 ; 26 | cellpadding: 0 ; 27 | } 28 | 29 | td { 30 | border-width: 0px ; 31 | border-collapse: collapse; 32 | border-color : #808080 ; 33 | empty-cells: show; 34 | padding: 5 ; 35 | spacing: 0 ; 36 | vertical-align:bottom; 37 | text-align:left; 38 | } 39 | 40 | 41 | th { 42 | border-collapse: collapse; 43 | border-width: 0px ; 44 | border-color: #808080 ; 45 | empty-cells: show; 46 | padding: 5 ; 47 | vertical-align:bottom; 48 | text-align:left; 49 | } 50 | 51 | 52 | .noindent { margin-left: -5% ; margin-right: -5%; } 53 | .moreindent { margin-left: 5% ; margin-right: 5%; } 54 | 55 | .box { /*margin-left : 5% ; 56 | margin-right : 7% ;*/ 57 | border: solid ; 58 | border-width: 1px; 59 | background-color: #F0F0F0; 60 | padding: 10; 61 | page-break-inside: avoid ; 62 | } 63 | 64 | 65 | /* Use this for the document title as displayed on the page at the top. */ 66 | 67 | h1.title { font-size: 160% ; font-weight: bold ; } 68 | h1 { font-size: 130% ; font-weight: bold ; } 69 | h2 { font-size: 105% ; font-weight: bold ; } 70 | h3 { font-size: 100% ; font-weight: bold ; } 71 | h4 { font-size: 100% ; font-style: italic ; } 72 | h5 { font-size: small-caps 100% ; } 73 | 74 | /* Same (if base font is 10pt) - but in points */ 75 | /* 76 | h1 { font-size: 16pt ; font-weight: bold ; } 77 | h2 { font-size: 13pt ; font-weight: bold ; } 78 | h3 { font-size: 11pt ; font-weight: bold ; } 79 | h4 { font-size: 10pt ; font-weight: normal ; font-style: italic ; } 80 | h5 { font-size: 10pt ; font-weight: normal; font-style: italic ; } 81 | h6 { font-size: small-caps 100% ; } 82 | */ 83 | 84 | /* These mess up Konqueror and you lose the left edge. 85 | h1 { margin-left: -4%;} 86 | h2,h3,h4,h5,h6 { margin-left: -4%; } 87 | */ 88 | 89 | ul { list-style-type: disc } 90 | dt { font-weight: bold } 91 | 92 | /* Change background/foreground colour on hover */ 93 | 94 | A:link { color: rgb(0, 0, 255) } /* for unvisited links */ 95 | A:hover { color: rgb(255, 0, 0) } /* when mouse is over link */ 96 | 97 | /* No extra space between paragraphs : inherits from body */ 98 | pre { 99 | font-family: monospace; 100 | font-size: 10pt ; 101 | margin-top: 1 ; 102 | margin-bottom: 1 ; 103 | } 104 | 105 | /* by Seiji */ 106 | div.defname { 107 | font-weight:bold; 108 | text-align: left; 109 | float: left; 110 | } 111 | div.deftype { 112 | text-align: right; 113 | } 114 | div.titlebar { 115 | background-color:#F0F0F0; color:back; 116 | padding:0.1em; 117 | } -------------------------------------------------------------------------------- /Manual/MANUAL.CSS: -------------------------------------------------------------------------------- 1 | /* Need to understand CSS2 inheritance */ 2 | 3 | body { 4 | font-family: Verdana, Arial, Helvetica, sans-serif ; 5 | font-size: 10pt ; 6 | /*line-height: 12pt ;*/ 7 | color: black; 8 | background: white ; 9 | text-align: justify; 10 | margin-left: 5%; 11 | margin-right: 5%; 12 | } 13 | 14 | /* code { font-family: courier } */ 15 | 16 | /* Broswer CSS2 table support is rather "individual" */ 17 | 18 | table { 19 | font-family: Verdana, Arial, sans-serif ; 20 | font-size: 10pt ; 21 | border-color : black ; 22 | border-collapse: collapse; 23 | border-width: 1px; 24 | border: 1; 25 | cellspacing: 0 ; 26 | cellpadding: 0 ; 27 | } 28 | 29 | td { 30 | border-width: 0px ; 31 | border-collapse: collapse; 32 | border-color : #808080 ; 33 | empty-cells: show; 34 | padding: 5 ; 35 | spacing: 0 ; 36 | vertical-align:bottom; 37 | text-align:left; 38 | } 39 | 40 | 41 | th { 42 | border-collapse: collapse; 43 | border-width: 0px ; 44 | border-color: #808080 ; 45 | empty-cells: show; 46 | padding: 5 ; 47 | vertical-align:bottom; 48 | text-align:left; 49 | } 50 | 51 | 52 | .noindent { margin-left: -5% ; margin-right: -5%; } 53 | .moreindent { margin-left: 5% ; margin-right: 5%; } 54 | 55 | .box { /*margin-left : 5% ; 56 | margin-right : 7% ;*/ 57 | border: solid ; 58 | border-width: 1px; 59 | background-color: #F0F0F0; 60 | padding: 10; 61 | page-break-inside: avoid ; 62 | } 63 | 64 | 65 | /* Use this for the document title as displayed on the page at the top. */ 66 | 67 | h1.title { font-size: 160% ; font-weight: bold ; } 68 | h1 { font-size: 130% ; font-weight: bold ; } 69 | h2 { font-size: 105% ; font-weight: bold ; } 70 | h3 { font-size: 100% ; font-weight: bold ; } 71 | h4 { font-size: 100% ; font-style: italic ; } 72 | h5 { font-size: small-caps 100% ; } 73 | 74 | /* Same (if base font is 10pt) - but in points */ 75 | /* 76 | h1 { font-size: 16pt ; font-weight: bold ; } 77 | h2 { font-size: 13pt ; font-weight: bold ; } 78 | h3 { font-size: 11pt ; font-weight: bold ; } 79 | h4 { font-size: 10pt ; font-weight: normal ; font-style: italic ; } 80 | h5 { font-size: 10pt ; font-weight: normal; font-style: italic ; } 81 | h6 { font-size: small-caps 100% ; } 82 | */ 83 | 84 | /* These mess up Konqueror and you lose the left edge. 85 | h1 { margin-left: -4%;} 86 | h2,h3,h4,h5,h6 { margin-left: -4%; } 87 | */ 88 | 89 | ul { list-style-type: disc } 90 | dt { font-weight: bold } 91 | 92 | /* Change background/foreground colour on hover */ 93 | 94 | A:link { color: rgb(0, 0, 255) } /* for unvisited links */ 95 | A:hover { color: rgb(255, 0, 0) } /* when mouse is over link */ 96 | 97 | /* No extra space between paragraphs : inherits from body */ 98 | pre { 99 | font-family: monospace; 100 | font-size: 10pt ; 101 | margin-top: 1 ; 102 | margin-bottom: 1 ; 103 | } 104 | 105 | /* by Seiji */ 106 | div.defname { 107 | font-weight:bold; 108 | text-align: left; 109 | float: left; 110 | } 111 | div.deftype { 112 | text-align: right; 113 | } 114 | div.titlebar { 115 | background-color:#F0F0F0; color:back; 116 | padding:0.1em; 117 | } -------------------------------------------------------------------------------- /RDF/README.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | RDF System 4 | 5 | 6 | 7 | 84 | 85 | 86 | 87 |

SWCLOS: A Semantic Web Reasoner on CLOS

88 |

RDF Subsystem

89 |

90 | This subsystem provides the tools for RDF/XML parser. After loading this module, 91 | load the RDFS module to clasify things in RDFS semantics. 92 | 93 | 94 | 95 | 96 | 97 | -------------------------------------------------------------------------------- /doc/overview.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | Overview of SWCLOS Code 4 | 5 | 6 | 7 | 8 | 9 | 10 |

Overview of SWCLOS Code

11 | 12 |

We had already published many papers and documents on SWCLOS, including 13 | SWCLOS user's manual. They are delivered together 14 | with this document from SWCLOS home page or you can 15 | search and easily find them over the Internet. However, while the concept and the aim of SWCLOS is very clear, 16 | it is difficult to read and understand the program code. The reason is partly because SWCLOS requires knowledge of 17 | RDF(S) and OWL in addition to knowledge of CLOS plus the Meta-Object Protocol (MOP), and partly because many 18 | fragments of procedures in program are allocated to many classes as methods and it makes hard to seize the effective 19 | functions realized by the combination of several methods as a whole program. 20 | 21 |

The aim of this document is to support readers to read the SWCLOS program code and understand it. It is 22 | desirable that readers have knowledge on CLOS and MOP. The book by G. Kiczales, 23 | 24 | "The Art of the Metaobject Protocol" helps for lispers who are not so matured on MOP. 25 | The documents on RDF(S) and OWL 26 | from W3C and papers on SWCLOS are also prerequisite for readers. 27 | 28 |

To generate this document from program source code automatically, the document generation system by 29 | Norvig's AIMA Lisp program is borrowed and 30 | tailored by author. This is very effective to save the cost for documentation and keep the concistency of 31 | information. 32 |

33 | 34 |

This document includes followings: 35 | 36 |

    37 |
  • An alphabetical index of all names in the code. 38 |
  • The Lisp source code itself for RDF, RDFS, OWL, 39 | and NTriple as a browsable directory. 40 |
  • The following subsystems are organized into subdirectories.

    41 |
      42 | 46 |
    • RDF: 47 | includes files for RDF/XML reader and parser. 48 |
    • RDFS: 49 | includes files for the implementation of the semantics of RDF and RDFS. 50 |
    • OWL: 51 | inludes files for the implementation of OWL. 52 |
    • NTriple: 53 | inludes files for the implementation of NTriple, NTriple parser/writer. 54 |
    55 |
56 | 57 |

58 | 59 |
60 | Author: Seiji Koide. 61 | Copyright (c) 2008,2009 Seiji Koide. Nov. 2009 62 | -------------------------------------------------------------------------------- /RDF/packages.cl: -------------------------------------------------------------------------------- 1 | ;;;-*- Mode: common-lisp; syntax: common-lisp; package: cg; base: 10 -*- 2 | ;;; 3 | ;;;; Packages in RDF, RDFS, and OWL System 4 | ;;; 5 | ;;; This module defines basic symbols in xml, xsd, rdf, rdfs, and owl package. 6 | ;;; Those symbols are exported so as to be QNames. 7 | 8 | (cl:provide :swclospackages) 9 | 10 | (cl:defpackage :xmlns 11 | (:use ) ; supressing using common lisp package 12 | ) 13 | (cl:defpackage :xml 14 | (:use ) ; supressing using common lisp package 15 | (:export lang )) 16 | (cl:defpackage :_ ; this package is provided for nodeID symbol. 17 | (:use ) ; supressing using common lisp package 18 | ) 19 | 20 | (cl:defpackage :xsd 21 | (:nicknames :xs) 22 | (:use ) ; supressing using common lisp package 23 | (:export "string" "boolean" "decimal" "float" "double" "dataTime" "time" "date" 24 | "gYearMonth" "gYear" "gMonthDay" "gDay" "gMonth" "hexBinary" "base64Binary" 25 | "anyURI" "normallizedString" "token" "language" "NMTOKEN" "Name" "NCName" 26 | "integer" "nonPositiveInteger" "negativeInteger" "long" "int" "short" "byte" 27 | "nonNegativeInteger" "unsignedLong" "unsignedInt" "unsignedShort" "unsignedByte" 28 | "positiveInteger" "simpleType" "anySimpleType" "true" "false" 29 | "duration" "duration-year" "duration-month" "duration-day" "duration-hour" 30 | "duration-minute" "duration-second") 31 | (:documentation "http://www.w3.org/2001/XMLSchema#")) 32 | 33 | (cl:defpackage :dc 34 | (:use ) ; supressing using common lisp package 35 | (:export "contributor" "coverage" "creator" "date" "description" "format" "identifier" 36 | "language" "publisher" "relation" "rights" "source" "subject" "title" "type")) 37 | 38 | (cl:defpackage :rdf 39 | (:use ) ; supressing using common lisp package 40 | (:export about 41 | XMLDatatype 42 | inLang 43 | resource ID parseType datatype nodeID 44 | Property List Statement subject predicate object 45 | Bag Seq Alt value li XMLDecl RDF Description type 46 | nil first rest XMLLiteral XMLLiteral-equal 47 | _1 _2 _3 _4 _5 _6 _7 _8 _9 48 | type-p subclass-p 49 | PlainLiteral) 50 | (:documentation "http://www.w3.org/1999/02/22-rdf-syntax-ns#")) 51 | 52 | (cl:defpackage :rdfs 53 | (:use ) ; supressing using common lisp package 54 | (:export Resource Class subClassOf subPropertyOf seeAlso domain range 55 | isDefinedBy range domain Literal Container label comment member 56 | ContainerMembershipProperty Datatype) 57 | (:documentation "http://www.w3.org/2000/01/rdf-schema#")) 58 | 59 | (defpackage :owl 60 | (:use ) ; supressing using common lisp package 61 | (:export Class Thing Nothing Restriction onProperty allValuesFrom someValuesFrom hasValue 62 | minCardinality maxCardinality cardinality 63 | allValuesFromRestriction someValuesFromRestriction hasValueRestriction 64 | cardinalityRestriction Ontology 65 | oneOf differentFrom sameAs AllDifferent distinctMembers equivalentClass 66 | TransitiveProperty ObjectProperty DatatypeProperty FunctionalProperty 67 | InverseFunctionalProperty SymmetricProperty inverseOf 68 | intersectionOf unionOf disjointWith complementOf equivalentProperty 69 | describe-slot-constraint 70 | DataRange DeprecatedProperty DeprecatedClass incompatibleWith backwardCompatibleWith 71 | priorVersion versionInfo imports OntologyProperty AnnotationProperty 72 | ) 73 | ;; documentation is supplied from OWL.RDF file. 74 | ) -------------------------------------------------------------------------------- /OWL/OWL.asdf: -------------------------------------------------------------------------------- 1 | ;;; -*- Mode: Lisp; Syntax: ANSI-Common-Lisp; Package: asdf; Base: 10; Lowercase: Yes -*- 2 | ;;; 3 | ;;;; SWCLOS: A Semantic Web Processor on CLOS 4 | ;;; 5 | ;;; IT Program Project in Japan: 6 | ;;: Building Operation-Support System for Large-scale System using IT. 7 | ;;; 8 | ;;; This code is written by Seiji Koide at Galaxy Express Corporation, Japan, 9 | ;;; for the realization of the MEXT IT Program in Japan. 10 | ;;; 11 | ;;; Copyright ゥ 2003, 2004, 2006 by Galaxy Express Corporation 12 | ;;; 13 | ;;; Copyright (c) 2007, 2008, 2009, 2013 Seiji Koide 14 | 15 | ;;; ASDF system definition. 16 | ;;; 17 | ;;; This file must be located at OWL directory that includes many OWL related files. 18 | ;;; This file must be used without compiling. 19 | 20 | (defpackage gx-system (:use :common-lisp :asdf)) 21 | 22 | (in-package :gx-system) 23 | 24 | (eval-when (:load-toplevel :execute) 25 | (defparameter *owl-directory* 26 | (make-pathname :host (pathname-host *load-truename*) 27 | :device (pathname-device *load-truename*) 28 | :directory (pathname-directory *load-truename*))) 29 | (setf (logical-pathname-translations "OWL") 30 | `(("*.*" 31 | ,(make-pathname 32 | :host (pathname-host *owl-directory*) 33 | :device (pathname-device *owl-directory*) 34 | :directory (pathname-directory *owl-directory*) 35 | :name :wild 36 | :type :wild 37 | )))) 38 | ) ; end of eval-when 39 | 40 | (eval-when (:load-toplevel :execute) 41 | (unless (asdf:find-system "rdfs" nil) 42 | (defparameter *rdfs-directory* 43 | (merge-pathnames 44 | (make-pathname 45 | :directory (substitute "RDFS" "OWL" 46 | (pathname-directory *owl-directory*) 47 | :test #'string=)) 48 | *owl-directory*)) 49 | (setf (logical-pathname-translations "RDFS") 50 | `(("*.*" 51 | ,(make-pathname 52 | :host (pathname-host *rdfs-directory*) 53 | :device (pathname-device *rdfs-directory*) 54 | :directory (pathname-directory *rdfs-directory*) 55 | :name :wild 56 | :type :wild 57 | )))) 58 | (load "RDFS:RDFS.asdf")) 59 | ) 60 | 61 | ;(defmethod source-file-type ((c cl-source-file) (s module)) "cl") 62 | 63 | (defsystem :owl 64 | :name "SWCLOS OWL system" 65 | :author "Seiji Koide " 66 | :maintainer "Seiji Koide " 67 | :version "2.0.0" 68 | :licence "SWCLOS" 69 | :description "RDFS subsystem of SWCLOS (an OWL Full processor on top of CLOS)." 70 | :long-description "This code is written at Galaxy Express Corporation, Japan, for the realization of the MEXT IT Program in Japan." 71 | :depends-on ("rdfs") 72 | :in-order-to ((compile-op (load-op "rdfs")) 73 | (load-op (load-op "rdfs"))) 74 | :pathname #+(and :asdf (not :asdf2)) (translate-logical-pathname "OWL:") 75 | #+(and :asdf :asdf2) nil 76 | :components 77 | ((:file "owlerror" :depends-on ()) 78 | (:file "owlkernel" :depends-on ()) 79 | (:file "owlsamedifferent" :depends-on ()) 80 | (:file "owlequivalentdisjoint" :depends-on ()) 81 | (:file "NNF" :depends-on ()) 82 | (:file "tunify" :depends-on ()) 83 | (:file "subsume" :depends-on ()) 84 | (:file "OWL" :depends-on ()) 85 | ) 86 | ) 87 | 88 | (in-package #:cl-user) 89 | 90 | (format t "~%;;To compile, execute these forms:~%~s~%" 91 | '(asdf:operate 'asdf:compile-op :owl)) 92 | 93 | (format t "~%;;To load, execute these forms:~%~s~%" 94 | '(asdf:operate 'asdf:load-op :owl)) 95 | -------------------------------------------------------------------------------- /install.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | Downloading and Installing SWCLOS 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 |

Downloading and Installing SWCLOS

12 |

13 | This page gives instructions for downloading SWCLOS, and 14 | installing it on your local system. This installation procedure need 15 | only be followed once. 16 | 17 |

Downloading SWCLOS

18 |

19 | To download the code, follow these steps: 20 | 21 |

    22 |
  1. Access SWCLOS home page 23 | http://www-kasm.nii.ac.jp/~koide/SWCLOS2-en.htm, and select the menu item "Download". 24 | 25 |
  2. Click the direction for ZIP file for downloading all modules and documents, then you 26 | can store SWCLOS system at any place of local PC. 27 | 28 |
  3. Unpack manually the ZIP file, if it is not expanded automatically. Then, replace the SWCLOS folder 29 | to your favorite directory, ex. C:\allegro-projects\" on Windows, 30 |
31 | 32 |

Installing a Lisp Interpreter/Compiler

33 |

34 | SWCLOS runs only on top of Allegro Common Lisp (ACL) from Franz, Inc. If you do not have ACL, you can download the 35 | evaluation version of ACL, Allegro CL Free Express Edition for Windows. 36 | It is free and works completely in the same as the commercial version. It is quite enough if you do not load huge ontologies 37 | on SWCLOS. Please make sure you have the authority of local manager in MS-Windows for installing ACL. 38 |

39 | 40 |

How to change the character mode:

41 | We always use ACL in modern mode (character case sensitive), in which the 42 | lisp system distinguishes upper-case letters and lower-case letters. 43 | The case-sensitive mode is mandatory to use the URI library and SWCLOS in ACL. 44 | Note that ACL Free Express is not in modern mode. 45 | You must follow the instruction below in order to set up modern mode for 46 | ACL Free Express. If you have a commercial ACL, you do not need the following steps. 47 | Running the modern version in MS-Windows is just menu selection from the start menu. 48 | 49 |
    50 |
  1. Run aclnn-express downloaded. 51 |
  2. Execute the following form in Lisp window. You will obtain 'allegro.exe' file under 52 | 'C:\Program Files\aclnn-express' folder. 53 |

    54 |

         (progn
    55 |        (build-lisp-image "sys:allegro.dxl" :case-mode :case-sensitive-lower)
    56 |        (when (probe-file "sys:allegro.exe") (delete-file "sys:allegro.exe"))
    57 |        (sys:copy-file "sys:allegro-express.exe" "sys:allegro.exe"))
    58 | 

    59 |

    60 |
  3. To start Lisp, invoke 'allegro.exe' instead of 'allegro-ansi.exe'. 61 | In Windows, it is a good idea to set up the start menu for 'allegro.exe'. You may change and revise 62 | the start menu folder from 'allegro-ansi.exe' to 'allegro.exe' on the title and the link. 63 |
64 | 65 |

Running SWCLOS

66 | 67 | The steps above need be done only once; 68 | you are now ready to use SWCLOS. Please read ReadMe.txt in the SWCLOS folder. 69 | 70 |

For Mac Users

71 | 72 | I confirmed that SWCLOS runs on top of ACL-express for MacOS X for Intell CPU, with IDE by X-Windows. 73 | I also confirmed the modern version can be generated on MacOS, too. 74 | 75 |

76 |


77 | Author: Seiji Koide. Modified Norvig's file. Copyright (c) 2011 Seiji Koide. Jan. 2011 78 | 79 | -------------------------------------------------------------------------------- /SWCLOS.lpr: -------------------------------------------------------------------------------- 1 | ;; -*- lisp-version: "9.0 [64-bit Windows *SMP*] (Mar 16, 2015 7:10)"; cg: "9.0"; -*- 2 | 3 | (in-package :cg-user) 4 | 5 | (define-project :name :SWCLOS 6 | :modules nil 7 | :projects (list (make-instance 'project-module :name "OWL/OWL" :show-modules nil) 8 | (make-instance 'project-module :name "NTriple/NTriple" :show-modules 9 | nil)) 10 | :libraries nil 11 | :editable-files nil 12 | :distributed-files nil 13 | :internally-loaded-files nil 14 | :project-package-name :common-graphics-user 15 | :main-form nil 16 | :compilation-unit t 17 | :concatenate-project-fasls nil 18 | :verbose nil 19 | :runtime-modules (list :cg-dde-utils :cg.acache :cg.base :cg.bitmap-pane 20 | :cg.bitmap-pane.clipboard :cg.bitmap-stream :cg.button :cg.caret 21 | :cg.chart-or-plot :cg.chart-widget :cg.check-box :cg.choice-list 22 | :cg.choose-printer :cg.class-grid :cg.class-slot-grid 23 | :cg.class-support :cg.clipboard :cg.clipboard-stack 24 | :cg.clipboard.pixmap :cg.color-dialog :cg.combo-box 25 | :cg.common-control :cg.comtab :cg.cursor-pixmap :cg.curve 26 | :cg.dialog-item :cg.directory-dialog :cg.directory-dialog-os 27 | :cg.drag-and-drop :cg.drag-and-drop-image :cg.drawable 28 | :cg.drawable.clipboard :cg.dropping-outline :cg.edit-in-place 29 | :cg.editable-text :cg.file-dialog :cg.fill-texture 30 | :cg.find-string-dialog :cg.font-dialog :cg.gesture-emulation 31 | :cg.get-pixmap :cg.get-position :cg.graphics-context 32 | :cg.grid-widget :cg.grid-widget.drag-and-drop :cg.group-box 33 | :cg.header-control :cg.hotspot :cg.html-dialog :cg.html-widget 34 | :cg.icon :cg.icon-pixmap :cg.ie :cg.item-list 35 | :cg.keyboard-shortcuts :cg.lamp :cg.lettered-menu 36 | :cg.lisp-edit-pane :cg.lisp-text :cg.lisp-widget :cg.list-view 37 | :cg.mci :cg.menu :cg.menu.tooltip :cg.message-dialog 38 | :cg.multi-line-editable-text :cg.multi-line-lisp-text 39 | :cg.multi-picture-button :cg.multi-picture-button.drag-and-drop 40 | :cg.multi-picture-button.tooltip :cg.object-editor 41 | :cg.object-editor.layout :cg.ocx :cg.os-widget :cg.os-window 42 | :cg.outline :cg.outline.drag-and-drop :cg.outline.edit-in-place 43 | :cg.palette :cg.paren-matching :cg.picture-widget 44 | :cg.picture-widget.palette :cg.pixmap :cg.pixmap-widget 45 | :cg.pixmap.file-io :cg.pixmap.printing :cg.pixmap.rotate 46 | :cg.printing :cg.progress-indicator :cg.project-window 47 | :cg.property :cg.radio-button :cg.rich-edit :cg.rich-edit-pane 48 | :cg.rich-edit-pane.clipboard :cg.rich-edit-pane.printing 49 | :cg.sample-file-menu :cg.scaling-stream :cg.scroll-bar 50 | :cg.scroll-bar-mixin :cg.scrolling-static-text 51 | :cg.selected-object :cg.shortcut-menu :cg.static-text 52 | :cg.status-bar :cg.string-dialog :cg.tab-control 53 | :cg.template-string :cg.text-edit-pane 54 | :cg.text-edit-pane.file-io :cg.text-edit-pane.mark 55 | :cg.text-or-combo :cg.text-widget :cg.timer :cg.toggling-widget 56 | :cg.toolbar :cg.tooltip :cg.trackbar :cg.tray 57 | :cg.up-down-control :cg.utility-dialog :cg.web-browser 58 | :cg.web-browser.dde :cg.wrap-string :cg.yes-no-list 59 | :cg.yes-no-string :dde) 60 | :splash-file-module (make-instance 'build-module :name "") 61 | :icon-file-module (make-instance 'build-module :name "") 62 | :include-flags (list :top-level :debugger) 63 | :build-flags (list :allow-runtime-debug) 64 | :autoload-warning nil 65 | :full-recompile-for-runtime-conditionalizations nil 66 | :include-manifest-file-for-visual-styles t 67 | :default-command-line-arguments "+M +t \"Console for Debugging\"" 68 | :additional-build-lisp-image-arguments (list :read-init-files nil) 69 | :old-space-size 256000 70 | :new-space-size 6144 71 | :runtime-build-option :standard 72 | :build-number 0 73 | :run-with-console nil 74 | :project-file-version-info nil 75 | :on-initialization 'default-init-function 76 | :default-error-handler-for-delivery 'report-unexpected-error-and-exit 77 | :on-restart 'do-default-restart) 78 | 79 | ;; End of Project Definition 80 | -------------------------------------------------------------------------------- /OWL/OWL.lpr: -------------------------------------------------------------------------------- 1 | ;; -*- lisp-version: "9.0 [64-bit Windows *SMP*] (Mar 16, 2015 7:10)"; cg: "9.0"; -*- 2 | 3 | (in-package :cg-user) 4 | 5 | (define-project :name :OWL 6 | :modules (list (make-instance 'module :name "owlerror") 7 | (make-instance 'module :name "owlkernel") 8 | (make-instance 'module :name "owlsamedifferent") 9 | (make-instance 'module :name "owlequivalentdisjoint") 10 | (make-instance 'module :name "NNF") 11 | (make-instance 'module :name "tunify") 12 | (make-instance 'module :name "subsume") 13 | (make-instance 'module :name "OWL")) 14 | :projects (list (make-instance 'project-module :name "../rdfs/rdfs" :show-modules nil)) 15 | :libraries nil 16 | :editable-files nil 17 | :distributed-files nil 18 | :internally-loaded-files nil 19 | :project-package-name :common-graphics-user 20 | :main-form nil 21 | :compilation-unit t 22 | :concatenate-project-fasls nil 23 | :verbose nil 24 | :runtime-modules (list :cg-dde-utils :cg.base :cg.bitmap-pane :cg.bitmap-pane.clipboard 25 | :cg.bitmap-stream :cg.button :cg.caret :cg.check-box 26 | :cg.choice-list :cg.choose-printer :cg.clipboard 27 | :cg.clipboard-stack :cg.clipboard.pixmap :cg.color-dialog 28 | :cg.combo-box :cg.common-control :cg.comtab :cg.cursor-pixmap 29 | :cg.curve :cg.dialog-item :cg.directory-dialog 30 | :cg.directory-dialog-os :cg.drag-and-drop 31 | :cg.drag-and-drop-image :cg.drawable :cg.drawable.clipboard 32 | :cg.dropping-outline :cg.edit-in-place :cg.editable-text 33 | :cg.file-dialog :cg.fill-texture :cg.find-string-dialog 34 | :cg.font-dialog :cg.gesture-emulation :cg.get-pixmap 35 | :cg.get-position :cg.graphics-context :cg.grid-widget 36 | :cg.grid-widget.drag-and-drop :cg.group-box :cg.header-control 37 | :cg.hotspot :cg.icon :cg.icon-pixmap :cg.item-list 38 | :cg.keyboard-shortcuts :cg.lettered-menu :cg.lisp-edit-pane 39 | :cg.lisp-text :cg.lisp-widget :cg.list-view :cg.mci :cg.menu 40 | :cg.menu.tooltip :cg.message-dialog :cg.multi-line-editable-text 41 | :cg.multi-line-lisp-text :cg.multi-picture-button 42 | :cg.multi-picture-button.drag-and-drop 43 | :cg.multi-picture-button.tooltip :cg.os-widget :cg.os-window 44 | :cg.outline :cg.outline.drag-and-drop :cg.outline.edit-in-place 45 | :cg.palette :cg.paren-matching :cg.picture-widget 46 | :cg.picture-widget.palette :cg.pixmap :cg.pixmap-widget 47 | :cg.pixmap.file-io :cg.pixmap.printing :cg.pixmap.rotate 48 | :cg.printing :cg.progress-indicator :cg.project-window 49 | :cg.property :cg.radio-button :cg.rich-edit :cg.rich-edit-pane 50 | :cg.rich-edit-pane.clipboard :cg.rich-edit-pane.printing 51 | :cg.sample-file-menu :cg.scaling-stream :cg.scroll-bar 52 | :cg.scroll-bar-mixin :cg.selected-object :cg.shortcut-menu 53 | :cg.static-text :cg.status-bar :cg.string-dialog :cg.tab-control 54 | :cg.template-string :cg.text-edit-pane 55 | :cg.text-edit-pane.file-io :cg.text-edit-pane.mark 56 | :cg.text-or-combo :cg.text-widget :cg.timer :cg.toggling-widget 57 | :cg.toolbar :cg.tooltip :cg.trackbar :cg.tray 58 | :cg.up-down-control :cg.utility-dialog :cg.web-browser 59 | :cg.web-browser.dde :cg.wrap-string :cg.yes-no-list 60 | :cg.yes-no-string :dde) 61 | :splash-file-module (make-instance 'build-module :name "") 62 | :icon-file-module (make-instance 'build-module :name "") 63 | :include-flags (list :top-level :debugger) 64 | :build-flags (list :allow-runtime-debug :purify) 65 | :autoload-warning t 66 | :full-recompile-for-runtime-conditionalizations nil 67 | :include-manifest-file-for-visual-styles t 68 | :default-command-line-arguments "+M +t \"Console for Debugging\"" 69 | :additional-build-lisp-image-arguments (list :read-init-files nil) 70 | :old-space-size 256000 71 | :new-space-size 6144 72 | :runtime-build-option :standard 73 | :build-number 0 74 | :run-with-console nil 75 | :project-file-version-info nil 76 | :on-initialization 'default-init-function 77 | :default-error-handler-for-delivery 'report-unexpected-error-and-exit 78 | :on-restart 'do-default-restart) 79 | 80 | ;; End of Project Definition 81 | -------------------------------------------------------------------------------- /RDFS/RDFS.lpr: -------------------------------------------------------------------------------- 1 | ;; -*- lisp-version: "9.0 [64-bit Windows *SMP*] (Mar 16, 2015 7:10)"; cg: "9.0"; -*- 2 | 3 | (in-package :cg-user) 4 | 5 | (define-project :name :RDFS 6 | :modules (list (make-instance 'module :name "SlotDef") 7 | (make-instance 'module :name "RDFboot") 8 | (make-instance 'module :name "DomainRange") 9 | (make-instance 'module :name "RdfsKernel") 10 | (make-instance 'module :name "GxType") 11 | (make-instance 'module :name "RdfsObjects") 12 | (make-instance 'module :name "GxForwardRef") 13 | (make-instance 'module :name "RdfsCore") 14 | (make-instance 'module :name "gxutils") 15 | (make-instance 'module :name "rdfwriter") 16 | (make-instance 'module :name "turtleparser")) 17 | :projects (list (make-instance 'project-module :name "../RDF/RDF" :show-modules nil)) 18 | :libraries nil 19 | :editable-files nil 20 | :distributed-files nil 21 | :internally-loaded-files nil 22 | :project-package-name :common-graphics-user 23 | :main-form nil 24 | :compilation-unit t 25 | :concatenate-project-fasls nil 26 | :verbose nil 27 | :runtime-modules (list :cg-dde-utils :cg.base :cg.bitmap-pane :cg.bitmap-pane.clipboard 28 | :cg.bitmap-stream :cg.button :cg.caret :cg.check-box 29 | :cg.choice-list :cg.choose-printer :cg.clipboard 30 | :cg.clipboard-stack :cg.clipboard.pixmap :cg.color-dialog 31 | :cg.combo-box :cg.common-control :cg.comtab :cg.cursor-pixmap 32 | :cg.curve :cg.dialog-item :cg.directory-dialog 33 | :cg.directory-dialog-os :cg.drag-and-drop 34 | :cg.drag-and-drop-image :cg.drawable :cg.drawable.clipboard 35 | :cg.dropping-outline :cg.edit-in-place :cg.editable-text 36 | :cg.file-dialog :cg.fill-texture :cg.find-string-dialog 37 | :cg.font-dialog :cg.gesture-emulation :cg.get-pixmap 38 | :cg.get-position :cg.graphics-context :cg.grid-widget 39 | :cg.grid-widget.drag-and-drop :cg.group-box :cg.header-control 40 | :cg.hotspot :cg.icon :cg.icon-pixmap :cg.item-list 41 | :cg.keyboard-shortcuts :cg.lettered-menu :cg.lisp-edit-pane 42 | :cg.lisp-text :cg.lisp-widget :cg.list-view :cg.mci :cg.menu 43 | :cg.menu.tooltip :cg.message-dialog :cg.multi-line-editable-text 44 | :cg.multi-line-lisp-text :cg.multi-picture-button 45 | :cg.multi-picture-button.drag-and-drop 46 | :cg.multi-picture-button.tooltip :cg.os-widget :cg.os-window 47 | :cg.outline :cg.outline.drag-and-drop :cg.outline.edit-in-place 48 | :cg.palette :cg.paren-matching :cg.picture-widget 49 | :cg.picture-widget.palette :cg.pixmap :cg.pixmap-widget 50 | :cg.pixmap.file-io :cg.pixmap.printing :cg.pixmap.rotate 51 | :cg.printing :cg.progress-indicator :cg.project-window 52 | :cg.property :cg.radio-button :cg.rich-edit :cg.rich-edit-pane 53 | :cg.rich-edit-pane.clipboard :cg.rich-edit-pane.printing 54 | :cg.sample-file-menu :cg.scaling-stream :cg.scroll-bar 55 | :cg.scroll-bar-mixin :cg.selected-object :cg.shortcut-menu 56 | :cg.static-text :cg.status-bar :cg.string-dialog :cg.tab-control 57 | :cg.template-string :cg.text-edit-pane 58 | :cg.text-edit-pane.file-io :cg.text-edit-pane.mark 59 | :cg.text-or-combo :cg.text-widget :cg.timer :cg.toggling-widget 60 | :cg.toolbar :cg.tooltip :cg.trackbar :cg.tray 61 | :cg.up-down-control :cg.utility-dialog :cg.web-browser 62 | :cg.web-browser.dde :cg.wrap-string :cg.yes-no-list 63 | :cg.yes-no-string :dde) 64 | :splash-file-module (make-instance 'build-module :name "") 65 | :icon-file-module (make-instance 'build-module :name "") 66 | :include-flags (list :top-level :debugger) 67 | :build-flags (list :allow-runtime-debug :purify) 68 | :autoload-warning t 69 | :full-recompile-for-runtime-conditionalizations nil 70 | :include-manifest-file-for-visual-styles t 71 | :default-command-line-arguments "+M +t \"Console for Debugging\"" 72 | :additional-build-lisp-image-arguments (list :read-init-files nil) 73 | :old-space-size 256000 74 | :new-space-size 6144 75 | :runtime-build-option :standard 76 | :build-number 0 77 | :run-with-console nil 78 | :project-file-version-info nil 79 | :on-initialization 'default-init-function 80 | :default-error-handler-for-delivery 'report-unexpected-error-and-exit 81 | :on-restart 'do-default-restart) 82 | 83 | ;; End of Project Definition 84 | -------------------------------------------------------------------------------- /RDF/22-rdf-syntax-ns.ttl: -------------------------------------------------------------------------------- 1 | @prefix rdf: . 2 | @prefix rdfs: . 3 | @prefix owl: . 4 | @prefix dc: . 5 | 6 | rdf:type owl:Ontology . 7 | dc:title "The RDF Vocabulary (RDF)" . 8 | dc:description "This is the RDF Schema for the RDF vocabulary defined in the RDF namespace." . 9 | 10 | rdf:type rdf:type rdf:Property . 11 | rdf:type rdfs:isDefinedBy . 12 | rdf:type rdfs:label "type" . 13 | rdf:type rdfs:comment "The subject is an instance of a class." . 14 | rdf:type rdfs:range rdfs:Class . 15 | rdf:type rdfs:domain rdfs:Resource . 16 | 17 | rdf:Property rdf:type rdfs:Class . 18 | rdf:Property rdfs:isDefinedBy . 19 | rdf:Property rdfs:label "Property" . 20 | rdf:Property rdfs:comment "The class of RDF properties." . 21 | rdf:Property rdfs:subClassOf rdfs:Resource . 22 | 23 | rdf:Statement rdf:type rdfs:Class . 24 | rdf:Statement rdfs:isDefinedBy . 25 | rdf:Statement rdfs:label "Statement" . 26 | rdf:Statement rdfs:subClassOf rdfs:Resource . 27 | rdf:Statement rdfs:comment "The class of RDF statements." . 28 | 29 | rdf:subject rdf:type rdf:Property . 30 | rdf:subject rdfs:isDefinedBy . 31 | rdf:subject rdfs:label "subject" . 32 | rdf:subject rdfs:comment "The subject of the subject RDF statement." . 33 | rdf:subject rdfs:domain rdf:Statement . 34 | rdf:subject rdfs:range rdfs:Resource . 35 | 36 | rdf:predicate rdf:type rdf:Property . 37 | rdf:predicate rdfs:isDefinedBy . 38 | rdf:predicate rdfs:label "predicate" . 39 | rdf:predicate rdfs:comment "The predicate of the subject RDF statement." . 40 | rdf:predicate rdfs:domain rdf:Statement . 41 | rdf:predicate rdfs:range rdfs:Resource . 42 | 43 | rdf:object rdf:type rdf:Property . 44 | rdf:object rdfs:isDefinedBy . 45 | rdf:object rdfs:label "object" . 46 | rdf:object rdfs:comment "The object of the subject RDF statement." . 47 | rdf:object rdfs:domain rdf:Statement . 48 | rdf:object rdfs:range rdfs:Resource . 49 | 50 | rdf:Bag rdf:type rdfs:Class . 51 | rdf:Bag rdfs:isDefinedBy . 52 | rdf:Bag rdfs:label "Bag" . 53 | rdf:Bag rdfs:comment "The class of unordered containers." . 54 | rdf:Bag rdfs:subClassOf rdfs:Container . 55 | 56 | rdf:Seq rdf:type rdfs:Class . 57 | rdf:Seq rdfs:isDefinedBy . 58 | rdf:Seq rdfs:label "Seq" . 59 | rdf:Seq rdfs:comment "The class of ordered containers." . 60 | rdf:Seq rdfs:subClassOf rdfs:Container . 61 | 62 | rdf:Alt rdf:type rdfs:Class . 63 | rdf:Alt rdfs:isDefinedBy . 64 | rdf:Alt rdfs:comment "The class of containers of alternatives." . 65 | rdf:Alt rdfs:subClassOf rdfs:Container . 66 | 67 | rdf:value rdf:type rdf:Property . 68 | rdf:value rdfs:isDefinedBy . 69 | rdf:value rdfs:label "value" . 70 | rdf:value rdfs:comment "Idiomatic property used for structured values." . 71 | rdf:value rdfs:domain rdfs:Resource . 72 | rdf:value rdfs:range rdfs:Resource . 73 | 74 | # the following are new additions, Nov 2002 75 | 76 | rdf:List rdf:type rdfs:Class . 77 | rdf:List rdfs:isDefinedBy . 78 | rdf:List rdfs:label "List" . 79 | rdf:List rdfs:comment "The class of RDF Lists." . 80 | rdf:List rdfs:subClassOf rdfs:Resource . 81 | 82 | rdf:nil rdf:type rdf:List . 83 | rdf:nil rdfs:isDefinedBy . 84 | rdf:nil rdfs:label "nil" . 85 | rdf:nil rdfs:comment "The empty list, with no items in it. If the rest of a list is nil then the list has no more items in it." . 86 | 87 | rdf:first rdf:type rdf:Property . 88 | rdf:first rdfs:isDefinedBy . 89 | rdf:first rdfs:label "first" . 90 | rdf:first rdfs:comment "The first item in the subject RDF list." . 91 | rdf:first rdfs:domain rdf:List . 92 | rdf:first rdfs:range rdfs:Resource . 93 | 94 | rdf:rest rdf:type rdf:Property . 95 | rdf:rest rdfs:isDefinedBy . 96 | rdf:rest rdfs:label "rest" . 97 | rdf:rest rdfs:comment "The rest of the subject RDF list after the first item." . 98 | rdf:rest rdfs:domain rdf:List . 99 | rdf:rest rdfs:range rdf:List . 100 | 101 | rdf:XMLLiteral rdf:type rdfs:Datatype . 102 | rdf:XMLLiteral rdfs:subClassOf rdfs:Literal . 103 | rdf:XMLLiteral rdfs:isDefinedBy . 104 | rdf:XMLLiteral rdfs:label "XMLLiteral" . 105 | rdf:XMLLiteral rdfs:comment "The class of XML literal values." . 106 | 107 | rdf:type rdf:Description . 108 | rdfs:seeAlso 109 | 110 | 111 | -------------------------------------------------------------------------------- /NTriple/NTriple.lpr: -------------------------------------------------------------------------------- 1 | ;; -*- lisp-version: "8.1 [Windows] (Aug 6, 2010 9:44)"; cg: "1.103.2.10"; -*- 2 | 3 | (in-package :cg-user) 4 | 5 | (define-project :name :NTriple 6 | :modules (list (make-instance 'module :name "ntparser") 7 | (make-instance 'module :name "ntriple") 8 | (make-instance 'module :name "ntwriter")) 9 | :projects nil 10 | :libraries nil 11 | :distributed-files nil 12 | :internally-loaded-files nil 13 | :project-package-name :common-graphics-user 14 | :main-form nil 15 | :compilation-unit t 16 | :verbose nil 17 | :runtime-modules (list :cg-dde-utils :cg.acache :cg.base 18 | :cg.bitmap-pane :cg.bitmap-pane.clipboard 19 | :cg.bitmap-stream :cg.button :cg.caret 20 | :cg.chart-or-plot :cg.chart-widget 21 | :cg.check-box :cg.choice-list 22 | :cg.choose-printer :cg.class-grid 23 | :cg.class-slot-grid :cg.class-support 24 | :cg.clipboard :cg.clipboard-stack 25 | :cg.clipboard.pixmap :cg.color-dialog 26 | :cg.combo-box :cg.common-control :cg.comtab 27 | :cg.cursor-pixmap :cg.curve :cg.dialog-item 28 | :cg.directory-dialog :cg.directory-dialog-os 29 | :cg.drag-and-drop :cg.drag-and-drop-image 30 | :cg.drawable :cg.drawable.clipboard 31 | :cg.dropping-outline :cg.edit-in-place 32 | :cg.editable-text :cg.file-dialog 33 | :cg.fill-texture :cg.find-string-dialog 34 | :cg.font-dialog :cg.gesture-emulation 35 | :cg.get-pixmap :cg.get-position 36 | :cg.graphics-context :cg.grid-widget 37 | :cg.grid-widget.drag-and-drop :cg.group-box 38 | :cg.header-control :cg.hotspot :cg.html-dialog 39 | :cg.html-widget :cg.icon :cg.icon-pixmap 40 | :cg.ie :cg.item-list :cg.keyboard-shortcuts 41 | :cg.lamp :cg.lettered-menu :cg.lisp-edit-pane 42 | :cg.lisp-text :cg.lisp-widget :cg.list-view 43 | :cg.mci :cg.menu :cg.menu.tooltip 44 | :cg.message-dialog 45 | :cg.multi-line-editable-text 46 | :cg.multi-line-lisp-text 47 | :cg.multi-picture-button 48 | :cg.multi-picture-button.drag-and-drop 49 | :cg.multi-picture-button.tooltip 50 | :cg.object-editor :cg.object-editor.layout 51 | :cg.ocx :cg.os-widget :cg.os-window 52 | :cg.outline :cg.outline.drag-and-drop 53 | :cg.outline.edit-in-place :cg.palette 54 | :cg.paren-matching :cg.picture-widget 55 | :cg.picture-widget.palette :cg.pixmap 56 | :cg.pixmap-widget :cg.pixmap.file-io 57 | :cg.pixmap.printing :cg.pixmap.rotate 58 | :cg.printing :cg.progress-indicator 59 | :cg.project-window :cg.property 60 | :cg.radio-button :cg.rich-edit 61 | :cg.rich-edit-pane 62 | :cg.rich-edit-pane.clipboard 63 | :cg.rich-edit-pane.printing 64 | :cg.sample-file-menu :cg.scaling-stream 65 | :cg.scroll-bar :cg.scroll-bar-mixin 66 | :cg.scrolling-static-text :cg.selected-object 67 | :cg.shortcut-menu :cg.static-text 68 | :cg.status-bar :cg.string-dialog 69 | :cg.tab-control :cg.template-string 70 | :cg.text-edit-pane :cg.text-edit-pane.file-io 71 | :cg.text-edit-pane.mark :cg.text-or-combo 72 | :cg.text-widget :cg.timer :cg.toggling-widget 73 | :cg.toolbar :cg.tooltip :cg.trackbar :cg.tray 74 | :cg.up-down-control :cg.utility-dialog 75 | :cg.web-browser :cg.web-browser.dde 76 | :cg.wrap-string :cg.yes-no-list 77 | :cg.yes-no-string :dde) 78 | :splash-file-module (make-instance 'build-module :name "") 79 | :icon-file-module (make-instance 'build-module :name "") 80 | :include-flags (list :top-level :debugger) 81 | :build-flags (list :allow-runtime-debug) 82 | :autoload-warning nil 83 | :full-recompile-for-runtime-conditionalizations nil 84 | :include-manifest-file-for-visual-styles t 85 | :default-command-line-arguments "+M +t \"Console for Debugging\"" 86 | :additional-build-lisp-image-arguments (list :read-init-files nil) 87 | :old-space-size 256000 88 | :new-space-size 6144 89 | :runtime-build-option :standard 90 | :build-number 0 91 | :on-initialization 'default-init-function 92 | :on-restart 'do-default-restart) 93 | 94 | ;; End of Project Definition 95 | -------------------------------------------------------------------------------- /RDFS/rdf-querysample.rdf: -------------------------------------------------------------------------------- 1 | 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 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | Raphael Volz 55 | 56 | 57 | Peter Haase 58 | 59 | 60 | Andreas Eberhart 61 | 62 | 63 | Jeen Broekstra 64 | jbroeks@cs.vu.nl 65 | 66 | 67 | 68 | An Overview of RDF Query Languages 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 08 78 | 2004 79 | 80 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | Information Systems 90 | Informationsysteme 91 | 92 | 93 | 94 | 95 | Database Management 96 | Datenbankmanagement 97 | 98 | 99 | 100 | 101 | Languages 102 | Sprachen 103 | 104 | 105 | 106 | 107 | Query Languages 108 | Anfragesprachen 109 | 110 | 111 | -------------------------------------------------------------------------------- /RDFS/rdf-schema.ttl: -------------------------------------------------------------------------------- 1 | @prefix rdf: . 2 | @prefix rdfs: . 3 | @prefix owl: . 4 | @prefix dc: . 5 | 6 | rdf:type owl:Ontology . 7 | dc:title "The RDF Schema vocabulary (RDFS)" . 8 | 9 | rdfs:Resource rdf:type rdfs:Class . 10 | rdfs:Resource rdfs:isDefinedBy . 11 | rdfs:Resource rdfs:label "Resource" . 12 | rdfs:Resource rdfs:comment "The class resource, everything." . 13 | 14 | rdfs:Class rdf:type rdfs:Class . 15 | rdfs:Class rdfs:isDefinedBy . 16 | rdfs:Class rdfs:label "Class" . 17 | rdfs:Class rdfs:comment "The class of classes." . 18 | rdfs:Class rdfs:subClassOf rdfs:Resource . 19 | 20 | rdfs:subClassOf rdf:type rdf:Property . 21 | rdfs:subClassOf rdfs:isDefinedBy . 22 | rdfs:subClassOf rdfs:label "subClassOf" . 23 | rdfs:subClassOf rdfs:comment "The subject is a subclass of a class." . 24 | rdfs:subClassOf rdfs:range rdfs:Class . 25 | rdfs:subClassOf rdfs:domain rdfs:Class . 26 | 27 | rdfs:subPropertyOf rdf:type rdf:Property . 28 | rdfs:subPropertyOf rdfs:isDefinedBy . 29 | rdfs:subPropertyOf rdfs:label "subPropertyOf" . 30 | rdfs:subPropertyOf rdfs:comment "The subject is a subproperty of a property." . 31 | rdfs:subPropertyOf rdfs:range rdf:Property . 32 | rdfs:subPropertyOf rdfs:domain rdf:Property . 33 | 34 | rdfs:comment rdf:type rdf:Property . 35 | rdfs:comment rdfs:isDefinedBy . 36 | rdfs:comment rdfs:label "comment" . 37 | rdfs:comment rdfs:comment "A description of the subject resource." . 38 | rdfs:comment rdfs:domain rdfs:Resource . 39 | rdfs:comment rdfs:range rdfs:Literal . 40 | 41 | rdfs:label rdf:type rdf:Property . 42 | rdfs:label rdfs:isDefinedBy . 43 | rdfs:label rdfs:label "label" . 44 | rdfs:label rdfs:comment "A human-readable name for the subject." . 45 | rdfs:label rdfs:domain rdfs:Resource . 46 | rdfs:label rdfs:range rdfs:Literal . 47 | 48 | rdfs:domain rdf:type rdf:Property . 49 | rdfs:domain rdfs:isDefinedBy . 50 | rdfs:domain rdfs:label "domain" . 51 | rdfs:domain rdfs:comment "A domain of the subject property." . 52 | rdfs:domain rdfs:range rdfs:Class . 53 | rdfs:domain rdfs:domain rdf:Property . 54 | 55 | rdfs:range rdf:type rdf:Property . 56 | rdfs:range rdfs:isDefinedBy . 57 | rdfs:range rdfs:label "range" . 58 | rdfs:range rdfs:comment "A range of the subject property." . 59 | rdfs:range rdfs:range rdfs:Class . 60 | rdfs:range rdfs:domain rdf:Property . 61 | 62 | rdfs:seeAlso rdf:type rdf:Property . 63 | rdfs:seeAlso rdfs:isDefinedBy . 64 | rdfs:seeAlso rdfs:label "seeAlso" . 65 | rdfs:seeAlso rdfs:comment "Further information about the subject resource." . 66 | rdfs:seeAlso rdfs:range rdfs:Resource . 67 | rdfs:seeAlso rdfs:domain rdfs:Resource . 68 | 69 | rdfs:isDefinedBy rdf:type rdf:Property . 70 | rdfs:isDefinedBy rdfs:isDefinedBy . 71 | rdfs:isDefinedBy rdfs:subPropertyOf rdfs:seeAlso . 72 | rdfs:isDefinedBy rdfs:label "isDefinedBy" . 73 | rdfs:isDefinedBy rdfs:comment "The defininition of the subject resource." . 74 | rdfs:isDefinedBy rdfs:range rdfs:Resource . 75 | rdfs:isDefinedBy rdfs:domain rdfs:Resource . 76 | 77 | rdfs:Literal rdf:type rdfs:Class . 78 | rdfs:Literal rdfs:isDefinedBy . 79 | rdfs:Literal rdfs:label" Literal" . 80 | rdfs:Literal rdfs:comment "The class of literal values, eg. textual strings and integers." . 81 | rdfs:Literal rdfs:subClassOf rdfs:Resource . 82 | 83 | rdfs:Container rdf:type rdfs:Class . 84 | rdfs:Container rdfs:isDefinedBy . 85 | rdfs:Container rdfs:label "Container" . 86 | rdfs:Container rdfs:subClassOf rdfs:Resource . 87 | rdfs:Container rdfs:comment "The class of RDF containers." . 88 | 89 | rdfs:ContainerMembershipProperty rdf:type rdfs:Class . 90 | rdfs:ContainerMembershipProperty rdfs:isDefinedBy . 91 | rdfs:ContainerMembershipProperty rdfs:label "ContainerMembershipProperty" . 92 | rdfs:ContainerMembershipProperty rdfs:comment "The class of container membership properties, rdf:_1, rdf:_2, ..., 93 | all of which are sub-properties of 'member'." . 94 | rdfs:ContainerMembershipProperty rdfs:subClassOf rdf:Property . 95 | 96 | rdfs:member rdf:type rdf:Property . 97 | rdfs:member rdfs:isDefinedBy . 98 | rdfs:member rdfs:label "member" . 99 | rdfs:member rdfs:comment "A member of the subject resource." . 100 | rdfs:member rdfs:domain rdfs:Resource . 101 | rdfs:member rdfs:range rdfs:Resource . 102 | 103 | rdfs:Datatype rdf:type rdfs:Class . 104 | rdfs:Datatype rdfs:isDefinedBy . 105 | rdfs:Datatype rdfs:label "Datatype" . 106 | rdfs:Datatype rdfs:comment "The class of RDF datatypes." . 107 | rdfs:Datatype rdfs:subClassOf rdfs:Class . 108 | 109 | rdf:type rdf:Description . 110 | rdfs:seeAlso . 111 | -------------------------------------------------------------------------------- /swclos.cl: -------------------------------------------------------------------------------- 1 | ;;; -*- Mode: Lisp; Syntax: Common-Lisp -*- 2 | ;;; 3 | ;;; This system is borrowed from AIMA by Norvig, and modified by Seiji. 4 | ;;; Copyright (c) 2008 Seiji Koide 5 | 6 | ;;;; A minimal facility for defining systems of files 7 | 8 | (defparameter *doc-system-names* nil 9 | "A list of names of the systems that have been defined.") 10 | 11 | (defstruct doc-system 12 | name (requires nil) (doc "") (parts nil) (examples nil) (loaded? nil)) 13 | 14 | (defun target-system-requires (system) 15 | (loop for mod in (ds:modules system) 16 | when (get-target-system mod) 17 | collect it)) 18 | 19 | (defun target-system-parts (system) 20 | (loop for mod in (ds:modules system) 21 | when (typep mod 'ds:default-module) 22 | collect mod)) 23 | 24 | ;;;; The Top-Level Functions: 25 | 26 | (defmacro def-doc-system (name requires doc &body parts) 27 | "Define a system as a list of parts. A part can be a string, which denotes 28 | a file name; or a symbol, which denotes a (sub)system name; or a list of the 29 | form (subdirectory / part...), which means the parts are in a subdirectory. 30 | The argument is a list of systems that must be loaded before this 31 | one. Note that a documentation string is mandatory." 32 | `(add-doc-system :name ',name 33 | :requires ',requires :doc ',doc :parts ',parts)) 34 | 35 | ;;;; Support Functions 36 | 37 | (defun add-doc-system (&key name requires doc parts examples) 38 | (pushnew name *doc-system-names*) 39 | (setf (get 'doc-system name) 40 | (make-doc-system :name name :examples examples 41 | :requires requires :doc doc :parts parts))) 42 | 43 | (defun get-target-system (name) 44 | "Return the system with this name. (If argument is a system, return it.)" 45 | (cond ((typep name 'ds:default-system) name) 46 | ((symbolp name) (find-system name)) 47 | (t nil))) 48 | 49 | (defun operate-on-target-system (target part operation &key (path nil) (load t) 50 | (directory-operation #'identity)) 51 | "Perform the operation on the part (or system) and its subparts (if any). 52 | Reasonable operations are load, load-binary, compile-load, and echo. 53 | If LOAD is true, then load any required systems that are unloaded." 54 | (let (system) 55 | (cond 56 | ((typep part 'ds:default-module) (funcall operation (ds:source-pathname part))) 57 | ((stringp part) (funcall operation (target-file part :swclos :path path))) 58 | ((and (consp part) (eq (second part) '/)) 59 | (let* ((subdirectory (mklist (first part))) 60 | (new-path (append path subdirectory))) 61 | (funcall directory-operation new-path) 62 | (dolist (subpart (nthcdr 2 part)) 63 | (operate-on-target-system target subpart operation :load load 64 | :path new-path 65 | :directory-operation directory-operation)))) 66 | ((consp part) 67 | (dolist (subpart part) 68 | (operate-on-target-system target subpart operation :load load :path path 69 | :directory-operation directory-operation))) 70 | ((setf system (get-target-system part)) 71 | ;; Load the required systems, then operate on the parts 72 | (load-system system) 73 | (operate-on-target-system target (target-system-parts system) operation 74 | :load load :path path 75 | :directory-operation directory-operation)) 76 | (t (warn "Unrecognized part: ~S in path ~A" part path))))) 77 | 78 | (defun target-file (name system &key (type nil) (path nil)) 79 | "Given a file name and maybe a file type and a relative path from the 80 | target system root directory, return the right complete pathname." 81 | (make-pathname :name name :type type :defaults #+:asdf (asdf:component-pathname (asdf:find-system system)) 82 | #-:asdf (ds:default-pathname (find-system system)) 83 | :directory (append (pathname-directory #+:asdf (asdf:component-pathname (asdf:find-system system)) 84 | #-:asdf (ds:default-pathname (find-system system))) 85 | (mklist path)))) 86 | 87 | (defun mklist (x) 88 | "If x is a list, return it; otherwise return a singleton list, (x)." 89 | (if (listp x) x (list x))) 90 | 91 | ;;; ---------------------------------------------------------------------- 92 | ;;;; Definitions of Systems 93 | ;;; ---------------------------------------------------------------------- 94 | 95 | (def-doc-system :RDF () 96 | "RDF module." 97 | ("RDF" / "Utils" "RdfIO" "IRI" "packages" "Xml" "rdferror" "NameSpace" 98 | "RDFShare" "Rdf" "RdfReader" "node")) 99 | 100 | (def-doc-system :RDFS () 101 | "RDFS module." 102 | ("RDFS" / "SlotDef" "RDFboot" "GxType" "DomainRange" "RdfsObjects" "RdfsKernel" 103 | "GxForwardRef" "RdfsCore" "gxutils" "rdfwriter")) 104 | 105 | (def-doc-system :OWL (:RDFS) 106 | "OWL module." 107 | ("OWL" / "owlerror" "owlkernel" "owlsamedifferent" "owlequivalentdisjoint" "NNF" "tunify" "subsume" "OWL")) 108 | 109 | (def-doc-system :NTriple (:RDFS :OWL) 110 | "NTriple module." 111 | ("NTriple" / "ntriple" "ntparser" "ntwriter")) 112 | 113 | (def-doc-system all () 114 | "There is no difference between all and everything" 115 | RDF RDFS OWL NTriple) 116 | 117 | (def-doc-system everything () 118 | "There is no difference between all and everything" 119 | all) 120 | 121 | (setf *doc-system-names* (nreverse *doc-system-names*)) 122 | -------------------------------------------------------------------------------- /RDF/RDF.lpr: -------------------------------------------------------------------------------- 1 | ;; -*- lisp-version: "8.1 [Windows] (Nov 9, 2010 11:30)"; cg: "1.103.2.10"; -*- 2 | 3 | (in-package :cg-user) 4 | 5 | (define-project :name :RDF 6 | :modules (list (make-instance 'module :name "Utils") 7 | (make-instance 'module :name "RdfIO") 8 | (make-instance 'module :name "IRI") 9 | (make-instance 'module :name "packages") 10 | (make-instance 'module :name "Xml") 11 | (make-instance 'module :name "rdferror") 12 | (make-instance 'module :name "NameSpace") 13 | (make-instance 'module :name "Literal") 14 | (make-instance 'module :name "RDFShare") 15 | (make-instance 'module :name "RdfParser") 16 | (make-instance 'module :name "RdfReader") 17 | (make-instance 'module :name "node")) 18 | :projects nil 19 | :libraries nil 20 | :distributed-files nil 21 | :internally-loaded-files nil 22 | :project-package-name :common-graphics-user 23 | :main-form nil 24 | :compilation-unit t 25 | :verbose nil 26 | :runtime-modules (list :cg-dde-utils :cg.acache :cg.base 27 | :cg.bitmap-pane :cg.bitmap-pane.clipboard 28 | :cg.bitmap-stream :cg.button :cg.caret 29 | :cg.chart-or-plot :cg.chart-widget 30 | :cg.check-box :cg.choice-list 31 | :cg.choose-printer :cg.class-grid 32 | :cg.class-slot-grid :cg.class-support 33 | :cg.clipboard :cg.clipboard-stack 34 | :cg.clipboard.pixmap :cg.color-dialog 35 | :cg.combo-box :cg.common-control :cg.comtab 36 | :cg.cursor-pixmap :cg.curve :cg.dialog-item 37 | :cg.directory-dialog :cg.directory-dialog-os 38 | :cg.drag-and-drop :cg.drag-and-drop-image 39 | :cg.drawable :cg.drawable.clipboard 40 | :cg.dropping-outline :cg.edit-in-place 41 | :cg.editable-text :cg.file-dialog 42 | :cg.fill-texture :cg.find-string-dialog 43 | :cg.font-dialog :cg.gesture-emulation 44 | :cg.get-pixmap :cg.get-position 45 | :cg.graphics-context :cg.grid-widget 46 | :cg.grid-widget.drag-and-drop :cg.group-box 47 | :cg.header-control :cg.hotspot :cg.html-dialog 48 | :cg.html-widget :cg.icon :cg.icon-pixmap 49 | :cg.ie :cg.item-list :cg.keyboard-shortcuts 50 | :cg.lamp :cg.lettered-menu :cg.lisp-edit-pane 51 | :cg.lisp-text :cg.lisp-widget :cg.list-view 52 | :cg.mci :cg.menu :cg.menu.tooltip 53 | :cg.message-dialog 54 | :cg.multi-line-editable-text 55 | :cg.multi-line-lisp-text 56 | :cg.multi-picture-button 57 | :cg.multi-picture-button.drag-and-drop 58 | :cg.multi-picture-button.tooltip 59 | :cg.object-editor :cg.object-editor.layout 60 | :cg.ocx :cg.os-widget :cg.os-window 61 | :cg.outline :cg.outline.drag-and-drop 62 | :cg.outline.edit-in-place :cg.palette 63 | :cg.paren-matching :cg.picture-widget 64 | :cg.picture-widget.palette :cg.pixmap 65 | :cg.pixmap-widget :cg.pixmap.file-io 66 | :cg.pixmap.printing :cg.pixmap.rotate 67 | :cg.plot-widget :cg.printing 68 | :cg.progress-indicator :cg.project-window 69 | :cg.property :cg.radio-button :cg.rich-edit 70 | :cg.rich-edit-pane 71 | :cg.rich-edit-pane.clipboard 72 | :cg.rich-edit-pane.printing 73 | :cg.sample-file-menu :cg.scaling-stream 74 | :cg.scroll-bar :cg.scroll-bar-mixin 75 | :cg.scrolling-static-text :cg.selected-object 76 | :cg.shortcut-menu :cg.static-text 77 | :cg.status-bar :cg.string-dialog 78 | :cg.tab-control :cg.template-string 79 | :cg.text-edit-pane :cg.text-edit-pane.file-io 80 | :cg.text-edit-pane.mark :cg.text-or-combo 81 | :cg.text-widget :cg.timer :cg.toggling-widget 82 | :cg.toolbar :cg.tooltip :cg.trackbar :cg.tray 83 | :cg.up-down-control :cg.utility-dialog 84 | :cg.web-browser :cg.web-browser.dde 85 | :cg.wrap-string :cg.yes-no-list 86 | :cg.yes-no-string :dde) 87 | :splash-file-module (make-instance 'build-module :name "") 88 | :icon-file-module (make-instance 'build-module :name "") 89 | :include-flags (list :top-level :debugger) 90 | :build-flags (list :allow-runtime-debug) 91 | :autoload-warning nil 92 | :full-recompile-for-runtime-conditionalizations nil 93 | :include-manifest-file-for-visual-styles t 94 | :default-command-line-arguments "+M +t \"Console for Debugging\"" 95 | :additional-build-lisp-image-arguments (list :read-init-files nil) 96 | :old-space-size 256000 97 | :new-space-size 6144 98 | :runtime-build-option :standard 99 | :build-number 0 100 | :on-initialization 'default-init-function 101 | :on-restart 'do-default-restart) 102 | 103 | ;; End of Project Definition 104 | -------------------------------------------------------------------------------- /RDF/node.cl: -------------------------------------------------------------------------------- 1 | ;;;-*- Mode: common-lisp; syntax: common-lisp; package: gx; base: 10 -*- 2 | ;;; 3 | ;;; RDF Node module 4 | ;;; 5 | 6 | (cl:provide :rdfnode) 7 | 8 | (defpackage :gx 9 | (:export name mclasses)) 10 | (in-package :gx) 11 | 12 | ;;;; gnode & rdf-node 13 | ;;; rdf-node will be a superclass of rdfs:Class. 14 | ;;; gnode will be a superclass of rdfs:Resource. 15 | ;;; gnode class is needed for registration of class-instance relation. 16 | 17 | (defclass rdf-node (standard-class) 18 | ((direct-instances :initarg :direct-instances 19 | :initform nil 20 | :accessor class-direct-instances)) 21 | (:documentation "This metaclass is node class. This metaclass provides method class-direct-instances")) 22 | 23 | (defclass gnode () 24 | ((excl::name :initarg :name :initform nil) 25 | (iri :initarg :iri :initform nil :accessor iri) 26 | ;(mclasses :initarg :mclasses :initform nil :accessor mclasses) 27 | (type-tag :initform nil :accessor type-tag) 28 | ;(inv-plist :initform nil) 29 | ) 30 | (:metaclass rdf-node) 31 | (:documentation "This class provides the concept of RDF graph.")) 32 | 33 | (defmethod mclasses ((instance gnode)) 34 | "returns multiple classes of . This function returns length=1 list for single class." 35 | (labels ((get-bright-supers (super) 36 | (cond ((not (shadowed-class-p super)) (list super)) 37 | (t (mapcan #'get-bright-supers (mop:class-direct-superclasses super)))))) 38 | (let ((class (class-of instance))) 39 | (cond ((shadowed-class-p class) 40 | (remove-duplicates (mapcan #'get-bright-supers (mop:class-direct-superclasses class)))) 41 | (t (list class)))))) 42 | 43 | ;;; An element of direct-instances slot are initially stored by method 44 | ;;; and maintained by which is invoked by 45 | ;;; change-class. 46 | 47 | (defmethod make-instance ((class rdf-node) &rest initargs) 48 | (declare (ignore initargs)) 49 | (let ((instance (call-next-method))) 50 | (push instance (class-direct-instances class)) 51 | instance)) 52 | 53 | (defun shadowed-class-p (x) 54 | "returns true if is an instance of shadowed class. 55 | shadowed-class is defined at RdfsObjects file." 56 | (eq (class-name (class-of x)) 'shadowed-class)) 57 | 58 | (defmethod update-instance-for-different-class :after ((previous gnode) current &rest initargs) 59 | (declare (ignore initargs)) 60 | (cond ((cl:typep current 'destroyed-class) 61 | (let ((old-class (class-of previous))) 62 | (setf (class-direct-instances old-class) 63 | (remove current (class-direct-instances old-class) :test #'eq)) 64 | )) 65 | (t (let ((old-class (class-of previous)) 66 | (new-class (class-of current))) 67 | ;; domain constraint should be satisfied, if old-class was satisfied. 68 | ;; class direct instances handling 69 | (setf (class-direct-instances old-class) 70 | (remove current (class-direct-instances old-class) :test #'eq)) 71 | (push current (class-direct-instances new-class)) 72 | )))) 73 | 74 | (defun node-p (x) 75 | (cl:typep x 'gnode)) 76 | 77 | (defun bnode-p (node) 78 | (or (not (slot-value node 'excl::name)) 79 | (not (symbol-package (slot-value node 'excl::name))))) 80 | 81 | (defmethod ground? ((node gnode)) 82 | (and (slot-value node 'excl::name) 83 | (symbol-package (slot-value node 'excl::name)))) 84 | 85 | (defmethod name ((node symbol)) 86 | node) 87 | 88 | (defmethod name ((node gnode)) 89 | "returns a QName or a nodeID of , if it exists. Otherwise nil." 90 | (let ((name (slot-value node 'excl::name))) 91 | (when (and name (symbol-package name)) name))) ; name might have uninterned symbol. 92 | 93 | (defmethod (setf name) (symbol (node gnode)) 94 | "exports for QName." 95 | (setf (slot-value node 'excl::name) symbol) 96 | (export-as-QName symbol) 97 | (setf (symbol-value symbol) node)) 98 | 99 | (defmethod shared-initialize :after ((instance gnode) slot-names &rest initargs) 100 | (cond ((and (null slot-names) (null initargs)) ; when change-class 101 | ) 102 | ((and (consp slot-names) (null initargs)) ; when propagated 103 | ) 104 | (t ; first or redefinition 105 | (let ((name (getf initargs :name))) 106 | (when name 107 | (when (nodeID? name) 108 | (setf (slot-value instance 'excl::name) nil)) 109 | (export-as-QName name) 110 | (setf (symbol-value name) instance)))))) 111 | 112 | 113 | ;;; 114 | ;;;; NodeID 115 | ;;; 116 | ;;; A nodeID is an exorted symbol in package "_". See the following example. 117 | ;;; ---------------------------------------------------------------------------------- 118 | ;;; (nodeID2symbol "abc") -> _:abc 119 | ;;; (make-unique-nodeID "abc") -> _:abc0 120 | ;;; ---------------------------------------------------------------------------------- 121 | (defun nodeID? (name) 122 | "Is this a nodeID?" 123 | (declare (optimize (speed 3) (safety 1))) 124 | (and (symbol-package name) 125 | (string= "_" (package-name (symbol-package name))))) 126 | 127 | (defun nodeID2symbol (str) 128 | (declare (optimize (speed 3) (safety 1))) 129 | "simply transforms to a exported symbol in anonymous node package :_ 130 | and returns it." 131 | (let ((nodeID (intern str :_))) 132 | (export nodeID (find-package :_)) 133 | nodeID)) 134 | 135 | (defun make-unique-nodeID (str) 136 | (declare (optimize (speed 3) (safety 1))) 137 | "makes a unique node ID from . Namely, adds numbers at the end of and makes unique symbol." 138 | (let ((symbol (gentemp str :_))) 139 | (export symbol (find-package :_)) 140 | symbol)) -------------------------------------------------------------------------------- /utilities/infix.cl: -------------------------------------------------------------------------------- 1 | ;;; -*- Mode: common-lisp; syntax: common-lisp; package: gx; base: 10 -*- 2 | ;;; 3 | ;;; Infix to Prefix transformation module 4 | ;;; 5 | ;;; This program is borrowed from AIMA 6 | ;;; 2008 (c) Seiji Koide 7 | ;;; 8 | ;;; History 9 | ;;; ------- 10 | ;;; 2008.03.25 File created. 11 | 12 | (cl:defpackage :gx 13 | (:shadow nil first rest member type typep type-of subtypep) 14 | (:use :common-lisp) 15 | ) 16 | 17 | (in-package :gx) 18 | 19 | ;;;; Prefix to Infix Conversion 20 | 21 | (defparameter *infix-ops* 22 | '((([ list match ]) ({ elts match }) (|(| nil match |)|)) 23 | ((*) (/)) 24 | ((+) (-)) 25 | ((<) (>) (<=) (>=) (=) (/=)) 26 | ((not not unary) (~ not unary)) 27 | ((and) (& and) (^ and)) 28 | ((or) (\| or)) 29 | ((=>)) 30 | ((<=>)) 31 | ((|,|))) 32 | "A list of lists of operators, highest precedence first.") 33 | 34 | (defun ->prefix (infix) 35 | "Convert an infix expression to prefix." 36 | (when (stringp infix) (setf infix (string->infix infix))) 37 | ;; INFIX is a list of elements; each one is in prefix notation. 38 | ;; Keep reducing (most tightly bound first) until there is only one 39 | ;; element left in the list. Example: In two reductions we go: 40 | ;; (a + b * c) => (a + (* b c)) => ((+ a (* b c))) 41 | (loop 42 | (when (not (length>1 infix)) (return (cl:first infix))) 43 | (setf infix (reduce-infix infix)))) 44 | 45 | (defun reduce-infix (infix) 46 | "Find the highest-precedence operator in INFIX and reduce accordingly." 47 | (dolist (ops *infix-ops* (error "Bad syntax for infix expression: ~S" infix)) 48 | (let* ((pos (position-if #'(lambda (i) (assoc i ops)) infix 49 | :from-end (eq (op-type (cl:first ops)) 'match))) 50 | (op (when pos (assoc (elt infix pos) ops)))) 51 | (when pos 52 | (return 53 | (case (op-type op) 54 | (match (reduce-matching-op op pos infix)) 55 | (unary (replace-subseq infix pos 2 56 | (list (op-name op) 57 | (elt infix (+ pos 1))))) 58 | (binary (replace-subseq infix (- pos 1) 3 59 | (list (op-name op) 60 | (elt infix (- pos 1)) 61 | (elt infix (+ pos 1))))) 62 | ; by seiji 63 | (otherwise (replace-subseq infix (- pos 1) 3 64 | (list (op-name op) 65 | (elt infix (- pos 1)) 66 | (elt infix (+ pos 1))))))))))) 67 | 68 | (defun op-token (op) (cl:first op)) 69 | (defun op-name (op) (or (second op) (cl:first op))) 70 | (defun op-type (op) (or (third op) 'BINARY)) 71 | (defun op-match (op) (fourth op)) 72 | 73 | (defun replace-subseq (sequence start length new) 74 | (nconc (subseq sequence 0 start) (list new) 75 | (subseq sequence (+ start length)))) 76 | 77 | (defun reduce-matching-op (op pos infix) 78 | "Find the matching op (paren or bracket) and reduce." 79 | ;; Note we don't worry about nested parens because we search :from-end 80 | (let* ((end (position (op-match op) infix :start pos)) 81 | (len (+ 1 (- end pos))) 82 | (inside-parens (remove-commas (->prefix (subseq infix (+ pos 1) end))))) 83 | (cond ((not (eq (op-name op) '|(|)) ;; handle {a,b} or [a,b] 84 | (replace-subseq infix pos len 85 | (cons (op-name op) inside-parens))) ; {set} 86 | ((and (> pos 0) ;; handle f(a,b) 87 | (function-symbol? (elt infix (- pos 1)))) 88 | (handle-quantifiers 89 | (replace-subseq infix (- pos 1) (+ len 1) 90 | (cons (elt infix (- pos 1)) inside-parens)))) 91 | (t ;; handle (a + b) 92 | (assert (length=1 inside-parens)) 93 | (replace-subseq infix pos len (cl:first inside-parens)))))) 94 | 95 | (defun remove-commas (exp) 96 | "Convert (|,| a b) to (a b)." 97 | (cond ((eq (op exp) '|,|) (nconc (remove-commas (arg1 exp) ) 98 | (remove-commas (arg2 exp)))) 99 | (t (list exp)))) 100 | 101 | (defun handle-quantifiers (exp) 102 | "Change (FORALL x y P) to (FORALL (x y) P)." 103 | (if (cl:member (op exp) '(forall exists)) 104 | `(,(op exp) ,(butlast (cl:rest exp)) ,(last1 exp)) 105 | exp)) 106 | 107 | ;;;; Tokenization: convert a string to a sequence of tokens 108 | 109 | (defun string->infix (string &optional (start 0)) 110 | "Convert a string to a list of tokens." 111 | (multiple-value-bind (token i) (parse-infix-token string start) 112 | (cond ((null token) cl:nil) 113 | ((null i) (list token)) 114 | (t (cons token (string->infix string i)))))) 115 | 116 | (defun parse-infix-token (string start) 117 | "Return the first token in string and the position after it, or nil." 118 | (let* ((i (position-if-not #'whitespace? string :start start)) 119 | (ch (if i (char string i)))) 120 | (cond ((null i) (values cl:nil cl:nil)) 121 | ((find ch "+-~()[]{},") (values (intern (string ch)) (+ i 1))) 122 | ((find ch "0123456789") (parse-integer string :start i :junk-allowed t)) 123 | ((symbol-char? ch) (parse-span string #'symbol-char? i)) 124 | ((operator-char? ch) (parse-span string #'operator-char? i)) 125 | (t (error "unexpected character: ~C" ch))))) 126 | 127 | (defun parse-span (string pred i) 128 | (let ((j (position-if-not pred string :start i))) 129 | (values (make-logic-symbol (subseq string i j)) j))) 130 | 131 | (defun make-logic-symbol (string) 132 | "Convert string to symbol, preserving case, except for AND/OR/NOT/FORALL/EXISTS." 133 | (cond ((find string '(and or not forall exists) :test #'string-equal)) 134 | ((lower-case-p (char string 0)) 135 | (concat-symbol "$" string)) ; by seiji 136 | ((equal string "Nil") '|Nil|) 137 | (t (intern string)))) ; by seiji 138 | 139 | (defun operator-char? (x) (find x "<=>&^|*/,")) 140 | 141 | (defun symbol-char? (x) (or (alphanumericp x) (find x "$!?%"))) 142 | 143 | (defun function-symbol? (x) 144 | (and (symbolp x) (not (cl:member x '(and or not ||))) 145 | (alphanumericp (char (string x) 0)))) 146 | 147 | (defun whitespace? (ch) 148 | (find ch " 149 | ")) 150 | -------------------------------------------------------------------------------- /utilities/infix.lisp: -------------------------------------------------------------------------------- 1 | ;;;-*- mode: common-lisp; syntax: common-lisp; package: gx; base: 10 -*- 2 | ;;; 3 | ;;; Infix to Prefix transformation module 4 | ;;; 5 | ;;; This program is borrowed from AIMA 6 | ;;; 2008 (c) Seiji Koide 7 | ;;; 8 | ;;; History 9 | ;;; ------- 10 | ;;; 2008.03.25 File created. 11 | 12 | (defpackage :swp 13 | (:shadowing-import-from :gx "type-of" "subtypep" "typep") 14 | (:shadowing-import-from :cl "first" "rest" "nil" "member") 15 | (:use :common-lisp :gx) 16 | ) 17 | 18 | (eval-when (:execute :load-toplevel :compile-toplevel) 19 | ) ; end of eval-when 20 | 21 | (in-package :gx) 22 | 23 | ;;;; Prefix to Infix Conversion 24 | 25 | (defparameter *infix-ops* 26 | '((([ list match ]) ({ elts match }) (|(| nil match |)|)) 27 | ((*) (/)) 28 | ((+) (-)) 29 | ((<) (>) (<=) (>=) (=) (/=)) 30 | ((not not unary) (~ not unary)) 31 | ((and) (& and) (^ and)) 32 | ((or) (\| or)) 33 | ((=>)) 34 | ((<=>)) 35 | ((|,|))) 36 | "A list of lists of operators, highest precedence first.") 37 | 38 | (defun ->prefix (infix) 39 | "Convert an infix expression to prefix." 40 | (when (stringp infix) (setf infix (string->infix infix))) 41 | ;; INFIX is a list of elements; each one is in prefix notation. 42 | ;; Keep reducing (most tightly bound first) until there is only one 43 | ;; element left in the list. Example: In two reductions we go: 44 | ;; (a + b * c) => (a + (* b c)) => ((+ a (* b c))) 45 | (loop 46 | (when (not (length>1 infix)) (return (cl:first infix))) 47 | (setf infix (reduce-infix infix)))) 48 | 49 | (defun reduce-infix (infix) 50 | "Find the highest-precedence operator in INFIX and reduce accordingly." 51 | (dolist (ops *infix-ops* (error "Bad syntax for infix expression: ~S" infix)) 52 | (let* ((pos (position-if #'(lambda (i) (assoc i ops)) infix 53 | :from-end (eq (op-type (cl:first ops)) 'match))) 54 | (op (when pos (assoc (elt infix pos) ops)))) 55 | (when pos 56 | (return 57 | (case (op-type op) 58 | (match (reduce-matching-op op pos infix)) 59 | (unary (replace-subseq infix pos 2 60 | (list (op-name op) 61 | (elt infix (+ pos 1))))) 62 | (binary (replace-subseq infix (- pos 1) 3 63 | (list (op-name op) 64 | (elt infix (- pos 1)) 65 | (elt infix (+ pos 1))))) 66 | ; by seiji 67 | (otherwise (replace-subseq infix (- pos 1) 3 68 | (list (op-name op) 69 | (elt infix (- pos 1)) 70 | (elt infix (+ pos 1))))))))))) 71 | 72 | (defun op-token (op) (cl:first op)) 73 | (defun op-name (op) (or (second op) (cl:first op))) 74 | (defun op-type (op) (or (third op) 'BINARY)) 75 | (defun op-match (op) (fourth op)) 76 | 77 | (defun replace-subseq (sequence start length new) 78 | (nconc (subseq sequence 0 start) (list new) 79 | (subseq sequence (+ start length)))) 80 | 81 | (defun reduce-matching-op (op pos infix) 82 | "Find the matching op (paren or bracket) and reduce." 83 | ;; Note we don't worry about nested parens because we search :from-end 84 | (let* ((end (position (op-match op) infix :start pos)) 85 | (len (+ 1 (- end pos))) 86 | (inside-parens (remove-commas (->prefix (subseq infix (+ pos 1) end))))) 87 | (cond ((not (eq (op-name op) '|(|)) ;; handle {a,b} or [a,b] 88 | (replace-subseq infix pos len 89 | (cons (op-name op) inside-parens))) ; {set} 90 | ((and (> pos 0) ;; handle f(a,b) 91 | (function-symbol? (elt infix (- pos 1)))) 92 | (handle-quantifiers 93 | (replace-subseq infix (- pos 1) (+ len 1) 94 | (cons (elt infix (- pos 1)) inside-parens)))) 95 | (t ;; handle (a + b) 96 | (assert (length=1 inside-parens)) 97 | (replace-subseq infix pos len (cl:first inside-parens)))))) 98 | 99 | (defun remove-commas (exp) 100 | "Convert (|,| a b) to (a b)." 101 | (cond ((eq (op exp) '|,|) (nconc (remove-commas (arg1 exp) ) 102 | (remove-commas (arg2 exp)))) 103 | (t (list exp)))) 104 | 105 | (defun handle-quantifiers (exp) 106 | "Change (FORALL x y P) to (FORALL (x y) P)." 107 | (if (cl:member (op exp) '(forall exists)) 108 | `(,(op exp) ,(butlast (cl:rest exp)) ,(last1 exp)) 109 | exp)) 110 | 111 | ;;;; Tokenization: convert a string to a sequence of tokens 112 | 113 | (defun string->infix (string &optional (start 0)) 114 | "Convert a string to a list of tokens." 115 | (multiple-value-bind (token i) (parse-infix-token string start) 116 | (cond ((null token) cl:nil) 117 | ((null i) (list token)) 118 | (t (cons token (string->infix string i)))))) 119 | 120 | (defun parse-infix-token (string start) 121 | "Return the first token in string and the position after it, or nil." 122 | (let* ((i (position-if-not #'whitespace? string :start start)) 123 | (ch (if i (char string i)))) 124 | (cond ((null i) (values cl:nil cl:nil)) 125 | ((find ch "+-~()[]{},") (values (intern (string ch)) (+ i 1))) 126 | ((find ch "0123456789") (parse-integer string :start i :junk-allowed t)) 127 | ((symbol-char? ch) (parse-span string #'symbol-char? i)) 128 | ((operator-char? ch) (parse-span string #'operator-char? i)) 129 | (t (error "unexpected character: ~C" ch))))) 130 | 131 | (defun parse-span (string pred i) 132 | (let ((j (position-if-not pred string :start i))) 133 | (values (make-logic-symbol (subseq string i j)) j))) 134 | 135 | (defun make-logic-symbol (string) 136 | "Convert string to symbol, preserving case, except for AND/OR/NOT/FORALL/EXISTS." 137 | (cond ((find string '(and or not forall exists) :test #'string-equal)) 138 | ((lower-case-p (char string 0)) 139 | (concat-symbol "$" string)) ; by seiji 140 | ((equal string "Nil") '|Nil|) 141 | (t (intern string)))) ; by seiji 142 | 143 | (defun operator-char? (x) (find x "<=>&^|*/,")) 144 | 145 | (defun symbol-char? (x) (or (alphanumericp x) (find x "$!?%"))) 146 | 147 | (defun function-symbol? (x) 148 | (and (symbolp x) (not (cl:member x '(and or not ||))) 149 | (alphanumericp (char (string x) 0)))) 150 | 151 | (defun whitespace? (ch) 152 | (find ch " 153 | ")) 154 | -------------------------------------------------------------------------------- /OWL/NNF.cl: -------------------------------------------------------------------------------- 1 | ;;;-*- Mode: common-lisp; syntax: common-lisp; package: gx; base: 10 -*- 2 | ;;; 3 | ;;;; NNF transformation module 4 | ;;; 5 | ;;; This program is borrowed from AIMA 6 | ;;; 2008, 2009 (c) Seiji Koide 7 | ;;; 8 | ;; History 9 | ;; ------- 10 | ;; 2008.08.18 move-not-inwards, conjunction, disjunction, make-exp, op, args, arg1, arg2 are moved to GxType 11 | ;; 2008.03.15 File created. 12 | 13 | (cl:defpackage :gx 14 | (:export "variable?") 15 | ) 16 | 17 | (in-package :gx) 18 | 19 | ;;............................................................................................. 20 | ;; 21 | ;; Convert Expressions to Normal Form from AIMA 22 | ;; 23 | 24 | (defun conjuncts (sentence) 25 | "Return a list of the conjuncts in this sentence." 26 | (cond ((eq (op sentence) 'and) (args sentence)) 27 | ((eq sentence 't) nil) 28 | (t (list sentence)))) 29 | 30 | (defun disjuncts (sentence) 31 | "Return a list of the disjuncts in this sentence." 32 | (cond ((eq (op sentence) 'or) (args sentence)) 33 | ((eq sentence nil) nil) 34 | (t (list sentence)))) 35 | 36 | (defconstant +logical-connectives+ '(and or not => <=>)) 37 | (defconstant +logical-quantifiers+ '(forall exists)) 38 | 39 | (defun atomic-clause? (sentence) 40 | "An atomic clause has no connectives or quantifiers." 41 | (not (or (member (op sentence) +logical-connectives+) 42 | (member (op sentence) +logical-quantifiers+)))) 43 | 44 | (defun literal-clause? (sentence) 45 | "A literal is an atomic clause or a negated atomic clause." 46 | (or (atomic-clause? sentence) 47 | (and (negative-clause? sentence) (atomic-clause? (arg1 sentence))))) 48 | 49 | (defun negative-clause? (sentence) 50 | "A negative clause has NOT as the operator." 51 | (eq (op sentence) 'not)) 52 | 53 | (defun merge-disjuncts (disjuncts) 54 | "Return a CNF expression for the disjunction." 55 | ;; The argument is a list of disjuncts, each in CNF. 56 | ;; The second argument is a list of conjuncts built so far. 57 | (case (length disjuncts) 58 | (0 'nil) ; seiji 59 | (1 (first disjuncts)) 60 | (t (conjunction 61 | (let ((result ())) 62 | (loop for y in (conjuncts (merge-disjuncts (rest disjuncts))) do 63 | (loop for x in (conjuncts (first disjuncts)) do 64 | (push (disjunction (append (disjuncts x) (disjuncts y))) 65 | result))) 66 | (nreverse result)))))) 67 | 68 | (defun eliminate-implications (p) 69 | (if (literal-clause? p) p 70 | (case (op p) 71 | (=> `(or ,(arg2 p) (not ,(arg1 p)))) 72 | (<=> `(and (or ,(arg1 p) (not ,(arg2 p))) 73 | (or (not ,(arg1 p)) ,(arg2 p)))) 74 | (t (cons (op p) (mapcar #'eliminate-implications (args p))))))) 75 | 76 | (defun has-variable? (p) 77 | (cond ((null p) nil) 78 | ((consp p) (some #'has-variable? p)) 79 | (t (variable? p)))) 80 | 81 | ;; in order to check the disjointness, conjuncitive normal form should be. 82 | (defun ->cnf (p &optional vars) 83 | "Convert a sentence p to conjunctive normal form [p 279-280]." 84 | ;; That is, return (and (or ...) ...) where 85 | ;; each of the conjuncts has all literal disjuncts. 86 | ;; VARS is a list of universally quantified variables that P is in scope of. 87 | (setf p (eliminate-implications (logic p))) 88 | (case (op p) 89 | (not (let ((p2 (move-not-inwards (arg1 p)))) 90 | (if (literal-clause? p2) p2 (->cnf p2 vars)))) 91 | (and (conjunction (mappend #'(lambda (q) (conjuncts (->cnf q vars))) (args p)))) 92 | (or (merge-disjuncts (mapcar #'(lambda (q) (->cnf q vars)) (args p)))) 93 | (forall (let ((new-vars (mapcar #'new-variable (mklist (arg1 p))))) 94 | (->cnf (sublis (mapcar #'cons (mklist (arg1 p)) new-vars) 95 | (arg2 p)) 96 | (append new-vars vars)))) 97 | (exists (->cnf (skolemize (arg2 p) (arg1 p) vars) vars)) 98 | (t p) ; p is atomic 99 | )) 100 | 101 | (defun ->inf (p) 102 | "Convert a sentence p to implicative normal form [p 282]." 103 | (conjunction (mapcar #'cnf1->inf1 (conjuncts (->cnf p))))) 104 | 105 | (defun cnf1->inf1 (p) 106 | ;; P is of the form (or (not a) (not b) ... c d ...) 107 | ;; Convert to: (=> (and a b ...) (or c d ...)) 108 | ;; where a,b,c,d ... are positive atomic clauses 109 | (let ((lhs (mapcar #'arg1 (remove-if-not #'negative-clause? (disjuncts p)))) 110 | (rhs (remove-if #'negative-clause? (disjuncts p)))) 111 | `(=> ,(conjunction lhs) ,(disjunction rhs)))) 112 | 113 | (defun logic (sentence) 114 | "Canonicalize a sentence into proper logical form." 115 | (cond ((stringp sentence) (->prefix sentence)) 116 | (t sentence))) 117 | 118 | ;; 119 | ;; 120 | ;; 121 | 122 | (defvar *new-variable-counter* 0) 123 | 124 | (defun variable? (x) 125 | "Is x a variable (a symbol starting with ?)?" 126 | (and (symbolp x) (eql (char (symbol-name x) 0) #\?))) 127 | 128 | (defun new-variable (var) 129 | "Create a new variable. Assumes user never types variables of form $X.9" 130 | (concat-symbol (if (variable? var) "" "?") 131 | var "." (incf *new-variable-counter*))) 132 | 133 | (defun concat-symbol (&rest args) 134 | "Concatenate the args into one string, and turn that into a symbol." 135 | (intern (format nil "~{~a~}" args))) 136 | 137 | (defun skolemize (p vars outside-vars) 138 | "Within the proposition P, replace each of VARS with a skolem constant, 139 | or if OUTSIDE-VARS is non-null, a skolem function of them." 140 | (sublis (mapcar #'(lambda (var) 141 | (cons var (if (null outside-vars) 142 | (skolem-constant var) 143 | (cons (skolem-constant var) outside-vars)))) 144 | (mklist vars)) 145 | p)) 146 | 147 | (defun skolem-constant (name) 148 | "Return a unique skolem constant, a symbol starting with '$'." 149 | (intern (format nil "$~A_~D" name (incf *new-variable-counter*)))) 150 | 151 | ;;; 152 | ;;; Followings are by Seiji 153 | ;;; 154 | 155 | (defun skolem-constant-p (x) 156 | (and (symbolp x) (char= (char (string x) 0) #\$))) 157 | 158 | (defun skolem-p (x) 159 | (or (and (consp x) (skolem-constant-p (first x))) 160 | (skolem-constant-p x))) 161 | 162 | (defun unskolemize (sk) 163 | (cond ((consp sk) 164 | (let ((skstr (string (car sk)))) 165 | (values (cdr sk) (intern (subseq skstr 1 (position #\_ skstr)))))) 166 | (t (let ((skstr (string sk))) 167 | (values nil (intern (subseq skstr 1 (position #\_ skstr)))))))) 168 | -------------------------------------------------------------------------------- /RDFS/rdf-schema.rdf: -------------------------------------------------------------------------------- 1 | 6 | 7 | 10 | 11 | 12 | 13 | Resource 14 | The class resource, everything. 15 | 16 | 17 | 18 | 19 | Class 20 | The class of classes. 21 | 22 | 23 | 24 | 25 | 26 | subClassOf 27 | The subject is a subclass of a class. 28 | 29 | 30 | 31 | 32 | 33 | 34 | subPropertyOf 35 | The subject is a subproperty of a property. 36 | 37 | 38 | 39 | 40 | 41 | 42 | comment 43 | A description of the subject resource. 44 | 45 | 46 | 47 | 48 | 49 | 50 | label 51 | A human-readable name for the subject. 52 | 53 | 54 | 55 | 56 | 57 | 58 | domain 59 | A domain of the subject property. 60 | 61 | 62 | 63 | 64 | 65 | 66 | range 67 | A range of the subject property. 68 | 69 | 70 | 71 | 72 | 73 | 74 | seeAlso 75 | Further information about the subject resource. 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | isDefinedBy 84 | The defininition of the subject resource. 85 | 86 | 87 | 88 | 89 | 90 | 91 | Literal 92 | The class of literal values, eg. textual strings and integers. 93 | 94 | 95 | 96 | 97 | 98 | Container 99 | 100 | The class of RDF containers. 101 | 102 | 103 | 104 | 105 | ContainerMembershipProperty 106 | The class of container membership properties, rdf:_1, rdf:_2, ..., 107 | all of which are sub-properties of 'member'. 108 | 109 | 110 | 111 | 112 | 113 | member 114 | A member of the subject resource. 115 | 116 | 117 | 118 | 119 | 120 | 121 | Datatype 122 | The class of RDF datatypes. 123 | 124 | 125 | 126 | 127 | 128 | 129 | 130 | 131 | -------------------------------------------------------------------------------- /RDF/22-rdf-syntax-ns.rdf: -------------------------------------------------------------------------------- 1 | 6 | 7 | 9 | The RDF Vocabulary (RDF) 10 | This is the RDF Schema for the RDF vocabulary defined in the RDF namespace. 11 | 12 | 13 | 14 | 15 | type 16 | The subject is an instance of a class. 17 | 18 | 19 | 20 | 21 | 22 | 23 | Property 24 | The class of RDF properties. 25 | 26 | 27 | 28 | 29 | 30 | Statement 31 | 32 | The class of RDF statements. 33 | 34 | 35 | 36 | 37 | subject 38 | The subject of the subject RDF statement. 39 | 40 | 41 | 42 | 43 | 44 | 45 | predicate 46 | The predicate of the subject RDF statement. 47 | 48 | 49 | 50 | 51 | 52 | 53 | object 54 | The object of the subject RDF statement. 55 | 56 | 57 | 58 | 59 | 60 | 61 | Bag 62 | The class of unordered containers. 63 | 64 | 65 | 66 | 67 | 68 | Seq 69 | The class of ordered containers. 70 | 71 | 72 | 73 | 74 | 75 | Alt 76 | The class of containers of alternatives. 77 | 78 | 79 | 80 | 81 | 82 | value 83 | Idiomatic property used for structured values. 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | List 93 | The class of RDF Lists. 94 | 95 | 96 | 97 | 98 | 99 | nil 100 | The empty list, with no items in it. If the rest of a list is nil then the list has no more items in it. 101 | 102 | 103 | 104 | 105 | first 106 | The first item in the subject RDF list. 107 | 108 | 109 | 110 | 111 | 112 | 113 | rest 114 | The rest of the subject RDF list after the first item. 115 | 116 | 117 | 118 | 119 | 120 | 121 | 122 | XMLLiteral 123 | The class of XML literal values. 124 | 125 | 126 | 127 | 128 | 129 | 130 | 131 | 132 | -------------------------------------------------------------------------------- /Manual/index.htm: -------------------------------------------------------------------------------- 1 | 2 | SWCLOS User's Manual 3 | 4 | 5 | 6 | 80 | 81 | 82 | 83 |
84 | 85 |

SWCLOS User's Manual

86 |
87 | 88 |

This document is a revised version of NII Technical Report 90 | (NII-2009-014E).

91 |

Table of Contents

92 |
    93 |
  1. Introduction 95 | 96 |
    97 |
  2. 98 |
  3. SWCLOS Basics 100 |
    101 |
    2.1  How to Get SWCLOS
    102 |
    103 |
    2.2  Proprietary Rights
    104 |
    105 |
    2.3  How to Start SWCLOS
    106 |
    107 |
    2.4  Monotonicity of Knowledge
    108 |
    109 |
    2.5  Open World Assumption and Three-Value Logic
  4. 110 |
  5. URI, 112 | QName, and Resource 113 |
    114 |
    3.1  URI
    115 |
    116 |
    3.2  QName
    117 |
    118 |
    3.3  URI Namedspace
    119 |
    120 |
    3.4  Resource
    121 |
    122 |
    3.5  NodeID
  6. 123 |
  7. RDF 125 | Resource Objects 126 |
    127 |
    4.1  Resource Objects and the Syntax in S-expression
    128 |
    129 |
    4.2  Adding and Getting a Resource Form
  8. 130 |
  9. RDFS 131 | Vocabularies and Semantics 132 |
    133 |
    5.1  Resource Classes, Metaclasses, and Instances
    134 |
    135 |
    5.2  rdf:type and rdfs:subClassOf
    136 |
    137 |
    5.3  rdfs:subPropertyOf
    138 |
    139 |
    5.4  Properties and Slots
    140 |
    141 |
    5.5  Adding Resource Objects
    142 |
    143 |
    5.6  Adding Slots
    144 |
    145 |
    5.7  Adding Slot Values
    146 |
    147 |
    5.8  Adding Multiple Types
    148 |
    149 |
    5.9  Extension of Property and Slot Definition
  10. 150 |
  11. String, 152 | Number, Datatype, and Lang 153 |
    154 |
    6.1  Literal
    155 |
    156 |
    6.2  XSD Datatypes in SWCLOS
    157 |
    158 |
    6.3  xml:lang in SWCLOS
  12. 159 |
  13. RDF 161 | Collection 162 |
    163 |
    7.1  RDF Container
    164 |
    165 |
    7.2  List
  14. 166 |
  15. Domain 168 | and Range 169 |
    170 |
    8.1  Adding Domain and Range Constraints
    171 |
    172 |
    8.2  Domain and Range Constraint Satisfaction
  16. 173 |
  17. RDFS 175 | Axioms and Entailments 176 |
    177 |
    9.1  RDF and RDFS Axioms
    178 |
    179 |
    9.2  RDFS Entailment
    180 |
    181 |
    9.3  RDF Entailment Rules
    182 |
    183 |
    9.4  RDFS Entailment Rules
  18. 184 |
  19. RDF/XML 186 | Parser and Writer 187 |
    188 |
    10.1  RDF/XML Parser
    189 |
    190 |
    10.2  RDF/XML Writer
  20. 191 |
  21. N-Triples 193 | 194 |
    195 |
    11.1  N-Triple Parser
    196 |
    197 |
    11.2  Adding N-Triples
    198 |
    199 |
    11.3  N-Triple Writer
  22. 200 |
  23. OWL in 202 | SWCLOS 203 |
    204 |
    12.1  OWL Extension of RDF and RDFS
    205 |
    206 |
    12.2  Description Logic and OWL in SWCLOS
    207 |
    208 |
    12.3  OWL Property Restrictions
    209 |
    210 |
    12.4  Substantial and Non-Substantial Relationship
    211 |
    212 |
    12.5  Axiomatic Complete Relations
  24. 213 |
  25. OWL 215 | Axioms and Entailment Rules 216 |
    217 |
    13.1  OWL Axioms
    218 |
    219 |
    13.2  OWL Semantics and Entailment Rules
  26. 220 |
  27. OWL 221 | APIs 222 |
    223 |
    14.1  Subsumption in OWL
224 |
225 | 226 |

Acknowledgements

227 |

SWCLOS was developed at one of the Japanese IT programs titled "Building 228 | Operation Support System for Large-Scale Systems using IT", that was conducted 229 | by the Ministry of Education, Culture, Sports, Science, and Technology from 2002 230 | to 2005 fiscal year. After 2005, SWCLOS is updated and maintained by Seiji Koide 231 | at IHI Corporation and National Insitute of Informatics.

232 |
233 | Author: Seiji 234 | Koide. Copyright (c) 2005, 2006 GALAXY EXPRESS CORPORATION. 235 | Feb.2006
Copyright (c) 2007-2010 Seiji Koide. 236 | Oct.2010
237 | 238 | 239 | --------------------------------------------------------------------------------