Add Orbit Guardrail Agent prototype

Summary

This merge request adds the initial Orbit Guardrail Agent prototype for the GitLab Transcend Showcase Track.

The prototype demonstrates an architecture-aware merge request guardrail workflow:

  • reads mock MR context,
  • uses Orbit-style project context fixtures,
  • enriches the workflow with LynkMesh-style dependency and blast-radius context,
  • detects a Controller-to-Model service-layer bypass,
  • generates a reviewer-ready MR briefing,
  • supports GitLab API MR comment dry-run mode,
  • includes demo evidence artifacts and a before/after architecture violation scenario.

Demo workflow

The current demo focuses on one deterministic guardrail:

Controller should not directly access Model when a Service layer exists.

Expected architecture:

  • Controller -> Service -> Model

Bad MR architecture:

  • Controller -> Model

The agent detects this as a guardrail violation and generates:

  • architecture violation summary,
  • repo-wide blast radius,
  • suggested test coverage,
  • reviewer checklist,
  • context evidence.

Validation

Run locally:

  • python -m pytest -q
  • python -m app.main --mode mock --out demo/sample_mr_comment.md
  • python -m app.main --mode gitlab_api --project-id 39119538 --mr-iid <MR_IID> --dry-run

Latest local validation:

  • 11 passed
  • mock mode works
  • GitLab API dry-run mode works
  • git diff --check clean

Current status

This MR is the prototype foundation.

Implemented:

  • mock Orbit/LynkMesh context adapters,
  • guardrail engine,
  • MR briefing renderer,
  • GitLab API dry-run support,
  • before/after demo scenario,
  • evidence artifacts.

Pending:

  • real GitLab Orbit/Duo integration,
  • AI Catalog publishing,
  • live MR comment rehearsal after this MR is created.

LynkMesh is used as a context enrichment concept behind the agent. It does not replace GitLab Orbit.

Merge request reports

Loading