towerops/test/towerops/preseem
Graham McIntire fd235d05b7 feat(insights): AI surfaces its own observations from full network state
Adds a parallel LLM path that reviews the whole org snapshot — Preseem
APs, SNMP signals, backhaul, agents, and the insight types the rules
already covered — and emits novel observations as ai_observation
insights (source=ai). Existing rule-based insights and per-insight
enrichment continue unchanged.

- lib/towerops/llm/network_snapshot.ex builds the bounded snapshot
- lib/towerops/llm/network_insight_prompt.ex builds the prompt and
  parses the LLM's JSON observations array
- lib/towerops/workers/ai_network_insight_worker.ex runs nightly at
  03:30 UTC (after the rule pass + per-insight enrichment) and on
  the superuser regenerate button
- preseem/insight.ex extends @valid_types with "ai_observation" and
  @valid_sources with "ai"
- insights_live/index.ex includes the new worker in the regen list
  and adds an "AI" source badge style

Bumps the SnmpKit Manager timeout-options test threshold from 500ms
to 3000ms (was flaking on loaded dev machines), and scopes
list_unenriched_insights/1 assertion in insights_test:573 to the
test's org so cross-suite leaks don't fail the count.
2026-05-10 14:29:56 -05:00
..
access_point_test.exs add preseem access points schema and migration 2026-02-12 17:11:36 -06:00
baseline_test.exs test fix and preseem check fix 2026-02-13 09:42:39 -06:00
client_test.exs test: cn_maestro/preseem client transport-error and forbidden branches 2026-05-09 09:37:10 -05:00
device_baseline_test.exs refactor/dry-improvements (#202) 2026-03-28 10:56:34 -05:00
device_matcher_test.exs stagger preseem sync across organizations 2026-02-13 10:52:32 -06:00
fleet_intelligence_test.exs add preseem baseline and fleet intelligence computation 2026-02-13 08:40:04 -06:00
fleet_profile_test.exs refactor/dry-improvements (#202) 2026-03-28 10:56:34 -05:00
insight_test.exs feat(insights): LLM-powered insight enrichment 2026-05-09 16:41:48 -05:00
insights_test.exs feat(insights): AI surfaces its own observations from full network state 2026-05-10 14:29:56 -05:00
subscriber_metric_test.exs refactor/dry-improvements (#202) 2026-03-28 10:56:34 -05:00
sync_log_test.exs refactor/dry-improvements (#202) 2026-03-28 10:56:34 -05:00
sync_test.exs stagger preseem sync across organizations 2026-02-13 10:52:32 -06:00