Skip to content

Commit 9bcce99

Browse files
committed
README.md fixes - Merge branch 'master'
2 parents 98fdcbc + 0ad1405 commit 9bcce99

1 file changed

Lines changed: 27 additions & 14 deletions

File tree

README.md

Lines changed: 27 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ GraphDB is an experimental graph database engine and command-line interface (CLI
1616
* [🧠 Key Benefits](#-key-benefits)
1717
* [🛠️ What GraphDB Does](#-what-graphdb-does)
1818
* [🧹 Quick Example](#-quick-example)
19-
* [🏗️ Architecture](#-architecture)
19+
* [🧹 Architecture](#-architecture)
2020
* [🔌 How It Works](#-how-it-works)
2121
* [🌐 Complementing Existing EHRs](#-complementing-existing-ehrs)
2222
* [🧪 Example Use Cases](#-example-use-cases)
@@ -84,7 +84,7 @@ RETURN p.name, p.age
8484

8585
This query traverses the graph to return patient names and ages, demonstrating GraphDB’s ability to handle relational queries efficiently.
8686

87-
## 🏗️ Architecture
87+
## 🧹 Architecture
8888

8989
GraphDB’s modular, daemonized architecture ensures scalability, performance, and flexibility. Below is a visual representation of its components and their interactions:
9090

@@ -146,7 +146,7 @@ GraphDB enhances, rather than replaces, existing EHR systems by:
146146
GraphDB’s graph-native approach unlocks powerful healthcare applications:
147147
* **Clinical Decision Support**: Identify drug-allergy interactions or suggest treatment paths by traversing patient history graphs in real-time. 🩺
148148
* **Billing Optimization**: Detect missed CPT coding opportunities or fraudulent billing patterns using graph-based anomaly detection. 💰
149-
* **Patient Risk Modeling**: Build longitudinal graphs of medical, behavioral, and socioeconomic factors for predictive analytics and proactive care. 📊
149+
* **Patient Risk Modeling**: Build longitudinal graphs of patient medical, behavioral, and socioeconomic factors for predictive analytics and proactive care. 📊
150150
* **Security and Compliance**: Visualize user access logs as graphs to ensure HIPAA/GDPR compliance and detect unauthorized access. 🔒
151151
* **Research and Epidemiology**: Analyze disease propagation networks, identify clinical trial cohorts, or study social determinants of health. 🔬
152152

@@ -167,13 +167,15 @@ Before building GraphDB, ensure the following are installed:
167167

168168
1. Clone the repository:
169169
```bash
170-
git clone https://github.com/dmitryro/graphdb.git
170+
git clone [https://github.com/dmitryro/graphdb.git](https://github.com/dmitryro/graphdb.git)
171171
cd graphdb
172172
```
173+
173174
2. Build the CLI executable:
174175
```bash
175176
cargo build --workspace --release --bin graphdb-cli
176177
```
178+
177179
The compiled binary will be located at `./target/release/graphdb-cli`.
178180

179181
### 🚀 Running GraphDB Components
@@ -188,31 +190,39 @@ GraphDB supports multiple interaction modes:
188190
```bash
189191
./target/release/graphdb-cli --cli
190192
```
193+
191194
Enter commands like `start`, `stop`, `status`, or `rest graph-query`.
192195
* **Start a Single Graph Daemon**:
193196
```bash
194197
./target/release/graphdb-cli start --port 9001
195198
```
199+
196200
Default port is 8080 if `--port` is omitted.
197201
* **Start a Daemon Cluster**:
198202
```bash
199203
./target/release/graphdb-cli start --cluster 9001-9003
200204
```
205+
201206
Launches daemons on ports 9001–9003.
202207
* **Start REST API and Storage Daemon**:
203208
```bash
204209
./target/release/graphdb-cli start --listen-port 8082 --storage-port 8085
205210
```
211+
206212
REST API runs on port 8082, storage daemon on 8085.
207213
* **Stop Components**:
208214
* Stop all components:
209215
```bash
210216
./target/release/graphdb-cli stop
211217
```
218+
212219
* Stop specific components:
213220
```bash
214221
./target/release/graphdb-cli stop rest
215222
./target/release/graphdb-cli stop daemon --port 9001
223+
```
224+
* Stop the Storage Daemon by port:
225+
```bash
216226
./target/release/graphdb-cli stop storage --port 8085
217227
```
218228

@@ -221,13 +231,15 @@ GraphDB supports multiple interaction modes:
221231
```bash
222232
./target/release/graphdb-cli --query "MATCH (n) RETURN n"
223233
```
234+
224235
* **Interactive CLI Query**:
225236
```
226237
graphdb-cli> rest graph-query "MATCH (p:Patient) RETURN p.name LIMIT 5"
227238
```
239+
228240
* **REST API Query**:
229241
```bash
230-
curl -X POST http://127.0.0.1:8082/api/v1/query \
242+
curl -X POST [http://127.0.0.1:8082/api/v1/query](http://127.0.0.1:8082/api/v1/query) \
231243
-H "Content-Type: application/json" \
232244
-d '{"query":"MATCH (n:Person {name: \"Alice\"}) RETURN n"}'
233245
```
@@ -245,14 +257,14 @@ The project is organized for modularity and maintainability:
245257

246258
## 📦 Crate/Module Details
247259

248-
### graphdb-lib 🧠
260+
### `graphdb-lib` 🧠
249261
* **Purpose**: Core graph engine with data structures (nodes, edges), traversal algorithms (BFS, DFS, shortest path), and query parsing for Cypher, SQL, and GraphQL.
250262
* **Features**:
251263
* Efficient in-memory graph representation.
252264
* Schema management for nodes and relationships.
253265
* Query execution engine with support for multiple query languages.
254266

255-
### server 💻
267+
### `server` 💻
256268
* **Purpose**: Houses the `graphdb-cli` binary for interactive and scripted use.
257269
* **Subcomponents** (`server/src/cli/`):
258270
* `cli.rs`: Parses command-line arguments and dispatches commands.
@@ -263,11 +275,11 @@ The project is organized for modularity and maintainability:
263275
* `daemon_management.rs`: Manages daemon lifecycle (spawning, monitoring, stopping).
264276
* `help_display.rs`: Generates detailed help messages for CLI commands.
265277

266-
### daemon-api ⚙️
278+
### `daemon-api` ⚙️
267279
* **Purpose**: Provides programmatic interfaces for controlling `graphdb-daemon` instances.
268280
* **Features**: Uses gRPC for efficient, language-agnostic communication between components.
269281

270-
### rest-api 🌐
282+
### `rest-api` 🌐
271283
* **Purpose**: Exposes RESTful endpoints for programmatic access.
272284
* **Key Endpoints**:
273285
* `GET /api/v1/health`: Checks system status.
@@ -279,15 +291,15 @@ The project is organized for modularity and maintainability:
279291
* `GET /api/v1/nodes/{id}` (Planned): Retrieves a specific node.
280292
* `GET /api/v1/relationships/{id}` (Planned): Retrieves a specific relationship.
281293

282-
### storage-daemon-server 🗄️
294+
### `storage-daemon-server` 🗄️
283295
* **Purpose**: Manages persistent storage with a pluggable architecture.
284296
* **Supported Backends**: Postgres, Redis, RocksDB, Sled.
285297
* **Features**: Ensures data durability, indexing, and transactional integrity.
286298

287-
### proto 📦
299+
### `proto` 📦
288300
* **Purpose**: Defines gRPC Protobuf messages and services for distributed communication.
289301

290-
### models/medical ⚕️
302+
### `models/medical` ⚕️
291303
* **Purpose**: Provides healthcare-specific graph structures and ontologies for context-aware queries.
292304

293305
## ⚡ Ports, Daemons, and Clusters
@@ -325,10 +337,10 @@ The `graphdb-cli` binary provides flexible interaction options:
325337
Interact with GraphDB programmatically via the REST API:
326338
```bash
327339
# Check system health
328-
curl http://127.0.0.1:8082/api/v1/health
340+
curl [http://127.0.0.1:8082/api/v1/health](http://127.0.0.1:8082/api/v1/health)
329341

330342
# Execute a graph query
331-
curl -X POST http://127.0.0.1:8082/api/v1/query \
343+
curl -X POST [http://127.0.0.1:8082/api/v1/query](http://127.0.0.1:8082/api/v1/query) \
332344
-H "Content-Type: application/json" \
333345
-d '{"query":"MATCH (n:Person {name: \"Alice\"}) RETURN n"}'
334346
```
@@ -379,3 +391,4 @@ MIT License (see [LICENSE](./LICENSE)).
379391
* **Issues**: [https://github.com/dmitryro/graphdb/issues](https://github.com/dmitryro/graphdb/issues)
380392
* **Documentation**: [https://docs.rs/graphdb](https://docs.rs/graphdb)
381393
* **Crates.io**: [https://crates.io/crates/graphdb](https://crates.io/crates/graphdb)
394+

0 commit comments

Comments
 (0)