#264 — Generate/modify persistence to support KPIs and Alerts

Repo: Twill-AI/facade State: open | Status: open Assignee: Unassigned

Created: 2025-01-07 · Updated: 2025-09-15

Description

AC:

  • An Alert table has been created that has the following columns: - widget_id (FGKEY) - threshold (number) - automation (?) - enabled (bool)
  • New ERD has been generated and is updatede in the wiki page
  • A master table exists to hold all KPI pre-set templates. It has to include all the same fields as our current KPI tiles plus: sources (aka used tables), default_threshold, default_automation, related widgets, it could be part of the main widgets template repository (it’s to possible to absorb defaults in “code field, see notes underneath)

Open questions

  • A decision needs to bee made about whether we want to use the existing widget table to hold these types of KPIs/alerts or we want a dedicated table for this. (see this comment and this one for relevant discussions)

  • Should the KPIs repository be a part of the general Widgets repository? See discussion

  • Where do we want to keep the KPI templates before they are loaded into the DB? Code? @AlexanderMakarov

Notes

  1. def

Notes

Add implementation notes, blockers, and context here

Add wikilinks to related people, meetings, or other tickets