Skip to main content
Updated July 25, 2026
Most of an engineering week disappears into tracing code, reproducing bugs, scaffolding tests, and rebuilding context that never ships anything. These are the eight AI use cases that hand that work to a coding agent, ranked by the time they give back.

All eight run on whichever AI coding agent you already use - Claude CodeClaude Code, CodexCodex, Gemini CLIGemini CLI, GitHub CopilotGitHub Copilot, or CursorCursor - connected to the tools listed with each use case.

Best AI Engineering Use Cases


Implement features

Best for well-scoped product work with clear acceptance criteria
3 hr/wkest. time saved
How it’s done today

You translate a ticket into code, find the relevant entry points, trace data flow, copy established patterns, update tests, and repeatedly move between the issue, editor, and terminal.

How AI helps

Given the repository and acceptance criteria, your agent finds the existing pattern, proposes a small plan, implements the change across the necessary files, and runs the focused checks before returning the diff.

LinearTicket is readyscope and acceptance are clear
Your AI agent

Locates the relevant code path, follows local conventions, implements the smallest complete change, and reports the tests and decisions.

Code change GitHub
Test results GitHub Actions
Review summary Linear
How to set it up

Required

GitHubGitLabCode repo

Reads the code, history, contribution rules, and existing implementation patterns.

Writes a branch or patch containing the scoped change.

Recommended

GitHub ActionsGitLab CICI/CD

Reads the required checks and prior failures.

Writes new or updated tests and the local check results.

Optional

VS CodeJetBrainsIDE

Reads local diagnostics, language tooling, and runtime output while it works.

JiraLinearIssues

Reads the ticket, acceptance criteria, dependencies, and design decisions.

Writes a concise implementation and verification summary.

If the issue tracker is not connected, paste the complete ticket into the coding agent at the repository root. Repository access and executable checks matter far more than automatic ticket updates.

Have a ready ticket, repository instructions, setup and test commands, and one similar implementation you trust. Start with changes that fit in one reviewable pull request.

Setup prompt

What good looks like

The diff should satisfy every acceptance criterion, resemble nearby code, avoid unrelated edits, include meaningful tests, and arrive with reproducible check results and no hidden decision disguised as implementation detail.

Choose your trigger

Start manually from a Ready for development ticket or a specific repository comment. Exclude vague discovery work, security-sensitive changes, large migrations, and tickets with unresolved product decisions.

What runs without you

The agent can pick up a ready ticket, implement it, and open a draft pull request on its own - merging never stops being yours. Keep every diff human-reviewed; after five tasks that land with only normal review feedback, let it create branches and draft PRs automatically. Revisit the repository instructions whenever the stack or conventions change, or the agent will keep reproducing yesterday’s patterns.

Pairs well with generate tests and review pull requests - the same ticket flows from change to coverage to first-pass review.

Investigate bugs

Best for reproducible failures that still require code tracing
2 hr/wkest. time saved
How it’s done today

You translate a vague report into reproduction steps, search logs and recent changes, trace the failing path through the codebase, form hypotheses, and manually assemble evidence for a fix.

How AI helps

Your agent reproduces the reported behavior, collects the relevant logs and stack traces, follows the code path, tests competing hypotheses, and proposes the smallest fix with a regression test.

GitHubBug is reproduciblesteps and expected behavior supplied
Your AI agent

Runs the reproduction, traces the failure through logs and code, narrows the cause, and verifies a minimal patch against the same steps.

Root-cause note Google Docs
Fix and test GitHub
Verification log Datadog
How to set it up

Required

GitHubGitLabCode repo

Reads the implementation, recent history, tests, and repository instructions.

Writes a proposed patch and regression test on a branch.

Recommended

DatadogGrafanaObservability

Reads the relevant logs, traces, errors, environment, and timestamps.

GitHub ActionsGitLab CICI/CD

Reads existing failures and test commands.

Writes the regression-test result and focused verification.

Optional

JiraLinearIssues

Reads the report, reproduction, expected behavior, impact, and affected versions.

Paste the report, stack trace, and a narrow log export into the coding agent if observability is not connected. A precise reproduction and timestamp are more useful than a long general description.

Have one deterministic reproduction, expected versus actual behavior, environment details, a recent failure timestamp, and the commands needed to run the affected service or test.

Setup prompt

What good looks like

The original failure must be demonstrated, the claimed cause must explain it, the regression test must protect the behavior, and the same reproduction must pass after a minimal diff without unrelated cleanup.

Choose your trigger

Run manually when a report has clear reproduction steps or automatically when a known deterministic test fails. Exclude intermittent production incidents without a bounded evidence pack; those belong in incident investigation.

What runs without you

Every fix stays human-reviewed - what graduates is the investigation itself. After five cases where the root cause held up, let the agent start on new reports automatically and post its reproduction and evidence as a ticket note before anyone picks the bug up. Check monthly that it still has access to the logs and test fixtures it relies on; a silent permissions change turns good investigations into guesses.

