Sorry again to take so long to respond. I have been a little too busy
to respond recently.
On 4 Dec 2005, at 16:42, Simon Phipps wrote:
On Dec 4, 2005, at 14:33, Henry Story wrote:
I have written my first blog entry in French [1] which has made me
aware that
it would be very useful to add language information to the atom
file generated by
BlogEd. A menu beneath the Entry icon would probably do the trick.
Henry
[1] http://bblfish.net/blog/page9.html#t2005_12_04.14_17_02_642
Does Atom allow there to be multiple parallel renditions of a blog
entry in different languages? I've been discussing with Dave
Johnson how we might provide a facility in Roller where a blog
entry might be provided in multiple languages and then select the
appropriate entry based on the contents of the HTTP GET. If this
were to be implemented, we'd need a way to express the same reality
in the Atom feed.
This is a complicated and delicate issue. An atom entry has been
syntactically limited by the atom spec by the following clause
[[
If multiple atom:entry elements with the same atom:id value
appear in
an Atom Feed Document, they represent the same entry. Their
atom:updated timestamps SHOULD be different. If an Atom Feed
Document contains multiple entries with the same atom:id, Atom
Processors MAY choose to display all of them or some subset of them.
One typical behavior would be to display only the entry with the
latest atom:updated timestamp.
]] last para of section 4.1.1 of http://www.ietf.org/rfc/rfc4287
So it is not really possible to put atom entries with the same id and
updated time stamp in a feed (without a SHOULD level violation) even
if they are translation of each other. That means that the Swiss
would not be able to publish a law with the same atom id in french
and in german, as they are obliged to publish these at the exact same
time by law. (No linguistic preference)
If we want to respect this we have to give different translations of
a document different ids. We should be able to specify that they are
translations of each other some other way. Using the Atom OWL
ontology [1] we could do this by adding some translation relation
between the entries. Once this the best way to do this is settled and
that it satisfies our needs it should be possible to put a proposal
to the atom syntax group for an extension to their xml format.
So perhaps something like this is needed
[ a :Feed, :Version;
:title [ :value "Example Feed";
:type "text/plain" ];
:link [ :href <http://example.org/>;
:rel iana:alternate ];
:updated "2003-12-13T18:30:02Z"^^xsd:dateTime;
:author [ :name "John Doe" ];
:id <urn:uuid:60a76c80-d399-11d9-b93C-0003939e0af6>;
:entry [ a :Entry;
:title [ :value "Atom-Powered Robots Run Amok";
:type "text/plain" ];
:link [ :href <http://example.org/2003/12/13/en/atom03>;
:rel iana:alternate ];
:id <tag:example.com,2005/en/atom03>;
:updated "2003-12-13T18:30:02Z"^^xsd:dateTime;
:summary [ :value "After a course of integration in
French philosophy,...";
:type "text/plain" ];
ext:translation <tag:example.com,2005/fr/atom03>
];
:entry [ a :Entry;
:title [ :value "Des Robot Atomiques se rebellent";
:type "text/plain" ];
:link [ :href <http://example.org/2003/12/13/fr/atom03>;
:rel iana:alternate ];
:id <tag:example.com,2005/fr/atom03>;
:updated "2003-12-13T18:30:02Z"^^xsd:dateTime;
:summary [ :value "Apres un cours d'integration en
philosophie francaise...";
:type "text/plain" ]
ext:translation <tag:example.com,2005/en/atom03>
];
] .
The ext:translation relation above relates a :Entry to an :EntryId
which is to say that it cannot distinguish between one version of an
entry and another. So we would either be saying that each version of
one entry is always going to be a translation of the other, or that
there is some version of the other entry that is a translation of
this one (which is a little too vague for comfort).
We could be more precise by giving each entry version its unique id,
in which case we could say that this particular entry is a
translation of that particular entry, which would be more precise and
satisfactory. In N3:
[ a :Feed, :Version;
:title [ :value "Example Feed";
:type "text/plain" ];
:link [ :href <http://example.org/>;
:rel iana:alternate ];
:updated "2003-12-13T18:30:02Z"^^xsd:dateTime;
:author [ :name "John Doe" ];
:id <urn:uuid:60a76c80-d399-11d9-b93C-0003939e0af6>;
:entry [ a :Entry;
= _:someid1;
:title [ :value "Atom-Powered Robots Run Amok";
:type "text/plain" ];
:link [ :href <http://example.org/2003/12/13/en/atom03>;
:rel iana:alternate ];
:id <tag:example.com,2005/en/atom03>;
:updated "2003-12-13T18:30:02Z"^^xsd:dateTime;
:summary [ :value "After a course of integration in
French philosophy,...";
:type "text/plain" ];
ext:translation _:someid2;
];
:entry [ a :Entry;
= _:someid2;
:title [ :value "Des Robot Atomiques se rebellent";
:type "text/plain" ];
:link [ :href <http://example.org/2003/12/13/fr/atom03>;
:rel iana:alternate ];
:id <tag:example.com,2005/fr/atom03>;
:updated "2003-12-13T18:30:02Z"^^xsd:dateTime;
:summary [ :value "Apres un cours d'integration en
philosophie francaise...";
:type "text/plain" ]
ext:translation _:someid1;
];
] .
So in RDF we have no trouble doing the right thing and we have choice.
It should therefore be possible to express something like the above
in atom syntax. How to do it is of course less clear given the lack
of clear semantics for the atom xml.
Henry Story
[1] http://groups.google.com/group/atom-owl/browse_frm/thread/
a5ff6dcca7b512b8
S.