Re: [ANN] silc - a tiny entity database for clojure (games)

2014-12-03 Thread Daniel Kersten
Is it possible to retrieve all entities with a set of attributes,
regardless of the attribute values?

On Wed, 3 Dec 2014 06:19 Atamert Ölçgen mu...@muhuk.com wrote:

 I don't feed trolls.

 On Wed, Dec 3, 2014 at 10:10 AM, Atamert Ölçgen mu...@muhuk.com wrote:

 Why are you using BigDecimal's for indices? If you want to go big, isn't
 BigInt a better choice?

 Actually, I would just use Long's. (MAX_VALUE = 9223372036854775807)

 On Wed, Dec 3, 2014 at 10:04 AM, Atamert Ölçgen mu...@muhuk.com wrote:

 This is a very nice example of abstraction. Using a hash-map is just an
 implementation detail.

 However I'd be very interested to hear if there are any other compelling
 use cases for this.


 Sparsely populated tables, unstructured anything... We used an EAV
 abstraction (over SQL) to build a product database. Different product types
 have very different fields, even same types of product might have different
 fields sometimes. In hindsight normalized relational tables would have been
 a better fit (the decision was made before I joined).

 In your README, the change and delete examples give the impression that
 they're mutating the db, but they actually return an updated db if I'm not
 mistaken.


 On Wed, Dec 3, 2014 at 6:37 AM, dan.stone16...@gmail.com wrote:

 I have put together a quick library http://github.com/danstone/silc
 that allows you to manage many entities and their attributes in a pure way
 with indexing for performance, include composite indexes.

 The intention of the library is certainly as the basis for an entity
 component system for games, that is how I am using it. However I'd be very
 interested to hear if there are any other compelling use cases for this.

 Pull requests welcome!

 Thanks,

 Dan

 --
 You received this message because you are subscribed to the Google
 Groups Clojure group.
 To post to this group, send email to clojure@googlegroups.com
 Note that posts from new members are moderated - please be patient with
 your first post.
 To unsubscribe from this group, send email to
 clojure+unsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/clojure?hl=en
 ---
 You received this message because you are subscribed to the Google
 Groups Clojure group.
 To unsubscribe from this group and stop receiving emails from it, send
 an email to clojure+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.




 --
 Kind Regards,
 Atamert Ölçgen

 -+-
 --+
 +++

 www.muhuk.com




 --
 Kind Regards,
 Atamert Ölçgen

 -+-
 --+
 +++

 www.muhuk.com




 --
 Kind Regards,
 Atamert Ölçgen

 -+-
 --+
 +++

 www.muhuk.com

 --
 You received this message because you are subscribed to the Google
 Groups Clojure group.
 To post to this group, send email to clojure@googlegroups.com
 Note that posts from new members are moderated - please be patient with
 your first post.
 To unsubscribe from this group, send email to
 clojure+unsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/clojure?hl=en
 ---
 You received this message because you are subscribed to the Google Groups
 Clojure group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to clojure+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.


-- 
You received this message because you are subscribed to the Google
Groups Clojure group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
Clojure group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [ANN] silc - a tiny entity database for clojure (games)

2014-12-03 Thread dan . stone16321
Yes I should probably not be using BigDecimals :)

I'll fix this as soon as I can.

