Skip to content
CAI
Software that uses CAICheck a score

almin/ddd-base

57.8

Adequate · 21 September 2026

620

lines of production code

TypeScript

primary language

4

measurements over time

CAI band scale
CAI trend line
CAI lens gauges

What this system is

This system is a TypeScript-based domain modeling framework that provides foundational utilities for managing state and data persistence. It features a Repository pattern with event-driven updates for saving and deleting entities, alongside a Converter for serializing domain objects to and from JSON. Additionally, it includes a Copyable mixin for creating modified copies of objects without mutation, all supported by comprehensive test coverage.

Features

Added Copyable mixin for object copying and mapping

A new \Copyable\ mixin has been added to \src/mixin/Copyable.ts\. This mixin provides two methods for creating modified copies of an object: \copy\, which accepts a partial object of new values, and \mapCopy\, which accepts a map of transformation functions to apply to existing properties. This allows users to generate new instances with updated or transformed state without mutating the original.

src/mixin · high confidence

Introduce Converter for JSON serialization and deserialization

A new \Converter\ class and \createConverter\ factory function are added to handle the conversion between Entity/ValueObject instances and JSON formats. The \Converter\ supports nested conversions and provides methods like \toJSON\, \propsToJSON\, \JSONToProps\, and \fromJSON\. This allows users to easily serialize and deserialize domain objects to and from JSON structures.

src · high confidence

Introduce Repository pattern with event-driven updates

A new Repository abstraction is introduced, providing both a base \Repository\ interface and two concrete implementations: \NonNullableRepository\ (which always returns an initial entity) and \NullableRepository\ (which may return undefined). The implementation includes a \RepositoryCore\ that manages entity storage and exposes an \events\ property, allowing consumers to subscribe to \save\ and \delete\ changes via the \onChange\ method.

src/repository · high confidence

Test coverage

Added test coverage for core domain and utility components

Added comprehensive test suites for the domain model and utility components, including Entity, ValueObject, RepositoryCore, NonNullableRepository, Serializer, Converter, and Copyable mixin. The new tests verify entity equality, value object comparison, repository save/find/delete/clear operations, serialization round-trips, and the copy/mapping behavior of the Copyable mixin.

test · high confidence

Dependencies

Updated project dependencies and build configuration

The project's development dependencies have been updated to newer versions, including @types/node, @types/mocha, cross-env, husky, lerna, lint-staged, mocha, prettier, rimraf, ts-node, and typescript. Additionally, the package.json has been updated to specify the TypeScript type definitions file, changed the main entry point, added a clean script using rimraf, and reconfigured husky hooks directly in the package.json.

(dependencies) · high confidence

Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

How this codebase got here

Score

  • CAI 63 → 58 (-4.8)
  • Rubric changed (rubric-2026.08.19 → rubric-2026.09.15) — scores are not directly comparable.

Lenses

  • Code Health 95 → 92 (-3.0)
  • Architecture 69 → 69 (+0.0)
  • Maturity 51 → 51 (+0.0)
  • Readiness 67 → 51 (-16.1)
  • Security 75 → 80 (+5.0)

Resolved (56)

  • Change coupling: NonNullableRepository.ts ↔ NullableRepository.ts (src/repository/NonNullableRepository.ts)
  • Coverage not included — suite not readable by the collector
  • Critical CVE: [GHSA redacted] (yarn.lock)
  • Critical CVE: [GHSA redacted] (yarn.lock)
  • Critical CVE: [GHSA redacted] (yarn.lock)
  • Critical CVE: [GHSA redacted] (yarn.lock)
  • Critical CVE: [GHSA redacted] (yarn.lock)
  • Critical CVE: [GHSA redacted] (yarn.lock)
  • Dependency hygiene not measured — dependency manifest found but not parsed for hygiene
  • High CVE: [GHSA redacted] (yarn.lock)
  • High CVE: [GHSA redacted] (yarn.lock)
  • High CVE: [GHSA redacted] (yarn.lock)
  • High CVE: [GHSA redacted] (yarn.lock)
  • High CVE: [GHSA redacted] (yarn.lock)
  • High CVE: [GHSA redacted] (yarn.lock)
  • High CVE: [GHSA redacted] (yarn.lock)
  • High CVE: [GHSA redacted] (yarn.lock)
  • High CVE: [GHSA redacted] (yarn.lock)
  • High CVE: [GHSA redacted] (yarn.lock)
  • High CVE: [GHSA redacted] (yarn.lock)
  • …and 36 more

New (54)

  • Coverage not measured — JavaScript/TypeScript suite
  • Critical CVE: [GHSA redacted] (yarn.lock)
  • Critical CVE: [GHSA redacted] (yarn.lock)
  • Critical CVE: [GHSA redacted] (yarn.lock)
  • Critical CVE: [GHSA redacted] (yarn.lock)
  • Critical CVE: [GHSA redacted] (yarn.lock)
  • Critical CVE: [GHSA redacted] (yarn.lock)
  • Documentation: no installation or build instructions (README.md)
  • High CVE: [GHSA redacted] (yarn.lock)
  • High CVE: [GHSA redacted] (yarn.lock)
  • High CVE: [GHSA redacted] (yarn.lock)
  • High CVE: [GHSA redacted] (yarn.lock)
  • High CVE: [GHSA redacted] (yarn.lock)
  • High CVE: [GHSA redacted] (yarn.lock)
  • High CVE: [GHSA redacted] (yarn.lock)
  • High CVE: [GHSA redacted] (yarn.lock)
  • High CVE: [GHSA redacted] (yarn.lock)
  • High CVE: [GHSA redacted] (yarn.lock)
  • High CVE: [GHSA redacted] (yarn.lock)
  • High CVE: [GHSA redacted] (yarn.lock)
  • …and 34 more

Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

Survey your own repository

almin/ddd-base was measured the same way every project in this corpus was: the same rubric, at a pinned commit, with the result published in full. Point a surveyor at a repository you know and see whether you agree with it.

About this page

  • The score is its most recent published measurement, taken on 21 September 2026 at a pinned commit. It is not a live figure and does not change until the project is measured again.
  • Measured at commit 960738a4530226379918dced104245726eb81e9e — the exact code this score is about.
  • Scored under rubric-2026.09.15 — the same rubric and the same method as every other entry in this index.
  • Measured by watchdog.canine.dev using codehealth-analyzer preprod-b84573e22831.