-
Notifications
You must be signed in to change notification settings - Fork 212
Expand file tree
/
Copy pathmanager.ts
More file actions
94 lines (80 loc) · 1.91 KB
/
Copy pathmanager.ts
File metadata and controls
94 lines (80 loc) · 1.91 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
import { VectorStoreSearchResult } from "./vector-store"
import * as vscode from "vscode"
/**
* Interface for the code index manager
*/
export interface ICodeIndexManager {
/**
* Event emitted when progress is updated
*/
onProgressUpdate: vscode.Event<{
systemStatus: IndexingState
fileStatuses: Record<string, string>
message?: string
}>
/**
* Current state of the indexing process
*/
readonly state: IndexingState
/**
* Whether the code indexing feature is enabled
*/
readonly isFeatureEnabled: boolean
/**
* Whether the code indexing feature is configured
*/
readonly isFeatureConfigured: boolean
/**
* Loads configuration from storage
*/
loadConfiguration(): Promise<void>
/**
* Starts the indexing process
*/
startIndexing(): Promise<void>
/**
* Stops any in-progress indexing operation and the file watcher
*/
stopIndexing(): void
/**
* Stops the file watcher
*/
stopWatcher(): void
/**
* Clears the index data
*/
clearIndexData(): Promise<void>
/**
* Searches the index
* @param query Query string
* @param limit Maximum number of results to return
* @returns Promise resolving to search results
*/
searchIndex(query: string, limit: number): Promise<VectorStoreSearchResult[]>
/**
* Gets the current status of the indexing system
* @returns Current status information
*/
getCurrentStatus(): { systemStatus: IndexingState; fileStatuses: Record<string, string>; message?: string }
/**
* Disposes of resources used by the manager
*/
dispose(): void
}
export type IndexingState = "Standby" | "Indexing" | "Indexed" | "Error" | "Stopping"
export type EmbedderProvider =
| "openai"
| "ollama"
| "openai-compatible"
| "gemini"
| "mistral"
| "vercel-ai-gateway"
| "bedrock"
| "openrouter"
| "semble"
export interface IndexProgressUpdate {
systemStatus: IndexingState
message?: string
processedBlockCount?: number
totalBlockCount?: number
}