Forum OpenACS Development: ANN: IMS-LD beta released

Posted by Luis de la Fuente on
Hello all,

We are glad to announce the release of the IMS-LD package for the .LRN platform. As its main features it includes:

- Full level A support (parser and player)
- SCORM, forums service and QTI already integrated
- Several extra features (users and permissions management, extra feedback with QTI, auto-finish of activities, etc.)

To test this package, you can follow one of this two ways:

1- The "difficult one": install the package from CVS (HEAD) and test it.
2- The quick one: use our test server ( Let me explain this server a little bit more...

- Open the URL and choose a server. I highly recommend postgresql-stable (5.2) one
- Login. If you only want to test the IMS-LD package with the pre-installed demo you'd better choose the 'user' cccount (all of the users have the same properties). You can also login as administrator (if you would like to try your own IMS-LD package).

USER account:
- All the users listed in the main page have the same properties, but if anyone has used 'userN' its actions have been saved, so you'd better take another account ('userN+1') to follow the user's path from scratch.
- Once you have logged into the system, please go to the 'test' community. There, you'll find the IMS-LD portlet. That means, you'll be able to start the demo.
- Next step is: act as if you were in student's shoes and enjoy the LD experience :P
- We will welcome all kind of comments...

ADMIN account:
- If you login as administrator, please go to 'imsldtest' community.
- This user can administrate not only the IMS-LD package, but also the whole site. This means that the admin is able to create users, Units of Learnings (UoLs), etc.
- No matter what you do, the system will be fully reinstalled in 24 hours, feel free to break or test anything.
- To add new UoLs, go to the control panel tab of the community and search for the portlet named "Unit of Learning Administration". From there you can access the admin interface of the IMS-LD package, and you will be able to add or delete Units of Learnings.


Posted by Rafael Calvo on
Great Job Luis,

This is a great contribution!



Posted by Luis de la Fuente on
Not only me, but all the E-LANE team must be included in the 'great job' package :D

thank you anyway,


Posted by Caroline Meeks on
Is the QTI integration done with Assessment or is a separate package?


Posted by Luis de la Fuente on
The QTI integration is done with Assessment: when a resource has type="imsqti_xmlv1p0", the IMS-LD package call the Assessment package to manage this resource.

Since communication between packages is possible, Assessment tells IMS-LD that the test has been completed and the resource is labeled as completed. Other interactions are possible, of course.


Posted by Michael Totschnig on
When I first tried to install package imsld, I got the error,

Database operation "dml" failed (exception ERROR, "FEHLER: Einfügen oder Aktualisieren in Tabelle »lang_message_keys« verletzt Fremdschlüssel-Constraint »lang_message_keys_fk«
DETAIL: Schlüssel (package_key)=(acs-translations) ist nicht in Tabelle »apm_package_types« vorhanden.

FEHLER: Einfügen oder Aktualisieren in Tabelle »lang_message_keys« verletzt Fremdschlüssel-Constraint »lang_message_keys_fk«
DETAIL: Schlüssel (package_key)=(acs-translations) ist nicht in Tabelle »apm_package_types« vorhanden.

Could it be, that acs-translations has to be added to the list of packages that imsld depends on?

Best regards,

Michael Totschnig

Posted by Malte Sussdorff on
Two options:

a) Get rid of internationalization of roles in acs-subsite
b) Make acs-subsite dependend on acs-translations

I prefer b) due to the fact that if you go down the a) road everyone who is using roles and need i18n role names has to fork.

Posted by Eduardo Pérez on
We already added the dependency of acs-translations to acs-subsite.
Just install acs-translations and everything should work.
Posted by Michael Totschnig on
I just did a fresh install and even though acs-subsite has acs-translations in its dependencies, I could install acs-subsite without having acs-translations checked out, and I cannot remember seeing any warning. Also when you checout acs-core module from CVS, you get acs-subsite, but not acs-translations.
Posted by Luis de la Fuente on
I have received this question:

When an environment contains more than one learning object, the import gives a warning and only the first one is used. The specification does not have this restriction and the Coppercore players presents a list of all objects in an environment. Is this a temporary simplification you choose during the initial phase of development or are there other design rationales?

