Developer Productivity Agents
AI-powered agents for feature flag cleanup, framework upgrades, and repository onboarding, automating common engineering workflows that are tedious and time-consuming.
Harness Developer Productivity agents automate common engineering workflows that are tedious and time-consuming. The Feature Flag Cleanup agent removes stale flags from codebases, the React Upgrade agent handles framework upgrades with custom prompts, and the Onboarding agent imports repositories and auto-generates CI pipelines.
Feature Flag Cleanup Agent
The Feature Flag Cleanup agent removes stale feature flags from codebases. Given a feature flag name and the desired treatment (e.g., on or off), it uses Claude AI to find all flag references, remove evaluations while keeping only the selected treatment's code path, and clean up unused imports and variables.
How it works
Task Generation: Generates a detailed cleanup prompt based on the flag name and desired treatment.
Code Analysis: Claude AI (up to 50 iterations) scans the codebase for all flag references.
Flag Removal: Removes flag evaluations, keeping only the code path for the selected treatment.
Cleanup: Removes unused imports, variables, and dead code left by flag removal.
Draft PR: Pushes changes and creates a draft PR via the Harness Code API.
Key inputs
anthropicKey
secret
Anthropic API key for Claude AI
harnessApiKey
secret
Harness API key for creating PRs
featureFlag
string
Name of the feature flag to remove
treatment
string
Desired treatment to keep (default: on)
repo
string
Repository name
branch
string
Target branch
Output artifacts
branch.txt: Name of the created branchcommit.txt: Commit SHA of the changespr_title.txt: AI-generated PR titlepr_description.txt: AI-generated PR description
Pipeline configuration
React Upgrade Agent
The React Upgrade agent automates React version upgrades and code modifications using custom prompts. Despite its name, it's the most flexible agent; it accepts any free-form prompt, making it suitable for framework upgrades, refactoring, dependency updates, and performance optimization.
Use cases
Upgrade React from version 17 to 18
Refactor class components to functional components with hooks
Update deprecated API usage across the codebase
Migrate from one state management library to another
Apply performance optimizations based on custom criteria
Key inputs
llmConnector
connector
LLM connector for AI operations
harnessKey
secret
Harness API key
gitConnector
connector
Git connector for repository access
repo
string
Repository name
branch
string
Target branch
prompt
string
Custom prompt describing the upgrade/modification task (required)
Pipeline configuration
Onboarding Agent
The Onboarding agent streamlines repository setup in Harness. It imports repositories from GitHub into Harness Code, analyzes the repo structure to detect technologies and build commands, and auto-generates a CI pipeline tailored to the project.
How it works
Repository Import: Clones the source repository from GitHub and imports it into Harness Code.
Technology Detection: Claude Sonnet analyzes the repo structure (languages, frameworks, build tools, dependencies).
Pipeline Generation: Claude Opus generates a complete CI pipeline based on the detected technology stack.
Pipeline Creation: The generated pipeline is created in Harness via the API.
Unique architecture
Uses two different Claude models: Sonnet for fast analysis, Opus for high-quality pipeline generation
No clone step in the pipeline; the agent container itself handles repository cloning
Runs on
linux/amd64platform (unlike most agents that usearm64)
Key inputs
anthropicKey
secret
Anthropic API key for Claude AI
harnessKey
secret
Harness API key for creating repos and pipelines
scmToken
secret
Optional SCM token for private repository access
repoNamespace
string
Source repository namespace/owner (e.g., myorg)
repoName
string
Source repository name
connectorRef
string
Harness connector reference for git operations (optional)
Pipeline configuration
Last updated
Was this helpful?