EnglishFrenchSpanish

OnWorks favicon

cwm - Online in the Cloud

Run cwm in OnWorks free hosting provider over Ubuntu Online, Fedora Online, Windows online emulator or MAC OS online emulator

This is the command cwm that can be run in the OnWorks free hosting provider using one of our multiple free online workstations such as Ubuntu Online, Fedora Online, Windows online emulator or MAC OS online emulator

PROGRAM:

NAME


cwm - Closed World Machine, an RDF/N3 semantic web data processor

DESCRIPTION


Command line RDF/N3 tool

<command> <options> <steps> [--with <more args> ]

OPTIONS


--pipe Don't store, just pipe out *

steps, in order left to right:

--rdf Input & Output ** in RDF/XML instead of n3 from now on

--n3 Input & Output in N3 from now on. (Default)

--rdf=flags
Input & Output ** in RDF and set given RDF flags

--n3=flags
Input & Output in N3 and set N3 flags

--ntriples
Input & Output in NTriples (equiv --n3=usbpartane -bySubject -quiet)

--language=x
Input & Output in "x" (rdf, n3, etc) --rdf same as: --language=rdf

--languageOptions=y
--n3=sp same as: --language=n3 --languageOptions=sp

--ugly Store input and regurgitate, data only, fastest *

--bySubject
Store input and regurgitate in subject order *

--no No output *
(default is to store and pretty print with anonymous nodes) *

--base=<uri>
Set the base URI. Input or output is done as though this were the document
URI.

--closure=flags
Control automatic lookup of identifiers (see below) <uri> Load
document. URI may be relative to current directory.

--apply=foo
Read rules from foo, apply to store, adding conclusions to store

--patch=foo
Read patches from foo, applying insertions and deletions to store

--filter=foo
Read rules from foo, apply to store, REPLACING store with conclusions

--query=foo
Read a N3QL query from foo, apply it to the store, and replace the store
with its conclusions

--sparql=foo
Read a SPARQL query from foo, apply it to the store, and replace the store
with its conclusions

--rules
Apply rules in store to store, adding conclusions to store

--think
as -rules but continue until no more rule matches (or forever!)

--engine=otter
use otter (in your $PATH) instead of llyn for linking, etc

--why Replace the store with an explanation of its contents

--why=u
proof tries to be shorter

--mode=flags
Set modus operandi for inference (see below)

--reify
Replace the statements in the store with statements describing them.

--dereify
Undo the effects of --reify

--flatten
Reify only nested subexpressions (not top level) so that no {} remain.

--unflatten
Undo the effects of --flatten

--think=foo
as -apply=foo but continue until no more rule matches (or forever!)

--purge
Remove from store any triple involving anything in class log:Chaff

--data Remove all except plain RDF triples (formulae, forAll, etc)

--strings
Dump :s to stdout ordered by :k whereever { :k log:outputString :s }

--crypto
Enable processing of crypto builtin functions. Requires python crypto.

--help print this message

--revision
print CVS revision numbers of major modules

--chatty=50
Verbose debugging output of questionable use, range 0-99

--sparqlServer
instead of outputting, start a SPARQL server on port 8000 of the store

--sparqlResults
After sparql query, print in sparqlResults format instead of rdf

finally:

--with Pass any further arguments to the N3 store as os:argv values

* mutually exclusive ** doesn't work for complex cases :-/

EXAMPLES


cwm --rdf foo.rdf --n3 --pipe
Convert from rdf/xml to rdf/n3

cwm foo.n3 bar.n3 --think
Combine data and find all deductions

cwm foo.n3 --flat --n3=spart

Mode flags affect inference extending to the web:
r Needed to enable any remote stuff.

a When reading schema, also load rules pointed to by schema (requires r, s)

E Errors loading schemas of definitive documents are ignored

m Schemas and definitive documents loaded are merged into the meta knowledge
(otherwise they are consulted independently)

s Read the schema for any predicate in a query.

u Generate unique ids using a run-specific

Closure flags are set to cause the working formula to be automatically expanded to the
closure under the operation of looking up:

s the subject of a statement added

p the predicate of a statement added

o the object of a statement added

t the object of an rdf:type statement added

i any owl:imports documents

r any doc:rules documents

E errors are ignored --- This is independant of --mode=E

n Normalize IRIs to URIs

e Smush together any nodes which are = (owl:sameAs)

See http://www.w3.org/2000/10/swap/doc/cwm for more documentation.

Setting the environment variable CWM_RDFLIB to 1 makes Cwm use rdflib to parse rdf/xml
files. Note that this requires rdflib.