In fact, the specification states that a learning object inside an evironment is mandatory and ocurs only 1 time (see section

Actually, most users does not take this restriction into account, neither CopperCore does. We prefer to follow the specification as much as possible, so we have included this warning.

Posted by Michael Totschnig on
Hello Luis,

I have the impression, that there is a problem in the wording of the textual specification, because it contradicts the XML schema. In the definition of the environment-type there is a choice group, inside which the learning-object appears once, but the group itself has unbounded as maxoccurs attribute:

            <xs:choice minOccurs="0" maxOccurs="unbounded">
                <xs:element ref="learning-object"/>
                <xs:element ref="service"/>
                <xs:element ref="environment-ref"/>

Thus, the schema clearly allows multiple learning-objects inside an environment. I have the impression that the author of the textual specification only looked at the single occurence of the learning-object element itself and overlooked the multiple occurence of the group where it is contained.

Best regards,


Posted by Luis de la Fuente on
I see... there's a bug to be fixed here.

It's not difficult to remove de warning and behave like CopperCore, but before doing this i prefer to ask in LD specialized forums.

Changes will be reported here when the best solution is achieved.

Posted by Michael Totschnig on

My next question: If there are several plays in a method, currently the imsld package only displays the first one, or did I miss something? The specification says that in this case the plays should be accessible concurrently by the user. Do you plan to implement this in the future and what are your ideas about how it should be shown in the UI?

Posted by Jose Pablo Escobedo Del Cid on
Yes, the plays will be shown concurrently, as well as the role parts. The reason why right now it doesn't behave that way is because of the table we are using to display the sequence. It was too confusing to display concurrent activities in the table.

That is why we are now working in a javascript tree (like the one LORS uses). It will be more easy to "navigate" inside the course using the tree. We are basing our development on the CopperCore tree, so when we finish with that, both of them should have pretty much the same behavior. Besides, with the table there was no sense to have into account the properties like "is-visible", or the sequence-type of the activity structures, but with the tree those properties will be interpreted/treated as they should.

BTW, we had a discussion about the learning-objects issue and we misunderstood the spec, so that will be fixed soon and commited this week.


When you parse the imsmanifest file, you assume that the namespace is mapped to the prefix imscp. But a imsmanifest file could map the namespace to any other prefix and still be valid according to the specification. Isn't is possible to tell the tdom parser to look for the namespace according to the URI and not the prefix. This would make the code also more readable, because you would not have to look for unprefixed and prefixed nodes?
To answer my own question. According to, it is possible to make XPath queries independent from the prefix in the source document by adding a namespace declaration node to the root with a prefix of your own choosing.
This could mean, that after parsing the manifest you could call
$manifest setAttributeNS "" xmlns:imscp "";

Whereever in the code where you have constructs like

set organizations [$manifest child all imscp:organizations]
if { ![llength $organizations] } {
set organizations [$manifest child all organizations]

you could more simply write

set organizations [$manifest selectNodes imscp:organizations]

What do you think?


Thanks for your help.

Just one question. That would affect all the child nodes, right?, what about the imsld specific nodes?

Yes, my idea is whenever you have to retrieve child nodes to use the selectNodes function, because thus you query for the actual namespace and not the prefix, whereas the child function seems to retrieve nodes only based on the prefix.

Sorry, that I forgot to add that the same would be necessary for all namespaces used in the manifest.

I am testing the imsld package with some of the learning designs found on in the "Runnable LD Example Units of Learning" node. When I tried, I realized following problem:

When an activity is referenced in several role-parts, following error is raised, upon access to a resource.

Database operation "0or1row" failed (exception NSINT, "Query returned more than one row.")

select item_id as rp_item_id, role_part_id
from imsld_role_partsi
where activity_structure_id = '3854'

The solution probably consists in passing also the act where the activity appears to the get_role_part_from_activity function. Unless, you return all role_parts where the activity is referenced, and mark them finished. But this would mean that the activity gets marked as finished for all plays where it appears.

This raises a more general question I wanted to ask you: In the design of the imsld package, I could not find the concept of a "run" that instantiates a learning design, and that would make it possible to restart the delivery from scratch with a new run if desired. Is this something you plan to add?

Michael, thanks a lot for the feedback. Your are helping us a lot.

We were dealing with that bug now. We think its' better to mark the activity finished in all the role parts that references it. What do you think?

About the other question, we haven't plan about multiple runs of the same UoL, but that could be possible, as you say. All we need (the info in the db) is there, so it would be just to add the API to do it. We will take it into account for our future developments/goals.


I am wondering if you do not need the concept of a "run" if you deal with multi-user learning_designs where you "enroll" users to a unit of learning, assign them to roles, before you start delivering it, and have to keep track of them as the community of users participating in the same "run", as suggested in the "Implementation guide" of the specification.


Currently, we are working on the support of roles into the application. When finishing this task, the information about completed resources will be: user_id, role_id, role_instance_id, resource_id.
With this, before delivering a unit of learning, you must assing roles. Moreover, to reply an IMS-LD you will only have to re-instance a role, and the resources will appear as not-completed, and the imsld will be replied.

All this features are on development. We can call for test before commiting on CVS.


We are right now working on supporting multiple runs for the same UoL. So the first thing the professor will have to do after uploading an UoL is to assign users to the run. Then the roles instances, properties instances, etc. will refer to the run (instance of the UoL).

More specifically, I was thinking about adding a "imsld_runs" table, which will map the run with the ims_ld_id. Then the instance of the roles will be made with the users which are assigned to the run, and the "status" table will also store the run_id. Also, the properties instances will refer This way there may be multiple runs for the same UoL.

Do you have any comments?


sorry for the late reply. What you describe seems reasonable to me. If you already have something up ready for testing, I would be glad to try it and give you detailed feedback.

Sorry, I forgot to react to the first point. I am not sure if marking the activity finished for all role parts where it is referenced, is what is intended by the specification.
If you think of a learning design with two plays, which both reference the same activity, but in two different contexts. If a user first executes play 1, and passes the activity, and later he executes play 2. When it comes to the activity he already has passed in play 1, it could possibly make a different sense in the new context, and if it had been already marked as finished, the flow of play 2 could become disturbed, or in the first case no longer make sense.
Does this make sense?
Sure, we have also thougth about this fact. The problem appears when the same activity is referenced from two different places, no matter if we are talking about role-part, environmente or plays, the fact is that you have to do the activity twice.

On one hand, the activity has different meaning into different contexts. Another point of view is that the activity is the same, and you can do again this activity, no matter if it have been finished or not. That means: if you have already done an activity and it's time to do it again from another place (role-part, play, etc.) the activity is shown and you can do it again.

Copper-Core behave like .LRN IMS-LD in this sense.