Re: @lang and @xml:lang in XHTML+RDFa 1.1

In practice, the way I handle this, is to perform range mapping on untyped literals. By looking up the range of the predicate, I can often infer the appropriate datatype for the literal, turning

	<> dc:modified "2010-01-13"@ja .

into

	<> dc:modified "2010-01-13"^^<http://www.w3.org/2001/XMLSchema#date> .

(having asserted xs:date a range of dc:modified).

In this way, I can map untyped literals (possibly with a language) to appropriately typed literals.

Gregg

On Jan 13, 2010, at 4:55 AM, KANZAKI Masahide wrote:

> Hello,
> 
> 2010/1/2 Shane McCarron <shane@aptest.com>:
>> I am in the process of producing an XHTML+RDFa 1.1 editors draft, and I am
>> pondering what the inclusion of @lang means for the processing rules.  To
>> me, it makes perfect sense to say that @lang and @xml:lang both can define
>> the language of an element, and that @xml:lang takes precedence.  This is
>> what XHTML 1.1 says. Does anyone see a problem with this?
> 
> 
> As I posted almost a year ago [1], I've been thinking that the use of
> X/HTML lang (xml:lang) attribute to generate RDF lang tag might be one
> of the most problematic parts in RDFa.
> 
> Generally, HTML authors put lang attribute on the <html> element,
> maybe in order to take advantage of assistive technology etc., not
> paying attention that the attribute value is inherited through the
> elements tree. So we tend to write something:
> 
> <html lang="ja" xml:lang="ja">
> ...
> <p xmlns:dc="http://purl.org/dc/terms/">
> Updated: <span property="dc:modified">2010-01-13</span>...
> </p>
> 
> which generates weird triple:
> 
> <> dc:modified "2010-01-13"@ja .
> 
> I've witnessed bunch of nonsense lang-tagged triples came from RDFa
> documents. We can cancel lang attribute with empty lang="" or
> xml:lang="", or can add datatype attribute, but very few people do
> this in practice. And if there is an English or French name marked
> with property="foaf:name", such name will be tagged with @ja.
> 
> Another concern is, if a user copy/paste the above paragraph into
> his/her HTML, that will be a valid RDFa but will generate different
> triple (without lang tag).
> 
> If lang attribute is not included in RDFa 1.1 processing model, but
> allowed to use for accessibility purpose, then we can write only lang
> attribute in <html> element to avoid this confusion. I'm not sure
> whether this is a good solution, but RDFa 1.1 should be a chance to
> clear this unwelcome situation.
> 
> best regards,
> 
> 
> [1] http://lists.w3.org/Archives/Public/public-rdf-in-xhtml-tf/2009Jan/0154.html
> 
> -- 
> @prefix : <http://www.kanzaki.com/ns/sig#> . <> :from [:name
> "KANZAKI Masahide"; :nick "masaka"; :email "mkanzaki@gmail.com"].
> 

Received on Wednesday, 13 January 2010 16:25:06 UTC