gnomonlearn
Docs/RFC-0039/Design Q&A

RFC-0039 · Design Q&A

Versioned draft snapshot

RFCs, reference catalogs, and evidence reflect Spec 3b2e3e7a114fb826b1445d39a48756b8fff629cd. Counts and pending/status notes belong to that snapshot. Read the dated project update for later progress.

Source repositories are private during staging. Links marked “repository access required” need access to the linked repository.

← Read the authored RFC

Q: How are nested template writes ordered within the two-pass transaction?

Status: Open

Source: RFC-0039 §§4.3, 6.1, 8 invariant 4 Issue: The parent executes all resources, then nested calls, then statements. A nested call executes its own statements before the parent’s remaining statements, so the stated resource-before-statement rule is not global. The RFC does not define whether a nested call can reference a resource from a later sibling or how cycles are rejected. Recommendation: Define a dependency graph for nested calls and resource references, reject cycles and unresolved forward references, and specify whether ordering is global or scoped to each invocation.

Q: What makes statement creation idempotent when the template has an idempotency key?

Status: Open

Source: RFC-0039 §§1, 6.2, 7 Issue: The key derives stable external IDs and upsert behavior only for resources. Re-execution still creates statements, which can duplicate edges or fail overlap constraints, despite the promised same-result behavior. Recommendation: Define stable statement identity and find-or-update semantics, including each for_each item and bitemporal interval, or narrow the idempotency claim to resources and document statement replay behavior.

Q: What result represents a value-form root or a skipped root object?

Status: Open

Source: RFC-0039 §§3.2, 4.1, 6.5 Issue: exports.root may name a value expression, but TemplateExecutionResult has only rootResourceId and rootResourceName. A false resource condition can also skip the mandatory root without defining whether execution succeeds. Recommendation: Use a tagged root result covering resource and value exports, and specify a diagnostic or explicit empty outcome when the root is skipped.

Q: What is the transaction behavior of continueOnError?

Status: Open

Source: RFC-0039 §§3, 6.5, 8 invariant 9; RFC-0038 §7 Issue: The executor refers to continueOnError, but the document and invocation contract do not define it. Continuing after a write error conflicts with rollback on failure unless failed operations are isolated. Recommendation: Define the option, result, and savepoint behavior precisely, or remove it and make execution atomic.

Q: Which runtime values are stable across a replay with the same inputs?

Status: Open

Source: RFC-0039 §§5.2, 7 Issue: now, uuid, and uniqueId can change on every execution, while §7 promises the same result for the same template and inputs. The cache and resource external IDs do not stabilize those values. Recommendation: Scope the promise to stable resource identity or capture nondeterministic values under an idempotency record and replay them; state how host-registered functions affect this guarantee.

Q: How should the reference-resolution prohibition be expressed in the structured claim?

Status: Open

Source: RFC-0039 §5.3; lean/Gnomon/Spec/Graph/Rfc0039.lean statement b8 Issue: The prose requires reference resolution to be a pure read with no side effects. The structured statement has modality MUST_NOT over a predicate that combines “has side effects” with “it is a pure read.” Negating that combined sentence makes the normative claim ambiguous and weakens the source-to-RDF projection. Recommendation: Express the prohibited behavior as a single positive predicate, “Reference resolution has side effects,” under MUST_NOT; keep the pure-read requirement as a separate affirmative statement if needed. Regenerate the RDF and reference catalog, then re-review the source-bound theorem citation.