reddb-cli 0.1.2-next.47 → 0.1.2-next.49

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/README.md +54 -2
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -22,9 +22,9 @@ One command. RedDB searches across tables, graphs, vectors, documents, and key-v
22
22
 
23
23
  ---
24
24
 
25
- ## 5 Data Models, 1 Engine
25
+ ## 7 Data Models, 1 Engine
26
26
 
27
- Stop running Postgres + Neo4j + Pinecone + Redis + Mongo. RedDB unifies them.
27
+ Stop running Postgres + Neo4j + Pinecone + Redis + Mongo + InfluxDB + RabbitMQ. RedDB unifies them.
28
28
 
29
29
  ```sql
30
30
  -- Relational rows
@@ -41,6 +41,15 @@ SEARCH SIMILAR TEXT 'anomaly detected' COLLECTION events
41
41
 
42
42
  -- Key-value
43
43
  PUT config.theme = 'dark'
44
+
45
+ -- Time-series metrics (with retention & downsampling)
46
+ CREATE TIMESERIES cpu_metrics RETENTION 90 d
47
+ INSERT INTO cpu_metrics (metric, value, tags) VALUES ('cpu.idle', 95.2, '{"host":"srv1"}')
48
+
49
+ -- Message queues (FIFO, priority, consumer groups)
50
+ CREATE QUEUE tasks MAX_SIZE 10000
51
+ QUEUE PUSH tasks '{"job":"process","id":123}'
52
+ QUEUE POP tasks
44
53
  ```
45
54
 
46
55
  Same file. Same engine. Same query language.
@@ -112,6 +121,49 @@ curl http://127.0.0.1:8080/config
112
121
 
113
122
  ---
114
123
 
124
+ ## Probabilistic Data Structures
125
+
126
+ Built-in approximate data structures for real-time analytics at scale.
127
+
128
+ ```sql
129
+ -- HyperLogLog: count unique visitors (~0.8% error, ~16KB memory)
130
+ CREATE HLL visitors
131
+ HLL ADD visitors 'user1' 'user2' 'user3'
132
+ HLL COUNT visitors
133
+
134
+ -- Count-Min Sketch: frequency estimation
135
+ CREATE SKETCH click_counter WIDTH 2000 DEPTH 7
136
+ SKETCH ADD click_counter 'button_a' 5
137
+ SKETCH COUNT click_counter 'button_a'
138
+
139
+ -- Cuckoo Filter: membership testing with deletion (unlike Bloom filters)
140
+ CREATE FILTER active_sessions CAPACITY 500000
141
+ FILTER ADD active_sessions 'session_abc'
142
+ FILTER CHECK active_sessions 'session_abc'
143
+ FILTER DELETE active_sessions 'session_abc'
144
+ ```
145
+
146
+ ---
147
+
148
+ ## Advanced Indexes
149
+
150
+ Beyond B-tree. Create the right index for your workload.
151
+
152
+ ```sql
153
+ -- Hash index: O(1) exact-match lookups
154
+ CREATE INDEX idx_email ON users (email) USING HASH
155
+
156
+ -- Bitmap index: fast analytical queries on low-cardinality columns
157
+ CREATE INDEX idx_status ON orders (status) USING BITMAP
158
+
159
+ -- R-Tree: spatial queries on geo data
160
+ CREATE INDEX idx_loc ON sites (location) USING RTREE
161
+ SEARCH SPATIAL RADIUS 48.8566 2.3522 10.0 COLLECTION sites COLUMN location LIMIT 50
162
+ SEARCH SPATIAL NEAREST 48.8566 2.3522 K 5 COLLECTION sites COLUMN location
163
+ ```
164
+
165
+ ---
166
+
115
167
  ## SQL Extensions
116
168
 
117
169
  RedDB extends SQL with `WITH` clauses for operational semantics:
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "reddb-cli",
3
- "version": "0.1.2-next.47",
3
+ "version": "0.1.2-next.49",
4
4
  "description": "JavaScript/TypeScript SDK for RedDB - unified multi-model database",
5
5
  "type": "commonjs",
6
6
  "main": "./sdk/red-sdk.js",