Files
hjha-server/PdkFriendServer/PdkFriendServer.csproj
xiaoou 89743cd511 feat: NeuralBot — ONNX模型驱动的Bot + 混合Bot训练架构
NeuralBot.cs:
- 加载ONNX模型,状态编码与Python trainer完全一致(13rank×4suit×7ch=364)
- ε-greedy探索(10%) + ONNX推理选Q值最高动作
- 多牌候选: 对子/三带二(优先带对子)/顺子/炸弹

PdkGameMain:
- BotTypes静态配置: ["NEURAL","NEURAL","ISMCTS"] = 2模型+1ISMCTS
- --mix参数: dotnet run -- --mix 100

hjha-console:
- --mix参数自动设置BotTypes并转调--stress

验证: 3局0错误, 1.3s/局, NeuralBot出牌正常
2026-07-13 02:20:44 +08:00

88 lines
3.9 KiB
XML

<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<OutputType>Library</OutputType>
<TargetFramework>net10.0</TargetFramework>
<RootNamespace>PdkFriendServer</RootNamespace>
<AssemblyName>PdkFriendServer</AssemblyName>
<Deterministic>true</Deterministic>
<GenerateAssemblyInfo>false</GenerateAssemblyInfo>
<AppendTargetFrameworkToOutputPath>false</AppendTargetFrameworkToOutputPath>
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
<GenerateBindingRedirectsOutputType>true</GenerateBindingRedirectsOutputType>
<Platforms>AnyCPU</Platforms>
<Configurations>Debug;Release</Configurations>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug|AnyCPU'">
<PlatformTarget>AnyCPU</PlatformTarget>
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>..\exe\PdkFriendServer\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<Prefer32Bit>false</Prefer32Bit>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Release|AnyCPU'">
<PlatformTarget>AnyCPU</PlatformTarget>
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>..\exe\PdkFriendServer_Re\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<Prefer32Bit>false</Prefer32Bit>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="MessagePack.Annotations" />
<PackageReference Include="Microsoft.Bcl.AsyncInterfaces" />
<PackageReference Include="Microsoft.ML.OnnxRuntime" />
<PackageReference Include="Microsoft.ML.OnnxRuntime.Managed" />
<PackageReference Include="Microsoft.NET.StringTools" />
<PackageReference Include="System.Buffers" />
<PackageReference Include="System.Memory" />
<PackageReference Include="System.Numerics.Vectors" />
<PackageReference Include="System.Runtime.CompilerServices.Unsafe" />
<PackageReference Include="System.Threading.Tasks.Extensions" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\ServerCore\ServerCore.csproj" />
<ProjectReference Include="..\GameFix\GameFix.csproj" />
<ProjectReference Include="..\GameModule\GameModule.csproj" />
<ProjectReference Include="..\GlobalSever\GlobalSever.csproj" />
<ProjectReference Include="..\MrWu\MrWu.csproj" />
<ProjectReference Include="..\NetWorkMessage\NetWorkMessage.csproj" />
<ProjectReference Include="..\ObjectModel\ObjectModel.csproj" />
<ProjectReference Include="..\ServerData\ServerData.csproj" />
</ItemGroup>
<!-- <ItemGroup>-->
<!-- <Compile Include="..\..\hjha_Client\Assets\ScriptCode\UnityGame\GamePlay\Card\Common\PaoDeKuaiF\GameFix\**\*.cs">-->
<!-- <Link>GameFix\%(RecursiveDir)%(Filename)%(Extension)</Link>-->
<!-- </Compile>-->
<!-- </ItemGroup>-->
<ItemGroup>
<Compile Remove="Program.cs" />
<Compile Remove="Form1.cs" />
<Compile Remove="Form1.Designer.cs" />
<Compile Remove="Properties/Resources.Designer.cs" />
<Compile Remove="Properties/Settings.Designer.cs" />
<Compile Remove="GlobalManager/GameServerProxy.cs" />
<Compile Remove="GlobalManager/GameSeverManager.cs" />
<Compile Remove="GlobalManager/MyFactory.cs" />
<Compile Remove="GlobalManager/PdkFactory.cs" />
<EmbeddedResource Remove="Properties/Resources.resx" />
<None Remove="Properties/Settings.settings" />
<None Remove="App.config" />
</ItemGroup>
</Project>