On Wednesday, December 3, 2014 2:10:53 AM UTC, Atamert Ölçgen wrote:

 Why are you using BigDecimal's for indices? If you want to go big, isn't 
 BigInt a better choice?

 Actually, I would just use Long's. (MAX_VALUE = 9223372036854775807)

 On Wed, Dec 3, 2014 at 10:04 AM, Atamert Ölçgen mu...@muhuk.com 
 javascript: wrote:

 This is a very nice example of abstraction. Using a hash-map is just an 
 implementation detail.

 However I'd be very interested to hear if there are any other compelling 
 use cases for this.


 Sparsely populated tables, unstructured anything... We used an EAV 
 abstraction (over SQL) to build a product database. Different product types 
 have very different fields, even same types of product might have different 
 fields sometimes. In hindsight normalized relational tables would have been 
 a better fit (the decision was made before I joined).

 In your README, the change and delete examples give the impression that 
 they're mutating the db, but they actually return an updated db if I'm not 
 mistaken.


 On Wed, Dec 3, 2014 at 6:37 AM, dan.sto...@gmail.com javascript: 
 wrote:

 I have put together a quick library http://github.com/danstone/silc 
 that allows you to manage many entities and their attributes in a pure way 
 with indexing for performance, include composite indexes.

 The intention of the library is certainly as the basis for an entity 
 component system for games, that is how I am using it. However I'd be very 
 interested to hear if there are any other compelling use cases for this.

 Pull requests welcome!

 Thanks,

 Dan

 -- 
 You received this message because you are subscribed to the Google
 Groups Clojure group.
 To post to this group, send email to clo...@googlegroups.com 
 javascript:
 Note that posts from new members are moderated - please be patient with 
 your first post.
 To unsubscribe from this group, send email to
 clojure+u...@googlegroups.com javascript:
 For more options, visit this group at
 http://groups.google.com/group/clojure?hl=en
 --- 
 You received this message because you are subscribed to the Google 
 Groups Clojure group.
 To unsubscribe from this group and stop receiving emails from it, send 
 an email to clojure+u...@googlegroups.com javascript:.
 For more options, visit https://groups.google.com/d/optout.




 -- 
 Kind Regards,
 Atamert Ölçgen

 -+-
 --+
 +++

 www.muhuk.com
  



 -- 
 Kind Regards,
 Atamert Ölçgen

 -+-
 --+
 +++

 www.muhuk.com
  

-- 
You received this message because you are subscribed to the Google
Groups Clojure group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
Clojure group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [ANN] silc - a tiny entity database for clojure (games)

2014-12-03 Thread dan . stone16321


  Is it possible to retrieve all entities with a set of attributes, 
 regardless of the attribute values?

 
Not yet, I haven't indexed for it. You could approximate it using the ave 
index if you just concat any set of entities under any value. However it 
would require the attributes you are interested in participating in the ave 
index.

It would be a worthy edition though so I'll look at it unless somebody 
wants to submit a pull request.

Cool project! Did you try using the pldb built into core.logic? I have a 
 similar system built atop pldb backing one of my side projects and I'm very 
 happy with it.


I do like pldb and core.logic and have used them in the past - I would very 
much like to introduce an optional core.logic front-end to this, however it 
was important to me that the primary interface was perhaps less declarative 
but with stronger performance guarantees as my use case for this is for 
game development.

-- 
You received this message because you are subscribed to the Google
Groups Clojure group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
Clojure group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [ANN] silc - a tiny entity database for clojure (games)

2014-12-03 Thread dan . stone16321
I have released an update to the lib with a new index the 
`attribute-entity` index, and improved the readme (I hope). Check it out!

Regards,

Dan

-- 
You received this message because you are subscribed to the Google
Groups Clojure group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
Clojure group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [ANN] silc - a tiny entity database for clojure (games)

