Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
37 changes: 37 additions & 0 deletions docs/handoffs/2026-07-24-a1-regex-guard.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
# HANDOFF — A1 regex validation / ReDoS guard (#80)

**Status:** Planned
**Branch:** `docs/open-issue-handoffs`
**Issue(s):** #80
**Last updated:** 2026-07-24

## Bottom line
Before storing or serving LLM-generated A1 regex rules, run pass/fail (or equivalent) probes and reject catastrophic/invalid patterns so the CLI cannot hang.

## Current state
- A1 rules produced in categorizer / rule publish path without a dedicated ReDoS gate (see audit §6).
- Still open from stabilize handoff follow-ups.

## What shipped
| PR / commit | Delivers |
|-------------|---------|
| (pending) | |

## Hook points (files to touch)
- `backend/app/services/categorizer.py`
- Rule publish / persist path before CLI consume
- `docs/audit/README.md` §6 for prior findings

## Open follow-ups
- [ ] test_pass / test_fail (or timeout harness) for candidate regex
- [ ] Reject path does not persist/serve bad patterns
- [ ] Tests for reject path

## How to verify
```bash
cd backend && uv run pytest tests/ -k regex -v
```

## Done means
- [ ] Unsafe/invalid regex not served to CLI
- [ ] Tests for reject path
15 changes: 15 additions & 0 deletions docs/handoffs/2026-07-24-deferred-load-test.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# HANDOFF — Load test / 5s rule (#22) [post-MVP]

**Status:** Planned (deferred)
**Branch:** `docs/open-issue-handoffs`
**Issue(s):** #22
**Last updated:** 2026-07-24

## Bottom line
Verify normal scan latency <5s and document bottlenecks. **Out of MVP.**

## Current state
Not started; do not pull into MVP PRs.

## Done means (later phase)
- [ ] Load harness + bottleneck notes
15 changes: 15 additions & 0 deletions docs/handoffs/2026-07-24-deferred-rag-finetune.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# HANDOFF — RAG fine-tune & performance test (#14) [post-MVP]

**Status:** Planned (deferred)
**Branch:** `docs/open-issue-handoffs`
**Issue(s):** #14
**Last updated:** 2026-07-24

## Bottom line
Measure extraction latency across chunk sizes and document optimal settings. **Out of MVP.**

## Current state
Not started; do not pull into MVP PRs.

## Done means (later phase)
- [ ] Benchmark harness + documented recommendations
16 changes: 16 additions & 0 deletions docs/handoffs/2026-07-24-deferred-regulatory-simulator.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# HANDOFF — Regulatory change simulator (#13) [post-MVP]

**Status:** Planned (deferred)
**Branch:** `docs/open-issue-handoffs`
**Issue(s):** #13
**Last updated:** 2026-07-24

## Bottom line
Watch a local folder and log drift alerts (e.g. to Loki) on new file detection. **Out of MVP** per epic #74 / `docs/ROADMAP.md` Phase 1 non-goals.

## Current state
Not started; do not pull into MVP PRs.

## Done means (later phase)
- [ ] Scope re-confirmed in Phase 2+
- [ ] Implementation + verify path documented then
40 changes: 40 additions & 0 deletions docs/handoffs/2026-07-24-e2e-live-hitl.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
# HANDOFF — E2E happy path + live HITL (#78)

**Status:** Planned
**Branch:** `docs/open-issue-handoffs`
**Issue(s):** #78
**Last updated:** 2026-07-24

## Bottom line
Documented cold-start path: compose/uv up → ingest sample policy → push/scan → pending HITL → approve/reject against the **live** API (mocks only as fallback).

