Skip to content

docs: propose durable session task runtime RFC v2 - #98717

Closed
mjnkao wants to merge 3 commits into
openclaw:mainfrom
mjnkao:codex/openclaw-durable-runtime-rfc-v2-ready
Closed

mjnkao wants to merge 3 commits into
openclaw:mainfrom
mjnkao:codex/openclaw-durable-runtime-rfc-v2-ready

Conversation

@mjnkao

@mjnkao mjnkao commented Jul 1, 2026 •

Copy link
Copy Markdown

What Problem This Solves

OpenClaw has strong sessions, Gateway, tasks, subagents, and operator surfaces, but long-running multi-agent work still needs a small core contract for durable session/task runtime state: run identity, step identity, event ordering, child links, recovery markers, and read-only inspection.

This PR is the RFC/architecture decision point for that boundary. It replaces the older RFC discussion in #97507 with updated naming and scope:

  • durable_runtime_* instead of workflow-oriented schema naming;
  • runtime runs/steps/events/refs/signals/timers/links as the core primitives;
  • local-first shared state DB posture;
  • Task Flow, Workboard, Work module, and external PM tools as projections/follow-ups, not prerequisites;
  • no product-specific terminology.

Dependency Chain

This is PR1 in the replacement durable runtime stack:

  1. PR1: RFC v2 docs only, this PR.
  2. PR2: durable runtime foundation, schema/store/CLI/Gateway read-only inspection.
  3. PR3: agent/session/subagent wiring on top of PR2.

PR2 and PR3 should be reviewed only after this boundary is acceptable.

Scope

Docs only. No runtime behavior changes.

Evidence

Authored evidence for the docs-only RFC:

  • node scripts/generate-docs-map.mjs --check passed after regenerating docs/docs_map.md.
  • node scripts/docs-list.js lists specs/durable-session-task-runtime-rfc.md.
  • git diff --check passed locally before push.
  • Runtime proof is intentionally not applicable: this PR only adds the RFC document and generated docs map entry. The behavior proof for disabled/enabled durable runtime paths is attached to PR2.

Notes

The older PRs #97507 and #97508 are intentionally left open while reviewers inspect this replacement stack. They can be closed after the new stack has review feedback.

@openclaw-barnacle openclaw-barnacle Bot added docs Improvements or additions to documentation size: XS triage: needs-pr-context Candidate: external PR body lacks required problem context or evidence. labels Jul 1, 2026
@clawsweeper

clawsweeper Bot commented Jul 1, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge. Reviewed July 3, 2026, 1:49 AM ET / 05:49 UTC.

Summary
Adds a proposed durable session/task runtime RFC under docs/specs/ and refreshes the generated docs map entry for that route.

PR surface: Docs +171. Total +171 across 2 files.

Reproducibility: not applicable. this is a docs-only architecture RFC, not a bug report or runtime patch. The reviewable checks are generated-doc consistency and consistency with current Task Flow, background-task, and subagent docs.

Review metrics: none identified.

Root-cause cluster
Relationship: canonical
Canonical: #98717
Summary: This PR is the current PR1 RFC v2 decision artifact for the replacement durable session/task runtime stack; older durable RFC/implementation PRs overlap, while the newer foundation and wiring PRs depend on this boundary.

Members:

Proposal only: this assessment does not dispatch repair, suppress jobs, mutate sibling items, close, or merge anything.

Merge readiness
Overall: 🦐 gold shrimp
Proof: 🌊 off-meta tidepool
Patch quality: 🦐 gold shrimp
Result: ready for maintainer review.

Overall follows the weaker of proof and patch quality, so missing proof can cap an otherwise strong patch.

Rank-up moves:

  • [P2] Record maintainer acceptance or redirection of the core durable-runtime boundary before merge.

Risk before merge

  • [P1] Merging this RFC would publish a preferred core durable-runtime architecture before maintainers accept whether the owner boundary belongs in core, Task Flow internals, or a narrower task/session module.
  • [P1] The companion implementation PRs are still open draft work, so schema names, env flags, Gateway projections, and operator controls may change before the public direction is stable.

