@@ -187,11 +187,6 @@ class Valves(BaseModel):
187187 description = "Azure Search index name for RAG" ,
188188 )
189189
190- AZURE_SEARCH_PROJECT_RESOURCE_ID : str = Field (
191- default = os .getenv ("AZURE_SEARCH_PROJECT_RESOURCE_ID" , "" ),
192- description = "Azure Search project resource ID" ,
193- )
194-
195190 AZURE_SEARCH_KEY : EncryptedStr = Field (
196191 default = os .getenv ("AZURE_SEARCH_KEY" , "" ),
197192 description = "Azure Search API key" ,
@@ -209,16 +204,6 @@ class Valves(BaseModel):
209204 description = "Azure Search semantic configuration name" ,
210205 )
211206
212- AZURE_SEARCH_EMBEDDING_ENDPOINT : str = Field (
213- default = os .getenv ("AZURE_SEARCH_EMBEDDING_ENDPOINT" , "" ),
214- description = "Azure Search embedding endpoint URL" ,
215- )
216-
217- AZURE_SEARCH_EMBEDDING_KEY : EncryptedStr = Field (
218- default = os .getenv ("AZURE_SEARCH_EMBEDDING_KEY" , "" ),
219- description = "Azure Search embedding API key" ,
220- )
221-
222207 AZURE_SEARCH_QUERY_TYPE : str = Field (
223208 default = os .getenv ("AZURE_SEARCH_QUERY_TYPE" , "vectorSimpleHybrid" ),
224209 description = "Azure Search query type (vectorSimpleHybrid, vector, semantic)" ,
@@ -339,7 +324,7 @@ def get_azure_search_data_sources(self) -> Optional[List[Dict[str, Any]]]:
339324 ):
340325 auth_config ["key" ] = self .valves .AZURE_SEARCH_KEY .get_decrypted ()
341326
342- # Build the data source configuration
327+ # Build the data source configuration with only officially supported parameters
343328 data_source = {
344329 "type" : "azure_search" ,
345330 "parameters" : {
@@ -355,40 +340,12 @@ def get_azure_search_data_sources(self) -> Optional[List[Dict[str, Any]]]:
355340 },
356341 }
357342
358- # Add optional project resource ID if configured
359- if self .valves .AZURE_SEARCH_PROJECT_RESOURCE_ID :
360- data_source ["parameters" ]["project_resource_id" ] = (
361- self .valves .AZURE_SEARCH_PROJECT_RESOURCE_ID
362- )
363-
364343 # Add semantic configuration if configured
365344 if self .valves .AZURE_SEARCH_SEMANTIC_CONFIGURATION :
366345 data_source ["parameters" ]["semantic_configuration" ] = (
367346 self .valves .AZURE_SEARCH_SEMANTIC_CONFIGURATION
368347 )
369348
370- # Add embedding configuration if configured
371- if self .valves .AZURE_SEARCH_EMBEDDING_ENDPOINT :
372- data_source ["parameters" ]["embeddingEndpoint" ] = (
373- self .valves .AZURE_SEARCH_EMBEDDING_ENDPOINT
374- )
375- data_source ["parameters" ]["embedding_dependency" ] = None
376-
377- if self .valves .AZURE_SEARCH_EMBEDDING_KEY :
378- data_source ["parameters" ]["embeddingKey" ] = (
379- self .valves .AZURE_SEARCH_EMBEDDING_KEY .get_decrypted ()
380- )
381-
382- # Add additional Azure Search parameters if using API key
383- if (
384- self .valves .AZURE_SEARCH_AUTHENTICATION_TYPE == "api_key"
385- and self .valves .AZURE_SEARCH_KEY
386- ):
387- data_source ["parameters" ]["key" ] = (
388- self .valves .AZURE_SEARCH_KEY .get_decrypted ()
389- )
390- data_source ["parameters" ]["indexName" ] = self .valves .AZURE_SEARCH_INDEX_NAME
391-
392349 return [data_source ]
393350
394351 def parse_models (self , models_str : str ) -> List [str ]:
0 commit comments