openai/openai-dotnet

Public

mirrored from https://github.com/openai/openai-dotnetAvailable

CodeCommitsIssuesPull requestsActionsInsightsSecurity
achandmsft-patch-1

Branches

Tags

  • No tags available.
0Branches0Tags
Go to file
Add file
Code

Clone

HTTPS

Download ZIP

src/OpenAI.csproj

95lines · modecode

1<Project Sdk="Microsoft.NET.Sdk">
2 <PropertyGroup>
3 <Description>
4 The official .NET library for the OpenAI service API.
5 </Description>
6 <AssemblyTitle>SDK Code Generation OpenAI</AssemblyTitle>
7 <PackageTags>OpenAI;openai-dotnet;ChatGPT;Dall-E</PackageTags>
8 <PackageLicenseExpression>MIT</PackageLicenseExpression>
9 <Copyright>Copyright (c) 2024 OpenAI (https://openai.com)</Copyright>
10
11 <VersionPrefix>2.2.0</VersionPrefix>
12 <VersionSuffix>beta.4</VersionSuffix>
13
14 <TargetFrameworks>net8.0;net6.0;netstandard2.0</TargetFrameworks>
15 <LangVersion>latest</LangVersion>
16
17 <!-- Generate an XML documentation file for the project. -->
18 <GenerateDocumentationFile>true</GenerateDocumentationFile>
19
20 <!-- Publish the repository URL in the built .nupkg (in the NuSpec <Repository> element) -->
21 <PublishRepositoryUrl>true</PublishRepositoryUrl>
22 <PackageIcon>OpenAI.png</PackageIcon>
23 <PackageReadmeFile>README.md</PackageReadmeFile>
24
25 <!-- Create a .snupkg file in addition to the .nupkg file. -->
26 <IncludeSymbols>true</IncludeSymbols>
27 <SymbolPackageFormat>snupkg</SymbolPackageFormat>
28
29 <!-- Embed source files that are not tracked by the source control manager in the PDB -->
30 <EmbedUntrackedSources>true</EmbedUntrackedSources>
31
32 <TreatWarningsAsErrors>true</TreatWarningsAsErrors>
33
34 <!-- Disable missing XML documentation warnings -->
35 <NoWarn>$(NoWarn),1570,1573,1574,1591</NoWarn>
36
37 <!-- Disable obsolete warnings -->
38 <NoWarn>$(NoWarn),0618</NoWarn>
39
40 <!-- Disable unused fields warnings -->
41 <NoWarn>$(NoWarn),0169</NoWarn>
42
43 <!-- Disable warnings for experimental APIs -->
44 <NoWarn>$(NoWarn),OPENAI001;OPENAI002;OPENAICUA001</NoWarn>
45
46 <Configurations>Debug;Release;Unsigned</Configurations>
47
48 <IsTrimmable Condition="$([MSBuild]::IsTargetFrameworkCompatible('$(TargetFramework)', 'net6.0'))">true</IsTrimmable>
49 <IsAotCompatible Condition="$([MSBuild]::IsTargetFrameworkCompatible('$(TargetFramework)', 'net7.0'))">true</IsAotCompatible>
50 </PropertyGroup>
51
52 <PropertyGroup Condition="'$(Configuration)' != 'Unsigned'">
53 <!-- Sign the assembly with the specified key file. -->
54 <SignAssembly>true</SignAssembly>
55 <AssemblyOriginatorKeyFile>OpenAI.snk</AssemblyOriginatorKeyFile>
56 </PropertyGroup>
57
58 <ItemGroup>
59 <InternalsVisibleTo Include="Azure.AI.OpenAI" Condition="'$(Configuration)' != 'Unsigned'">
60 <PublicKey>0024000004800000940000000602000000240000525341310004000001000100097ad52abbeaa2e1a1982747cc0106534f65cfea6707eaed696a3a63daea80de2512746801a7e47f88e7781e71af960d89ba2e25561f70b0e2dbc93319e0af1961a719ccf5a4d28709b2b57a5d29b7c09dc8d269a490ebe2651c4b6e6738c27c5fb2c02469fe9757f0a3479ac310d6588a50a28d7dd431b907fd325e18b9e8ed</PublicKey>
61 </InternalsVisibleTo>
62 <InternalsVisibleTo Include="Azure.AI.OpenAI" Condition="'$(Configuration)' == 'Unsigned'" />
63 <InternalsVisibleTo Include="OpenAI.Tests" Condition="'$(Configuration)' != 'Unsigned'">
64 <PublicKey>0024000004800000940000000602000000240000525341310004000001000100b197326f2e5bfe2e2a49eb2a05bee871c55cc894325b3775159732ad816c4f304916e7f154295486f8ccabefa3c19b059d51cd19987cc2d31a3195d6203ad0948662f51cc61cc3eb535fc852dfe5159318c734b163f7d1387f1112e1ffe10f83aae7b809c4e36cf2025da5d1aed6b67e1556883d8778eeb63131c029555166de</PublicKey>
65 </InternalsVisibleTo>
66 <InternalsVisibleTo Include="OpenAI.Tests" Condition="'$(Configuration)' == 'Unsigned'" />
67 </ItemGroup>
68
69 <PropertyGroup Condition="'$(TargetFramework)' == 'netstandard2.0'">
70 <!-- Allow use of unsafe code, for System.Net.ServerSentEvents polyfill on netstandard2.0
71 TODO https://github.com/openai/openai-dotnet/issues/41: Remove once polyfill for
72 System.Net.ServerSentEvents is removed in favor of referencing the package -->
73 <AllowUnsafeBlocks>true</AllowUnsafeBlocks>
74 </PropertyGroup>
75
76 <PropertyGroup Condition="'$(GITHUB_ACTIONS)' == 'true'">
77 <!-- Normalize stored file paths in symbols when in a CI build. -->
78 <ContinuousIntegrationBuild>true</ContinuousIntegrationBuild>
79 </PropertyGroup>
80 <ItemGroup>
81 <None Include="OpenAI.png" Pack="true" PackagePath="\" />
82 <None Include="..\CHANGELOG.md" Pack="true" PackagePath="\" />
83 <None Include="..\README.md" Pack="true" PackagePath="\" />
84 </ItemGroup>
85
86 <ItemGroup>
87 <PackageReference Include="Microsoft.SourceLink.GitHub" Version="8.0.0" PrivateAssets="All" />
88 <PackageReference Include="System.ClientModel" Version="1.2.1" />
89 <PackageReference Update="Microsoft.Bcl.Numerics" Version="8.0.0" />
90 </ItemGroup>
91
92 <ItemGroup Condition="!$([MSBuild]::IsTargetFrameworkCompatible('$(TargetFramework)', 'net6.0'))">
93 <PackageReference Include="System.Diagnostics.DiagnosticSource" Version="6.0.1" />
94 </ItemGroup>
95</Project>