MCPcopy
hub / github.com/mixedbread-ai/mgrep / Store

Interface Store

src/lib/store.ts:77–145  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

75}
76
77export interface Store {
78 /**
79 * List files in a store as an async iterator
80 *
81 * @param storeId - The ID of the store
82 * @param options - Optional filtering options
83 * @param options.pathPrefix - Only return files whose path starts with this prefix
84 */
85 listFiles(
86 storeId: string,
87 options?: ListFilesOptions,
88 ): AsyncGenerator<StoreFile>;
89
90 /**
91 * Upload a file to a store
92 */
93 uploadFile(
94 storeId: string,
95 file: File | ReadableStream,
96 options: UploadFileOptions,
97 ): Promise<void>;
98
99 /**
100 * Delete a file from a store by its external ID
101 */
102 deleteFile(storeId: string, externalId: string): Promise<void>;
103
104 /**
105 * Search in one or more stores
106 */
107 search(
108 storeIds: string[],
109 query: string,
110 top_k?: number,
111 search_options?: SearchOptions,
112 filters?: SearchFilter,
113 ): Promise<SearchResponse>;
114
115 /**
116 * Retrieve store information
117 */
118 retrieve(storeId: string): Promise<unknown>;
119
120 /**
121 * Create a new store
122 */
123 create(options: CreateStoreOptions): Promise<unknown>;
124
125 /**
126 * Ask a question to one or more stores
127 */
128 ask(
129 storeIds: string[],
130 question: string,
131 top_k?: number,
132 search_options?: SearchOptions,
133 filters?: SearchFilter,
134 ): Promise<AskResponse>;

Callers 14

listStoreFileMetadataFunction · 0.65
uploadFileFunction · 0.65
deleteFileFunction · 0.65
initialSyncFunction · 0.65
search.tsFile · 0.65
searchMethod · 0.65
startWatchFunction · 0.65
retrieveMethod · 0.65
getInfoMethod · 0.65
startWatchFunction · 0.65
createMethod · 0.65
search.tsFile · 0.65

Implementers 2

MixedbreadStoresrc/lib/store.ts
TestStoresrc/lib/store.ts

Calls

no outgoing calls

Tested by

no test coverage detected