Pairs well with generate tests and investigate incidents - a confirmed root cause hands the regression test and the incident timeline their starting evidence.

Generate tests

Best for closing clear coverage gaps around important behavior
2 hr/wkest. time saved
How it’s done today

You read the implementation and existing test style, identify meaningful behavior gaps, build fixtures and mocks, write assertions, and repeatedly tune brittle tests until they pass reliably.

How AI helps

Your agent maps important behavior and failure paths, follows the nearest test pattern, creates focused cases, and runs them both independently and inside the relevant suite.

GitHubCoverage gap identifiedbehavior and boundary are known
Your AI agent

Derives cases from observable behavior, reuses local fixtures, and proves each test can fail for the intended reason before returning it.

Test cases GitHub
Coverage note Google Docs
Suite results GitHub Actions
How to set it up

Required

GitHubGitLabCode repo

Reads the implementation, nearest tests, fixtures, helpers, and behavior contract.

Writes focused test files or additions.

Recommended

GitHub ActionsGitLab CICI/CD

Reads test commands, coverage output, and flaky-test history.

Writes the focused and suite-level results.

Optional

VS CodeJetBrainsIDE

Reads language diagnostics and local runtime output while the tests are built.

A local coding agent with repository access is enough. Supply the exact behavior to protect; a percentage coverage target by itself tends to produce low-value tests.

Have the target behavior, relevant files, test command, and one nearby test that represents the preferred style. Decide whether the goal is regression protection, edge cases, or a missing contract.

Setup prompt

What good looks like

The tests should exercise observable behavior, fail for a meaningful reason, match local style, avoid unnecessary mocks, run reliably, and add protection not already present in the suite.

Choose your trigger

Run from a review comment, a bug fix, or an explicit coverage-gap task. Do not auto-generate tests for every changed line; require a named behavior or risk.

What runs without you

Test diffs stay reviewed like any other code change. Once five additions in a row have landed without rework, let the agent push updates to a draft PR on its own - the red-green proof inside each test is what keeps this safe. Watch the flaky-test signals weekly; a generated test that flakes erodes trust in the whole suite faster than a missing one.

Pairs well with implement features and investigate bugs - both produce the changes that need exactly this protection.

Review pull requests

Best for a consistent first pass before a human reviewer
1.5 hr/wkest. time saved
How it’s done today

You open the ticket, inspect the diff, trace changed call paths, cross-check conventions and tests, and write review comments while trying to separate real defects from style preferences.

How AI helps

When a pull request is ready, your agent compares it with the stated intent, inspects affected code and tests, runs relevant checks, and leaves a short list of evidence-backed findings for the reviewer.

GitHubPull request readydraft status removed
Your AI agent

Checks behavior, correctness, security, tests, and repository conventions, then reports only actionable findings with exact locations.

Review findings GitHub
Check results GitHub Actions
Risk summary Linear
How to set it up

Required

GitHubGitLabCode repo

Reads the pull request, base branch, ticket, surrounding code, and review rules.

Writes review comments or a draft review for the engineer.

Recommended

GitHub ActionsGitLab CICI/CD

Reads required check results, coverage changes, and failure logs.

Optional

JiraLinearIssues

Reads acceptance criteria and linked design decisions.

Run the coding agent against the pull-request branch locally if repository review integration is unavailable. Ask for a review report rather than copying the raw diff into a general chatbot.

Have repository review guidance, the ticket, required checks, and examples of useful versus noisy review comments. Define focus areas such as correctness, security, migrations, or backward compatibility.

Setup prompt

What good looks like

Comments should identify a real failure or maintainability risk, point to the exact code, explain how to reproduce or reason about it, and avoid noise that a formatter or human preference would settle.

Choose your trigger

Run when a pull request leaves draft or when a reviewer explicitly requests it. Skip generated files, dependency-lock-only changes, and repositories without review instructions until those rules exist.

What runs without you

Approval and merge are permanently human - the agent’s review is a first pass, not a gate. Keep its comments in draft for the first ten pull requests and compare them with what your reviewers caught. When the overlap is consistently useful, let non-blocking comments post automatically. Once a month, sample merged PRs for defects it missed; the agent’s silence should never be read as approval.

Pairs well with implement features - both work from the same repository rules, on opposite sides of the diff.

Understand codebases

Best for onboarding to an unfamiliar service or tracing one feature
1.5 hr/wkest. time saved
How it’s done today

You search folders and symbols, jump between callers and data models, read stale architecture pages, and ask teammates to explain how one request or feature moves through the system.

How AI helps

Your agent maps the relevant files, traces the execution and data flow, explains project-specific terms, and gives you a source-linked walkthrough you can challenge with follow-up questions.

