[PR #912] [MERGED] fix(long-term-memory): harden thread lifecycle validation #1189

Closed
opened 2026-10-21 05:05:00 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/Pasta-Devs/Marinara-Agents/pull/912
Author: @Promansis
Created: 9/18/2026
Status: ✅ Merged
Merged: 9/18/2026
Merged by: @Promansis

Base: staging ← Head: fix/long-term-memory-thread-lifecycle-fanout


📝 Commits (3)

  • 8a1ac3d fix(long-term-memory): harden thread lifecycle validation (#909)
  • f5d8f35 test(long-term-memory): cover resolved thread parser links (#909)
  • 4a8ee3a Merge branch 'staging' into fix/long-term-memory-thread-lifecycle-fanout

📊 Changes

8 files changed (+142 additions, -73 deletions)

View changed files

📝 artifacts/long-term-memory-1.3.3.zip (+0 -0)
📝 catalog/catalog.json (+4 -4)
📝 catalog/v2/catalog.json (+4 -4)
📝 catalog/v3/catalog.json (+4 -4)
📝 packages/long-term-memory/manifest.json (+2 -2)
📝 packages/long-term-memory/server.mjs (+28 -28)
📝 packages/long-term-memory/src/engine/packages/server/src/services/long-term-memory/evidence-unit-validation.ts (+5 -29)
📝 tests/long-term-memory-extraction-graph.regression.ts (+95 -2)

📄 Description

Pull request

Important

Contributions target staging. Only SpicyMarinara may promote this repository's staging branch to main.
Outside and first-time contributors also require an approving review from SpicyMarinara.

Linked issue

Closes #909

Why this change

  • LTM thread validation incorrectly rejected valid unresolved threads when their wording lacked resolver keywords and compared resolved-thread fanout using non-canonical subject IDs.

What changed

  • Removed the lexical resolver-wording gate while retaining structural, evidence, source-hash, and link-target validation.
  • Compared resolved-thread fanout using canonical timeline note IDs.
  • Added extraction-graph regressions for resolver-free threads, exact existing-thread reuse, retained and missing resolution events, and invalid/dropped link targets.
  • Rebuilt the long-term-memory package outputs: server.mjs, manifest hashes, archive, and catalog entries in catalog.json, catalog/v2/catalog.json, and catalog/v3/catalog.json.

Package and security impact

  • Affected package IDs: long-term-memory
  • Engine compatibility impact: None; manifest compatibility remains Engine 2.4.1 through <4.0.0.
  • New or changed permissions/entrypoints: None.
  • Restart, storage, update, or uninstall impact: No lifecycle contract changes; package installation, offline restart, backup inclusion, uninstall, and reinstall were validated.

Validation

  • node scripts/validate-catalog.mjs passes locally
  • git diff --check passes locally
  • Rebuilt every affected manifest, payload, artifact, and catalog entry
  • Installed or updated the affected package through Marinara Engine
  • Checked supported modes, restart behavior, and uninstall cleanup
  • Read and followed CONTRIBUTING.md

Manual verification notes

  • Focused extraction graph and reliability regressions passed.
  • test-ltm.sh all passed, including browser, installation, runtime, routes, storage, UI, and loading checks.
  • Separate test-ltm.sh routes and test-ltm.sh lifecycle passed.
  • test-ci.sh passed with 0 errors; existing lint warnings remain.
  • Package rebuild and archive/catalog integrity checks passed.
  • Independent review completed with no actionable findings.

Documentation impact

  • No documentation changes needed
  • Updated this README catalog and package guidance
  • Updated linked Marinara Engine documentation

UI evidence (if applicable)

Not applicable; this change affects server-side extraction validation and generated package outputs.

Summary by CodeRabbit

  • New Features

    • Added support for resolved thread status and resolved_in links during extraction.
    • Resolved threads can now compile into status updates when their resolution event is present.
  • Bug Fixes

    • Resolved-thread validation now reports missing link targets or resolution events appropriately.
    • Removed vague-thread diagnostics and related drop messages.
    • Improved resolved-thread fan-out handling to use timeline events and link targets.

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/Pasta-Devs/Marinara-Agents/pull/912 **Author:** [@Promansis](https://github.com/Promansis) **Created:** 9/18/2026 **Status:** ✅ Merged **Merged:** 9/18/2026 **Merged by:** [@Promansis](https://github.com/Promansis) **Base:** `staging` ← **Head:** `fix/long-term-memory-thread-lifecycle-fanout` --- ### 📝 Commits (3) - [`8a1ac3d`](https://github.com/Pasta-Devs/Marinara-Agents/commit/8a1ac3dd0e42a82a6aef11ab7bcb0d186e175f9a) fix(long-term-memory): harden thread lifecycle validation (#909) - [`f5d8f35`](https://github.com/Pasta-Devs/Marinara-Agents/commit/f5d8f3558113b408003a17139c57e44dda686f8a) test(long-term-memory): cover resolved thread parser links (#909) - [`4a8ee3a`](https://github.com/Pasta-Devs/Marinara-Agents/commit/4a8ee3ab3e3189dbe6b8c721701c53028e043733) Merge branch 'staging' into fix/long-term-memory-thread-lifecycle-fanout ### 📊 Changes **8 files changed** (+142 additions, -73 deletions) <details> <summary>View changed files</summary> 📝 `artifacts/long-term-memory-1.3.3.zip` (+0 -0) 📝 `catalog/catalog.json` (+4 -4) 📝 `catalog/v2/catalog.json` (+4 -4) 📝 `catalog/v3/catalog.json` (+4 -4) 📝 `packages/long-term-memory/manifest.json` (+2 -2) 📝 `packages/long-term-memory/server.mjs` (+28 -28) 📝 `packages/long-term-memory/src/engine/packages/server/src/services/long-term-memory/evidence-unit-validation.ts` (+5 -29) 📝 `tests/long-term-memory-extraction-graph.regression.ts` (+95 -2) </details> ### 📄 Description # Pull request > [!IMPORTANT] > Contributions target `staging`. Only `SpicyMarinara` may promote this repository's `staging` branch to `main`. > Outside and first-time contributors also require an approving review from `SpicyMarinara`. ## Linked issue Closes #909 ## Why this change - LTM thread validation incorrectly rejected valid unresolved threads when their wording lacked resolver keywords and compared resolved-thread fanout using non-canonical subject IDs. ## What changed - Removed the lexical resolver-wording gate while retaining structural, evidence, source-hash, and link-target validation. - Compared resolved-thread fanout using canonical timeline note IDs. - Added extraction-graph regressions for resolver-free threads, exact existing-thread reuse, retained and missing resolution events, and invalid/dropped link targets. - Rebuilt the `long-term-memory` package outputs: `server.mjs`, manifest hashes, archive, and catalog entries in `catalog.json`, `catalog/v2/catalog.json`, and `catalog/v3/catalog.json`. ## Package and security impact - Affected package IDs: `long-term-memory` - Engine compatibility impact: None; manifest compatibility remains Engine `2.4.1` through `<4.0.0`. - New or changed permissions/entrypoints: None. - Restart, storage, update, or uninstall impact: No lifecycle contract changes; package installation, offline restart, backup inclusion, uninstall, and reinstall were validated. ## Validation <!-- These are human tasks. Never tick a box for a check that was not actually performed. --> - [ ] `node scripts/validate-catalog.mjs` passes locally - [ ] `git diff --check` passes locally - [ ] Rebuilt every affected manifest, payload, artifact, and catalog entry - [ ] Installed or updated the affected package through Marinara Engine - [ ] Checked supported modes, restart behavior, and uninstall cleanup - [ ] Read and followed `CONTRIBUTING.md` ### Manual verification notes - Focused extraction graph and reliability regressions passed. - `test-ltm.sh all` passed, including browser, installation, runtime, routes, storage, UI, and loading checks. - Separate `test-ltm.sh routes` and `test-ltm.sh lifecycle` passed. - `test-ci.sh` passed with 0 errors; existing lint warnings remain. - Package rebuild and archive/catalog integrity checks passed. - Independent review completed with no actionable findings. ## Documentation impact - [ ] No documentation changes needed - [ ] Updated this README catalog and package guidance - [ ] Updated linked Marinara Engine documentation ## UI evidence (if applicable) Not applicable; this change affects server-side extraction validation and generated package outputs. <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit - **New Features** - Added support for resolved thread status and `resolved_in` links during extraction. - Resolved threads can now compile into status updates when their resolution event is present. - **Bug Fixes** - Resolved-thread validation now reports missing link targets or resolution events appropriately. - Removed vague-thread diagnostics and related drop messages. - Improved resolved-thread fan-out handling to use timeline events and link targets. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-10-21 05:05:00 +07:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Pasta-Devs/Marinara-Agents#1189
No description provided.