Elevate MiroFish/CrowdSight from single-container dev to a SaaS foundation: - Local memory backend (Zep-compatible): memory services/models, local graph builder + updater, AgentActivity seam, import-boundary isolation; Zep stays default, local is opt-in behind MEMORY_BACKEND. Semantic parity not yet proven. - Durable product persistence: projects/simulations/reports schema (migration 0007) + tenant/owner-scoped ProductRepository + dual-write + scoped_project read-first + ArtifactStore abstraction; durable JobQueue + worker.py. - SaaS hardening: durable RateLimiter (wired to login), UsageService (LLM accounting), redacted AuditService, idempotency, CORS allowlist, safe API errors, single-use PasswordResetService + endpoints (covers invite-pending). - Exactly 3 roles (super_admin/admin/user) with tenant authz policy. - Admin UI: GET/POST/PATCH /api/admin/users + GET/PUT /api/admin/settings (super-admin only, encrypted/masked); AdminView.vue + SettingsView.vue with admin/super-admin route guards, th/en i18n. - Production deploy topology: multi-stage Dockerfile (frontend build + gunicorn wsgi + nginx SPA-proxy + supervisord worker), backend/wsgi.py, gunicorn dep. Backend 197 passed; frontend 10 tests + build green. ruff unavailable (gap). No commit of credentials; secrets handled via env/.env.example. Deferred: Zep semantic A/B parity, object storage cutover, mobile QA, EasyPanel container build of deploy topology.
2.5 KiB
2.5 KiB
Local Memory Parity Slice — 2026-08-24
Scope
Bounded local-memory compatibility work only:
LocalMemoryTools.panorama_searchnow preserves the legacy all-graph inventory contract while relevance-ranking active and historical facts.LocalMemoryTools.insight_forgenow derives entity insights and relationship chains from matching edges with the legacy-compatible output shape.LocalEntityReaderrejects explicitly supplied graph IDs that differ from its repository-bound graph ID.MEMORY_BACKEND=zepremains the default compatibility path; this slice does not remove Zep or cut over ReportAgent/ProfileGenerator globally.
TDD evidence
- Added
backend/tests/fixtures/memory_parity/tools_fixture.jsonwith three entities, current and invalidated temporal edges, and one unrelated active edge. - Added
backend/tests/test_memory_parity.pycovering panorama inventory/temporal behavior, insight entity/relationship shape, and five conflicting graph-ID call forms. - Ran the new tests before the production change; the suite failed for the expected missing parity and scope behaviors.
- Implemented the minimal adapter and reader changes.
- Re-ran the focused parity suite: 8 passed.
Verification
- Focused consumer regression set: 17 passed.
- Backend full suite: 81 passed.
- Python
compileall: PASS. git diff --check: PASS.- Added-lines security scan: 0 findings.
ruff: unavailable in the backend environment; no lint pass is claimed.- A probe run from repository root failed because that cwd cannot resolve the backend pytest executable; the same probe rerun from
backend/passed 8/8. This is a command-location issue, not a test failure.
Independent review gate
- The first bounded reviewer was stopped after exceeding the context/time budget; its silence was not treated as approval.
- Replacement reviewer:
deleg_73fac0de. - Required five-key JSON verdict:
passed=true,security_concerns=[],logic_errors=[]. - Non-blocking suggestion: consider future LLM query decomposition for
insight_forge; localsub_queries=[query]remains an explicit semantic gap outside this slice. - This closes the review gate for this slice only. It is not approval of full semantic parity, the broader migration, or production readiness.
Remaining boundary
This proves only the bounded panorama/insight/entity-reader contract. It does not prove semantic LLM parity (sub_queries remains local [query]), complete graph/profile/simulation/report E2E, all local consumer cutovers, migration parity, or production readiness.