Skip to content

Commit

Permalink
Merge pull request #40351 from dotnet/main
Browse files Browse the repository at this point in the history
  • Loading branch information
BillWagner committed Apr 8, 2024
2 parents 59ca7fd + 0dd37de commit 4febfbf
Show file tree
Hide file tree
Showing 26 changed files with 584 additions and 475 deletions.
46 changes: 46 additions & 0 deletions docs/ai/dotnet-ai-ecosystem.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
---
title: Overview of the .NET + AI Ecosystem
description: This article provides an overview of the ecosystem of SDKs and tools available to .NET developers integrating AI into their applications.
ms.date: 04/04/2024
ms.topic: overview
ms.custom: devx-track-dotnet, devx-track-dotnet-ai
---

# Overview of the .NET + AI ecosystem

.NET can be used with many different libraries and tools that support the development of generative AI applications. This page includes a summary of the services and tools you might need to use in your applications, with links to learn more about each of them.

> [!NOTE]
> We recommend using the [Semantic Kernel SDK](/semantic-kernel/overview/) to orchestrate your calls to large language models (LLMs) and manage interactions with the various services mentioned here. Semantic Kernel makes it easy to work with different services without having to learn a different API for each one.
> [!IMPORTANT]
> These SDKs and tools are built by a variety of sources. Not all SDKs are maintained by Microsoft. When considering an SDK, be sure to evaluate its quality, licensing, and support to ensure they meet your requirements. Also make sure you review each SDK's documentation for detailed version compatibility information.
## Working with models

Today, you can use .NET to access models built by OpenAI, using either the Azure OpenAI SDK or the Semantic Kernel. These models can be hosted by OpenAI or in Azure using the Azure AI services. Preview support is coming soon in Semantic Kernel to work with other models, and you can experiment today using open-source SDKs created by the .NET developer community.

