- From: Paul Vincent <pvincent@tibco.com>
- Date: Wed, 22 Aug 2007 03:35:13 -0700
- To: "Dave Reynolds" <der@hplb.hpl.hp.com>, "Gary Hallmark" <gary.hallmark@oracle.com>
- Cc: "RIF WG" <public-rif-wg@w3.org>
> So how is all this done at the moment. In the MISMO example is the data > model exchanged via an XML Schema (plus human readable documentation) or > is there some other machine readable model representation being used? The former: MISMO is an example of a DSL implemented as an XML schema, with published PDFs of decision tables used to represent the mortgage rates and conditions. Interestingly, other than RIF(/PRR), there is a strong attempt to sell MISMO on the idea of using XBRL as the rule interchange format. However, I view XBRL itself as a DSL that is itself a (strong) candidate for using RIF in future. > How are the elements of that XML (or other) schema being mapped to > predicates etc in the case of ILog, Oracle, JBossRules etc? FYI most tools map XML docs to the internal / Java-based object model via things like JAXB... PS: Dumb and dumber - I note I've used XSL in lieu of XSD in other posts - oops! Refs: [1] MISMO http://www.mismo.org/Workgroups/businessrulesexchange.html [2] MISMO use case example http://blog.athico.com/2007/06/w3c-rule-interchange-format-for.html [3] Popular XML mapping libraries: https://jaxb.dev.java.net/ http://www.castor.org/xml-mapping.html http://xerces.apache.org/xerces2-j/index.html [4] XML Schema front page supporting RIF...: <<XML Schemas express shared vocabularies and allow machines to carry out rules made by people. >> http://www.w3.org/XML/Schema Paul Vincent TIBCO | ETG/Business Rules > -----Original Message----- > From: public-rif-wg-request@w3.org [mailto:public-rif-wg-request@w3.org] > On Behalf Of Dave Reynolds > Sent: 22 August 2007 09:09 > To: Gary Hallmark > Cc: RIF WG > Subject: Re: presenting data models in RIF > > > Gary Hallmark wrote: > > > > > > > > Dave Reynolds wrote: > > > >> Do rules themselves need to access the data model not just the data? > > > > rules need access to data and relationships. For example, I expect a 1 > > to many relationship between purchase orders and line items, and I > > expect to be able to express a condition in a rule about a purchase > > order and its related line items. > > Sure that's the data, not the model. If the rule itself needed to check > the range constraint of the relationship hasLineItem or check the > cardinality constraint that would be model-level access. > > > The rules I've seen in RIF access relations and frames, not XML data nor > > RDF data nor Java data. If I plan to interchange some rules in RIF and > > a data model in an XML schema, I'd also need some mapping information > > that shows some kind of correspondence between schema definitions and > > frames and relations. How do I "bind" frames and relations in RIF to > > types and relationships in XML schema? > > Exactly. In the case of RDF we are proposing a single canonical mapping > so that every RDF vocabulary uses the same mapping. > > In the case of XMLSchema I would expect this to be done by schema > annotation which is why I mentioned the SAWSDL spec a while back. > > You *could* have a canonical default mapping for un-annotated XMLSchemas > but that would likely either have to make some assumptions like striping > which won't be satisfied by all XMLSchema documents or would produce > counter-intuitive mapping results on some schemas. > > > Given an element > > "http://someplace/line-item" and another element "http://someplace/po" > > that contains a sequence of 0 or more line-item elements, how do I write > > rules about po/@num = 123 and its related line-items? What are the > > frames? slots? Association between po and its related line-items? > > Whatever the schema said in its annotations. > > If you don't have schema annotations then it would depend on whether we > had a default mapping scheme. > > If RIF doesn't define a default mapping schema for generic XML data then > you either access it via XPath operators or you could use the RDF > mapping. Assuming the data is striped then the RDF mapping which would > give you something like: > > po1[rdf:type->eg:PO, > eg:num->"123" > eg:line-item->li1[rdf:type->eg:Line-item, ...]] > > where po1 and li1 are gensym'ed identifiers (the skolem constants used > to represent RDF bNodes). > > > So how is all this done at the moment. In the MISMO example is the data > model exchanged via an XML Schema (plus human readable documentation) or > is there some other machine readable model representation being used? > How are the elements of that XML (or other) schema being mapped to > predicates etc in the case of ILog, Oracle, JBossRules etc? > > Dave > -- > Hewlett-Packard Limited > Registered Office: Cain Road, Bracknell, Berks RG12 1HN > Registered No: 690597 England > > >> In the case of semantic web applications then yes, but that's not a > >> problem since RDFS/OWL are themselves encoded in RDF so an RDF access > >> mechanism is sufficient. > >> > >> I haven't heard any use cases for accessing the model itself in the > >> XML or object cases. Gary presented a case (car/lorry/vehicle) for > >> there *being* a data model but the rules seemed to only need to > >> consult the type of instances not the hierarchy or domain/range > >> constraints themselves). I understood Paul to be saying that direct > >> access to the schema from the rules would be unusual in the business > >> rule setting. > >> > >> > >> As a way to make progress I would find it helpful to get more use > >> cases from the commercial vendors on how data models are exchanged at > >> the moment and why a new RIF data model interchange would help. Based > >> on things like the URC document section on processing models I had > >> been under the impression that the dominant approach, outside RDF/OWL, > >> was to define the data model in XML Schema and don't really see how > >> the existence of a new class hierarchy relation is of significant > >> benefit in processing data defined in such a way. > >> > >> Dave > >> > >> [Unfortunately I won't be able to make the next telecon.] > > > >
Received on Wednesday, 22 August 2007 10:35:30 UTC