Coder Social home page Coder Social logo

kami-js's People

Contributors

abassobl avatar pirbo avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Forkers

happy-ferret

kami-js's Issues

Aesthetic: Link-right & link-left impose chirality on a non-chiral graph

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.

Loss of information when exporting to JSON

Attributes on nodes that have the same name will get their parents re-assigned when exporting to JSON. For example, the following graph:
capture

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:
capture

This means the modeler must rename the actions with globally unique labels when writing the "local" nuggets, which is not feasible outside toy models.

Action attributes attracted to top-left corner very strongly

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.
capture

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.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.