2014-12-03 Thread James Reeves
Coincidentally, I put together a similar library a few months ago (
https://github.com/weavejester/ittyon), but I didn't think anyone else
would find it useful. It looks like there are more people experimenting
with games in Clojure than I thought.

- James


On 3 December 2014 at 21:30, dan.stone16...@gmail.com wrote:

 I have released an update to the lib with a new index the
 `attribute-entity` index, and improved the readme (I hope). Check it out!

 Regards,

 Dan

 --
 You received this message because you are subscribed to the Google
 Groups Clojure group.
 To post to this group, send email to clojure@googlegroups.com
 Note that posts from new members are moderated - please be patient with
 your first post.
 To unsubscribe from this group, send email to
 clojure+unsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/clojure?hl=en
 ---
 You received this message because you are subscribed to the Google Groups
 Clojure group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to clojure+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.


-- 
You received this message because you are subscribed to the Google
Groups Clojure group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
Clojure group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[ANN] silc - a tiny entity database for clojure (games)

2014-12-02 Thread dan . stone16321
I have put together a quick library http://github.com/danstone/silc that 
allows you to manage many entities and their attributes in a pure way with 
indexing for performance, include composite indexes.

The intention of the library is certainly as the basis for an entity 
component system for games, that is how I am using it. However I'd be very 
interested to hear if there are any other compelling use cases for this.

Pull requests welcome!

Thanks,

Dan

-- 
You received this message because you are subscribed to the Google
Groups Clojure group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
Clojure group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [ANN] silc - a tiny entity database for clojure (games)

2014-12-02 Thread Wei Hsu
A pure entity database would have been useful for a game I was working on 
last month. I'll try it out for the next one. Thanks for publishing it!

On Tuesday, December 2, 2014 2:37:06 PM UTC-8, dan.sto...@gmail.com wrote:

 I have put together a quick library http://github.com/danstone/silc that 
 allows you to manage many entities and their attributes in a pure way with 
 indexing for performance, include composite indexes.

 The intention of the library is certainly as the basis for an entity 
 component system for games, that is how I am using it. However I'd be very 
 interested to hear if there are any other compelling use cases for this.

 Pull requests welcome!

 Thanks,

 Dan


-- 
You received this message because you are subscribed to the Google
Groups Clojure group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
Clojure group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [ANN] silc - a tiny entity database for clojure (games)

2014-12-02 Thread Reid McKenzie
Cool project! Did you try using the pldb built into core.logic? I have a 
similar system built atop pldb backing one of my side projects and I'm 
very happy with it.


Reid
On 12/02/2014 04:37 PM, dan.stone16...@gmail.com wrote:
I have put together a quick library http://github.com/danstone/silc 
that allows you to manage many entities and their attributes in a pure 
way with indexing for performance, include composite indexes.


The intention of the library is certainly as the basis for an entity 
component system for games, that is how I am using it. However I'd be 
very interested to hear if there are any other compelling use cases 
for this.


Pull requests welcome!

Thanks,

Dan
--
You received this message because you are subscribed to the Google
Groups Clojure group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient 
with your first post.

To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
---
You received this message because you are subscribed to the Google 
Groups Clojure group.
To unsubscribe from this group and stop receiving emails from it, send 
an email to clojure+unsubscr...@googlegroups.com 
mailto:clojure+unsubscr...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.


--
You received this message because you are subscribed to the Google
Groups Clojure group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups Clojure group.

To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [ANN] silc - a tiny entity database for clojure (games)

2014-12-02 Thread Atamert Ölçgen
This is a very nice example of abstraction. Using a hash-map is just an
implementation detail.

However I'd be very interested to hear if there are any other compelling
 use cases for this.


Sparsely populated tables, unstructured anything... We used an EAV
abstraction (over SQL) to build a product database. Different product types
have very different fields, even same types of product might have different
fields sometimes. In hindsight normalized relational tables would have been
a better fit (the decision was made before I joined).

In your README, the change and delete examples give the impression that
they're mutating the db, but they actually return an updated db if I'm not
mistaken.


On Wed, Dec 3, 2014 at 6:37 AM, dan.stone16...@gmail.com wrote:

 I have put together a quick library http://github.com/danstone/silc that
 allows you to manage many entities and their attributes in a pure way with
 indexing for performance, include composite indexes.

 The intention of the library is certainly as the basis for an entity
 component system for games, that is how I am using it. However I'd be very
 interested to hear if there are any other compelling use cases for this.

 Pull requests welcome!

 Thanks,

 Dan

 --
 You received this message because you are subscribed to the Google
 Groups Clojure group.
 To post to this group, send email to clojure@googlegroups.com
 Note that posts from new members are moderated - please be patient with
 your first post.
 To unsubscribe from this group, send email to
 clojure+unsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/clojure?hl=en
 ---
 You received this message because you are subscribed to the Google Groups
 Clojure group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to clojure+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.




-- 
Kind Regards,
Atamert Ölçgen

-+-
--+
+++

www.muhuk.com

-- 
You received this message because you are subscribed to the Google
Groups Clojure group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
Clojure group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [ANN] silc - a tiny entity database for clojure (games)

2014-12-02 Thread Atamert Ölçgen
Why are you using BigDecimal's for indices? If you want to go big, isn't
BigInt a better choice?

Actually, I would just use Long's. (MAX_VALUE = 9223372036854775807)

On Wed, Dec 3, 2014 at 10:04 AM, Atamert Ölçgen mu...@muhuk.com wrote:

 This is a very nice example of abstraction. Using a hash-map is just an
 implementation detail.

 However I'd be very interested to hear if there are any other compelling
 use cases for this.


 Sparsely populated tables, unstructured anything... We used an EAV
 abstraction (over SQL) to build a product database. Different product types
 have very different fields, even same types of product might have different
 fields sometimes. In hindsight normalized relational tables would have been
 a better fit (the decision was made before I joined).

 In your README, the change and delete examples give the impression that
 they're mutating the db, but they actually return an updated db if I'm not
 mistaken.


 On Wed, Dec 3, 2014 at 6:37 AM, dan.stone16...@gmail.com wrote:

 I have put together a quick library http://github.com/danstone/silc that
 allows you to manage many entities and their attributes in a pure way with
 indexing for performance, include composite indexes.

 The intention of the library is certainly as the basis for an entity
 component system for games, that is how I am using it. However I'd be very
 interested to hear if there are any other compelling use cases for this.

 Pull requests welcome!

 Thanks,

 Dan

 --
 You received this message because you are subscribed to the Google
 Groups Clojure group.
 To post to this group, send email to clojure@googlegroups.com
 Note that posts from new members are moderated - please be patient with
 your first post.
 To unsubscribe from this group, send email to
 clojure+unsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/clojure?hl=en
 ---
 You received this message because you are subscribed to the Google Groups
 Clojure group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to clojure+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.




 --
 Kind Regards,
 Atamert Ölçgen

 -+-
 --+
 +++

 www.muhuk.com




-- 
Kind Regards,
Atamert Ölçgen

-+-
--+
+++

www.muhuk.com

-- 
You received this message because you are subscribed to the Google
Groups Clojure group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
Clojure group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [ANN] silc - a tiny entity database for clojure (games)

2014-12-02 Thread Raoul Duke
 Actually, I would just use Long's. (MAX_VALUE = 9223372036854775807)

https://www.google.com/search?q=youtube+gangnam+overflow

-- 
You received this message because you are subscribed to the Google
Groups Clojure group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
Clojure group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [ANN] silc - a tiny entity database for clojure (games)

2014-12-02 Thread Atamert Ölçgen
I don't feed trolls.

On Wed, Dec 3, 2014 at 10:10 AM, Atamert Ölçgen mu...@muhuk.com wrote:

 Why are you using BigDecimal's for indices? If you want to go big, isn't
 BigInt a better choice?

 Actually, I would just use Long's. (MAX_VALUE = 9223372036854775807)

 On Wed, Dec 3, 2014 at 10:04 AM, Atamert Ölçgen mu...@muhuk.com wrote:

 This is a very nice example of abstraction. Using a hash-map is just an
 implementation detail.

 However I'd be very interested to hear if there are any other compelling
 use cases for this.


 Sparsely populated tables, unstructured anything... We used an EAV
 abstraction (over SQL) to build a product database. Different product types
 have very different fields, even same types of product might have different
 fields sometimes. In hindsight normalized relational tables would have been
 a better fit (the decision was made before I joined).

 In your README, the change and delete examples give the impression that
 they're mutating the db, but they actually return an updated db if I'm not
 mistaken.


 On Wed, Dec 3, 2014 at 6:37 AM, dan.stone16...@gmail.com wrote:

 I have put together a quick library http://github.com/danstone/silc
 that allows you to manage many entities and their attributes in a pure way
 with indexing for performance, include composite indexes.

 The intention of the library is certainly as the basis for an entity
 component system for games, that is how I am using it. However I'd be very
 interested to hear if there are any other compelling use cases for this.

 Pull requests welcome!

 Thanks,

 Dan

 --
 You received this message because you are subscribed to the Google
 Groups Clojure group.
 To post to this group, send email to clojure@googlegroups.com
 Note that posts from new members are moderated - please be patient with
 your first post.
 To unsubscribe from this group, send email to
 clojure+unsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/clojure?hl=en
 ---
 You received this message because you are subscribed to the Google
 Groups Clojure group.
 To unsubscribe from this group and stop receiving emails from it, send
 an email to clojure+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.




 --
 Kind Regards,
 Atamert Ölçgen

 -+-
 --+
 +++

 www.muhuk.com




 --
 Kind Regards,
 Atamert Ölçgen

 -+-
 --+
 +++

 www.muhuk.com




-- 
Kind Regards,
Atamert Ölçgen

-+-
--+
+++

www.muhuk.com

-- 
You received this message because you are subscribed to the Google
Groups Clojure group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
Clojure group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.