import { type SessionEvent } from "@github/copilot-sdk"; import type { TrajectoryEvent } from "./types.js"; type ToolStartEvent = Extract; export interface CopilotTrajectoryConverterOptions { /** * Indicates the events are coming from a Copilot CLI log, which changes where we expect some data to come from: * - Token usage counts will come from a session.shutdown event, rather than assistant.usage */ fromLog?: boolean; } /** * Handles converting incoming Copilot events (either SDK, or Copilot CLI log events) * and converting them to our internal Trajectory format. * * @example * const adapter = new CopilotAdapter(); * * // if using a copilot SDK session * session.on(() => { adapter.on(e) }); * * // or just feed events directly from an events.jsonl file. * for (const line of lines) { * adapter.on(JSON.parse(line)); * } */ export declare class CopilotAdapter { events: TrajectoryEvent[]; model?: string; sessionId?: string; workspace?: string; skillsLoaded: string[]; options: CopilotTrajectoryConverterOptions; toolsMap: Map; constructor(opts?: CopilotTrajectoryConverterOptions); on(event: SessionEvent): void; } export {}; //# sourceMappingURL=copilot-adapter.d.ts.map