Repository navigation
Closed
Labels
enhancementNew feature or requestepic:memory-lifecycleMemory lifecycle: soft-delete, deprecation, aging, Dream safetylifecycleMemory lifecycle management (deprecation, pruning, aging)priority:mediumFix soonrustPull requests that update rust codescope:cliCLI and UX
Milestone
Description
Overview
Tambahkan subcommand uteke lifecycle untuk kontrol manual memory lifecycle. User bisa lihat status, soft-delete, restore, run cycle, dan prune.
Commands
# Status overview
uteke lifecycle status
# Output: active=990, deprecated=10, pinned=5, total=1005
# next_cycle: in 3d 4h
# deprecated_oldest: 2024-01-15 (25 days until TTL prune)
# Manual soft-delete
uteke lifecycle deprecate <id> [--reason "manual cleanup"]
# Output: ✓ Memory abc123 deprecated (reason: manual cleanup)
# Use `uteke lifecycle promote abc123` to restore
# Restore deprecated → active
uteke lifecycle promote <id>
# Output: ✓ Memory abc123 promoted back to active
# Run lifecycle cycle now (deprecate cold + prune expired)
uteke lifecycle cycle [--dry-run]
# Output: Lifecycle cycle complete
# deprecated=10 (cap 1% of 1000)
# pruned=3 (deprecated >30d)
# candidates_remaining=15
# Hard-delete expired deprecated (manual prune)
uteke lifecycle prune [--dry-run] [--ttl 30]
# Output: Pruned 3 memories (deprecated >30 days, expired)
# These memories are permanently deleted.
# List deprecated memories pending review
uteke lifecycle pending [--limit 20]
# Output: 10 deprecated memories pending review:
# abc123 | "User prefers..." | deprecated 5d ago | TTL in 25d
# def456 | "Old config..." | deprecated 12d ago | TTL in 18dImplementation
// crates/uteke-cli/src/main.rs — add Lifecycle subcommand
#[derive(Subcommand)]
enum LifecycleCmd {
Status,
Deprecate { id: String, #[arg(long)] reason: Option<String> },
Promote { id: String },
Cycle { #[arg(long)] dry_run: bool },
Prune { #[arg(long)] dry_run: bool, #[arg(long)] ttl: Option<u32> },
Pending { #[arg(long)] limit: Option<usize> },
}Files Changed
| File | Change |
|---|---|
crates/uteke-cli/src/main.rs |
Add Lifecycle subcommand enum + handler |
crates/uteke-cli/src/config.rs |
Wire lifecycle config to CLI startup |
Acceptance Criteria
-
lifecycle statusshows counts + next cycle estimate -
lifecycle deprecatesoft-deletes with optional reason -
lifecycle promoterestores deprecated memory -
lifecycle cycle --dry-runpreviews without modifying -
lifecycle prunehard-deletes only expired deprecated -
lifecycle pendinglists deprecated with TTL countdown - All commands respect lifecycle config
- Clear output formatting (tables or structured text)
Dependencies
- Depends on feat: Dynamic auto-lifecycle cycle — percentage-based soft-delete scheduler #933 (auto_lifecycle_cycle)
- Depends on feat: deprecate_with_reason() + promote() + Store undeprecate #929 (deprecate_with_reason, promote)
- Depends on feat: CLI lifecycle commands — status, deprecate, promote, cycle, prune #935 (pending_review API)
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestepic:memory-lifecycleMemory lifecycle: soft-delete, deprecation, aging, Dream safetylifecycleMemory lifecycle management (deprecation, pruning, aging)priority:mediumFix soonrustPull requests that update rust codescope:cliCLI and UX
Activity
ajianaz commentedon Aug 8, 2026
Implemented in PR #938 (merged). Closing as completed.
feat(#928-#937): safe memory lifecycle — soft delete, dynamic cap, CL…
docs: rewrite v0.13.0 changelog with all features and fixes