GitHubNew area to understandservice or feature named
Your AI agent

Starts broad, narrows to the requested path, and supports every explanation with files, symbols, and the current implementation.

Architecture map GitHub
Execution trace Google Docs
Glossary Notion
How to set it up

Required

GitHubGitLabCode repo

Reads the current code, tree, symbols, history, and repository instructions.

Recommended

Google DocsNotionDocs

Reads architecture decisions, runbooks, diagrams, and product terminology.

Writes a source-linked walkthrough or onboarding note.

Optional

VS CodeJetBrainsIDE

Reads language intelligence and runtime commands for confirming the execution path.

Run the agent at the repository root and point it at a specific feature or service. Broad requests such as “explain everything” are less useful than tracing one user action end to end.

Have the repository instructions, setup commands, any current architecture docs, and three questions a new engineer genuinely needs answered.

Setup prompt

What good looks like

A new engineer should be able to navigate from the explanation to the exact code, follow the real execution path, distinguish current implementation from stale docs, and know where changes and tests normally belong.

Choose your trigger

Run manually when onboarding, picking up a ticket in an unfamiliar area, or preparing a design. Require a named feature, service, or path so the output stays useful.

What runs without you

This workflow is read-only, so the risk is staleness, not damage. After three accurate walkthroughs, let it save its output automatically as onboarding notes - but treat them as snapshots until an engineer confirms them, not as durable documentation. Regenerate after any major architecture change; an outdated walkthrough misleads more than no walkthrough at all.

Pairs well with update documentation - a verified walkthrough is halfway to the documentation page.

Refactor code safely

Best for mechanical improvements with behavior that must stay fixed
1.5 hr/wkest. time saved
How it’s done today

You inventory references, characterize current behavior, make repetitive changes across files, repair tests and types, and inspect the diff for accidental behavior changes.

How AI helps

Your agent maps every affected call site, establishes a behavior-preserving test baseline, applies the refactor in small steps, and reruns focused and broader checks after each stage.

GitHubRefactor scopedbehavior must remain unchanged
Your AI agent

Builds a reference map and test baseline, performs staged edits, and stops when checks reveal a behavior change outside the agreed scope.

Refactor diff GitHub
Reference map Sourcegraph
Check report GitHub Actions
How to set it up

Required

GitHubGitLabCode repo

Reads all definitions, references, tests, generated boundaries, and repository rules.

Writes the staged refactor on a branch.

Recommended

GitHub ActionsGitLab CICI/CD

Reads the behavior baseline and required checks.

Writes focused and full-suite results.

Optional

VS CodeJetBrainsIDE

Reads symbol references, type errors, and runtime verification.

A local coding agent can do this with repository and terminal access. Do not paste isolated files into chat for a cross-cutting refactor; the reference map is part of the work.

Have the exact boundary to change, the behavior that must not change, known public APIs, test commands, and a rollback-friendly branch. Split migrations from cleanup where possible.

Setup prompt

What good looks like

The external behavior and public interfaces should remain unchanged, all references should be accounted for, the diff should contain only the agreed structural change, and tests should pass before and after each stage.

Choose your trigger

Start manually from an approved technical task. Exclude emergency production fixes, broad “clean up the codebase” requests, and migrations that intentionally change behavior.

What runs without you

Refactors never graduate to autonomy - every stage stays reviewed and merges small. What the agent earns over time is scope: start with renames and extractions before trusting it with module boundaries. Recheck how it finds references whenever the language tooling changes; a refactor that misses one dynamic call site is worse than no refactor.

Pairs well with generate tests and review pull requests - characterization tests and a careful first pass are what make staged refactors safe.

Update documentation

Best for keeping reference and runbook changes beside the code change
1 hr/wkest. time saved
How it’s done today

After code changes, you locate every affected README, reference page, example, runbook, and diagram, then rewrite them while checking that commands and names still match the implementation.

How AI helps

Your agent reads the diff, finds documentation that describes the changed behavior, updates examples and commands, and flags pages that appear stale or need a product decision.

GitHubCode change readybehavior or interface changed
Your AI agent

Maps the diff to affected reader tasks, updates the nearest sources of truth, and validates commands, links, names, and examples.

Docs changes Google Docs
Example updates GitHub
Stale-page list Notion
How to set it up

Required

GitHubGitLabCode repo

Reads the code diff, tests, examples, changelog, and documentation references.

Writes documentation changes stored with the code.

Recommended

Google DocsNotionDocs

Reads external guides, runbooks, architecture pages, and style guidance.

Writes reviewable updates or an affected-page list.

Optional

GitHub ActionsGitLab CICI/CD

Reads documentation link, snippet, and example-validation results.

Point the agent at the diff and documentation roots. If external docs are not connected, have it produce a precise patch list with old and replacement text for each page.

