Skip to content

Add SCM functional knowledge domain - #192

Open
Jesper Schulz-Wedde (JesperSchulz) wants to merge 2 commits into
mainfrom
jesperschulz-scm-knowledge-domain
Open

Jesper Schulz-Wedde (JesperSchulz) wants to merge 2 commits into
mainfrom
jesperschulz-scm-knowledge-domain

Conversation

@JesperSchulz

@JesperSchulz Jesper Schulz-Wedde (JesperSchulz) commented Sep 17, 2026

Copy link
Copy Markdown
Contributor

Summary

Introduce microsoft/knowledge/scm/: nine scoped functional rules with original, self-contained bad/good AL samples. Independently based on refreshed main (b91443be), intended to land before #57; no unmerged Finance code or shared-domain abstraction is required.

Knowledge inventory Why it matters
Item-ledger/value posting ownership Preserve quantity, application, valuation and tracking relationships.
Calculated revaluation batch posting Preserve aggregate allocation, quantity checks, rounding and standard-cost updates.
Item unapplication/reapplication Preserve the cost/application graph and finalization lifecycle.
Reservation cancellation Handle counterparts and surviving tracking, including late-binding exceptions.
Source-specific item-tracking transfer Preserve partial base quantities, ownership, statuses and remainders.
Warehouse-adjustment reconciliation Distinguish registration/calculation from item-ledger posting.
Transfer shipment/receipt posting Preserve in-transit, partial-receipt, document and cost lineage.
Date-aware available-to-promise Account for demand, reservations, incoming supply, location and variant.
Requisition action-message carry-out Preserve action semantics and demand/reservation handoff to supply.

Research is synthesized from Microsoft Learn and BCApps 8f7a04cb (BaseApp source 30.0). No implementation bodies are copied. The posting rule is retained for SCM-specific application/value/tracking invariants and capacity/WIP/temporary-buffer exclusions, not generic engine-use advice.

Review feedback and integration

  • Articles now use descriptive BC facts/consequences and exact inline See sample links. All 18 AL companions are global and import-free; executable bodies are unchanged.
  • al-scm-review is 121 lines instead of 213, retaining deterministic cues, index-first bounded retrieval and the strict mutation/posting-or-supply/demand gate. DO/schema governs output; embedded examples and the SCM-only shared-test block are removed.
  • Preserve dynamic $expectedLeaves.Count diagnostics and number-free/common coverage wording.
  • Reciprocal ownership: Item/Value/Capacity/Warehouse and inventory-application records are SCM; pure G/L/customer/vendor/detailed/VAT mutations are Finance, even if that leaf is absent. Equivalent inventory-originated posting bypasses have one SCM primary owner; independent financial defects remain separate.

Validation

The exact publication tree was checked after refreshing origin/main:

  • Frontmatter: 0 errors/0 warnings; index/retrieval: 316 articles and 525 samples round-tripped.
  • Skill/schema checks: 18 Microsoft leaves; review contract: 8 cases; fixture preparation: 88 cases/19 domains.
  • Blinded, source-bound case-at-a-time confirmation: 9/9 exact positives and 9/9 clean controls, with every result checked against its opaque request ID, file and source SHA256.
  • Full-DO probes: on-hand display, warehouse caption and pure G/L mutation are not-applicable with zero coverage/findings; mixed Item Ledger+G/L posting yields exactly one SCM primary finding.
  • All 18 final AL samples plus 4 probes compile with CodeCop, using Base Application 28.5.54151.54677 (Cloud/runtime 17.0). Generated SymbolReference inventories confirm all 18 sample codeunits and 4 probe codeunits, without namespaces/imports or ambiguity exceptions.
  • All 7 GitHub checks pass on 525e84e.

An initial batch-model result had three positional tool-response/case association errors. Its immutable output and audit were retained; scorer controls verified the harness, and confirmation used bound individual requests rather than repairing findings. The independently observed read-only gate weakening was fixed narrowly.

No BC environment deployment or database posting tests were performed. Compilation and source research are separate evidence, not runtime coverage across every BC version.

Introduce nine source-backed rules with original AL sample pairs, bounded SCM review routing, and complete positive/clean evaluation coverage.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Align article and AL sample conventions, keep BC facts separate from review mechanics, and clarify reciprocal Finance ownership without bespoke shared test assertions.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant