@squidcloud/client
    Preparing search index...

    Interface GetKnowledgeBaseGraphStatusResponse

    Response structure for a knowledge base's GraphRAG build/readiness status. Drives the ai-eval readiness poll (index until contextsIndexed === contextsTotal and buildJob is not in-progress).

    interface GetKnowledgeBaseGraphStatusResponse {
        buildJob?: KnowledgeBaseGraphBuildJob;
        combinedIngestUsage?: KnowledgeBaseGraphUsage;
        communityCount: number;
        contextsIndexed: number;
        contextsTotal: number;
        docNodesTotal?: number;
        docsDescribed?: number;
        enabled: boolean;
        entityCount: number;
        facets?: KnowledgeBaseGraphFacetStatus[];
        ingestUsage?: KnowledgeBaseGraphUsage;
        lastRebuildUsage?: KnowledgeBaseGraphUsage;
        relationshipCount: number;
        staleDocCount?: number;
        structureStale?: boolean;
        topicEdges?: KnowledgeBaseGraphTopicEdge[];
        topics?: KnowledgeBaseGraphTopic[];
    }
    Index

    Properties

    Status of the most recent backfill/rebuild job, when one exists.

    combinedIngestUsage?: KnowledgeBaseGraphUsage

    Lifetime LLM usage of the combined contextual-blurb + graph-extraction call (run automatically for ragType:'contextual' graph-enabled KBs), when any was recorded. Covers BOTH the contextual blurb and graph extraction in one call, so it is not directly comparable to the graph-only ingestUsage.

    communityCount: number

    Number of communities detected (Phase 3), 0 when none.

    contextsIndexed: number

    Contexts stamped as graph-indexed.

    contextsTotal: number

    Total contexts in the KB.

    docNodesTotal?: number

    Document nodes in the KB's graph (Layered KB Graph L1) — one per graph-indexed context.

    docsDescribed?: number

    Document nodes carrying a non-empty LLM description (failed descriptions retry on rebuild).

    enabled: boolean

    Whether GraphRAG is enabled on the KB.

    entityCount: number

    Number of entities in the KB's graph partition.

    The KB's facet trees (Layered KB Graph L3, deterministic) — empty until a rebuild builds them.

    Lifetime LLM usage of incremental graph ingestion (per-upsert extraction), when any was recorded.

    lastRebuildUsage?: KnowledgeBaseGraphUsage

    LLM usage of the most recent rebuildGraph run (including its re-extraction), when one ran.

    relationshipCount: number

    Number of outgoing relationships (mirrors excluded).

    staleDocCount?: number

    Documents added since the last topic build (the structureStale numerator).

    structureStale?: boolean

    True when documents were graph-indexed after the last topic build — themes may lag content until the next rebuildGraph. Only meaningful once topics exist (absent before the first rebuild).

    Leaf-level inter-topic edges (relationship counts crossing topic boundaries), present once a graph build has computed them. Roll up to coarser tiers by mapping each endpoint to its ancestor.

    The KB's topic (theme) hierarchy — present once a graph build has clustered topics. Ids churn on rebuild (KnowledgeBaseGraphTopic.id); resolve them per session, never persist them.