Have the final diff, docs style guide, ownership map, link and snippet checks, and an example of a good release-linked documentation update.

Setup prompt

What good looks like

Every affected reader task should remain accurate, examples and commands should work, stale names and links should be gone, and the documentation diff should explain the behavior rather than repeat implementation details.

Choose your trigger

Run when a pull request changes a public interface, command, workflow, configuration, or operational procedure. Skip internal-only refactors that do not affect documented behavior.

What runs without you

Documentation changes stay reviewed alongside the code change they belong to. After five accurate change-to-page mappings, let the agent attach its docs checklist to qualifying pull requests automatically - the author confirms it instead of reconstructing it. Audit for stale pages quarterly; this workflow only catches drift for changes that go through review.

Pairs well with implement features and understand codebases - both create the change context the docs update needs.

Investigate incidents

Best for assembling the timeline and evidence while responders stay focused
0.5 hr/wkest. time saved
How it’s done today

Responders jump between alerts, logs, traces, deployments, chat, and code while someone manually reconstructs the timeline and tries to separate symptoms from the likely change.

How AI helps

Your agent gathers the bounded evidence pack, correlates alerts with deployments and code paths, maintains a timestamped timeline, and prepares hypotheses and follow-up work for the incident lead.

DatadogIncident declaredservice and time window set
Your AI agent

Builds a live evidence timeline, links symptoms to recent changes and affected paths, and updates hypotheses without taking production action.

Incident timeline Google Docs
Evidence links Datadog
Follow-up tasks Asana
How to set it up

Required

DatadogGrafanaObservability

Reads alerts, logs, traces, dashboards, service health, and the incident time window.

Recommended

GitHubGitLabCode repo

Reads recent deployments, commits, runbooks, ownership, and relevant code paths.

Optional

SlackMicrosoft TeamsChat

Reads incident-channel decisions and timestamps.

Writes concise evidence updates for the incident lead to review.

JiraLinearIssues

Writes approved remediation and prevention follow-ups after the incident.

Export the relevant logs, deploy history, and incident chat for the defined time window. Do not give the agent unrestricted production action; its default role here is evidence and coordination.

Have the affected service, start time, impact, incident channel, dashboard links, deployment history, runbooks, and a named incident lead who decides actions.

Setup prompt

What good looks like

The timeline should use exact timestamps and source links, hypotheses should never be reported as facts, evidence should stay within the incident scope, and follow-ups should map to observed failure modes.

Choose your trigger

Run when an incident record is created with an affected service, lead, and time window. Exclude low-priority alerts and automated flapping unless a human declares an incident.

What runs without you

Evidence collection can run automatically from the moment an incident is declared - that is the point of the workflow. Remediation and every external or company-wide message stay with the incident lead, permanently. After each incident, spend five minutes on what the agent missed or mis-linked; that review is what makes the next timeline trustworthy.

Pairs well with investigate bugs and update documentation - the incident evidence pack becomes the bug reproduction, and the postmortem becomes the runbook update.

How to choose

  • Start with investigate bugs or generate tests if you want proof quickly - both are bounded, and the result is verifiable the same day.
  • Shipping features weekly? Implement features pays off most once the agent knows your repository rules; add review pull requests to protect the other side of the diff.
  • New to the codebase, or growing the team? Understand codebases and update documentation turn every question into a durable artifact.
  • Own production? Investigate incidents assembles evidence while responders respond, and refactor code safely is for the debt you keep deferring - scoped, staged, never during an incident.

What didn’t make the list (yet)

Two engineering categories are marketed heavily and deliberately missing here: Autonomous “AI software engineers” - agents that take a ticket to production without review - are the loudest promise in the category and absent from every workflow above by design. The working pattern is agent-drafts, engineer-reviews: an agent can earn branch and draft-PR autonomy, never merge or deploy. Deployment and production remediation stay excluded until approval gates are environment-specific and tested. Unattended auto-merge - bots that merge dependency updates or AI fixes the moment CI turns green - is excluded on purpose. Green checks measure what your tests cover, not what changed; the review and refactor workflows above exist precisely because “passing” and “safe” are different claims.

Frequently Asked Questions

AI works best on bounded repository tasks with a clear result and executable checks: implementing a scoped feature, reproducing a bug, adding tests, reviewing a pull request, explaining unfamiliar code, and updating documentation alongside a change.
Yes. Connect it to the repository and provide the project instructions, setup commands, architecture notes, and test commands. The agent should inspect existing patterns before editing and report the files and checks it changed or ran.
Require the smallest relevant tests, lint and type checks, a diff review, and a direct verification of the requested behavior. For risky changes, add focused regression tests and use the same CI gates as any human-authored pull request.
These workflows shift time from searching, scaffolding, and repetitive edits toward problem definition, design, verification, and review. They are most valuable when an engineer remains responsible for scope and correctness.