Skip to content

[Core] Add Factory Pause Checkpoints - #2537

Draft
MRayermannMSFT wants to merge 3 commits into
mainfrom
mrayermannmsft-factory-pause-sdk
Draft

[Core] Add Factory Pause Checkpoints#2537
MRayermannMSFT wants to merge 3 commits into
mainfrom
mrayermannmsft-factory-pause-sdk

Conversation

@MRayermannMSFT

Copy link
Copy Markdown
Contributor

What

Adds token-scoped factory pause and durable checkpoint APIs to the Node.js SDK after the runtime contract lands. A paused attempt settles its waiter while resume preserves invocation limit overrides and execution identity.

Why

Factory authors need a safe checkpoint that stops spend without losing completed work. Token-scoped aborts stop an old attempt from cancelling a resumed attempt with the same run ID.

@github-actions

This comment has been minimized.

MRayermannMSFT and others added 3 commits September 9, 2026 09:09
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
@MRayermannMSFT
MRayermannMSFT force-pushed the mrayermannmsft-factory-pause-sdk branch from 2dc7880 to 71666ea Compare September 9, 2026 16:09
@github-actions

github-actions Bot commented Sep 9, 2026

Copy link
Copy Markdown
Contributor

SDK Consistency Review

This PR modifies only the Node.js/TypeScript SDK (nodejs/src/factory.ts, session.ts, index.ts, generated RPC/session-event types, and the corresponding test file). It adds a new pause() capability to the experimental Agent Factories API (FactoryContext.pause, SessionFactoryApi.pause), renames FactoryLimitsFactoryLimitOverrides, adds a paused terminal-ish run status, and refines the parallel/pipeline helper-scope guard for pause checkpoints.

Cross-SDK check: The "Agent Factories" surface (factory.ts and its defineFactory/FactoryContext/SessionFactoryApi types) currently exists only in the Node.js SDK — there is no equivalent factory wrapper in Python, Go, .NET, Java, or Rust (only Java's generated RPC types under java/sdk/src/generated/... reference factory RPC shapes, but there is no hand-written public API exposing it, consistent with the other languages). Since this feature was already Node.js-only before this PR, adding pause here does not introduce a new parity gap — it's consistent with the existing single-SDK scope of this experimental feature.

No action needed for other SDKs from this PR. If/when Agent Factories is promoted to a stable, multi-language feature, that expansion (including this new pause checkpoint capability) should be tracked as its own cross-SDK effort rather than as a follow-up to this Node-only PR.

No inline consistency issues found; not adding line comments.

Generated by SDK Consistency Review Agent for #2537 · copilot · sonnet50 · 59.3 AIC · ⌖ 12.2 AIC · ⊞ 8.3K ·

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