(
private readonly configHandler: ConfigHandler,
private readonly ide: IDE,
private readonly _injectedGetLlm: () => Promise<ILLM | undefined>,
private readonly _onError: (e: any) => void,
private readonly getDefinitionsFromLsp: GetLspDefinitionsFunction,
endpointType: "default" | "fineTuned",
)
| 76 | private modelProvider: BaseNextEditModelProvider | null = null; |
| 77 | |
| 78 | private constructor( |
| 79 | private readonly configHandler: ConfigHandler, |
| 80 | private readonly ide: IDE, |
| 81 | private readonly _injectedGetLlm: () => Promise<ILLM | undefined>, |
| 82 | private readonly _onError: (e: any) => void, |
| 83 | private readonly getDefinitionsFromLsp: GetLspDefinitionsFunction, |
| 84 | endpointType: "default" | "fineTuned", |
| 85 | ) { |
| 86 | this.completionStreamer = new CompletionStreamer(this.onError.bind(this)); |
| 87 | this.contextRetrievalService = new ContextRetrievalService(this.ide); |
| 88 | this.endpointType = endpointType; |
| 89 | this.loggingService = NextEditLoggingService.getInstance(); |
| 90 | } |
| 91 | |
| 92 | public static initialize( |
| 93 | configHandler: ConfigHandler, |
nothing calls this directly
no test coverage detected