Flags for N3 output are as follows:-

a Anonymous nodes should be output using the _: convention (p flag or not). d Don't
use default namespace (empty prefix) e escape literals --- use \u notation i Use
identifiers from store - don't regen on output l List syntax suppression. Don't use (..)
n No numeric syntax - use strings typed with ^^ syntax p Prefix suppression - don't
use them, always URIs in <> instead of qnames. q Quiet - don't output comments about
version and base URI used. r Relative URI suppression. Always use absolute URIs. s
Subject must be explicit for every statement. Don't use ";" shorthand. t "this" and
"()" special syntax should be suppressed. u Use \u for unicode escaping in URIs instead
of utf-8 %XX v Use "this log:forAll" for @forAll, and "this log:forAll" for "@forSome".
/ If namespace has no # in it, assume it ends at the last slash if outputting.

Flags for N3 input:

B Turn any blank node into an existentially qualified explicitly named node.

Flags to control RDF/XML output (after --rdf=) areas follows:

b - Don't use nodeIDs for Bnodes c - Don't use elements as class names d - Default
namespace supressed. l - Don't use RDF collection syntax for lists r - Relative URI
suppression. Always use absolute URIs. z - Allow relative URIs for namespaces

Flags to control RDF/XML INPUT (after --rdf=) follow:

S - Strict spec. Unknown parse type treated as Literal instead of error.

T - take foreign XML as transparent and parse any RDF in it

(default is to ignore unless rdf:RDF at top level)

L - If non-rdf attributes have no namespace prefix, assume in local <#> namespace

D - Assume default namespace declared as local document is assume xmlns=""

R - Do not require an outer <rdf:RDF>, treating the file as RDF content (opposite of
T)

Note: The parser (sax2rdf) does not support reification, bagIds, or
parseType=Literal.

It does support the rest of RDF incl. datatypes, xml:lang, and nodeIds.

Use cwm online using onworks.net services


Free Servers & Workstations

Download Windows & Linux apps

  • 1
    Psi
    Psi
    Psi is cross-platform powerful XMPP
    client designed for experienced users.
    There are builds available for MS
    Windows, GNU/Linux and macOS.. Audience:
    End Users...
    Download Psi
  • 2
    Blobby Volley 2
    Blobby Volley 2
    Official continuation of the famous
    Blobby Volley 1.x arcade game..
    Audience: End Users/Desktop. User
    interface: OpenGL, SDL. Programming
    Language: C++, Lua. C...
    Download Blobby Volley 2
  • 3
    SuiteCRM
    SuiteCRM
    SuiteCRM is the award-winning Customer
    Relationship Management (CRM)
    application brought to you by authors
    and maintainers, SalesAgility. It is the
    world�s mos...
    Download SuiteCRM
  • 4
    Poweradmin
    Poweradmin
    Poweradmin is a web-based DNS
    administration tool for PowerDNS server.
    The interface has full support for most
    of the features of PowerDNS. It has full
    support...
    Download Poweradmin
  • 5
    Gin Web Framework
    Gin Web Framework
    Gin is an incredibly fast web framework
    written in Golang that can perform up to
    40 times faster, thanks to its
    martini-like API and custom version of
    httprout...
    Download Gin Web Framework
  • 6
    CEREUS LINUX
    CEREUS LINUX
    CEREUS LINUX basado en MX LINUX con
    varios entornos de escritorios. This is
    an application that can also be fetched
    from
    https://sourceforge.net/projects/cereu...
    Download CEREUS LINUX
  • More »

Linux commands

  • 1
    aa-clickquery
    aa-clickquery
    aa-clickquery - program for querying
    click-apparmor DESCRIPTION: This program
    is used to query click-apparmor for
    information. USAGE: aa-clickquery
    --click-fra...
    Run aa-clickquery
  • 2
    aa-exec-click
    aa-exec-click
    aa-exec-click - program for executing
    click packages under confinement
    DESCRIPTION: This program is used to
    execute click package under AppArmor
    confinement. I...
    Run aa-exec-click
  • 3
    cpio
    cpio
    cpio - copy files to and from archives ...
    Run cpio
  • 4
    cpipe
    cpipe
    cpipe - copy stdin to stdout while
    counting bytes and reporting progress ...
    Run cpipe
  • 5
    FvwmSave
    FvwmSave
    FvwmSave - the Fvwm desktop-layout
    saving module ...
    Run FvwmSave
  • 6
    FvwmSave1
    FvwmSave1
    FvwmSave - the FVWM desktop-layout
    saving module ...
    Run FvwmSave1
  • More »

Ad