Maintainer options:

  1. Hold for boundary acceptance (recommended)
    Keep the PR open until maintainers explicitly accept or redirect the core durable-runtime boundary before publishing it as docs direction.
  2. Land as accepted direction
    Maintainers may intentionally accept the public-direction risk and land the RFC as the chosen architecture gate for the companion implementation stack.
  3. Pause the durable stack
    If the boundary is not a current core priority, pause or close this RFC and keep the implementation PRs from advancing until the product direction changes.

Next step before merge

  • [P2] The remaining blocker is maintainer architecture/product acceptance, not an automated repair; the prior docs-map issue is fixed.

Security
Cleared: Cleared: this PR only adds Markdown RFC content plus a generated docs-map entry and does not change executable code, workflows, dependency resolution, secrets handling, or package metadata.

Review details

Best possible solution:

Keep this as the PR1 RFC gate and merge only after maintainers explicitly accept or redirect the durable-runtime owner boundary and companion PR sequence.

Do we have a high-confidence way to reproduce the issue?

Not applicable: this is a docs-only architecture RFC, not a bug report or runtime patch. The reviewable checks are generated-doc consistency and consistency with current Task Flow, background-task, and subagent docs.

Is this the best way to solve the issue?

Unclear as final product direction: the RFC is a reasonable discussion artifact and the docs-map defect is fixed, but the durable runtime boundary needs maintainer acceptance before merge.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning high; reviewed against c5afa92c1f8a.

Label changes

Label changes:

  • add status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Not applicable: Real behavior proof is not required because this PR only changes files under docs/.
  • remove status: 🔁 re-review loop: Current PR status label is status: 👀 ready for maintainer look.

Label justifications:

  • P3: This is a docs-only draft RFC for future architecture direction, not a current shipped runtime regression.
  • merge-risk: 🚨 other: Merging would publish a preferred durable-runtime architecture before maintainers settle the core-vs-Task-Flow-vs-task/session ownership boundary.
  • rating: 🦐 gold shrimp: Overall readiness is 🦐 gold shrimp; proof is 🌊 off-meta tidepool and patch quality is 🦐 gold shrimp.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Not applicable: Real behavior proof is not required because this PR only changes files under docs/.
Evidence reviewed

PR surface:

Docs +171. Total +171 across 2 files.

View PR surface stats
Area Files Added Removed Net
Source 0 0 0 0
Tests 0 0 0 0
Docs 2 171 0 +171
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 2 171 0 +171

What I checked:

Likely related people:

  • mjnkao: Authored this RFC and the related durable-runtime replacement stack, so they are the best source for intent and follow-up revisions even though the runtime is not on main yet. (role: durable RFC stack author/proposer; confidence: medium; commits: 8d0fab1dfb3e, a040e3079191, 9ff8f44fd5fe; files: docs/specs/durable-session-task-runtime-rfc.md, docs/docs_map.md)
  • vincentkoc: Visible docs history includes automation-section restructuring, TaskFlow naming, and docs navigation/map work that governs where this RFC fits in the docs tree. (role: docs IA and automation docs contributor; confidence: medium; commits: ec17260e264c, d9c662dc695c, 8a916652e8b8; files: docs/automation/taskflow.md, docs/automation/tasks.md, docs/docs_map.md)
  • steipete: Recent current-main history includes Task Flow registry work, and the related durable routines PR shows overlap with shared SQLite, Gateway, CLI, and operator-lifecycle product boundaries. (role: adjacent runtime and product-boundary contributor; confidence: medium; commits: 2f84c47b8bc2, 786ba1e63a69; files: src/tasks/task-flow-registry.ts, docs/automation/taskflow.md)
What the crustacean ranks mean
  • 🦀 challenger crab: rare, exceptional readiness with strong proof, clean implementation, and convincing validation.
  • 🦞 diamond lobster: very strong readiness with only minor maintainer review expected.
  • 🐚 platinum hermit: good normal PR, likely mergeable with ordinary maintainer review.
  • 🦐 gold shrimp: useful signal, but proof or patch confidence is still limited.
  • 🦪 silver shellfish: thin signal; proof, validation, or implementation needs work.
  • 🧂 unranked krab: not merge-ready because proof is missing/unusable or there are serious correctness or safety concerns.
  • 🌊 off-meta tidepool: rating does not apply to this item.

Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics.

