[kepler-dev] seek/kepler conference call notes
Edward A Lee
eal at eecs.berkeley.edu
Thu Aug 26 07:50:26 PDT 2004
At 10:31 AM 8/25/2004 -0800, Matt Jones wrote:
>Well, two more issues I can see cropping up.
>
>1) We need to make semantic annotations for individual actors, as well as
>models. As far as I know there is not a MoML provided for individual
>actors independently of a model? How do we annotate, for example, the
>GarpAlgorithm actor outside of a MoML model so that we can use these
>annotations in the discovery service? Should we be providing a standalone
>MoML for every actor that contains only the actor and its port
>descriptions, and then attach the 'configure' annotations to that?
I assume here you mean atomic actors, defined in Java.
The key question is where you want the semantic annotation stored.
If it's part of the actor definition, then I would argue that it should
be in the Java file. This could be done using the same SemanticAnnotation
class that I suggested in my previous email (which extends
ConfigurableAttribute). The constructor for the actor would
look something like:
public MyActor extends TypedAtomicActor {
public MyActor(CompositeEntity container, String name) {
...
semanticAnnotation = new SemanticAnnotation(
this, "semanticAnnotation");
semanticAnnotation.configure(
" ... text for the annotation here ... ");
...
}
public SemanticAnntation semanticAnnotation;
}
An advantage of this is that, in effect, the Java file provides
a _default_ semantic annotation, but individual instances could
override it.
Also, it keeps the entire actor definition together in one place.
>2) Some of our actors have a set of ports that are defined and loaded at
>design time rather than compile time, and are determined by an external
>source. For example, the EMLDataSource actor gets its port definitions by
>reading the metadata about a data source, and the WebService actor gets
>its port definitions by reading the WSDL document for the service. I had
>thought that having external annotations would be good because they could
>be associated with the WSDL or EML rather than the actor itself. We'll
>need a way to annotate these dynamically created ports as well as those
>that are statically defined within an actor. I envision this to be
>common. Another example is instantiating a hypothetical R actor with the
>ports needed for data flow into and out of a specific R script, rather
>than using the CommandLine as we currently do (which bypasses all of our
>typing mechanisms).
If the SemanticAnnotation class is a configurable attribute,
then the same code that creates the ports could create an instance
of SemanticAnnotation contained by the ports. Would this do the job?
Edward
------------
Edward A. Lee, Professor
518 Cory Hall, UC Berkeley, Berkeley, CA 94720
phone: 510-642-0455, fax: 510-642-2739
eal at eecs.Berkeley.EDU, http://ptolemy.eecs.berkeley.edu/~eal
More information about the Kepler-dev
mailing list