# CLI 0.0.4-microsoft-preview.27

Microsoft migration engine preview. Stable `latest` remains 0.0.3.

## Mermaid link-style recovery

- Recover target architecture diagrams when Mermaid 11 reports its opaque
  `Cannot set properties of undefined (setting 'style')` error because the
  model supplied `linkStyle` indexes that do not identify real edges.
- Retry the exact normalized graph without presentation-only `linkStyle`
  directives. The repair is accepted only when the pinned Mermaid grammar then
  validates the diagram; nodes, edges, labels, and architecture content are not
  changed.
- Prevent the planning model from spending repeated long calls resubmitting the
  same otherwise-valid architecture until the host's `MODEL_TOOL_LOOP` guard
  stops the stage.

The reported FINACCONT-BT planning audit contained 28 graph edges and 201
`linkStyle` directives, reaching index 200. The regression test reproduces the
same out-of-range styling failure class and verifies that only presentation
directives are removed.

## Microsoft stage safeguards

- Treat matching custom source code anywhere in the selected migration
  inventory as available migration input instead of persisting it as a missing
  binary dependency merely because it is outside the current flow group.
- Reject helper/library-only flow groups without an executable BizTalk entry
  point, require every selected artifact to be grouped or explicitly ungrouped,
  keep caller/callee orchestrations together, and revalidate resumed grouping
  caches before later stages can use them.
- Require a distinct runnable Logic Apps workflow for every selected source
  orchestration, including child, parked, and error workflows. Existing workflow
  names cannot be overwritten in a way that silently removes verified source
  coverage.

## Verification and limits

- 131 Microsoft migration-core tests, 252 CLI tests, and 30 public
  release/installer/documentation tests pass. CLI lint, TypeScript compilation,
  and the production build also pass.
- All 141 previously published assets through preview.26 matched the local
  staging tree byte-for-byte over HTTPS before this release was added.
- The Mermaid fallback does not accept a malformed graph: if parsing still
  fails after presentation-only link styling is removed, the architecture is
  rejected and no planning file is changed.
- No live end-to-end customer migration, deployed Logic Apps runtime test, or
  business-equivalence test was performed for this release.

## PowerShell update

```powershell
Invoke-WebRequest 'https://tools.lambogenius.com/lambogenius-integration-migration/0.0.4-microsoft-preview.27/install-cli.ps1' -OutFile install-cli-preview27.ps1
# Review the downloaded script before running it.
& .\install-cli-preview27.ps1 -SkipDependencies
li.cmd --version
```

Expected version: `0.0.4-microsoft-preview.27`. This preview is not promoted to
the stable `latest` alias. Preserve existing reports and generated output, then
use a fresh generated workspace because Microsoft engine changes participate in
migration fingerprints. Do not edit fingerprint records to force checkpoint
reuse. Installation does not reset license counters.
