GET_KNOWLEDGE_GRAPH_STATUS

Use the DBMS_AI_GRAPHRAG.GET_KNOWLEDGE_GRAPH_STATUS function to retrieve the status of a knowledge graph.

Syntax

DBMS_AI_GRAPHRAG.GET_KNOWLEDGE_GRAPH_STATUS (
    kg_name  IN VARCHAR2
) RETURN JSON;

Parameters

Parameter Description
kg_name Name of the knowledge graph.

The function returns a JSON object that includes the overall graph status, source statuses, graph counts, and failure diagnostics. The kg_status field reports the overall graph status and can have the following values:

kg_status value Description
CREATING Graph creation is in progress.
READY Core graph creation is complete. Status checks detected no outstanding failures or pending artifacts.
READY_PARTIAL Core graph creation is complete, but some extraction, summary, or embedding work has failed or remains incomplete. You can query the graph using the available information.
FAILED Graph creation failed or stopped before completion, or required graph objects are missing.

Example

This example retrieves the status of the BOOKS_KG knowledge graph.

DECLARE
    l_status JSON;
BEGIN
    l_status := DBMS_AI_GRAPHRAG.GET_KNOWLEDGE_GRAPH_STATUS(
        kg_name => 'BOOKS_KG'
    );
END;
/