/** * TestChimp Runner Core * Shared functionality for VS Code extension and GitHub Actions */ import { ExecutionService } from './execution-service'; import { ScenarioService } from './scenario-service'; import { ScenarioWorker } from './scenario-worker-class'; import { PlaywrightMCPService } from './playwright-mcp-service'; import { LLMFacade } from './llm-facade'; import { AuthConfig } from './auth-config'; import { CreditUsageService, CreditUsageCallback, CreditUsage, CreditUsageReason } from './credit-usage-service'; import { RUNNER_CORE_BUILD_TAG } from './build-info'; export { ExecutionService, ScenarioService, ScenarioWorker, PlaywrightMCPService, LLMFacade, CreditUsageService, CreditUsageCallback, CreditUsage, CreditUsageReason }; export { RUNNER_CORE_BUILD_TAG }; import { FileHandler, LocalFileHandler, CIFileHandler, NoOpFileHandler } from './file-handler'; export { FileHandler, LocalFileHandler, CIFileHandler, NoOpFileHandler }; import { LLMProvider, LLMRequest, LLMResponse } from './llm-provider'; import { ProgressReporter, StepProgress, JobProgress, StepExecutionStatus, StepInfo, DebugStats, ToolUsageStats, TokenUsage, StepProgressResponse, StepModificationResult } from './progress-reporter'; import { BackendProxyLLMProvider } from './providers/backend-proxy-llm-provider'; import { LocalLLMProvider } from './providers/local-llm-provider'; export { LLMProvider, LLMRequest, LLMResponse }; export { ProgressReporter, StepProgress, JobProgress, StepExecutionStatus, StepInfo, DebugStats, ToolUsageStats, TokenUsage, StepProgressResponse, StepModificationResult }; export { BackendProxyLLMProvider, LocalLLMProvider }; import type { AgentConfig, SiteLearnings } from './orchestrator'; export { OrchestratorAgent, ToolRegistry, Tool, ToolParameter, ToolExecutionContext, AgentConfig, AgentContext, AgentDecision, JourneyMemory, MemoryStep, SiteLearnings, // Exported for scriptservice to use ScreenLearnings, ScreenStateLearning, OrchestratorStepResult, SelfReflection, ToolCall, ToolResult, ExplorationMode, DEFAULT_AGENT_CONFIG } from './orchestrator'; export * from './types'; export { PageInfo, InteractiveElement } from './utils/page-info-utils'; export { DEFAULT_MODEL, DEFAULT_SIMPLER_MODEL, VISION_MODEL } from './model-constants'; export * from './auth-config'; export { loadEnvConfig } from './env-loader'; export * from './script-utils'; export { TestFileParser, parseScenarioAnnotationComponents } from './utils/test-file-parser'; export type { ParsedTestFile, ParsedSuite, ParsedTest, ParsedHook, ParsedTestStatement, ScenarioAnnotationComponents } from './utils/test-file-parser'; export { InitializationCodeUtils } from './utils/initialization-code-utils'; export { denormalizePomSteps } from './utils/pom-denormalizer'; export declare class TestChimpService { private executionService; scenarioService: ScenarioService; private playwrightService; private llmProvider; private progressReporter?; private creditUsageService; private fileHandler; private authConfig; private backendUrl; private logger?; private orchestratorOptions?; private outputChannel?; private creditUsageCallback?; constructor(fileHandler?: FileHandler, authConfig?: AuthConfig, backendUrl?: string, maxWorkers?: number, llmProvider?: LLMProvider, progressReporter?: ProgressReporter, orchestratorOptions?: { orchestratorConfig?: Partial; debugMode?: boolean; }, creditUsageCallback?: CreditUsageCallback); /** * Set authentication configuration for the service * Recreates LLM provider and services with new auth config */ setAuthConfig(authConfig: AuthConfig): Promise; /** * Set backend URL for the service * Recreates LLM provider and services with new backend URL */ setBackendUrl(backendUrl: string): void; /** * Set logger callback for capturing execution logs */ setLogger(logger: (message: string, level?: 'log' | 'error' | 'warn') => void): void; /** * Set output channel for worker logs (VS Code OutputChannel) * This enables orchestrator thinking logs to appear in output console */ setOutputChannel(outputChannel: any): void; /** * Set credit usage callback * Server-side: Use callback to update DB directly (no axios calls) * Client-side: Don't set callback, uses auth for axios calls to backend */ setCreditUsageCallback(callback: CreditUsageCallback): void; /** * Log a message using the configured logger */ private log; /** * Get current authentication configuration */ getAuthConfig(): AuthConfig | null; /** * Get SOM handler from orchestrator agent (for bug artifact analysis) * Returns handler from execution service (test-based) or scenario service (exploration) */ getSomHandler(): any; initialize(): Promise; shutdown(): Promise; generateScript(scenario: string, testName?: string, config?: string, model?: string, scenarioFileName?: string, existingBrowser?: any, existingContext?: any, existingPage?: any, existingSiteLearnings?: SiteLearnings, jobId?: string, // Optional jobId from caller (e.g., scriptservice) headless?: boolean, // defaults to false (headed mode) steps?: Array<{ description: string; code?: string; }>, // Predefined steps (skip LLM breakdown) initialUrl?: string): Promise; executeScript(request: any): Promise; executeScriptWithAIRepair(request: any): Promise; runTestFile(request: any): Promise; executeExploration(page: any, explorationConfig: any, jobId: string, existingSiteLearnings?: SiteLearnings): Promise; reportScriptGenerationCredit(jobId?: string): Promise; reportAIRepairCredit(jobId?: string): Promise; findTestChimpTests(directory: string, recursive?: boolean): string[]; } //# sourceMappingURL=index.d.ts.map