TomTom Maps for JavaScript
    Preparing search index...

    Type Alias MapAgentInstance<CS>

    MapAgentInstance: ToolLoopAgent & {
        state: CS;
        destroy(): void;
        getCodeExecutionMode(): CodeExecutionMode;
    }

    The return type of createMapAgent(), a real ToolLoopAgent instance with state access and cleanup.

    Type Parameters

    Type Declaration

    • Readonlystate: CS

      Live agent state (built-in + custom slices).

    • destroy: function
      • Tears down by resetting all state slices that have a reset() method.

        Returns void

    • getCodeExecutionMode: function
      • Where the data tools' generated code runs now. In a browser, unavailable (code fails) and main-thread (code runs unisolated) both mean the iframe sandbox couldn't start.

        Returns CodeExecutionMode