Skip to content

Commit

Permalink
[Search] Regenerate with 2024-03-01-Preview spec (Azure#28576)
Browse files Browse the repository at this point in the history
  • Loading branch information
dgetu authored Mar 17, 2024
1 parent 0108b2b commit d738efb
Show file tree
Hide file tree
Showing 108 changed files with 7,835 additions and 5,915 deletions.
499 changes: 207 additions & 292 deletions .vscode/cspell.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion sdk/search/perf-tests/search-documents/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"license": "ISC",
"dependencies": {
"@azure/identity": "^4.0.1",
"@azure/search-documents": "12.0.0-beta.4",
"@azure/search-documents": "12.1.0-beta.1",
"@azure/test-utils-perf": "^1.0.0",
"dotenv": "^16.0.0"
},
Expand Down
14 changes: 14 additions & 0 deletions sdk/search/search-documents/.eslintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
{
"overrides": [
{
"files": ["samples-dev/**.ts"],
"rules": {
// Suppresses errors for the custom TSDoc syntax we use for docs
"tsdoc/syntax": "off",
// Suppresses spurious missing dependency error as ESLint thinks the sample's runtime deps
// should be runtime deps for us too
"import/no-extraneous-dependencies": "off"
}
}
]
}
3 changes: 0 additions & 3 deletions sdk/search/search-documents/.vscode/settings.json

This file was deleted.

92 changes: 92 additions & 0 deletions sdk/search/search-documents/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,97 @@
# Release History

## 12.1.0-beta.1 (2024-02-06)

### Breaking Changes

- Refactor in alignment with v12 [#28576](https://github.com/Azure/azure-sdk-for-js/pull/28576)
- Replace or replace the following types/properties
- Use `ExhaustiveKnnAlgorithmConfiguration` in place of
- `ExhaustiveKnnVectorSearchAlgorithmConfiguration`
- Use `HnswAlgorithmConfiguration` in place of
- `HnswVectorSearchAlgorithmConfiguration`
- Use `PIIDetectionSkill.categories` in place of
- `PIIDetectionSkill.piiCategories`
- Use `QueryAnswer` in place of
- `Answers`
- `AnswersOption`
- `QueryAnswerType`
- Use `QueryAnswerResult` in place of
- `AnswerResult`
- Use `QueryCaption` in place of
- `Captions`
- `QueryCaptionType`
- Use `QueryCaptionResult` in place of
- `CaptionResult`
- Use `SearchRequestOptions.VectorSearchOptions.filterMode` in place of
- `SearchRequestOptions.vectorFilterMode`
- Use `SearchRequestOptions.VectorSearchOptions.queries` in place of
- `SearchRequestOptions.vectorQueries`
- Use `SearchRequestOptions.semanticSearchOptions.answers` in place of
- `SearchRequestOptions.answers`
- Use `SearchRequestOptions.semanticSearchOptions.captions` in place of
- `SearchRequestOptions.captions`
- Use `SearchRequestOptions.semanticSearchOptions.configurationName` in place of
- `SearchRequestOptions.semanticConfiguration`
- Use `SearchRequestOptions.semanticSearchOptions.debugMode` in place of
- `SearchRequestOptions.debugMode`
- Use `SearchRequestOptions.semanticSearchOptions.errorMode` in place of
- `SearchRequestOptions.semanticErrorHandlingMode`
- Use `SearchRequestOptions.semanticSearchOptions.maxWaitInMilliseconds` in place of
- `SearchRequestOptions.semanticMaxWaitInMilliseconds`
- Use `SearchRequestOptions.semanticSearchOptions.semanticFields` in place of
- `SearchRequestOptions.semanticFields`
- Use `SearchRequestOptions.semanticSearchOptions.semanticQuery` in place of
- `SearchRequestOptions.semanticQuery`
- Use `SemanticErrorMode` in place of
- `SemanticErrorHandlingMode`
- Use `SemanticErrorReason` in place of
- `SemanticPartialResponseReason`
- Use `SemanticPrioritizedFields` in place of
- `PrioritizedFields`
- Use `SemanticSearch` in place of
- `SemanticSettings`
- Use `SemanticSearchResultsType` in place of
- `SemanticPartialResponseType`
- Use `SimpleField.vectorSearchProfileName` in place of
- `SimpleField.vectorSearchProfile`
- Use `VectorSearchProfile.algorithmConfigurationName` in place of
- `VectorSearchProfile.algorithm`
- Narrow some enum property types to the respective string literal union
- `BlobIndexerDataToExtract`
- `BlobIndexerImageAction`
- `BlobIndexerParsingMode`
- `BlobIndexerPDFTextRotationAlgorithm`
- `CustomEntityLookupSkillLanguage`
- `EntityCategory`
- `EntityRecognitionSkillLanguage`
- `ImageAnalysisSkillLanguage`
- `ImageDetail`
- `IndexerExecutionEnvironment`
- `KeyPhraseExtractionSkillLanguage`
- `OcrSkillLanguage`
- `RegexFlags`
- `SearchIndexerDataSourceType`
- `SentimentSkillLanguage`
- `SplitSkillLanguage`
- `TextSplitMode`
- `TextTranslationSkillLanguage`
- `VisualFeature`
- Remove `KnownLexicalAnalyzerName` as a duplicate of `KnownAnalyzerNames`
- Remove `KnownCharFilterName` as a duplicate of `KnownCharFilterNames`
- Remove `KnownTokenFilterName` as a duplicate of `KnownTokenFilterNames`
- Remove `SearchRequest` as a duplicate of `SearchRequestOptions`

### Features Added

- Add vector compression [#28772](https://github.com/Azure/azure-sdk-for-js/pull/28772)
- Service-side scalar quantization of your vector data
- Optional reranking with full-precision vectors
- Optional oversampling of documents when reranking compressed vectors
- Add `Edm.Half`, `Edm.Int16`, and `Edm.SByte` vector spaces [#28772](https://github.com/Azure/azure-sdk-for-js/pull/28772)
- Add non-persistent vector usage through `SimpleField.stored` [#28772](https://github.com/Azure/azure-sdk-for-js/pull/28772)
- Expose the internal HTTP pipeline to allow users to send raw requests with it

## 12.0.0-beta.4 (2023-10-11)

### Features Added
Expand Down
6 changes: 3 additions & 3 deletions sdk/search/search-documents/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ The Azure AI Search service is well suited for the following application scenari
* In a search client application, implement query logic and user experiences
similar to commercial web search engines and chat-style apps.

Use the Azure.Search.Documents client library to:
Use the @azure/search-documents client library to:

* Submit queries using vector, keyword, and hybrid query forms.
* Implement filtered queries for metadata, geospatial search, faceted navigation,
Expand Down Expand Up @@ -349,14 +349,14 @@ interface Hotel {
hotelId?: string;
hotelName?: string | null;
description?: string | null;
descriptionVector?: Array<number> | null;
descriptionVector?: Array<number>;
parkingIncluded?: boolean | null;
lastRenovationDate?: Date | null;
rating?: number | null;
rooms?: Array<{
beds?: number | null;
description?: string | null;
} | null>;
}>;
}

const client = new SearchClient<Hotel>(
Expand Down
14 changes: 7 additions & 7 deletions sdk/search/search-documents/api-extractor.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,22 +10,22 @@
},
"dtsRollup": {
"enabled": true,
"untrimmedFilePath": "",
"publicTrimmedFilePath": "./types/search-documents.d.ts"
"publicTrimmedFilePath": "./types/search-documents.d.ts",
"untrimmedFilePath": ""
},
"messages": {
"tsdocMessageReporting": {
"default": {
"logLevel": "none"
}
},
"extractorMessageReporting": {
"ae-missing-release-tag": {
"logLevel": "none"
},
"ae-unresolved-link": {
"logLevel": "none"
}
},
"tsdocMessageReporting": {
"default": {
"logLevel": "none"
}
}
}
}
2 changes: 1 addition & 1 deletion sdk/search/search-documents/assets.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@
"AssetsRepo": "Azure/azure-sdk-assets",
"AssetsRepoPrefixPath": "js",
"TagPrefix": "js/search/search-documents",
"Tag": "js/search/search-documents_f8e9f163e2"
"Tag": "js/search/search-documents_b75f2ec5af"
}
4 changes: 0 additions & 4 deletions sdk/search/search-documents/openai-patch.diff

This file was deleted.

65 changes: 33 additions & 32 deletions sdk/search/search-documents/package.json
Original file line number Diff line number Diff line change
@@ -1,44 +1,44 @@
{
"name": "@azure/search-documents",
"version": "12.0.0-beta.4",
"version": "12.1.0-beta.1",
"description": "Azure client library to use Cognitive Search for node.js and browser.",
"sdk-type": "client",
"main": "dist/index.js",
"module": "dist-esm/src/index.js",
"types": "types/search-documents.d.ts",
"scripts": {
"audit": "node ../../../common/scripts/rush-audit.js && rimraf node_modules package-lock.json && npm i --package-lock-only 2>&1 && npm audit",
"build": "npm run clean && tsc -p . && dev-tool run bundle && api-extractor run --local",
"build:browser": "tsc -p . && dev-tool run bundle",
"build:node": "tsc -p . && dev-tool run bundle",
"build:samples": "echo Obsolete.",
"execute:samples": "dev-tool samples run samples-dev",
"build:test": "tsc -p . && dev-tool run bundle",
"build": "npm run clean && tsc -p . && dev-tool run bundle && api-extractor run --local",
"check-format": "dev-tool run vendored prettier --list-different --config ../../../.prettierrc.json --ignore-path ../../../.prettierignore \"src/**/*.ts\" \"test/**/*.ts\" \"samples-dev/**/*.ts\" \"*.{js,json}\"",
"clean": "rimraf --glob dist dist-* temp types *.tgz *.log",
"execute:samples": "dev-tool samples run samples-dev",
"extract-api": "tsc -p . && api-extractor run --local",
"format": "dev-tool run vendored prettier --write --config ../../../.prettierrc.json --ignore-path ../../../.prettierignore \"src/**/*.ts\" \"test/**/*.ts\" \"samples-dev/**/*.ts\" \"*.{js,json}\"",
"generate:client": "autorest --typescript swagger/Service.md & autorest --typescript swagger/Data.md & wait",
"generate:embeddings": "ts-node scripts/generateSampleEmbeddings.ts",
"integration-test": "npm run integration-test:node && npm run integration-test:browser",
"integration-test:browser": "dev-tool run test:browser",
"integration-test:node": "dev-tool run test:node-js-input -- --timeout 5000000 'dist-esm/test/**/*.spec.js'",
"integration-test": "npm run integration-test:node && npm run integration-test:browser",
"lint:fix": "eslint package.json api-extractor.json src test --ext .ts --fix --fix-type [problem,suggestion]",
"lint": "eslint package.json api-extractor.json src test --ext .ts",
"lint": "eslint package.json api-extractor.json src test samples-dev --ext .ts",
"lint:fix": "eslint package.json api-extractor.json src test samples-dev --ext .ts --fix --fix-type [problem,suggestion]",
"pack": "npm pack 2>&1",
"test": "npm run build:test && npm run unit-test",
"test:browser": "npm run build:test && npm run unit-test:browser",
"test:node": "npm run build:test && npm run unit-test:node",
"test": "npm run build:test && npm run unit-test",
"unit-test": "npm run unit-test:node && npm run unit-test:browser",
"unit-test:browser": "dev-tool run test:browser",
"unit-test:node": "dev-tool run test:node-ts-input -- --timeout 1200000 \"test/**/*.spec.ts\" \"test/**/**/*.spec.ts\"",
"unit-test": "npm run unit-test:node && npm run unit-test:browser"
"unit-test:node": "dev-tool run test:node-ts-input -- --timeout 1200000 \"test/**/*.spec.ts\" \"test/**/**/*.spec.ts\""
},
"files": [
"dist/",
"dist-esm/src/",
"types/search-documents.d.ts",
"LICENSE",
"README.md",
"LICENSE"
"dist-esm/src/",
"dist/",
"types/search-documents.d.ts"
],
"browser": {
"./dist-esm/src/base64.js": "./dist-esm/src/base64.browser.js",
Expand All @@ -47,12 +47,8 @@
"//metadata": {
"constantPaths": [
{
"path": "swagger/Service.md",
"prefix": "package-version"
},
{
"path": "swagger/Data.md",
"prefix": "package-version"
"path": "src/constants.ts",
"prefix": "SDK_VERSION"
},
{
"path": "src/generated/data/searchClient.ts",
Expand All @@ -63,8 +59,12 @@
"prefix": "packageDetails"
},
{
"path": "src/constants.ts",
"prefix": "SDK_VERSION"
"path": "swagger/Data.md",
"prefix": "package-version"
},
{
"path": "swagger/Service.md",
"prefix": "package-version"
}
]
},
Expand All @@ -84,31 +84,34 @@
"homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/search/search-documents/",
"sideEffects": false,
"dependencies": {
"@azure/core-client": "^1.3.0",
"@azure/core-auth": "^1.3.0",
"@azure/core-client": "^1.3.0",
"@azure/core-http-compat": "^2.0.1",
"@azure/core-paging": "^1.1.1",
"@azure/core-tracing": "^1.0.0",
"@azure/core-rest-pipeline": "^1.3.0",
"@azure/core-http-compat": "^2.0.1",
"@azure/core-tracing": "^1.0.0",
"@azure/logger": "^1.0.0",
"tslib": "^2.2.0",
"events": "^3.0.0"
"events": "^3.0.0",
"tslib": "^2.2.0"
},
"devDependencies": {
"@azure/openai": "1.0.0-beta.12",
"@azure/test-utils": "^1.0.0",
"@azure-tools/test-recorder": "^3.0.0",
"@azure/core-util": "^1.6.1",
"@azure/dev-tool": "^1.0.0",
"@azure/eslint-plugin-azure-sdk": "^3.0.0",
"@azure-tools/test-recorder": "^3.0.0",
"@azure/openai": "1.0.0-beta.12",
"@azure/test-utils": "^1.0.0",
"@microsoft/api-extractor": "^7.31.1",
"@types/chai": "^4.1.6",
"@types/mocha": "^10.0.0",
"@types/node": "^18.0.0",
"@types/sinon": "^17.0.0",
"c8": "^8.0.0",
"chai": "^4.2.0",
"cross-env": "^7.0.2",
"dotenv": "^16.0.0",
"eslint": "^8.0.0",
"esm": "^3.2.18",
"inherits": "^2.0.3",
"karma": "^6.2.0",
"karma-chrome-launcher": "^3.0.0",
Expand All @@ -122,13 +125,11 @@
"karma-mocha-reporter": "^2.2.5",
"karma-sourcemap-loader": "^0.3.8",
"mocha": "^10.0.0",
"c8": "^8.0.0",
"rimraf": "^5.0.5",
"sinon": "^17.0.0",
"ts-node": "^10.0.0",
"typescript": "~5.3.3",
"util": "^0.12.1",
"esm": "^3.2.18"
"util": "^0.12.1"
},
"//sampleConfiguration": {
"productName": "Azure Search Documents",
Expand Down
Loading

0 comments on commit d738efb

Please sign in to comment.