Add PUT /memory endpoint that supports partial field updates:
- content (with automatic embedding regeneration)
- tags (with dual-write to memory_tags junction table)
- metadata, importance, pinned, memory_type
Implementation layers:
- Store::update_fields(): dynamic SQL UPDATE with only provided fields
- Uteke::update_memory(): validation + embedding regeneration + cache invalidation
- Handler: UUID validation, 400 for empty updates, 404 for missing memories
Acceptance criteria:
- Partial update semantics (only provided fields changed)
- Content update regenerates embedding automatically
- 404 if memory not found
- Input validation (content length, tags count, importance range, memory type)
Note: Cannot compile locally (missing libssl-dev). CI will verify.
Summary
Implements #659 β PUT /memory endpoint for partial memory field updates.
Changes
crates/uteke-server/src/types.rsMemoryUpdateRequeststruct with optional fields:id(required),content,tags,metadata,importance,pinned,memory_typecrates/uteke-core/src/memory/crud.rsStore::update_fields()β dynamic SQL UPDATE that only modifies provided fieldsmemory_tagsjunction table when tags are updatedbool(true if row was found and updated)crates/uteke-core/src/operations.rsUteke::update_memory()public APIretry_embed)crates/uteke-server/src/handlers.rsPUT /memoryhandlerAcceptance Criteria
Testing