That's nice to hear! Did you notice any slow-downs when it had to do the
extra parsing of such a library (e.g. measure the request response time
of the Refresh button on the Script Editor panel)? How big is the .js
snippet that you have added? The ADS engine needs to periodically
rebuild those APIs, esp after ontology changes.
Holger
On 2022-03-25 12:42 pm, Nicholas Car wrote:
We have successfully tested manipulation of local RDF data in EDG ADS
script using N3.js imported inline into an ADS script.
So now we can retrieve external RDF, in Turtle, parse it, query it
(not SPARQL, just triple patterns) and do things with it like insert
it into local EDG graphs.
Nick
On Sat, Mar 19, 2022 at 9:31 AM Holger Knublauch
<[email protected]> wrote:
Hi Fan Li, others,
Did you have a chance to look at
https://www.topquadrant.com/doc/7.1/scripting/nodejs.html ?
I agree it would be nice to have ES modules within TopBraid but
this also opens up potential problems, trying to cram everything
into a single (Java) virtual machine. With the Node.js approach
above, users can more easily divide the workload, into a more
traditional services architecture.
I would be interested in hearing what types of external libraries
people would be particularly interested in using, so that we are
better informed about the future direction here.
Thanks
Holger
On 18 Mar 2022, at 10:19 pm, Fan Li <[email protected]> wrote:
Hi Holger, it would be great if ADS can support ES module import
from node_modules, which would open up a lot of possibilities.
On Thursday, March 17, 2022 at 8:21:11 PM UTC-4 Holger Knublauch
wrote:
Hi Nick,
no, inline execution would be the only option right now, e.g.
copy the library into a dash:IncludedScript. I am aware this
is not ideal and we have a Jira ticket to make working with
files (from the workspace) easier. But it won't happen in 7.2
which is ready for release very soon.
One problem is that adding libraries adds to the footprint of
the GraalVM that we use. Consider that you have dozens of
asset collections. For each Ontology in them, TopBraid will
generate a new ADS API, and I am not sure if GraalVM would
optimize each copy to reuse those building blocks. So any
solution here would need to optimize that.
Holger
On 2022-03-18 10:09 am, Nicholas Car wrote:
Dear TB users,
Is it possible, within an ADS script, to import arbitrary
JavaScript packages?
For example, if I wanted to use luxon
(https://openbase.com/js/luxon) for date/time manipulation,
how would I get it? Are there options other than having to
inline the entire module?
I understand that there are several modes for executing ADS
code, but I'm interested in the in-EDG mode in particular.
Thanks,
Nick
--
You received this message because you are subscribed to the
Google Groups "TopBraid Suite Users" group.
To unsubscribe from this group and stop receiving emails
from it, send an email to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/topbraid-users/CAP7nqh0G_%3DLZRvDs1OHk3mNs_2W4N-m0xLijXUsdNr3Ks50tVQ%40mail.gmail.com
<https://groups.google.com/d/msgid/topbraid-users/CAP7nqh0G_%3DLZRvDs1OHk3mNs_2W4N-m0xLijXUsdNr3Ks50tVQ%40mail.gmail.com?utm_medium=email&utm_source=footer>.
--
You received this message because you are subscribed to the
Google Groups "TopBraid Suite Users" group.
To unsubscribe from this group and stop receiving emails from it,
send an email to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/topbraid-users/6d39cf59-35bd-4fac-9f43-879f3ff577b1n%40googlegroups.com
<https://groups.google.com/d/msgid/topbraid-users/6d39cf59-35bd-4fac-9f43-879f3ff577b1n%40googlegroups.com?utm_medium=email&utm_source=footer>.
--
You received this message because you are subscribed to the Google
Groups "TopBraid Suite Users" group.
To unsubscribe from this group and stop receiving emails from it,
send an email to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/topbraid-users/82186F09-F933-472C-B0EB-93243E8B152B%40topquadrant.com
<https://groups.google.com/d/msgid/topbraid-users/82186F09-F933-472C-B0EB-93243E8B152B%40topquadrant.com?utm_medium=email&utm_source=footer>.
--
You received this message because you are subscribed to the Google
Groups "TopBraid Suite Users" group.
To unsubscribe from this group and stop receiving emails from it, send
an email to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/topbraid-users/CAP7nqh1jHCa-i7H0AjfMPBLN6LRdW3m7sJPeYe%3DQbVC%3DG-XEDA%40mail.gmail.com
<https://groups.google.com/d/msgid/topbraid-users/CAP7nqh1jHCa-i7H0AjfMPBLN6LRdW3m7sJPeYe%3DQbVC%3DG-XEDA%40mail.gmail.com?utm_medium=email&utm_source=footer>.
--
You received this message because you are subscribed to the Google Groups "TopBraid
Suite Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/topbraid-users/78e7ecda-26a7-004e-f436-5d4c525b0c61%40topquadrant.com.