Skip to content

Human Gate (HUG)

Everyone needs a hug once in a while.

Many pipelines have moments where a machine shouldn’t make the call. Maybe it’s an architecture decision that shapes six months of work. Maybe it’s a deployment to production. Maybe it’s content going out under someone’s name. A human gate - a HUG - is how you put a person in that seat.

HUG pauses a cliq pipeline at any gate phase, presents a structured review to a human through a clean web interface, and resumes based on their verdict. The reviewer gets everything they need to make a decision — a brief, artifacts, diffs, check results — and a chat assistant they can question about the work. When they decide, the pipeline continues.

No context switching. No “can you look at this PR when you get a chance.” The reviewer opens a link, sees what matters, and acts.


A human gate is a hug phase. The orchestrator runs automated checks first — all checks must pass before a review is created. If any check fails, the gate fails immediately and no review is sent. Reviewers only see complete, valid work.

When checks pass, the hug agent:

  1. Assembles context from the workspace — role brief, check results, artifacts, git diff, pipeline timeline
  2. Creates a review on the hug server (a standalone web service backed by PostgreSQL)
  3. Notifies reviewers via Slack with a direct link
  4. Opens a chat connection so the reviewer can ask questions in real time
  5. Polls for a verdict, sending reminders at the configured interval
  6. Writes an audit trail to .cliq/reviews/ — the permanent record
  7. Returns the verdict to the orchestrator as a standard gate result
Orchestrator ── A2A ──▶ Hug Agent ── POST + WebSocket ──▶ Hug Server ──▶ Human (browser)

The hug agent is the protocol boundary. The orchestrator sees a normal A2A agent. The hug server sees HTTP and WebSocket traffic. The human sees a web page. Everyone speaks their native language.


When the reviewer submits their decision, the hug agent maps it to a standard gate verdict:

Human actionGate verdictWhat happens
ApprovePASSPipeline continues to the next phase
Request ChangesROUTE:<target>Work routes to the selected phase with feedback
RejectESCALATEPipeline halts — human intervention required
Timeout (no action)ESCALATEPipeline halts with “timed out” reason

When routing work back, the reviewer’s comment becomes routing context delivered to the target phase through the gate channel.


I want to…Go to
Install and run the hug serverHUG Server
Add a human gate to my teamConfiguring Gates
See real-world team.yml patternsExamples
Look up settings or fix an issueSettings & Troubleshooting