kappa-dev / kami-js Goto Github PK
View Code? Open in Web Editor NEWAnnoted knowledge representation translation into Kappa (Knowledge Aggregator and Model Instantiator)
Annoted knowledge representation translation into Kappa (Knowledge Aggregator and Model Instantiator)
Using link-left and link-right to connect action boxes to agents makes it awkward to re-arrange agents. When importing a large amount of nuggets, re-arranging is crucial to visualizing the graph. Unless the modeler has the foresight to link-left & link-right with a global perspective, the graphs become "tangled".
Unless link-left & link-right will be deprecated, I would suggest adding a "flip link-right & link-left" to an action's context menu, so that the modeler can alter this visual/logic element.
Attributes on nodes that have the same name will get their parents re-assigned when exporting to JSON. For example, the following graph:
Becomes the following JSON, where the rate attributes are now pointing to the same entity on the tree:
{"version":2.0,
"agents":[
{"classes":["agent"],"father_classes":[],"path":[],"labels":["C"],"values":[],"x":474,"y":252},
{"classes":["agent"],"father_classes":[],"path":[],"labels":["D"],"values":[],"x":802,"y":248},
{"classes":["agent"],"father_classes":[],"path":[],"labels":["A"],"values":[],"x":474,"y":139},
{"classes":["agent"],"father_classes":[],"path":[],"labels":["B"],"values":[],"x":809,"y":127}
],
"regions":[
],
"key_rs":[
],
"attributes":[
{"classes":["attribute","list"],"father_classes":["action","bnd","revers"],"path":["rev-bind"],"labels":["rate"],"values":["2.0"],"x":620.0760961020505,"y":323.9735501703761},
{"classes":["attribute","list"],"father_classes":["action","bnd","revers"],"path":["rev-bind"],"labels":["rate"],"values":["1.0"],"x":620.093746391759,"y":161.53215372790945}
],
"flags":[
],
"actions":[
{"classes":["action","bnd","revers"],"labels":["rev-bind"],
"left":[{"ref":["agents",0]}],
"right":[{"ref":["agents",1]}],
"context":[],
"x":596,"y":275.51666259765625},
{"classes":["action","bnd","revers"],"labels":["rev-bind"],
"left":[{"ref":["agents",2]}],
"right":[{"ref":["agents",3]}],
"context":[],
"x":585,"y":123}
]
}
When read back, Kami displays the following graph, where the rate attribute got its parent re-assigned:
This means the modeler must rename the actions with globally unique labels when writing the "local" nuggets, which is not feasible outside toy models.
With all nodes unlocked, attributes of actions are attracted to the canvas' top-left corner, and pull in that direction the rest of the graph & connected components.
Since one can not lock these attribute nodes into position, they often end up divorced from their parent node, sometimes gravitating to positions behind other nodes, making large graphs impossible to organize.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.