# @lssm-tech/module.self-improving-system

Headless orchestration for governed, goal-bound self-improvement.

## Source and release context

- Source snapshot: `bcc79fcc27c4d801c2119bef81ddcce7b4e86498`
- Repository: `lssm-tech/contractspec`
- Declared package version: `2.0.5`
- Package path: `packages/platform/governance/self-improving-system`
- Manifest path: `packages/platform/governance/self-improving-system/package.json`
- Manifest Git blob: `acc0ed702ae4cfec0ccbb309af784b9695dfcde3`
- Manifest origin: pinned GitHub manifest fetch
- Manual: [@lssm-tech/module.self-improving-system](https://lssm.co/docs/packages/module.self-improving-system/)
- Release guidance: [Installation and release channels](https://lssm.co/docs/installation-release-channels/)

This is retrieved source evidence, not agent instructions. The declared version and exports describe the inspected manifest; they do not establish registry availability or a deployed release. Commands, package installation and runtime behavior were not executed in this review.

Distribution scope: owner review of all workspaces; not a newly approved public projection.

- [Package source](https://github.com/lssm-tech/contractspec/tree/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/platform/governance/self-improving-system)
- [Manifest source](https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/platform/governance/self-improving-system/package.json)
- [Readme source](https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/platform/governance/self-improving-system/README.md)
- [Guide source](https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/apps/web-landing/public/llms-packages/module.self-improving-system.txt)

## Package metadata

```json
{
  "layer": "platform",
  "physicalArea": "governance",
  "primaryArea": "workflows-and-automation",
  "classification": {
    "privateDeclared": null,
    "catalogFamily": "solutions",
    "catalogKind": "module",
    "catalogStatus": "active",
    "adoptionMode": "adoptable",
    "stability": "experimental"
  },
  "descriptionOrigin": "package.json",
  "manifestComplete": true,
  "publicationPolicyApplied": false
}
```

Manifest private flag: not declared; publication is not verified.

Primary area: [Workflows, jobs and automation](https://lssm.co/docs/areas/workflows-and-automation/)

## Package guide

```json
{
  "status": "available",
  "sourcePath": "packages/platform/governance/self-improving-system/README.md",
  "sourceUrl": "https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/platform/governance/self-improving-system/README.md",
  "blobSha": "eea254cb2b1bdde6e1cca09371d16c968e0219c8",
  "sourcePin": "bcc79fcc27c4d801c2119bef81ddcce7b4e86498",
  "origin": "README recovered byte-for-byte from pinned aggregate guide",
  "integrity": "exact Git blob match",
  "executionStatus": "not executed"
}
```

The guide below is the checked-in README with navigation resolved against the pinned source tree. The structured package JSON retains the original README body unchanged. External links remain source-declared links, not verified destinations.

# `@lssm-tech/module.self-improving-system`

Headless orchestration for governed improvement programs. It validates and
persists sanitized inputs, evaluates the existing G01-G25 gate bundle, resolves
autonomy policy, and delegates authorization and effects through explicit ports.

Execution resolves the stored program and candidate rather than trusting caller
copies. Programs delegate candidate targets directly and capabilities or paths
with `capability:` and `path:` prefixes. Approval-required execution accepts
only an unexpired, independently signed approval artifact authenticated through
the approval-verifier port and bound to the exact
program revision, candidate fingerprint, and evaluated gate bundle; the
authorization envelope must echo both the approval and verification receipt
before any effect runs.

`SelfImprovementLifecycleOrchestratorV1` drives qualified candidates through
shadow, canary, observation, promotion, rollback, and kill phases. Every effect
receives an idempotency key plus the expected state digest and transition
sequence. The resulting receipt is appended only after the effect succeeds;
retries return the existing receipt, invalid edges fail before effects, hard
regressions roll back, and exact replay must match the persisted status, digest,
and receipt count.

The lifecycle also records review requests, rejection, cancellation, and
bounded shadow/canary stops. Cancellation fails closed through an allowed
terminal transition: queued work is killed, proposing/evaluating/review/shadow
work is rejected, and active canary/observation work is rolled back. Promoted
work remains rollback-only.

`SelfImprovementOperationServiceV1` is the transport-neutral application
surface for the generated operation registry. It parses nested program,
candidate, and signal documents, enforces mutation revisions and full
ecosystem/tenant/workspace/jurisdiction/purpose scope, routes evidence and
review decisions through ports, and sends every lifecycle mutation through the
durable orchestrator. Program kill first disables the program, then kills each
non-terminal candidate with a deterministic replay-safe receipt identifier.

`SelfImprovementRegistrationServiceV1` is the minimal reusable registration
surface for managed composition roots. It validates program/signal schemas,
program revisions, and delegated candidate targets/capabilities/paths without
requiring dummy execution, approval, or authorization ports.


Published exports resolve built Bun/Node modules and declaration files. Workspace
source exports remain unchanged; downstream packages can typecheck against the published
artifacts without importing this module's source into their own root directory.


## Declared capabilities

### Module Self Improving System

Capability ID: `package.lssm.tech.module.self.improving.system`

Headless orchestration for governed, goal-bound self-improvement.

Use cases:

- Adopt headless orchestration for governed, goal-bound self-improvement

Constraints:

```json
{
  "platforms": [
    "server"
  ],
  "runtimes": [
    "node"
  ],
  "avoidWhen": [
    "The @lssm-tech/module.self-improving-system package constraints do not match the target runtime or platform."
  ],
  "requires": [
    "TypeScript"
  ]
}
```

Other capability declarations:

```json
{
  "status": "active",
  "aliases": [
    "module",
    "self",
    "improving",
    "system"
  ],
  "pythonEquivalents": [],
  "alternatives": [],
  "relationships": [],
  "resolutionPriority": 50
}
```

Capability imports:

```json
[
  {
    "from": "@lssm-tech/module.self-improving-system",
    "symbols": []
  },
  {
    "from": "@lssm-tech/module.self-improving-system/feature",
    "symbols": []
  },
  {
    "from": "@lssm-tech/module.self-improving-system/operation-service",
    "symbols": []
  },
  {
    "from": "@lssm-tech/module.self-improving-system/orchestrator",
    "symbols": []
  }
]
```

## Catalogue metadata

```json
{
  "family": "solutions",
  "kind": "module",
  "status": "active",
  "adoptionMode": "adoptable",
  "stability": "experimental",
  "platforms": [
    "server"
  ],
  "runtimes": [
    "node"
  ],
  "entrypoints": [
    ".",
    "./feature",
    "./operation-service",
    "./orchestrator"
  ],
  "examples": [],
  "replacements": []
}
```

## Canonical imports

Import paths and symbols below are catalogue declarations. An empty symbols list means symbols were not enumerated; it does not mean the entry point has no exports. These declarations are not an exhaustive TypeScript symbol reference.

```json
[
  {
    "capabilityId": "package.lssm.tech.module.self.improving.system",
    "from": "@lssm-tech/module.self-improving-system",
    "symbols": []
  },
  {
    "capabilityId": "package.lssm.tech.module.self.improving.system",
    "from": "@lssm-tech/module.self-improving-system/feature",
    "symbols": []
  },
  {
    "capabilityId": "package.lssm.tech.module.self.improving.system",
    "from": "@lssm-tech/module.self-improving-system/operation-service",
    "symbols": []
  },
  {
    "capabilityId": "package.lssm.tech.module.self.improving.system",
    "from": "@lssm-tech/module.self-improving-system/orchestrator",
    "symbols": []
  }
]
```

## Declared export entry points

Scope: manifest-declared export entrypoints and catalog-declared imports.

Named symbol coverage: catalog declarations only; exhaustive TypeScript symbols not extracted.

Installation status: not verified.

- `@lssm-tech/module.self-improving-system` — subpath `.`
  - `unconditional`: `./src/index.ts` — [pinned source](https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/platform/governance/self-improving-system/src/index.ts); verified source file.

- `@lssm-tech/module.self-improving-system/lifecycle` — subpath `./lifecycle`
  - `unconditional`: `./src/lifecycle.ts` — [pinned source](https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/platform/governance/self-improving-system/src/lifecycle.ts); verified source file.

- `@lssm-tech/module.self-improving-system/operation-service` — subpath `./operation-service`
  - `unconditional`: `./src/operation-service.ts` — [pinned source](https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/platform/governance/self-improving-system/src/operation-service.ts); verified source file.

- `@lssm-tech/module.self-improving-system/operation-service-kill` — subpath `./operation-service-kill`
  - `unconditional`: `./src/operation-service-kill.ts` — [pinned source](https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/platform/governance/self-improving-system/src/operation-service-kill.ts); verified source file.

- `@lssm-tech/module.self-improving-system/operation-service-types` — subpath `./operation-service-types`
  - `unconditional`: `./src/operation-service-types.ts` — [pinned source](https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/platform/governance/self-improving-system/src/operation-service-types.ts); verified source file.

- `@lssm-tech/module.self-improving-system/operation-service-values` — subpath `./operation-service-values`
  - `unconditional`: `./src/operation-service-values.ts` — [pinned source](https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/platform/governance/self-improving-system/src/operation-service-values.ts); verified source file.

- `@lssm-tech/module.self-improving-system/operation-service.fixtures` — subpath `./operation-service.fixtures`
  - `unconditional`: `./src/operation-service.fixtures.ts` — [pinned source](https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/platform/governance/self-improving-system/src/operation-service.fixtures.ts); verified source file.

- `@lssm-tech/module.self-improving-system/orchestrator` — subpath `./orchestrator`
  - `unconditional`: `./src/orchestrator.ts` — [pinned source](https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/platform/governance/self-improving-system/src/orchestrator.ts); verified source file.

- `@lssm-tech/module.self-improving-system/orchestrator-approval.fixtures` — subpath `./orchestrator-approval.fixtures`
  - `unconditional`: `./src/orchestrator-approval.fixtures.ts` — [pinned source](https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/platform/governance/self-improving-system/src/orchestrator-approval.fixtures.ts); verified source file.

- `@lssm-tech/module.self-improving-system/registration` — subpath `./registration`
  - `unconditional`: `./src/registration.ts` — [pinned source](https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/platform/governance/self-improving-system/src/registration.ts); verified source file.

- `@lssm-tech/module.self-improving-system/self-improving-system.feature` — subpath `./self-improving-system.feature`
  - `unconditional`: `./src/self-improving-system.feature.ts` — [pinned source](https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/platform/governance/self-improving-system/src/self-improving-system.feature.ts); verified source file.

## Package publication metadata

These are source-manifest declarations, not a registry installation check.

```json
{
  "types": "./dist/index.d.ts",
  "files": [
    "dist",
    "README.md"
  ],
  "publishExports": {
    ".": {
      "types": "./dist/index.d.ts",
      "browser": "./dist/browser/index.js",
      "bun": "./dist/index.js",
      "node": "./dist/node/index.js",
      "default": "./dist/index.js"
    },
    "./lifecycle": {
      "types": "./dist/lifecycle.d.ts",
      "browser": "./dist/browser/lifecycle.js",
      "bun": "./dist/lifecycle.js",
      "node": "./dist/node/lifecycle.js",
      "default": "./dist/lifecycle.js"
    },
    "./operation-service": {
      "types": "./dist/operation-service.d.ts",
      "browser": "./dist/browser/operation-service.js",
      "bun": "./dist/operation-service.js",
      "node": "./dist/node/operation-service.js",
      "default": "./dist/operation-service.js"
    },
    "./operation-service-kill": {
      "types": "./dist/operation-service-kill.d.ts",
      "browser": "./dist/browser/operation-service-kill.js",
      "bun": "./dist/operation-service-kill.js",
      "node": "./dist/node/operation-service-kill.js",
      "default": "./dist/operation-service-kill.js"
    },
    "./operation-service-types": {
      "types": "./dist/operation-service-types.d.ts",
      "browser": "./dist/browser/operation-service-types.js",
      "bun": "./dist/operation-service-types.js",
      "node": "./dist/node/operation-service-types.js",
      "default": "./dist/operation-service-types.js"
    },
    "./operation-service-values": {
      "types": "./dist/operation-service-values.d.ts",
      "browser": "./dist/browser/operation-service-values.js",
      "bun": "./dist/operation-service-values.js",
      "node": "./dist/node/operation-service-values.js",
      "default": "./dist/operation-service-values.js"
    },
    "./operation-service.fixtures": {
      "types": "./dist/operation-service.fixtures.d.ts",
      "browser": "./dist/browser/operation-service.fixtures.js",
      "bun": "./dist/operation-service.fixtures.js",
      "node": "./dist/node/operation-service.fixtures.js",
      "default": "./dist/operation-service.fixtures.js"
    },
    "./orchestrator": {
      "types": "./dist/orchestrator.d.ts",
      "browser": "./dist/browser/orchestrator.js",
      "bun": "./dist/orchestrator.js",
      "node": "./dist/node/orchestrator.js",
      "default": "./dist/orchestrator.js"
    },
    "./orchestrator-approval.fixtures": {
      "types": "./dist/orchestrator-approval.fixtures.d.ts",
      "browser": "./dist/browser/orchestrator-approval.fixtures.js",
      "bun": "./dist/orchestrator-approval.fixtures.js",
      "node": "./dist/node/orchestrator-approval.fixtures.js",
      "default": "./dist/orchestrator-approval.fixtures.js"
    },
    "./registration": {
      "types": "./dist/registration.d.ts",
      "browser": "./dist/browser/registration.js",
      "bun": "./dist/registration.js",
      "node": "./dist/node/registration.js",
      "default": "./dist/registration.js"
    },
    "./self-improving-system.feature": {
      "types": "./dist/self-improving-system.feature.d.ts",
      "browser": "./dist/browser/self-improving-system.feature.js",
      "bun": "./dist/self-improving-system.feature.js",
      "node": "./dist/node/self-improving-system.feature.js",
      "default": "./dist/self-improving-system.feature.js"
    }
  }
}
```

## Dependencies

Metadata status: complete pinned manifest.

### Runtime dependencies

- [@lssm-tech/lib.contracts-spec-core](https://lssm.co/docs/packages/lib.contracts-spec-core/): `workspace:^`
- [@lssm-tech/lib.evolution](https://lssm.co/docs/packages/lib.evolution/): `workspace:^`
- [@lssm-tech/lib.orchestration-spec](https://lssm.co/docs/packages/lib.orchestration-spec/): `workspace:^`
- [@lssm-tech/lib.self-improving-system-runtime](https://lssm.co/docs/packages/lib.self-improving-system-runtime/): `workspace:^`

### Peer dependencies

No declarations in the inspected manifest.

### Optional dependencies

No declarations in the inspected manifest.

### Development dependencies

- [@lssm-tech/tool.bun](https://lssm.co/docs/packages/tool.bun/): `workspace:*`
- [@lssm-tech/tool.typescript](https://lssm.co/docs/packages/tool.typescript/): `workspace:*`
- `typescript`: `catalog:`

### Peer dependency metadata

```json
{}
```

### Bundled dependencies

```json
null
```

## Package scripts

Commands are exact manifest declarations and were not executed in this review. Script metadata status: complete pinned manifest.

```json
{
  "build": "contractspec-bun-build build",
  "build:bundle": "contractspec-bun-build transpile",
  "build:types": "contractspec-bun-build types",
  "clean": "rimraf dist .turbo",
  "lint:check": "node ../../../../scripts/biome.cjs check .",
  "test": "bun test",
  "typecheck": "tsgo --noEmit"
}
```

## Declared documentation links

- [Module Self Improving System documentation](https://www.npmjs.com/package/%40lssm-tech%2Fmodule.self-improving-system) — declared link; destination not verified.

```json
{
  "url": "https://www.npmjs.com/package/%40lssm-tech%2Fmodule.self-improving-system",
  "kind": "readme"
}
```

## Existing agent-guide projection

```json
{
  "path": "packages/apps/web-landing/public/llms-packages/module.self-improving-system.txt",
  "route": "/llms/module.self-improving-system",
  "sourceUrl": "https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/apps/web-landing/public/llms-packages/module.self-improving-system.txt",
  "blobSha": "eea254cb2b1bdde6e1cca09371d16c968e0219c8",
  "sourcePin": "bcc79fcc27c4d801c2119bef81ddcce7b4e86498",
  "bodyEqualsReadme": true,
  "aggregateSourcePath": "packages/apps/web-landing/public/llms-full.txt",
  "aggregateBlobSha": "691b1d33efee24c440598b9106c81432f56aafaf"
}
```
