lloyal-agents API Reference
    Preparing search index...

    Class CorpusSource

    Corpus-backed research source using local file search, read, and grep

    Provides grounding tools (search, read_file, grep) over a set of loaded Resource / Chunk pairs. On bind, tokenizes chunks via the reranker and prepends a reranker-backed search tool to the tool list. The search tool is ordered first so the model prefers semantic search before falling back to read_file or grep.

    The research tool is a self-referential ResearchTool that spawns sub-agents with corpus-specific prompts and the full grounding toolkit.

    Hierarchy

    Index

    Constructors

    Properties

    Accessors

    Methods

    Constructors

    Properties

    name: "corpus"

    Accessors

    • get groundingTools(): Tool<Record<string, unknown>>[]

      Returns Tool<Record<string, unknown>>[]

    Methods

    • Late-bind reranker and build the research toolkit

      Tokenizes all chunks through the reranker, prepends a SearchTool to the tool list, then constructs the self-referential ResearchTool with corpus-specific prompts. Idempotent — skips if already bound.

      Parameters

      Returns Operation<void>