Skip to content

Implementation mode

From a ticket to a merge request ready for review

You add a label to a ticket. Forge plans the change, writes it, checks it and opens a draft merge request. Once CI passes, it moves the ticket to Code Review and assigns a reviewer. A person always does the merge.

  • Requester

    Describes in the ticket what should change and adds the implementation label.

  • Reviewer

    Gets the ticket once CI is green. Reviews the change, decides on the merge, and either fixes review comments or leaves the fixing to Forge.

  • Forge operator

    Connects the repositories and CI and sets up labels, ticket statuses, the reviewer and limits.

How implementation works

Seven steps from the label to the review.

Implementation flow: people and Forge take turns over seven steps

Forge reviews a ticket's spec only once, and only if the project has not turned this off. Step 7 happens only when you return the ticket with comments, and then steps 5 to 7 can repeat.

Step by step

  1. Requester

    Step 1: Write the request and add the label

    In the ticket, write what should change, how you will know it is done and what should stay as it is. Attach whatever Forge needs: a screen design, sample data or a pointer to a similar place in the code.

    Then add the implementation label. The ticket has to be in the status Forge picks tickets up from, usually TODO.

    TicketPRJ-132

    Form for changing billing details

    Customers edit their billing address and company ID in the portal. It is done when the change is saved and the form rejects an invalid company ID. The accounting export stays as it is.

    Labels
    portal forge
  2. Forge

    Step 2: Forge reviews the spec

    Before the first implementation, Forge reviews the spec and posts the result as a comment in the ticket. It does not touch the code.

    The comment has two percentage scores. Spec accuracy says how far the request can be done without guessing. Fit for Forge says how well one run can handle it in the project's repositories. It also gives a verdict, an estimate of how much time Forge will need, what the spec is missing and questions sorted by priority.

    The review does not stop the implementation, even if it finds gaps. Implementation usually starts a few minutes later and uses the review findings for planning.

    CommentsPRJ-132
    Forge25 minutes ago

    📋 Spec review
    Spec accuracy: 85% · Fit for Forge: 80%

    Verdict: implementable as written.

    Forge time estimate: ≈ 48 min (28 min – 1.5 h) to implement up to a draft MR; each round of fixes after CI or review ≈ 12 min.

  3. Forge

    Step 3: Forge plans and writes the change

    Forge creates a branch named after the ticket key and title and starts a run. It plans the change, reviews the plan, writes the code, reviews its own diff and runs the project's mandatory checks.

    It logs progress in a single comment in the ticket. Each step gets a line with a timestamp, and while a step runs, its line says "running…".

    CommentsPRJ-132
    Forgejust now

    🤖 Forge — progress

    • 03.12. 09:12 — ▶ Run started · Implement
    • 03.12. 09:13 — ✅ Cloning repositories · 38 s
    • 03.12. 09:24 — Phase plan-review done — plan approved ✅ (2 m 05 s).
    • 03.12. 09:46 — Phase diff-review-and-fix done — diff reviewed, any findings fixed inline ✅ (5 m 48 s).
    • 03.12. 09:49 — ✅ Mandatory checks · 2 m 54 s · 4/4 passed
    • 03.12. 09:50 — ⏳ Commit + push + MR · running…
  4. Forge

    Step 4: Forge opens a draft merge request

    Forge commits the change, pushes it to the branch and opens a draft merge request with the ai-generated label. The description has the ticket key and a summary of the change. It adds a link to the merge request to the ticket and moves the ticket to In Progress.

    If the change touches several repositories, each one gets its own merge request, always from a branch with the same name.

    Merge requestPRJ-132

    Draftai-generated

    Form for changing billing details

    PRJ-132-form-for-changing-billing-detailsmain

    CI checks1 of 2 passed

    • buildpassed
    • unit-testsrunning
  5. Forge

    Step 5: Forge watches CI and fixes it

    Your project's CI runs on the merge request. If it fails, Forge reads what failed, fixes it and pushes the fix to the same branch. By default it tries at most three times and logs every attempt in the ticket.

    Once CI passes, Forge moves the ticket to Code Review and assigns a reviewer.

    CommentsPRJ-132
    Forge12 minutes ago

    AI attempt 1/3 — CI red, launching auto-fix.

    Forgejust now

    Green CI → Code Review + assigned reviewer (from the Reviewer field).

  6. Reviewer

    Step 6: Review the change

    Review the merge request as you would one from a colleague. If it is fine, merge it. Forge never merges on its own.

    If you find a problem, you can fix it yourself with a commit to the same branch. Or leave it to Forge: write comments in the merge request and move the ticket to the status for returned tickets. Forge ignores comments until the ticket is returned.

    Comment in the merge request

    portal/billing/BillingForm.ts

    41const id = form.companyId.trim()42if (!isValidCompanyId(id)) return form.invalid()43await saveBillingDetails({ ...form, companyId: id })
    Peter Smithon line 42

    We only validate the company ID in the form. Add the same check on the server so an invalid ID cannot get in through the API.

  7. Forge

    Step 7: Forge handles the comments

    Forge moves the ticket back to In Progress and decides for each comment whether to fix it, just reply, or decline it with a reason, for example when it goes beyond the ticket. Then it fixes the code and replies in every thread, even if a fix did not work.

    It never resolves threads. That is up to whoever wrote the comment. The fix triggers CI again, and once it passes, the ticket goes back to Code Review.

    Thread in the merge request

    portal/billing/BillingForm.ts

    41const id = form.companyId.trim()42if (!isValidCompanyId(id)) return form.invalid()43await saveBillingDetails({ ...form, companyId: id })
    Peter Smithon line 42

    We only validate the company ID in the form. Add the same check on the server so an invalid ID cannot get in through the API.

    Forgejust now

    I added the company ID format check to the API as well, with a test that rejects an invalid ID.

