38 lines
1.5 KiB
Markdown
38 lines
1.5 KiB
Markdown
---
|
|
phase: 06-lab-advisor
|
|
verified: 2026-04-10
|
|
status: human_needed
|
|
score: 4/4 (code) — live OpenRouter validation pending
|
|
overrides_applied: 0
|
|
---
|
|
|
|
# Phase 6 Verification
|
|
|
|
## Goal
|
|
Users can ask strategic homelab questions and receive streaming answers from Claude Opus with full inventory context, with conversation history persisted across sessions.
|
|
|
|
## Code-Level Verification (Complete)
|
|
|
|
| # | Success Criterion | Status | Evidence |
|
|
|---|------|--------|----------|
|
|
| 1 | Streaming response from Claude Opus via OpenRouter | ✓ | `internal/advisor/handler.go` StreamChat using TierClient + go-openai stream |
|
|
| 2 | Inventory context pre-loaded into each conversation | ✓ | `internal/advisor/context.go` InventoryContextBuilder with 60s cache |
|
|
| 3 | Conversation history persists across sessions | ✓ | `internal/store/` PostgreSQL pgx/v5 + 12 passing integration tests against 10.5.0.109 |
|
|
| 4 | Model switchable via dropdown without restart | ✓ | Per-request model field in JSON body |
|
|
|
|
## All 5 Requirements Covered
|
|
ADV-01 through ADV-05 — implemented and tested with PostgreSQL integration.
|
|
|
|
## Test Results
|
|
- `go test ./internal/store/... -v` — 12 tests pass against live PostgreSQL
|
|
- `go build ./...` — clean
|
|
- `cd web && npm run build` — clean
|
|
|
|
## Human Verification Required
|
|
|
|
1. Real OpenRouter API key needed (currently empty in .env)
|
|
2. Live Opus chat with inventory context
|
|
3. Conversation history visual review
|
|
|
|
## Status
|
|
`human_needed` — code complete, requires operator OpenRouter API key for live testing.
|