PlaygroundDiscordContext EngineeringDashboardSign Up >
DocumentationSDK ReferenceGraphiti
DocumentationSDK ReferenceGraphiti
  • SDK Reference

We’re hiring! Come build with us →

LogoLogo
PlaygroundDiscordContext EngineeringDashboardSign Up >
SDK ReferenceGraph

POST
https://api.getzep.com/api/v2/graph/search
POST
/api/v2/graph/search
1from zep_cloud import Zep
2
3client = Zep(
4 api_key="YOUR_API_KEY",
5)
6client.graph.search(
7 query="query",
8)
Try it
1{
2 "edges": [
3 {
4 "created_at": "string",
5 "fact": "string",
6 "name": "string",
7 "source_node_uuid": "string",
8 "target_node_uuid": "string",
9 "uuid": "string",
10 "attributes": {},
11 "episodes": [
12 "string"
13 ],
14 "expired_at": "string",
15 "invalid_at": "string",
16 "relevance": 1.1,
17 "score": 1.1,
18 "valid_at": "string"
19 }
20 ],
21 "episodes": [
22 {
23 "content": "string",
24 "created_at": "string",
25 "uuid": "string",
26 "metadata": {},
27 "processed": true,
28 "relevance": 1.1,
29 "role": "string",
30 "role_type": "norole",
31 "score": 1.1,
32 "source": "text",
33 "source_description": "string",
34 "task_id": "string",
35 "thread_id": "string"
36 }
37 ],
38 "nodes": [
39 {
40 "created_at": "string",
41 "name": "string",
42 "summary": "string",
43 "uuid": "string",
44 "attributes": {},
45 "labels": [
46 "string"
47 ],
48 "relevance": 1.1,
49 "score": 1.1
50 }
51 ]
52}
Was this page helpful?
Previous

Get Graph

Next
Built with
Perform a graph search query.
Search Graph

Request

Graph search query
querystringRequired<=400 characters

The string to search for (required)

bfs_origin_node_uuidslist of stringsOptional
Nodes that are the origins of the BFS searches
center_node_uuidstringOptional
Node to rerank around for node distance reranking
graph_idstringOptional

The graph_id to search in. When searching user graph, please use user_id instead.

limitintegerOptional<=50
The maximum number of facts to retrieve. Defaults to 10. Limited to 50.
min_fact_ratingdoubleOptional
The minimum rating by which to filter relevant facts
min_scoredoubleOptional
Deprecated
mmr_lambdadoubleOptional
weighting for maximal marginal relevance
rerankerenumOptional
Defaults to RRF
Allowed values:
scopeenumOptional
Defaults to Edges. Communities will be added in the future.
Allowed values:
search_filtersobjectOptional
Search filters to apply to the search
user_idstringOptional
The user_id when searching user graph. If not searching user graph, please use graph_id instead.

Response

Graph search results
edgeslist of objects or null
episodeslist of objects or null
nodeslist of objects or null

Errors

The user_id when searching user graph. If not searching user graph, please use graph_id instead.