メインコンテンツへ移動
Nowledge MemNowledge Mem

グラフの検索

GET
/graph/search

Search the knowledge graph.

Finds memories matching your query and returns them with their connections as visualization-ready graph data.

クエリパラメータ

query*Query

Search query

limit?Limit
Range1 <= value <= 100
Default30
depth?Depth

Traversal depth for graph search

Range1 <= value <= 5
Default2
node_types?array<string>|

Filter by node types

edge_types?array<string>|

Filter by edge types

include_metadata?Include Metadata

Include metadata in results

Defaulttrue
space_id?|

Optional memory space lens for the graph

レスポンスボディ

application/json

application/json

curl -X GET "https://example.com/graph/search?query=string"
{  "communities": [    {      "algorithm": "louvain",      "description": "",      "id": "string",      "member_count": 0,      "metadata": {},      "name": "string",      "resolution": 1,      "strength": 1    }  ],  "community_hulls": [    {      "color": "#9B59B6",      "community_id": "string",      "community_name": "string",      "hull_type": "convex",      "member_count": 0,      "member_nodes": [        "string"      ],      "metadata": {},      "opacity": 0.1,      "stroke_color": "#8E44AD",      "stroke_width": 2    }  ],  "edges": [    {      "edge_type": "string",      "id": "string",      "label": "string",      "metadata": {        "conditions": "string",        "confidence": 0,        "context": "string",        "description": "string",        "hop_count": 0,        "path_length": 0,        "path_position": 0,        "relation_type": "string",        "relationship_type": "string",        "source_id": "string",        "source_name": "string",        "source_reference": "string",        "strength": 0,        "target_id": "string",        "target_name": "string",        "temporal_info": "string",        "total_path_length": 0,        "visualization": {}      },      "relevance_score": 0,      "source": "string",      "target": "string",      "weight": 0    }  ],  "metadata": {    "entity_nodes": 0,    "error": "string",    "filter_type": "string",    "memory_nodes": 0,    "mention_edges": 0,    "query_method": "string",    "relationship_edges": 0,    "total_communities": 0,    "total_edges": 0,    "total_nodes": 0,    "traversal_depth": 0  },  "nodes": [    {      "color": "string",      "community": "string",      "hop_count": 0,      "id": "string",      "importance": 0,      "label": "string",      "metadata": {        "community_id": 0,        "confidence": 0,        "content": "string",        "created_at": "string",        "degree": 0,        "description": "string",        "entity_count": 0,        "entity_type": "string",        "hop_count": 0,        "importance": 0,        "pagerank_score": 0,        "source": "string",        "thread_id": "string",        "title": "string",        "updated_at": "string"      },      "node_subtype": "string",      "node_type": "string",      "pagerank_score": 0,      "size": 0,      "thread_id": "string"    }  ],  "query": "string",  "search_metadata": {    "filters_applied": {      "edge_types": [        "string"      ],      "node_types": [        "string"      ]    },    "graph_stats": {      "community_nodes": 0,      "entity_nodes": 0,      "memory_nodes": 0,      "mention_edges": 0,      "relation_edges": 0    },    "search_method": "string",    "search_results": {      "communities_found": 0,      "entities_found": 0,      "memories_found": 0,      "threads_found": 0    },    "unified_query": true,    "visualization_ready": true  },  "visualization_config": {    "edge_weight_range": [      0    ],    "layout_recommendations": {},    "node_size_range": [      0    ]  }}