How this review workflow works
  • ClawSweeper keeps one durable marker-backed review comment per issue or PR.
  • Re-runs edit this comment so the latest verdict, findings, and automation markers stay together instead of adding duplicate bot comments.
  • A fresh review can be triggered by eligible @clawsweeper re-review comments, exact-item GitHub events, scheduled/background review runs, or manual workflow dispatch.
  • PR/issue authors and users with repository write access can comment @clawsweeper re-review or @clawsweeper re-run on an open PR or issue to request a fresh review only.
  • Maintainers can also comment @clawsweeper review to request a fresh review only.
  • Fresh-review commands do not start repair, autofix, rebase, CI repair, or automerge.
  • Maintainer-only repair and merge flows require explicit commands such as @clawsweeper autofix, @clawsweeper automerge, @clawsweeper fix ci, or @clawsweeper address review.
  • Maintainers can comment @clawsweeper explain to ask for more context, or @clawsweeper stop to stop active automation.

@clawsweeper clawsweeper Bot added rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. labels Jul 1, 2026
@clawsweeper clawsweeper Bot added status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. P3 Low-priority cleanup, docs, polish, ergonomics, or speculative work. merge-risk: 🚨 other 🚨 Merging this PR has meaningful risk outside the owned taxonomy. and removed status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. labels Jul 1, 2026
@mjnkao

mjnkao commented Jul 1, 2026

Copy link
Copy Markdown
Author

Updated after ClawSweeper review:

  • regenerated and committed docs/docs_map.md for docs/specs/durable-session-task-runtime-rfc.md;
  • verified node scripts/generate-docs-map.mjs --check;
  • verified node scripts/docs-list.js includes the durable runtime RFC;
  • git diff --check passed.

@clawsweeper re-review

@clawsweeper

clawsweeper Bot commented Jul 1, 2026 •

Copy link
Copy Markdown
Contributor

🦞🧹
ClawSweeper re-review requested.

I asked ClawSweeper to review this item again.
Action: item re-review queued (workflow sweep.yml, event repository_dispatch).
Result: the existing ClawSweeper review comment will be edited in place when the review finishes.

@clawsweeper clawsweeper Bot added status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. and removed status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. labels Jul 1, 2026
@openclaw-barnacle openclaw-barnacle Bot removed the triage: needs-pr-context Candidate: external PR body lacks required problem context or evidence. label Jul 2, 2026
@clawsweeper clawsweeper Bot added status: 🔁 re-review loop A fresh ClawSweeper review was explicitly requested after the latest review. and removed status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. labels Jul 2, 2026
@mjnkao

mjnkao commented Jul 3, 2026

Copy link
Copy Markdown
Author

@clawsweeper re-review

The docs-map finding is fixed at current head 9ff8f44fd5fe07f1988512cccf32b72d1378d430.

Verified live/local state:

  • docs/docs_map.md includes specs/durable-session-task-runtime-rfc.md and route /specs/durable-session-task-runtime-rfc;
  • the RFC worktree is clean at the PR head;
  • gh pr checks 98717 -R openclaw/openclaw reports no current non-passing/non-skipped check buckets.

No code changes in this follow-up; this is only to clear the stale docs-map review/status after the already-pushed fix.

@clawsweeper clawsweeper Bot added status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. and removed status: 🔁 re-review loop A fresh ClawSweeper review was explicitly requested after the latest review. labels Jul 3, 2026
@mjnkao

mjnkao commented Jul 7, 2026

Copy link
Copy Markdown
Author

Superseded by #101828, which restates the durable-core scope with a clearer RFC/root-cause/test-plan review gate.

The new PR keeps this stack durable-core-only: Workboard/TaskFlow and product workflow surfaces are out of scope. Closing this older PR to avoid review confusion; implementation PRs will follow sequentially after #101828 is reviewed.

@mjnkao mjnkao closed this Jul 7, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

docs Improvements or additions to documentation merge-risk: 🚨 other 🚨 Merging this PR has meaningful risk outside the owned taxonomy. P3 Low-priority cleanup, docs, polish, ergonomics, or speculative work. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. size: XS status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant