# Supplemental source inputs for sparse connector transforms

`applyConnectorFieldMappings` accepts an optional `transformSourceRecord` record
when `filterMappingsBySourcePresence` or `coalescedPropertyChanges` is enabled.
It provides evaluation inputs, not additional target writes. Callers that omit
it retain their existing source selection and missing-dependency behavior.

A property event can contain only `child`, while its selected mapping transforms
`$Record.parent & "|" & $Record.child`. Previously a caller could provide the
parent in its hydrated `sourceRecord`, but the coalesced reducer correctly
removed that unobserved property. The transform then lacked an input and skipped.
The new explicit input completes this calculation without replaying a synthetic
parent event or applying every field from a later provider snapshot.

## Authority and execution

1. The executing standard Flow's owner selects the authoritative mapping tuple.
   The complete mapping set and target schema are validated before selection.
2. The existing coalesced reducer chooses observed values by source field and
   latest `occurredAt`; its output remains independent of enrichment. Existing
   derivations and selected-value validations retain their behavior.
3. Observed fields alone determine eligible mappings. Direct mappings require
   their source field; transforms require at least one observed expression
   dependency. A constant expression cannot select itself. The canonical
   `ConnectorTransformReferencedSourceFields` AST reader owns dependencies;
   there is no second authored field list or provider-specific parser.
4. Only missing dependencies of those eligible transforms may be read from
   `transformSourceRecord`. Observed values, including explicit null or blank,
   win case-insensitively. These supplemental keys cannot select another target.
   Neither input record is changed. A dependency still absent from both records
   leaves its mapping skipped under the existing sparse contract.
5. Existing formula evaluation, value maps, conflict policies, blank-clear rules,
   target locking, permissions, validation and persistence write the selected
   values. Shared outbound mapping construction is unchanged.

The supplemental record is a Flow input, not a new identity authority or an
as-of-event provider snapshot. Its author must supply the already authenticated
record for the same remote identity through the established connector read path.
The engine neither fetches provider data nor infers missing values from the
current local target. A later context value can participate in a selected
transform; it never replaces the explicitly observed event value.

Invalid or duplicate context parameters fail before persistence. An authored
context must resolve to a record and requires sparse selection; it cannot be
used to turn a full/default mapping application into an implicit partial write.
Sparse selection remains incompatible with `applyExtraUpdates`.

## Owners and verification

Under [the L0/L1 standard](l0-l1-standard.md), the existing mapping action owns
selection and the formula engine owns dependency interpretation. Packs own the
compound expression, supplying the source context and selecting delta mapping
tuples. The missing capability is the separation between observed write inputs
and supplemental expression inputs at this existing action seam; the generic
parent/child executable regression demonstrates the prior failure.

`executor_connector_field_mapping.go` is the sole production caller of sparse
selection. `buildConnectorFieldMappingUpdatesWithEngine` is also used by
`runtime_outbound_intent.go`, so this change leaves that shared builder intact.
`connector_push_payload.go` already uses the same AST dependency reader for its
separate outbound field requirements and authorization.

`connector_transform_source_test.go` observes the actual persistence update from
the action. It covers compound child-only events, unrelated fields, observed
precedence and casing, blanks, unresolved dependencies, opt-out compatibility,
input detachment and malformed context. Pack tests must additionally execute the
authored assignments/actions with the native runtime. Provider delivery and
terminal WorkItem coverage remain deployment acceptance; helper success alone
does not prove that journey.
