Graph Analysis
In-memory graph analysis on connectome datasets. SynDB constructs a directed graph from synapse data in ClickHouse (up to 10M edges) and runs network algorithms using petgraph.
Requires Academic verification.
Graph Metrics
Basic network statistics:
curl -H "Authorization: Bearer $TOKEN" \
https://api.syndb.xyz/v1/graph/{dataset_id}/metrics
Returns: node count, edge count, density, number of connected components, mean clustering coefficient, diameter, hub neurons (highest centrality).
Motif Analysis (Triadic Census)
Count all 16 three-node subgraph patterns (triadic census):
curl -X POST -H "Authorization: Bearer $TOKEN" \
https://api.syndb.xyz/v1/graph/{dataset_id}/motifs
Compare by Synapse Type
Compare motif distributions across different neurotransmitter types:
curl -X POST -H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
https://api.syndb.xyz/v1/graph/{dataset_id}/motifs/compare-synapse-types
Shortest Path
Find the shortest path between two neurons:
curl -X POST -H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
https://api.syndb.xyz/v1/graph/{dataset_id}/shortest-path \
-d '{"source": "neuron-id-1", "target": "neuron-id-2"}'
Uses Dijkstra’s algorithm. Supports configurable edge weight modes.
Reachability
Find all neurons reachable within N hops:
curl -X POST -H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
https://api.syndb.xyz/v1/graph/{dataset_id}/reachability \
-d '{"source": "neuron-id", "max_hops": 3}'
BFS traversal, maximum 100 hops.
Reachability Curve
Sample how reachability grows with hop count:
curl -H "Authorization: Bearer $TOKEN" \
"https://api.syndb.xyz/v1/graph/{dataset_id}/reachability-curve?max_hops=20&samples=100"
Returns the fraction of the network reachable at each hop distance, sampled from random starting neurons (max 500 samples, max 20 hops).
Full Analysis
Run metrics + motifs + hub neuron detection in one call:
curl -X POST -H "Authorization: Bearer $TOKEN" \
https://api.syndb.xyz/v1/graph/{dataset_id}/full-analysis
Cross-Dataset Comparison
Compare graph properties across multiple datasets:
curl -X POST -H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
"https://api.syndb.xyz/v1/graph/compare" \
-d '{"dataset_ids": ["uuid-1", "uuid-2", "uuid-3"]}'
Graph Precompute (CLI)
For large datasets, precompute graph metrics and store results in ClickHouse materialized tables:
syndb graph-precompute --dataset-id {uuid}
This is a batch operation typically run as part of the ETL pipeline or as a Kubernetes job.