<commit_before># What it does

Store data as entity attribute values in memory. Fast queries and manipulation of state.

# How to use it

```js
var db = Wharf();
//TODO
```

There are 3 ways to include this library

## With browserify

```js
var Wharf = require('entity-wharf');<commit_msg>more docs<commit_after># What it does

Stores your data in an elegant way that will give you great flexibility and leverage. This library is designed to be used as a state management solution for applications that need to be performant for quickly mutating state over many different types of entities with similar characteristics. Applications such as games and simulations. If performance isn't this crucial then check out [DataScript](https://github.com/tonsky/datascript) which provides immutability, versioning, undo/redo, and the powerful datalog query engine.

All data stored in Wharf is organized uniformly as
 * *Entity* - just an id (i.e. 1)
 * *Attribute* - an attribute of the entity (i.e. _name_ or _age_)
 * *Value* - the value of the attribute (i.e. _"bob"_ or _50_)

For example let's describe some shapes.

entity 1 is a red square
entity 2 is a blue triangle
entity 3 is a red circle

|Entity|Attribute|Value|
|-|-|-|
|1|color|red|
|1|width|20|
|1|height|20|
|1|n\_edges|4|
|2|color|blue|
|2|base|10|
|2|height|40|
|2|n\_edges|3|
|3|color|red|
|3|radius|20|
|3|n\_edges|0|


# How to use it

```js
var db = Wharf();
//TODO
```

There are 3 ways to include this library

## With browserify

```js
var Wharf = require('entity-wharf');
{'fraction_non_alphanumeric': 0.10714285714285714, 'fraction_numerical': 0.02077922077922078, 'mean_word_length': 4.445229681978798, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 1, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6450812', 'n_tokens_mistral': 518, 'n_tokens_neox': 478, 'n_words': 212}