Relationships
Query connections between entities and story clusters. The Relationships API exposes two distinct relationship types: entity relationships (how named people, organizations, and places co-occur across articles) and cluster relationships (how story clusters share underlying entities and narrative threads).
Entity relationships
Query relationships between named entities — how strongly two entities are connected based on co-occurrence patterns, context, and narrative proximity across the full article corpus.
| Parameter | Type | Description |
|---|---|---|
| entity | string | Entity ID to map relationships from. Required. |
| depth | integer | Relationship traversal depth. Range: 1–3. Default: 1 |
| min_strength | float | Minimum relationship strength to include. Range: 0.0–1.0. Default:
0.5
|
| type | enum | Relationship type filter: co_mention · causal · adversarial ·
collaborative
|
| time_range | string | Restrict to articles within window. Default: 30d |
Relationship network
Generate a network graph of entity relationships suitable for visualization. Returns nodes and weighted edges in a format compatible with standard graph libraries (D3, Sigma, Cytoscape).
| Parameter | Type | Description |
|---|---|---|
| entity | string | Root entity ID. The network radiates outward from this node. |
| depth | integer | Traversal depth. Default: 2 |
| max_nodes | integer | Cap on returned nodes. Default: 50 |
| min_strength | float | Minimum edge strength to include. Default: 0.4 |
Cluster relationships
Compute entity-based relationships between a specific set of story clusters. For each pair in the provided set, the API aggregates all named entities extracted by Layer 1 across the clusters' articles and returns weighted edges based on shared entity overlap.
This endpoint is complementary to the Layer 3 graph. The Layer 3 graph pre-computes relationships across the full corpus and is highest quality when data density is high. Cluster relationships are computed on demand for exactly the clusters you specify — always available regardless of corpus size, and grounded directly in Layer 1 named entity extraction.
| Parameter | Type | Description |
|---|---|---|
| ids | string | Comma-separated list of cluster IDs. Min: 2. Max: 20. Required. |
| min_shared | integer | Minimum shared named entities required to return a relationship. Default: 3 |
0.15
across 80+ shared entities represents a strong thematic connection. Sort by shared_count
for the most signal-dense pairs, or by confidence for the most topically distinct
relationships.
Relationship types
The type field on entity relationships describes the nature of the connection as inferred
from article context:
| Type | Description |
|---|---|
co_mention |
Entities appear together in articles without a directional relationship inferred |
collaborative |
Entities are referenced in cooperative or aligned contexts — partnerships, agreements, joint actions |
adversarial |
Entities appear in opposing, conflicting, or competitive contexts |
causal |
One entity's actions are described as causing or influencing outcomes involving the other |
Cluster relationships currently return shared_entities only. Directional relationship
types between clusters are on the roadmap for Layer 3 v2.