This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2021-04-26
Channels
- # announcements (10)
- # asami (15)
- # babashka (200)
- # beginners (48)
- # calva (56)
- # cider (6)
- # clara (2)
- # cljs-dev (18)
- # cljsrn (6)
- # clojars (3)
- # clojure (23)
- # clojure-czech (2)
- # clojure-europe (41)
- # clojure-germany (5)
- # clojure-italy (19)
- # clojure-nl (5)
- # clojure-uk (8)
- # clojurescript (60)
- # clojureverse-ops (5)
- # cursive (14)
- # datomic (6)
- # events (1)
- # figwheel-main (5)
- # graalvm (17)
- # honeysql (2)
- # instaparse (1)
- # integrant (9)
- # jobs (5)
- # music (2)
- # off-topic (37)
- # other-languages (1)
- # pathom (10)
- # proletarian (5)
- # quil (3)
- # reagent (39)
- # reitit (4)
- # remote-jobs (3)
- # reveal (6)
- # rum (9)
- # shadow-cljs (27)
- # vrac (3)
- # xtdb (5)
Loom is still alive! 😄 https://github.com/aysylu/loom/commits/master
possibly a stupid question: does asami allow you to associate weights (or other properties) to edges?
(Like setting properties on a relationship in Neo4j: (:Person {person_id:'123'})-[:FRIEND {date:'1972-01-01'}]->(m:Person {person_id:'456'})
[I.e. Person 123 and Person 456 have been friends since 1972-01-01] )
You can add edges multiple times, or if you use the graph update function on a connection, you can update the graph with another function that lets you set the number more directly
This is done by passing a connection to the function asami.storage/transact-update
along with a function that receives a graph and a transaction number to use.
That function can then call asami.multi-graph/multi-graph-add
e.g.
(storage/transact-update my-connection
(fn [graph txid]
(multi-graph/multi-graph-add graph entity attribute value txid weight)))
Cisco was using this specifically to weight edges that were being displayed, so the plotting algorithm could make useful decisions on layout
Oh, sorry @kiran.joshi. I was on my phone and didn’t read the full question about other properties.
Durable storage has allocated an ID for every statement (i.e. each individual edge), and properties can be given to these. BUT… I haven’t exposed it, because I don’t know what the API should look like yet
I thought that this was a decision I could put off for a while longer, because no one had asked for it 🙂
This isn’t an afterthought. It would be slightly cheaper to not have these IDs. But I wanted to support reification on edges, specifically like this, so I built it in