Skip to content

Commit 7a1064a

Browse files
authored
Merge pull request #95 from ImperialBower/dabomb
added AI-BOM
2 parents d3c483b + d5ecad5 commit 7a1064a

2 files changed

Lines changed: 108 additions & 1 deletion

File tree

AI-BOM.md

Lines changed: 106 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,106 @@
1+
# AI Bill of Materials — pkcore
2+
3+
_Last updated: 2026-05-07 · pkcore v0.0.56_
4+
5+
An inventory of every AI component in this repository — development tools used to build it, algorithms implemented within it, and external AI services it integrates with (current or planned). Modeled on the SBOM concept applied to AI systems.
6+
7+
---
8+
9+
## 1. Development Tools
10+
11+
AI tools used to author this codebase. Not part of the shipped library, but relevant to provenance.
12+
13+
| Tool | Vendor | Role | Notes |
14+
|------|--------|------|-------|
15+
| Claude Code | Anthropic | Primary AI coding assistant | All EPICs from EPIC-18 onward; see [`CLAUDE.md`](./CLAUDE.md) |
16+
| GitHub Copilot | GitHub / Microsoft | Autocomplete, macro generation | Used for repetitive macro patterns; see [`docs/EPIC-00g_Enter_AI.md`](./docs/EPIC-00g_Enter_AI.md) |
17+
18+
---
19+
20+
## 2. AI Audits
21+
22+
Formal code reviews performed by AI models. Full reports in `docs/`.
23+
24+
| Date | Model | Report | Version |
25+
|------|-------|--------|---------|
26+
| 2026-04-13 | Claude Sonnet 4.6 (max effort) | [`docs/AUDIT_Claude_Code_max.md`](./docs/AUDIT_Claude_Code_max.md) | v0.0.40 |
27+
| 2026-04-13 | GPT-5.4 | [`docs/AUDIT_GPT-5.4.md`](./docs/AUDIT_GPT-5.4.md) | v0.0.40 |
28+
| 2026-04-13 | Gemini 3.1 | [`docs/AUDIT_Gemini_3.1.md`](./docs/AUDIT_Gemini_3.1.md) | v0.0.40 |
29+
30+
---
31+
32+
## 3. Algorithms Implemented
33+
34+
Game-theory and AI/ML algorithms built directly into pkcore. **No external ML dependencies** — all computation is in-process.
35+
36+
| Algorithm | Module | Status | EPIC |
37+
|-----------|--------|--------|------|
38+
| Counterfactual Regret Minimization (CFR) | `analysis::gto` | Complete | EPIC-15 |
39+
| CFR+ (faster convergence) | `analysis::gto` | Complete | EPIC-16 |
40+
| Discounted CFR (DCFR) | `analysis::gto` | Complete | EPIC-16 |
41+
| (1+λ)-Evolution Strategy | `bot::exploit` | Complete | EPIC-28 |
42+
| Rule-Based Probabilistic Decision Engine | `bot::decider` | Complete | EPIC-18 |
43+
| Exploitative Adaptive Decision Engine | `bot::exploitative_decider` | Complete | EPIC-27 |
44+
45+
---
46+
47+
## 4. Agent Architecture
48+
49+
Autonomous decision-making components shipped in the library.
50+
51+
| Component | Description | Status | Cargo Feature |
52+
|-----------|-------------|--------|---------------|
53+
| `BotProfile` | YAML-serializable bot personality (ranges, aggression, bluff frequencies) | Complete | `bot-profiles` |
54+
| `BotDecider` trait | Object-safe, `Send + Sync` decision interface | Complete | default |
55+
| `RuleBasedDecider` | Profile-driven probabilistic in-process agent | Complete | default |
56+
| `JokerDecider` | Randomly adopts one of 8 reference profiles per hand | Complete | default |
57+
| `ExploitativeDecider` | Converts live opponent stats into runtime profile deviations | Complete | `bot-profiles` |
58+
| `ExploitTrainer` | Cross-session profile optimizer (evolution strategies) | Complete | `bot-training` |
59+
| `SimTable` | All-bot batch simulation runner | Complete | default |
60+
| `PlayerStats` / `StatsRegistry` | Per-opponent VPIP/PFR/AF/WTSD model builder | Complete | `player-stats` |
61+
62+
---
63+
64+
## 5. External AI Integrations
65+
66+
pkcore currently ships **zero external AI service dependencies**. The following integrations are planned in the `pkdealer` repository (EPIC-23, EPIC-24).
67+
68+
| Service | Type | Status | EPIC | Notes |
69+
|---------|------|--------|------|-------|
70+
| Anthropic Claude | LLM agent client | Planned | EPIC-23 (pkdealer) | Natural-language poker decisions; OTel `gen_ai.*` tracing |
71+
| OpenAI GPT-4o | LLM agent client | Planned | EPIC-23 (pkdealer) | Comparison baseline against rule-based agents |
72+
| Ollama | Local LLM agent client | Stretch | EPIC-23 (pkdealer) | Offline / on-prem variant |
73+
| Langfuse | LLM observability | Planned | EPIC-24 (pkdealer) | Prompt versioning, win-rate scoring, cost tracking |
74+
75+
---
76+
77+
## 6. Observability Plan
78+
79+
OpenTelemetry semantic conventions planned for LLM agent decision spans (EPIC-23/24, implemented in `pkdealer`):
80+
81+
```
82+
gen_ai.system → "anthropic" | "openai" | "ollama"
83+
gen_ai.request.model → "claude-sonnet-4-6" | "gpt-4o" | ...
84+
gen_ai.usage.input_tokens
85+
gen_ai.usage.output_tokens
86+
poker.hand_id
87+
poker.street → "preflop" | "flop" | "turn" | "river"
88+
poker.pot_odds
89+
poker.action_chosen → "fold" | "call" | "raise" | "all-in"
90+
```
91+
92+
No vendor SDK required — ingested via OTLP into Langfuse/Jaeger.
93+
94+
---
95+
96+
## 7. References
97+
98+
| Document | Purpose |
99+
|----------|---------|
100+
| [`ROADMAP.md`](./ROADMAP.md) | Full 5-phase vision including LLM agent phases |
101+
| [`docs/EPIC-00g_Enter_AI.md`](./docs/EPIC-00g_Enter_AI.md) | History of AI tooling adoption |
102+
| [`docs/EPIC-18_Bot_Playing_Styles.md`](./docs/EPIC-18_Bot_Playing_Styles.md) | Bot profile design |
103+
| [`docs/EPIC-23_Bot_Agents.md`](./docs/EPIC-23_Bot_Agents.md) | Planned LLM agent clients |
104+
| [`docs/EPIC-27_Exploitative_Decider.md`](./docs/EPIC-27_Exploitative_Decider.md) | Adaptive decision engine |
105+
| [`docs/EPIC-28_Profile_Training.md`](./docs/EPIC-28_Profile_Training.md) | Evolutionary training loop |
106+
| [`src/bot/BOT_MODULE_GUIDE.md`](./src/bot/BOT_MODULE_GUIDE.md) | Bot architecture reference |

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
1-
# pkcore AKA Spawn of [Fudd](https://github.com/ImperialBower/fudd)
1+
# pkcore
22

33
[![Crates.io](https://img.shields.io/crates/v/pkcore.svg)](https://crates.io/crates/pkcore)
44
[![CI](https://github.com/ImperialBower/pkcore/actions/workflows/basic.yaml/badge.svg)](https://github.com/ImperialBower/pkcore/actions/workflows/basic.yaml)
55
[![Security audit](https://github.com/ImperialBower/pkcore/actions/workflows/audit.yml/badge.svg)](https://github.com/ImperialBower/pkcore/actions/workflows/audit.yml)
66
[![License: GPL v3](https://img.shields.io/badge/License-GPLv3-blue.svg)](https://www.gnu.org/licenses/gpl-3.0)
7+
[![AI BOM](https://img.shields.io/badge/AI--BOM-tracked-blueviolet)](./AI-BOM.md)
78

89
🚧 **Work In Progress** 🚧
910

0 commit comments

Comments
 (0)