Coder Social home page Coder Social logo

search-dotnet-getting-started's Introduction

page_type description languages products
sample
Contains several projects to help you get started with Azure AI Search and the .NET SDK
csharp
azure
azure-cognitive-search

Getting Started with Azure AI Search using .NET

This repository includes several projects that show you how to use the Azure.Search.Documents client library in Azure SDK for .NET to create C# applications that use Azure AI Search.

An earlier version of the samples that were built using the Microsoft.Azure.Search client libraries can be found in the v10 branch of this repo. To download those versions, switch the branch from master to v10, and then select Code to download or open those samples.

DotNetHowTo

This sample is a simple .NET Core console application that shows you how to:

  • Create and delete a search index
  • Upload documents
  • Search and filter documents within an index

To run this sample, open the solution in Visual Studio and modify appsettings.json to use valid values for your search service.

DotNetHowToEncryptionUsingCMK

This sample demonstrates how to create a synonym-map and an index that are encrypted with a customer-managed key in Azure Key Vault. This sample uses several services that must be set up in advance: Azure Key Vault, Azure Active Directory, and modifications to your existing search service.

The appsettings.json file provides placeholders for service information.

For detailed instructions, see How to configure customer-managed keys for data encryption in Azure AI Search.

DotNetHowToSynonyms

This sample demonstrates the benefits of adding a synonym map using "before-and-after" queries:

  • Creates a search index
  • Searches for documents using terms that do not appear in the indexed documents (query returns no results)
  • Define and upload synonym rules
  • Re-run the queries. This time, query results are found due to matching synonyms in the synonym list.

To run this sample, open the solution in Visual Studio and modify app.config to use valid values for your search service.

For detailed instructions, see Example: Add synonyms for Azure AI Search in C#.

DotNetHowToIndexers

This sample is a simple .NET Core console application that shows how create and run a search indexer that retrieves data from an Azure SQL database.

Before you can run this sample, you will need an Azure SQL database that contains sample data used by the indexer. You will also need to modify settings in appsettings.json.

  1. Create a new database in Azure SQL named hotels.
  2. Run the data\hotels.sql script provided in this sample against your Azure SQL database.
  3. Open the DotNetHowToIndexers.sln in Visual Studio.
  4. Update the appsettings.json with your service name, api key, and connection string to your Azure SQL database.
  5. Compile and Run the project using Visual Studio.

DotNetETagsExplainer

This sample is a .NET Core console application that shows how to use ETags to update Azure AI Search resources safely in the presence of concurrency. The code in this sample simulates concurrent write operations so that you can see how that condition is handled.

To run this sample, open the solution in Visual Studio and modify appsettings.json to use valid values for your search service.

Retired samples

The following samples have been removed from the master branch.

DotNetHowToSecurityTrimming (Archived)

This sample is now archived. It's replaced by instructions for setting up access control on the azure-search-openai-demo.

DotNetHowToAutocomplete

This sample was not migrated to use the Azure.Search.Documents client library. It has been replaced by a project in the create-first-app sample in the azure-search-dotnet-samples repository. Alternatively, you can look at the v10 version of the sample.

DotNetHowToMultipleDataSources

This sample was not migrated to use the Azure.Search.Documents client library. It has been replaced by the multiple-data-sources sample in the azure-search-dotnet-samples repository. Alternatively, you can look at the v10 version of the sample.

DotNetSample

This sample was not migrated to use the Azure.Search.Documents client library. We recommend that you refer to DotNetHowToIndexers to view code that calls the Azure SQL Indexer. Alternatively, you can look at the v10 version of the sample.


This project has adopted the Microsoft Open Source Code of Conduct. For more information see the Code of Conduct FAQ or contact [email protected] with any additional questions or comments.

search-dotnet-getting-started's People

Contributors

brjohnstmsft avatar heidisteen avatar acomsmpbot avatar mhko avatar mrcarter8 avatar dependabot[bot] avatar liamca avatar supernova-eng avatar mgottein avatar gavinkendall avatar natinimni avatar nithinmohantk avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.