cribbage-trainer
May 4, 2026 ยท View on GitHub
Summary
Two-player cribbage discard and play improvement tool.
Project Philosophy
To ensure the app's value proposition remains intact, the scoring engine relies strictly on objective simulation and probability, not subjective expert rules of thumb. Both humans and AI agents need to understand and respect this constraint. Expected values must always be derived from simulation, enumeration, or probability, rather than hard-coded heuristics or subjective weighting.
Continuous deployment
Code in main is automatically built on git push and deployed to the GitHub
Pages hosted app and
Storybook site
on build success via GitHub Action Workflow.
Local and Development Setup
Install
- Install the latest version of the version of Node.js
specified in
.nvmrcby hand, or if using nvm:nvm install - Install third-party dependencies:
npm install
Build and Run
- Build production version of app (optional):
npm run build - Serve up and navigate to the dev app server:
npm startthenopen http://localhost:5173 - Serve up and navigate to the production preview app server:
npm run buildthennpm run start:production-previewandopen http://localhost:4173
Lint and Test
npm run docker:build-and-test-all
Develop
- Serve Storybook stories:
npm run storybook - Build a static version of the Storybook stories:
npm run storybook:build - Serve a static version of the Storybook stories:
npm run storybook:serve
Contributing
Before making changes, all developers and AI agents must read CONTRIBUTING.md and AGENTS.md.
License & AI Provenance
This project utilizes AI coding assistants in its development. All AI-generated code is rigorously reviewed, tested, and modified by human maintainers. The compiled repository and all its contents are distributed under the Mozilla Public License 2.0 (MPL 2.0). See the LICENSE file for more details.