Labels Forge adds

The labels on the ticket tell you what Forge is doing or why it is waiting.

  • ai-running

    Forge is working on the ticket right now. A second run on the same ticket will not start.

  • ai-spec-reviewed

    The spec review is done. Remove the label to run it again.

  • ai-needs-human

    Forge could not finish the ticket and handed it to a person. While the label is on, Forge skips the ticket.

  • ai-review-pending

    Forge ran out of run budget before the final check of its own change. The ticket comment explains how to finish it.

  • ai-phase-error

    One of Forge's steps ended with an error. The label does not block further work, and Forge does not remove it on its own.

When something gets stuck

  • Why did Forge not pick up the ticket?

    Forge skips a ticket that has the ai-needs-human label, is in a status Forge does not work with (such as Done or Backlog), or already has a run going. Forge picks up a ticket waiting for another unfinished ticket once the blocking one is done.

  • What do I do when the ticket gets ai-needs-human?

    Read the comment to see where Forge stopped. Then decide: improve the request and try again, fix the change by hand, or close the ticket. For Forge to come back to the ticket, remove ai-needs-human. If a merge request already exists, though, Forge does not start a new implementation over it and hands the ticket to a person again. The exception is an unfinished final check, marked with ai-review-pending.

  • What if CI keeps failing?

    When the attempts run out, Forge hands the ticket to a person and leaves the merge request open. The usual causes are flaky tests, a CI outage or an error outside the ticket's scope. If CI fails for a reason no code change can fix, such as credentials that have expired, Forge changes nothing and says in a comment which step failed.

  • What if the merge request has a conflict?

    CI does not run on a merge request that conflicts with its target branch, so Forge does not move the ticket to Code Review. It says so in the ticket only once and waits for a person to resolve the conflict. If the project has merge request maintenance on, Forge merges the target branch itself.

  • What if a person works on the ticket too?

    Forge recognizes a branch or merge request that a person created for the same ticket by the commit author and leaves it alone. It mentions this in the ticket only once and carries on with its own work.

  • Where can I see progress and cost?

    Progress is in Forge's progress comment in the ticket. If the project has an hourly rate, the ticket's price is right under the comment's heading. The ticket detail in the Forge client portal shows the status, the current run and a timeline of all runs. When a ticket is waiting for you, the portal says why and what to do.

What needs to be set up

Your Forge operator connects the project. Agree on the following with them.

Project details

  • the implementation label and, optionally, a separate spec review label,
  • ticket status names: where Forge picks tickets up (TODO), in progress (In Progress), Code Review and returned (Returned / Blocked); without a status for returned tickets, Forge does not handle review comments,
  • the project's default reviewer,
  • the repositories, their CI and mandatory checks; a repository without CI, such as a docs repository, can be marked so nobody waits for CI.

Optional settings

  • merge request maintenance in Code Review: off, on conflict only, or always; when on, Forge merges the target branch and fixes failing CI,
  • the language of comments and descriptions: Czech or English (the default); code and code comments are always in English,
  • a custom commit message format, for example when CI checks it,
  • an hourly rate used to calculate the ticket's price in the comment,
  • logging work time in the ticket.

Technical details

For those who connect Forge or review its merge requests.

Branch and merge request

  • The branch is named after the ticket key and title and is the same in every repository. A ticket gets at most one merge request per repository, and a repeated run continues on the existing branch.
  • Before pushing, Forge merges the current target branch into its own branch. It tries to resolve conflicts. If it cannot, it still opens the merge request, with a warning in the description.
  • The commit message has the ticket key and title, or a short description of the fix for fixes.
  • Where the git platform does not support draft merge requests, the title starts with (DRAFT).
  • A person decides the merge order of several merge requests from one ticket.

Review comments

  • Forge reads line comments, the general discussion and the review summary. It treats the whole general discussion as one thread and answers it with one comment.
  • It skips comments from bots where the git platform marks them as bots.
  • It does not react again to a comment it has already answered. If the reviewer replies and returns the ticket again, another round runs.
  • An accepted comment counts as part of the request, so later checks in the run do not undo the change made for it.

Safeguards

  • At most one run works on a ticket at a time.
  • Forge stops a run that exceeds the project's time limit or sits idle for too long, and says why in the ticket.
  • If the run budget, the most one run may spend, runs out, Forge pushes the work so far as a draft with a warning at the top of the description and hands the ticket to a person. It does not fix CI on such a change.
  • If the language model is unavailable, the run ends with an error and the ticket goes back in the queue. Repeated failures end with a hand-off to a person.

What Forge does not do

  • It does not merge, not even after green CI.
  • It does not disable or bypass mandatory checks, and it does not change repository or CI settings.
  • After Code Review it does not work on its own. The exception is merge request maintenance when it is on. Otherwise it continues only when the ticket is returned with comments.

Default limits

Limit in the project settingsDefault
CI fix attempts3
Plan and plan review rounds2
Concurrent runs in the project5

Tickets over the concurrent run limit wait until a run finishes.