Detect Patterns (Experimental)

Detects structural patterns in a knowledge graph including relationship frequencies, multi-hop paths, co-occurrences, hubs, and clusters.

Request

Pattern detection request
detectobjectOptional

Which pattern types to detect with type-specific configuration. Omit to detect all types with defaults.

graph_idstringOptional
Graph ID when detecting patterns on a named graph
include_examplesbooleanOptional

Include example node/edge UUIDs per pattern. Default: false

limitintegerOptional1-200

Max patterns to return. Default: 50, Max: 200

min_occurrencesintegerOptional>=1

Minimum occurrence count to report a pattern. Default: 2

recency_weightenumOptional

Exponential half-life decay applied to edge created_at timestamps. Valid values: none, 7_days, 30_days, 90_days. Default: none

Allowed values:
search_filtersobjectOptional

Filters which edges/nodes participate in pattern detection. Reuses the same filter format as /graph/search.

seedsobjectOptional
Seed selection. If omitted, analyzes the entire graph.
user_idstringOptional
User ID when detecting patterns on a user graph

Response

Detected patterns
metadataobject or null
Statistics about the detection run
patternslist of objects or null

Detected patterns, sorted by weighted_score descending

Errors