actrone-memory
    Preparing search index...

    Function llamaindexMemory

    • LlamaIndex.TS: memory for a llamaindex agent / chat engine. getSystemPrompt returns the governed context to pass as the agent's systemPrompt (or prepend to it) for the turn, and saveTurn persists the completed exchange: call them around agent.chat({ message }). Structural, so llamaindex stays an optional peer dependency.

      Parameters

      Returns {
          getSystemPrompt: (
              query: string,
              tokenBudget?: number,
          ) => Promise<string>;
          saveTurn: (
              userMessage: string,
              assistantMessage: string,
          ) => Promise<string>;
      }