LightRAG icon

LightRAG

Query and manage LightRAG with optional live progress in n8n Chat

Query Data

AI-generated

Summary

Submit a query to LightRAG’s structured data endpoint and return the retrieved entities, relationships, chunks, and references. Provide a JSON request body with a query string of at least three characters; the body defaults to the complete incoming item.

Inputs

  • Request Body — JSON object sent to POST /query/data. Defaults to the full current input item, which must include a query string. The query must be at least three characters; an optional mode must be one of local, global, hybrid, naive, mix, or bypass.

Output shape

One output item per input item, containing the LightRAG response as JSON.

The operation returns the endpoint response without reshaping it. Requests use the required LightRAG API credentials; invalid bodies or request failures raise an error unless the node is configured to continue on fail.

Examples

Example 1: Retrieve structured RAG data for a question

Set Request Body to {"query":"What is LightRAG?","mode":"hybrid"}. The same body can be supplied in the incoming item because the field defaults to $json.

Links

Discussion