turnstone/app/services
pyr0ball 5da8db2bcd fix(diagnose): pass full timeline clusters and hypothesis descriptions to synthesizer LLM
Stage 5 (SummarySynthesizer) was only sending aggregate timeline stats to the
LLM (cluster count, burst count, gap count) — the actual sequenced cluster data
that Stage 1 reconstructed was never included. The LLM had no per-cluster
timestamps, severity, burst flags, silence gaps, or representative text to
write the TIMELINE section from.

Added _build_timeline_block() to emit a numbered per-cluster summary matching
the format Stage 3 uses for the hypothesizer, and included it in the user
message alongside the hypothesis block.

Also fixed _build_hypothesis_block() to include the 2-4 sentence description
each hypothesis carries — previously only the title and novelty score reached
the LLM.

11 new tests cover _build_timeline_block() directly (burst label, gap threshold,
pattern tags, text truncation at 200 chars, null start_iso, multi-cluster
numbering). 529 tests passing.
2026-06-16 21:46:01 -07:00
..
diagnose fix(diagnose): pass full timeline clusters and hypothesis descriptions to synthesizer LLM 2026-06-16 21:46:01 -07:00
__init__.py feat: initial Turnstone POC — ingest, FTS search, MCP server 2026-05-08 12:12:34 -07:00
anomaly.py feat(ui): security alert dedup, clickable criticals, loading shimmer 2026-06-13 09:32:26 -07:00
blocklist.py feat: dual-backend SQLite/Postgres + multi-tenant source namespacing 2026-06-08 08:37:54 -07:00
cybersec.py fix(cybersec): clean up debug traceback logging 2026-06-10 13:20:56 -07:00
discover.py feat(sources): context-aware filesystem log scanner (#23) 2026-06-14 14:01:45 -07:00
embeddings.py refactor: extract embeddings service layer — decouple context embedder from Ollama 2026-05-25 11:01:25 -07:00
incidents.py feat: dual-backend SQLite/Postgres + multi-tenant source namespacing 2026-06-08 08:37:54 -07:00
llm.py chore: sanitize internal hostnames and IP references 2026-06-13 10:02:46 -07:00
models.py feat: domain-view mapping for patterns and diagnose output (#32) 2026-06-01 19:57:16 -07:00
nl_source.py feat: bundle PII sanitization, onboarding wizard, NL source addition (#51, #52, #53) 2026-05-29 14:14:28 -07:00
orchard.py feat(orchard): auto-enrollment API for branch node provisioning (#27) 2026-06-14 14:30:18 -07:00
pihole.py feat(blocklist): 6 REST endpoints + Pi-hole settings fields 2026-05-15 21:15:09 -07:00
search.py feat(ui): security alert dedup, clickable criticals, loading shimmer 2026-06-13 09:32:26 -07:00
ssh_targets.py feat: SSH target manager — GUI editor for remote host configuration (#24) 2026-06-14 15:27:12 -07:00
ticket_export.py feat: incident ticket export — Notion and Jira integration (#12) 2026-06-14 15:46:11 -07:00