Refactor pilot architecture and remove dashboard #15

Merged
masi merged 1 commits from refactor/pilot-architecture-langfuse into main 2026-09-01 00:28:07 +00:00
Contributor

Summary

  • split transport, model, and trusted configuration concerns into focused modules
  • preserve ai_review as the compatibility facade for existing webhook/CI callers
  • remove the obsolete dashboard server, data layer, Kubernetes manifest, docs, and tests
  • document the current pilot architecture and Langfuse as the analytics surface

Verification

  • python3 -m compileall -q pilot tests
  • 242 focused tests passed
  • full suite previously passed with 476 tests
## Summary - split transport, model, and trusted configuration concerns into focused modules - preserve `ai_review` as the compatibility facade for existing webhook/CI callers - remove the obsolete dashboard server, data layer, Kubernetes manifest, docs, and tests - document the current pilot architecture and Langfuse as the analytics surface ## Verification - `python3 -m compileall -q pilot tests` - 242 focused tests passed - full suite previously passed with 476 tests
masi added 4 commits 2026-09-01 00:21:54 +00:00
The standard /api/public/ingestion path feeds only the trace-upsert
queue; evalService.createEvalJobs only dispatches targetObject in
{TRACE, DATASET}. Observation rules fire exclusively from the OTel
pipeline, which this pilot does not use. The trace body already carries
review input/output via langfuse_trace, so a trace rule sees the same
material an observation rule would.
Remove the obsolete dashboard now that Langfuse is the analytics surface.\nIntroduce focused transport, model, and configuration modules while preserving the ai_review facade, and document the current runtime architecture.
pragent-bot bot reviewed 2026-09-01 00:27:05 +00:00
pragent-bot bot left a comment

🤖 AI Review · pragent pilot · headroom/MiniMax-M2.7 · b4041f68 · Merge confidence: 5/5 🟢

PR-Agent pilot on this repo. Comments are LLM-generated; treat as suggestions, not mandates.

Summary of Changes

  • Adds gitea_client.py (HTTP transport adapter) and model_client.py (Anthropic-compatible model adapter) extracted from ai_review.py
  • Adds review_config.py (opt-in policy with injected transport for testability) and review_ports.py (Protocol interfaces, currently unused)
  • Deletes dashboard.py, dashboard_data.py, k8s/pragent-dashboard.yaml, and four dashboard test files — obsolete after removing the dashboard subsystem
  • Delegates parse_text_blocks, _http, and call_model in ai_review.py to the new modules; updates webhook_server to use review_config.repo_enabled

Key Risks & Concerns

  • review_ports.py defines Forge/Reviewer/Telemetry protocols with no implementing callers — either premature scaffolding or forgotten interface contract
  • webhook_server.py retains base64 and urllib.parse imports from the old is_repo_enabled inline implementation — now dead code after the refactor
  • No dedicated test file for review_config.py despite it owning the security-sensitive opt-in gate; test coverage relies on test_webhook_server which patches at a distance
🔋 AI Usage & Run Details
  • Model / Engine: headroom/MiniMax-M2.7 · opencode · 24 steps · 307.5s
  • Total Tokens: 71,646 (71.6K) in / 10,108 (10.1K) out (0 reasoning, cache 1,498,191 (1.5M) read / 132,512 (132.5K) write, 1,712,457 (1.7M) total)
  • Actual: $0.00 (headroom/MiniMax-M2.7 — free tier)
  • Scope: Whole-repo checkout at head sha (agent can read any file + run linters, not just the diff) — input tokens include files read beyond the diff. Per-comment output is attributed (one model pass produces all findings; output split by each finding's body weight).
🤖 **AI Review** · pragent pilot · headroom/MiniMax-M2.7 · `b4041f68` · Merge confidence: 5/5 🟢 > PR-Agent pilot on this repo. Comments are LLM-generated; treat as suggestions, not mandates. ### Summary of Changes - Adds gitea_client.py (HTTP transport adapter) and model_client.py (Anthropic-compatible model adapter) extracted from ai_review.py - Adds review_config.py (opt-in policy with injected transport for testability) and review_ports.py (Protocol interfaces, currently unused) - Deletes dashboard.py, dashboard_data.py, k8s/pragent-dashboard.yaml, and four dashboard test files — obsolete after removing the dashboard subsystem - Delegates parse_text_blocks, _http, and call_model in ai_review.py to the new modules; updates webhook_server to use review_config.repo_enabled ### Key Risks & Concerns - review_ports.py defines Forge/Reviewer/Telemetry protocols with no implementing callers — either premature scaffolding or forgotten interface contract - webhook_server.py retains base64 and urllib.parse imports from the old is_repo_enabled inline implementation — now dead code after the refactor - No dedicated test file for review_config.py despite it owning the security-sensitive opt-in gate; test coverage relies on test_webhook_server which patches at a distance <details> <summary>🔋 AI Usage & Run Details</summary> - **Model / Engine**: `headroom/MiniMax-M2.7` · opencode · 24 steps · 307.5s - **Total Tokens**: 71,646 (71.6K) in / 10,108 (10.1K) out (0 reasoning, cache 1,498,191 (1.5M) read / 132,512 (132.5K) write, 1,712,457 (1.7M) total) - **Actual**: $0.00 (headroom/MiniMax-M2.7 — free tier) - **Scope**: Whole-repo checkout at head sha (agent can read any file + run linters, not just the diff) — input tokens include files read beyond the diff. Per-comment output is *attributed* (one model pass produces all findings; output split by each finding's body weight). </details> <!-- pragent:sha=b4041f6892059152091987304777498129b53e0b -->
masi merged commit 3a110ab52c into main 2026-09-01 00:28:07 +00:00
Sign in to join this conversation.
No Reviewers
2 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: gitea_admin/pragent#15