## Current state
- Sample fixtures: `docs/mvp/fixtures/` (#81, PR #86).
- HITL endpoints exist on backend (`PATCH /validate/{id}`); frontend may still be mock-leaning — confirm `frontend/services/api.ts`.
- No committed smoke checklist/runbook for the full path yet.

## What shipped
| PR / commit | Delivers |
|-------------|---------|
| (pending) | |

## Hook points (files to touch)
- `docker-compose.yml`
- `frontend/services/api.ts` + HITL UI components
- `docs/ONBOARDING.md`, `docs/mvp/` runbook
- Wire fixtures from #81 into the runbook

## Open follow-ups
- [ ] Runbook (cold start → HITL)
- [ ] Live HITL card against backend
- [ ] Smoke script or checklist in-repo

## How to verify
```bash
# follow runbook once written; smoke script when present
```

## Done means
- [ ] Runbook in docs
- [ ] HITL card works with backend up
- [ ] Smoke script or checklist committed
12 changes: 12 additions & 0 deletions docs/handoffs/2026-07-24-legacy-loki-20.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# HANDOFF — Log every verdict to Loki (#20) [legacy]

**Status:** Planned (superseded by #77)
**Branch:** `docs/open-issue-handoffs`
**Issue(s):** #20 → implement via #77
**Last updated:** 2026-07-24

## Bottom line
Legacy Loki push tracker. **Do not implement here** — execute [#77](2026-07-24-verdict-loki-push.md) (schema from #76) and close #20 when that DoD is met.

## Done means
- [ ] Closed as duplicate/completed by #77
12 changes: 12 additions & 0 deletions docs/handoffs/2026-07-24-legacy-presidio-17.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# HANDOFF — Presidio PII integration (#17) [legacy]

**Status:** Planned (superseded by #79)
**Branch:** `docs/open-issue-handoffs`
**Issue(s):** #17 → implement via #79
**Last updated:** 2026-07-24

## Bottom line
Legacy tracker for Presidio on diffs/snippets. **Do not implement here** — execute [#79](2026-07-24-presidio-pii.md) and close #17 when that DoD is met.

## Done means
- [ ] Closed as duplicate/completed by #79
40 changes: 40 additions & 0 deletions docs/handoffs/2026-07-24-presidio-pii.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
# HANDOFF — Presidio PII gate on /validate (#79)

**Status:** Planned
**Branch:** `docs/open-issue-handoffs`
**Issue(s):** #79 (legacy #17)
**Last updated:** 2026-07-24

## Bottom line
Block high-risk PII in `code_snippet` on `/validate` (email / card / phone at minimum) via a `PIIScannerService`; force HIGH/block when detected.

## Current state
- No `backend/app/services/pii.py` yet.
- Validate path runs LLM risk check only.
- Legacy #17 is the same capability; close when #79 ships.

## What shipped
| PR / commit | Delivers |
|-------------|---------|
| (pending) | |

## Hook points (files to touch)
- `backend/app/services/pii.py` (new)
- `backend/app/api/validate.py` — gate before/alongside validator
- `backend/pyproject.toml` — Presidio (or agreed detector) deps
- Tests: unit detector + integration PII → HIGH/block

## Open follow-ups
- [ ] Detector service + config
- [ ] Integrate into `/validate`
- [ ] Unit + integration tests
- [ ] Close #17 when done

## How to verify
```bash
cd backend && uv run pytest tests/ -k pii -v
```

## Done means
- [ ] Unit tests for detector
- [ ] Integration: PII snippet → block/HIGH
42 changes: 42 additions & 0 deletions docs/handoffs/2026-07-24-verdict-loki-push.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
# HANDOFF — Push verdicts to Loki (#77)

**Status:** Planned
**Branch:** `docs/open-issue-handoffs`
**Issue(s):** #77 (legacy #20)
**Last updated:** 2026-07-24

## Bottom line
Ship every `verdict_event` to Grafana Loki when configured; otherwise keep a durable local/structured fallback so dev stays green without Loki.

## Current state
- Schema lives in `backend/app/services/verdict_log.py` (#76 on `mvp/75-76-81-foundation` / PR #86 — do not re-invent keys).
- Validate emits `verdict_event` to app logger; **no** Loki HTTP push yet.
- Legacy #20 is the same intent; close it when #77 ships.

## What shipped
| PR / commit | Delivers |
|-------------|---------|
| (pending) | |

## Hook points (files to touch)
- `backend/app/services/verdict_log.py` / logger — push after `emit_verdict_log`
- `backend/app/core/config.py` — `LOKI_URL` (or equiv) + enable flag
- `backend/app/api/validate.py` — HITL resolve path should also emit
- CLI / `pg` completion path if it logs verdicts independently

## Open follow-ups
- [ ] Config + no-op when unset
- [ ] Emit on validate completion + HITL approve/reject
- [ ] Tests with mocked Loki (or file sink)
- [ ] Close #20 when done

## How to verify
```bash
cd backend && uv run pytest tests/ -k loki -v
# with LOKI_URL set: trigger /validate and confirm push (or mock)
```

## Done means
- [ ] Config flag/URL
- [ ] Emit on CLI-driven validate completion + HITL resolve
- [ ] No-op / file fallback when Loki unset
9 changes: 9 additions & 0 deletions docs/handoffs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,3 +38,12 @@ Agents: use project skill **`feature-plan`** (`.agents/skills/feature-plan/` and
|------|---------|----------------|--------|
| 2026-07-24 | [stabilize-contracts-and-ci](2026-07-24-stabilize-contracts-and-ci.md) | `dev` / #61–#64, #73, #84 | Done |
| 2026-07-24 | [mvp-continuous-compliance-gate](2026-07-24-mvp-continuous-compliance-gate.md) | `docs/mvp-handoffs` / #74 | In progress |
| 2026-07-24 | [verdict-loki-push](2026-07-24-verdict-loki-push.md) | `docs/open-issue-handoffs` / #77 (#20) | Planned |
| 2026-07-24 | [e2e-live-hitl](2026-07-24-e2e-live-hitl.md) | `docs/open-issue-handoffs` / #78 | Planned |
| 2026-07-24 | [presidio-pii](2026-07-24-presidio-pii.md) | `docs/open-issue-handoffs` / #79 (#17) | Planned |
| 2026-07-24 | [a1-regex-guard](2026-07-24-a1-regex-guard.md) | `docs/open-issue-handoffs` / #80 | Planned |
| 2026-07-24 | [legacy-presidio-17](2026-07-24-legacy-presidio-17.md) | `docs/open-issue-handoffs` / #17 → #79 | Planned |
| 2026-07-24 | [legacy-loki-20](2026-07-24-legacy-loki-20.md) | `docs/open-issue-handoffs` / #20 → #77 | Planned |
| 2026-07-24 | [deferred-regulatory-simulator](2026-07-24-deferred-regulatory-simulator.md) | `docs/open-issue-handoffs` / #13 | Deferred |
| 2026-07-24 | [deferred-rag-finetune](2026-07-24-deferred-rag-finetune.md) | `docs/open-issue-handoffs` / #14 | Deferred |
| 2026-07-24 | [deferred-load-test](2026-07-24-deferred-load-test.md) | `docs/open-issue-handoffs` / #22 | Deferred |
Loading