Commit Graph
16 Commits
Author SHA1 Message Date
GustavoandClaude Sonnet 5 a99a25cb1a feat(v2): complete n8n workflow template (36 nodes) covering full V2 pipeline + shadow branch
- 14 new Code node drivers implementing the pipeline stages: normalize
  candidates, build context SQL, merge context + hash, decide AI need,
  prepare AI prompt, validate AI response, AI-disabled fallback, reuse
  cached classification, compute score, select top 10, prepare memory/
  envio records, build message/digest, compare legacy x V2, debug panel.
- Consolidated the two context queries (followups/tasks) into a single
  UNION ALL query tagged by tipo, and added a "Merge - Unir Shadow"
  synchronization node before comparing legacy x V2: n8n does not
  guarantee relative execution order between sibling branches that only
  share an early common ancestor, so cross-branch data was only safe to
  read by name once a real Merge node forced both to complete first.
- Reordered score calculation before the memory upsert (score is needed
  in the persisted row) and turned both Data Table writes into
  side-effect branches that fan out from the main path instead of
  gating it, so the Data Table node's own output shape never needs to
  carry the full pipeline state forward.
- Fixed a duplicate-identifier bug in the build script: score.js's
  require('./cooldown') survived inlining and collided with
  cooldown.js's own computeCooldown function in the same Code node
  scope. build-workflow.js now strips inter-module requires when
  inlining, and a new test syntax-checks every generated jsCode string
  plus asserts no leftover require() calls.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-24 15:31:44 -03:00
GustavoandClaude Sonnet 5 ec596a29a8 feat(v2): add build script that inlines tested logic/*.js into n8n Code nodes
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-24 15:20:54 -03:00
GustavoandClaude Sonnet 5 00bb89f4f4 feat(v2): candidate pool SQL (admin exclusion preserved, no hard LIMIT 10) + verbatim legacy SQL for shadow mode
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-24 15:19:39 -03:00
GustavoandClaude Sonnet 5 60015c0972 feat(v2): add short message and coordination digest builders
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-24 15:18:15 -03:00
GustavoandClaude Sonnet 5 d3917707e0 feat(v2): add Top10 selection with soft group diversity, hard 10-item cap
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-24 15:17:37 -03:00
GustavoandClaude Sonnet 5 749be7dbae feat(v2): add auditable final score combining actionability, baseline and cooldown
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-24 15:17:06 -03:00
GustavoandClaude Sonnet 5 014c48d578 feat(v2): add state-based cooldown with critical override
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-24 15:16:25 -03:00
GustavoandClaude Sonnet 5 efba7792fa feat(v2): add safe AI fallback and cache/reanalysis decision
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-24 15:15:50 -03:00
GustavoandClaude Sonnet 5 c445e00fc5 feat(v2): add strict schema validation for AI classification JSON
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-24 15:15:21 -03:00
GustavoandClaude Sonnet 5 7dccb85efa feat(v2): add ticket normalization and bounded AI context builder
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-24 15:14:50 -03:00
GustavoandClaude Sonnet 5 30e532f811 feat(v2): add context fingerprint hash that ignores time-only fields
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-24 15:14:17 -03:00
GustavoandClaude Sonnet 5 32ebe0d4f2 feat(v2): add parseConfig with clamped TOP_N and safe defaults
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-24 15:13:48 -03:00
GustavoandClaude Sonnet 5 ff5620c95c chore: scaffold node:test runner for V2 deterministic logic
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-24 15:13:19 -03:00
GustavoandClaude Sonnet 5 49f487d636 docs: add V2 implementation plan (17 tasks, TDD for deterministic logic)
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-24 15:12:08 -03:00
GustavoandClaude Sonnet 5 de147107d5 docs: add V2 design spec (approved)
docs/superpowers/specs/2026-08-24-coordenador-glpi-v2-design.md
Covers Etapa 0 recovery findings, architecture, data model, AI schema,
scoring, message format, shadow mode. Approved by user in chat.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-24 15:00:34 -03:00
GustavoandClaude Sonnet 5 1eb1f80b4f chore: baseline import of existing Coordenador GLPI V1 project
Snapshot of the pre-existing, working V1 automation (n8n workflow +
SQL query + docker-compose + README) exactly as found on disk, before
any V2 changes. .env is intentionally not tracked (gitignored,
contains local secrets).

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-24 15:00:26 -03:00