ddsWrapper 1.0.147
dotnet add package ddsWrapper --version 1.0.147
NuGet\Install-Package ddsWrapper -Version 1.0.147
<PackageReference Include="ddsWrapper" Version="1.0.147" />
<PackageVersion Include="ddsWrapper" Version="1.0.147" />
<PackageReference Include="ddsWrapper" />
paket add ddsWrapper --version 1.0.147
#r "nuget: ddsWrapper, 1.0.147"
#:package ddsWrapper@1.0.147
#addin nuget:?package=ddsWrapper&version=1.0.147
#tool nuget:?package=ddsWrapper&version=1.0.147
ddsWrapper
A .NET wrapper for double-dummy bridge solvers, bundling two native engines:
- DDS — Bo Haglund's battle-tested double-dummy solver.
- bridge-solver — a modern Rust-based solver with card-by-card play analysis and claim checking.
Deals are expressed in PBN format, e.g.:
N:AKQT3.J6.KJ42.95 652.AK42.AQ87.T4 J74.QT95.T.AK863 98.873.9653.QJ72
Requirements
- Windows x64
- .NET 10 or later
- The Visual C++ Redistributable (MSVC runtime) must be installed, as
bridgesolver.dllanddds.dlldepend on it.
Installation
dotnet add package ddsWrapper
Both native DLLs (dds.dll and bridgesolver.dll) are automatically copied to your output directory on build.
Usage
DDS — Double-Dummy Solver
Wraps dds.dll for high-performance, multi-threaded double-dummy analysis.
using DDS;
// Solve a single board: which cards can be played and how many tricks does each score?
var state = new GameState(...);
List<CardPotential> cards = ddsWrapper.BestCards(state);
// Full double-dummy table: tricks for every seat × strain combination
TableResults table = ddsWrapper.CalcDDtable(deal);
byte tricksNorthSpades = table[Seats.North, Suits.Spades];
BridgeSolverWrapper — bridge-solver
Wraps bridgesolver.dll for double-dummy tables, card-by-card play analysis, and claim checking.
Library version
using BridgeSolver;
string version = BridgeSolverWrapper.GetVersion(); // e.g. "2.0.0"
Double-dummy table
Returns trick counts for all 20 seat × strain combinations.
string deal = "N:AKQT3.J6.KJ42.95 652.AK42.AQ87.T4 J74.QT95.T.AK863 98.873.9653.QJ72";
TableResults tricks = BridgeSolverWrapper.DdTableTricks(deal);
byte northInSpades = tricks[Seats.North, Suits.Spades];
Batch double-dummy analysis
Solve up to 1,000 deals in parallel, returning only deals where at least one contract is makeable.
List<Deal> deals = ...; // up to 1000 deals
TableResults needed = ...; // which suits to evaluate (0 = skip, 1 = evaluate)
List<TableResults> results = BridgeSolverWrapper.PossibleTricks(deals, needed, maxDuration: 5);
Card-by-card play analysis
Evaluate which of a set of candidate cards gives the best outcome for declarer.
GameState state = ...;
List<Bridge.Card> candidates = ...;
List<CardPotential> best = BridgeSolverWrapper.BestCards(state, candidates);
Stateful play analysis with Analyzer
Analyzer maintains state across cards played in the same deal. Dispose when done.
using var analyzer = new BridgeSolverWrapper.Analyzer();
string requestJson = """
{
"dealstr": "N:AKQT3.J6.KJ42.95 652.AK42.AQ87.T4 J74.QT95.T.AK863 98.873.9653.QJ72",
"trump": "S",
"declarer": "N",
"leader": "E",
"plays": ["C2"]
}
""";
string responseJson = analyzer.Play(requestJson);
// {"contract_tricks": 10, ...}
Conventions
| Concept | Values |
|---|---|
| Strains | "C", "D", "H", "S", "NT" |
| Seats | "N", "E", "S", "W" |
| Vulnerable | "None", "NS", "EW", "All" |
| Deal format | PBN, e.g. "N:AK.... ..." |
Trick counts in TableResults are indexed as [seat, strain] using the Seats and Suits enums,
with seats N=0, E=1, S=2, W=3 and strains C=0, D=1, H=2, S=3, NT=4.
Native DLLs
| File | Source | Licence |
|---|---|---|
dds.dll |
dds-bridge/dds | Apache-2.0 |
bridgesolver.dll |
bridge-craftwork/bridge-solver | MIT OR Apache-2.0 |
Third-party notices for bridgesolver.dll are included in bridge-solver/THIRD-PARTY-NOTICES.
Licence
MIT OR Apache-2.0 — see repository for details.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net10.0 is compatible. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
-
net10.0
- Bridge.Fundamentals (>= 2026.2.19.1)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 1.0.147 | 97 | 11/10/2026 |
| 1.0.144 | 95 | 11/10/2026 |
| 1.0.139 | 90 | 11/8/2026 |
| 1.0.138 | 82 | 11/8/2026 |
| 1.0.137 | 95 | 11/8/2026 |
| 1.0.136 | 90 | 11/8/2026 |
| 1.0.135 | 95 | 11/8/2026 |
| 1.0.134 | 86 | 11/8/2026 |
| 1.0.133 | 93 | 11/8/2026 |
| 1.0.132 | 84 | 11/8/2026 |
| 1.0.129 | 92 | 11/8/2026 |
| 1.0.121 | 127 | 10/12/2026 |
| 1.0.118 | 104 | 10/12/2026 |
| 1.0.111 | 200 | 5/24/2026 |
| 1.0.105 | 455 | 2/26/2026 |
| 1.0.104 | 428 | 2/26/2026 |
| 1.0.103 | 562 | 2/22/2026 |
| 1.0.102 | 552 | 2/22/2026 |
| 1.0.101 | 694 | 2/10/2026 |
| 1.0.100 | 686 | 2/8/2026 |