| NuGet package | Supported models | Maintainer or vendor | Link to docs |
|----------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------|
| [Microsoft.SemanticKernel](https://www.nuget.org/packages/Microsoft.SemanticKernel/) | [OpenAI models](https://platform.openai.com/docs/models/overview)<br/>[Azure OpenAI supported models](/azure/ai-services/openai/concepts/models) | [Semantic Kernel](https://github.com/microsoft/semantic-kernel) (Microsoft) | [Semantic Kernel documentation](/semantic-kernel/) |
| [Azure OpenAI SDK](https://www.nuget.org/packages/Azure.AI.OpenAI/) | [Azure OpenAI supported models](/azure/ai-services/openai/concepts/models) | [Azure SDK for .NET](https://github.com/Azure/azure-sdk-for-net) (Microsoft) | [Azure OpenAI services documentation](/azure/ai-services/openai/) |

## Connect your data using vector stores

To increase relevancy and tailor AI applications for your own data, you'll likely need to work with a vector store. Many services provide a native SDK for .NET, which you can use directly. You can also use Semantic Kernel, which provides an extensible component model that allows you to try different vector stores without needing to learn each SDK.

| NuGet package | Supported vector store | Maintainer or vendor | Link to docs |
|----------------------------------------------------------------------------------------|-----------------------------------|-------------------------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------|
| [Microsoft.SemanticKernel](https://www.nuget.org/packages/Microsoft.SemanticKernel/) | [Supported vector stores](/semantic-kernel/memories/vector-db#available-connectors-to-vector-databases) | [Semantic Kernel](https://github.com/microsoft/semantic-kernel) (Microsoft) | [Semantic Kernel: What is a vector database](/semantic-kernel/memories/vector-db) |
| [Azure.Search.Documents](https://www.nuget.org/packages/Azure.Search.Documents/) | Azure AI Search | [Azure SDK for .NET](https://github.com/Azure/azure-sdk-for-net) (Microsoft) | [Azure AI Search client library for .NET](/dotnet/api/overview/azure/search.documents-readme) |
| [Milvus.Client](https://www.nuget.org/packages/Milvus.Client) | Milvus Vector Database | [Milvus](https://milvus.io/) | [Install Milvus C# SDK](https://milvus.io/docs/v2.2.x/install-csharp.md) |
| [Qdrant.Client](https://www.nuget.org/packages/Qdrant.Client) | Qdrant Vector Database | [Qdrant](https://qdrant.tech) | [Qdrant .NET SDK](https://github.com/qdrant/qdrant-dotnet) |

## Other options

This article summarized the tools and SDKs in the .NET ecosystem, with a focus on services that provide official support for .NET. Depending on your needs and stage of app development, you might also want to take a look at the open-source options for the ecosystem in [the unofficial list of .NET + AI resources](https://github.com/jmatthiesen/dotnet-ai-resources?tab=readme-ov-file#models). Microsoft is not the maintainer of many of these projects, so be sure to review their quality, licensing, and support.

## Next Steps

- [What is Semantic Kernel?](/semantic-kernel/overview/)
- [Quickstart - Summarize text using Azure AI chat app with .NET](./quickstarts/quickstart-openai-summarize-text.md)
2 changes: 2 additions & 0 deletions docs/azure/TOC.yml
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,8 @@
href: ../ai/get-started-app-chat-template.md
- name: Scale Azure OpenAI with Azure Container apps
href: ../ai/get-started-app-chat-scaling-with-azure-container-apps.md
- name: .NET + AI ecosystem
href: ../ai/dotnet-ai-ecosystem.md
- name: Azure SDK for .NET
items:
- name: What is the Azure SDK for .NET?
Expand Down
2 changes: 1 addition & 1 deletion docs/azure/includes/dotnet-all.md
Original file line number Diff line number Diff line change
Expand Up @@ -314,7 +314,7 @@
| unknown | NuGet [1.0.0-beta.1](https://www.nuget.org/packages/Azure.ResourceManager.MigrationDiscoverySap/1.0.0-beta.1) | | GitHub [1.0.0-beta.1](https://github.com/Azure/azure-sdk-for-net/tree/Azure.ResourceManager.MigrationDiscoverySap_1.0.0-beta.1/sdk/migrationdiscoverysap/Azure.ResourceManager.MigrationDiscoverySap/) |
| unknown | NuGet [1.0.0-beta.5](https://www.nuget.org/packages/Azure.ResourceManager.ScVmm/1.0.0-beta.5) | [docs](/dotnet/api/overview/azure/ResourceManager.ScVmm-readme?view=azure-dotnet-preview&amp;preserve-view=true) | GitHub [1.0.0-beta.5](https://github.com/Azure/azure-sdk-for-net/tree/Azure.ResourceManager.ScVmm_1.0.0-beta.5/sdk/arc-scvmm/Azure.ResourceManager.ScVmm/) |
| Azure.Communication.Administration | NuGet [1.0.0-beta.3](https://www.nuget.org/packages/Azure.Communication.Administration/1.0.0-beta.3) | | |
| Communication Calling Windows Client | NuGet [1.5.0](https://www.nuget.org/packages/Azure.Communication.Calling.WindowsClient/1.5.0) | | |
| Communication Calling Windows Client | NuGet [1.5.0](https://www.nuget.org/packages/Azure.Communication.Calling.WindowsClient/1.5.0)<br>NuGet [1.6.0-beta.1](https://www.nuget.org/packages/Azure.Communication.Calling.WindowsClient/1.6.0-beta.1) | | |
| Unknown Display Name | NuGet [12.0.0-beta.1](https://www.nuget.org/packages/Azure.Storage.DataMovement.Files.Shares/12.0.0-beta.1) | | |
| Unknown Display Name | NuGet [0.7.6](https://www.nuget.org/packages/DotNetty.Common/0.7.6) | | |
| Unknown Display Name | NuGet [1.0.2](https://www.nuget.org/packages/Microsoft.Azure.Functions.Worker.Extensions.Http.AspNetCore.Analyzers/1.0.2) | | |
Expand Down
7 changes: 6 additions & 1 deletion docs/core/compatibility/9.0.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: Breaking changes in .NET 9
titleSuffix: ""
description: Navigate to the breaking changes in .NET 9.
ms.date: 01/09/2024
ms.date: 02/01/2024
no-loc: [Blazor, Razor, Kestrel]
---
# Breaking changes in .NET 9
Expand All @@ -25,6 +25,7 @@ If you're migrating an app to .NET 9, the breaking changes listed here might aff

| Title | Type of change | Introduced version |
|------------------------------------------------------------------------------------------|---------------------|--------------------|
| [API obsoletions with custom diagnostic IDs](core-libraries/9.0/obsolete-apis-with-custom-diagnostics.md) | Source incompatible | Preview 1 |
| [Creating type of array of System.Void not allowed](core-libraries/9.0/type-instance.md) | Behavioral change | Preview 1 |
| [Inline array struct size limit is enforced](core-libraries/9.0/inlinearray-size.md) | Behavioral change | Preview 1 |
| [InMemoryDirectoryInfo prepends rootDir to files](core-libraries/9.0/inmemorydirinfo-prepends-rootdir.md) | Behavioral change | Preview 1 |
Expand Down Expand Up @@ -58,3 +59,7 @@ If you're migrating an app to .NET 9, the breaking changes listed here might aff
| Title | Type of change | Introduced version |
|-----------------------------------------------------------------------------------------|---------------------|--------------------|
| [`GetXmlNamespaceMaps` type change](wpf/9.0/xml-namespace-maps.md) | Behavioral change/Source incompatible | Preview 3 |

## See also

- [What's new in .NET 9](../whats-new/dotnet-9/overview.md)
Original file line number Diff line number Diff line change
Expand Up @@ -37,14 +37,13 @@ In projects that target platforms for which APIs that they use aren't available,

> [!TIP]
>
> - Blazor WebAssembly projects and Razor class library projects include browser support automatically.
> - To manually add the browser as a supported platform for your project, add the following entry to your project file:
> Blazor WebAssembly projects and Razor class library projects include browser support automatically. To manually add the browser as a supported platform for your project, add the following entry to your project file:
>
> ```xml
> <ItemGroup>
> <SupportedPlatform Include="browser" />
> </ItemGroup>
> ```
> ```xml
> <ItemGroup>
> <SupportedPlatform Include="browser" />
> </ItemGroup>
> ```

## Version introduced

Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
---
title: "Breaking change: .NET 9 obsoletions with custom IDs"
titleSuffix: ""
description: Learn about the .NET 9 breaking change in core .NET libraries where some APIs have been marked as obsolete with a custom diagnostic ID.
ms.date: 04/05/2024
---
# API obsoletions with non-default diagnostic IDs (.NET 9)

Some APIs have been marked as obsolete, starting in .NET 9. This breaking change is specific to APIs that have been marked as obsolete *with a custom diagnostic ID*. Suppressing the default obsoletion diagnostic ID, which is [CS0618](../../../../csharp/language-reference/compiler-messages/cs0618.md) for the C# compiler, does not suppress the warnings that the compiler generates when these APIs are used.

## Change description

In previous .NET versions, these APIs can be used without any build warning. In .NET 9 and later versions, use of these APIs produces a compile-time warning or error with a custom diagnostic ID. The use of custom diagnostic IDs allows you to suppress the obsoletion warnings individually instead of blanket-suppressing all obsoletion warnings.

The following table lists the custom diagnostic IDs and their corresponding warning messages for obsoleted APIs.

| Diagnostic ID | Description | Severity |
| - | - |
| [SYSLIB0009](../../../../fundamentals/syslib-diagnostics/syslib0009.md) | <xref:System.Net.AuthenticationManager> is not supported. Methods will no-op or throw <xref:System.PlatformNotSupportedException>. | Warning |

## Version introduced

.NET 9

## Type of breaking change

These obsoletions can affect [source compatibility](../../categories.md#source-compatibility).

## Recommended action

- Follow the specific guidance provided for the each diagnostic ID using the URL link provided on the warning.

- Warnings or errors for these obsoletions can't be suppressed using the standard diagnostic ID for obsolete types or members; use the custom `SYSLIBxxxx` diagnostic ID value instead.

## Affected APIs

### SYSLIB0009

- <xref:System.Net.AuthenticationManager?displayProperty=fullName>

## See also

- [API obsoletions with non-default diagnostic IDs (.NET 8)](../8.0/obsolete-apis-with-custom-diagnostics.md)
- [API obsoletions with non-default diagnostic IDs (.NET 7)](../7.0/obsolete-apis-with-custom-diagnostics.md)
- [API obsoletions with non-default diagnostic IDs (.NET 6)](../6.0/obsolete-apis-with-custom-diagnostics.md)
- [API obsoletions with non-default diagnostic IDs (.NET 5)](../5.0/obsolete-apis-with-custom-diagnostics.md)
- [Obsolete features in .NET 5+](../../../../fundamentals/syslib-diagnostics/obsoletions-overview.md)
2 changes: 2 additions & 0 deletions docs/core/compatibility/toc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@ items:
href: aspnet-core/9.0/key-resolution.md
- name: Core .NET libraries
items:
- name: API obsoletions with custom diagnostic IDs
href: core-libraries/9.0/obsolete-apis-with-custom-diagnostics.md
- name: Creating type of array of System.Void not allowed
href: core-libraries/9.0/type-instance.md
- name: Inline array struct size limit is enforced
Expand Down
34 changes: 18 additions & 16 deletions docs/core/install/templates.md
Original file line number Diff line number Diff line change
Expand Up @@ -208,22 +208,24 @@ For example, the .NET 7 SDK includes templates for a console app targeting .NET
dotnet new install Microsoft.DotNet.Common.ProjectTemplates.3.1
```

01. Try creating the app a second time.

```dotnetcli
dotnet new console --framework netcoreapp3.1
```

And you should see a message indicating the project was created.

> The template "Console Application" was created successfully.
>
> Processing post-creation actions...
> Running 'dotnet restore' on path-to-project-file.csproj...
> Determining projects to restore...
> Restore completed in 1.05 sec for path-to-project-file.csproj.
>
> Restore succeeded.
1. Try creating the app a second time.

```dotnetcli
dotnet new console --framework netcoreapp3.1
```

And you should see a message indicating the project was created.

<!-- markdownlint-disable MD027 -->
> The template "Console Application" was created successfully.
>
> Processing post-creation actions...
> Running 'dotnet restore' on path-to-project-file.csproj...
> Determining projects to restore...
> Restore completed in 1.05 sec for path-to-project-file.csproj.
>
> Restore succeeded.
<!-- markdownlint-enable MD027 -->
## See also

Expand Down
60 changes: 30 additions & 30 deletions docs/framework/app-domains/build-multifile-assembly.md
Original file line number Diff line number Diff line change
Expand Up @@ -171,51 +171,51 @@ This article explains how to create a multifile assembly and provides code that
>
> Two compilations create a two-file assembly:
>
> ```cpp
> cl /clr:pure /LN Stringer.cpp
> cl /clr:pure Client.cpp /link /ASSEMBLYMODULE:Stringer.netmodule
> ```
> ```cpp
> cl /clr:pure /LN Stringer.cpp
> cl /clr:pure Client.cpp /link /ASSEMBLYMODULE:Stringer.netmodule
> ```
>
> ```csharp
> csc /t:module Stringer.cs
> csc Client.cs /addmodule:Stringer.netmodule
> ```
> ```csharp
> csc /t:module Stringer.cs
> csc Client.cs /addmodule:Stringer.netmodule
> ```
>
> ```vb
> vbc /t:module Stringer.vb
> vbc Client.vb /addmodule:Stringer.netmodule
> ```
> ```vb
> vbc /t:module Stringer.vb
> vbc Client.vb /addmodule:Stringer.netmodule
> ```
>
> One compilation creates a two-file assembly:
>
> ```cpp
> cl /clr:pure /LN Stringer.cpp
> cl /clr:pure Client.cpp /link /ASSEMBLYMODULE:Stringer.netmodule
> ```
> ```cpp
> cl /clr:pure /LN Stringer.cpp
> cl /clr:pure Client.cpp /link /ASSEMBLYMODULE:Stringer.netmodule
> ```
>
> ```csharp
> csc /out:Client.exe Client.cs /out:Stringer.netmodule Stringer.cs
> ```
> ```csharp
> csc /out:Client.exe Client.cs /out:Stringer.netmodule Stringer.cs
> ```
>
> ```vb
> vbc /out:Client.exe Client.vb /out:Stringer.netmodule Stringer.vb
> ```
> ```vb
> vbc /out:Client.exe Client.vb /out:Stringer.netmodule Stringer.vb
> ```

5. Use the [Assembly Linker (Al.exe)](../tools/al-exe-assembly-linker.md) to create the output file that contains the assembly manifest. This file contains reference information for all modules or resources that are part of the assembly.

At the command prompt, type the following command:
At the command prompt, type the following command:

**al** \<*module name*> \<*module name*>**/main:**\<*method name*> **/out:**\<*file name*> **/target:**\<*assembly file type*>
**al** \<*module name*> \<*module name*>**/main:**\<*method name*> **/out:**\<*file name*> **/target:**\<*assembly file type*>

In this command, the *module name* arguments specify the name of each module to include in the assembly. The **/main:** option specifies the method name that is the assembly's entry point. The **/out:** option specifies the name of the output file, which contains assembly metadata. The **/target:** option specifies that the assembly is a console application executable (*.exe*) file, a Windows executable (*.win*) file, or a library (*.lib*) file.
In this command, the *module name* arguments specify the name of each module to include in the assembly. The **/main:** option specifies the method name that is the assembly's entry point. The **/out:** option specifies the name of the output file, which contains assembly metadata. The **/target:** option specifies that the assembly is a console application executable (*.exe*) file, a Windows executable (*.win*) file, or a library (*.lib*) file.

In the following example, *Al.exe* creates an assembly that is a console application executable called *myAssembly.exe*. The application consists of two modules called *Client.netmodule* and *Stringer.netmodule*, and the executable file called *myAssembly.exe*, which contains only assembly metadata. The entry point of the assembly is the `Main` method in the class `MainClientApp`, which is located in *Client.dll*.
In the following example, *Al.exe* creates an assembly that is a console application executable called *myAssembly.exe*. The application consists of two modules called *Client.netmodule* and *Stringer.netmodule*, and the executable file called *myAssembly.exe*, which contains only assembly metadata. The entry point of the assembly is the `Main` method in the class `MainClientApp`, which is located in *Client.dll*.

```cmd
al Client.netmodule Stringer.netmodule /main:MainClientApp.Main /out:myAssembly.exe /target:exe
```
```cmd
al Client.netmodule Stringer.netmodule /main:MainClientApp.Main /out:myAssembly.exe /target:exe
```

You can use the [MSIL Disassembler (Ildasm.exe)](../tools/ildasm-exe-il-disassembler.md) to examine the contents of an assembly, or determine whether a file is an assembly or a module.
You can use the [MSIL Disassembler (Ildasm.exe)](../tools/ildasm-exe-il-disassembler.md) to examine the contents of an assembly, or determine whether a file is an assembly or a module.

## See also

Expand Down
Loading

0 comments on commit 4febfbf

Please sign in to comment.