π§ Agent Fundamentals β Introduction to Early Test Generation Agents
Early AI offers multiple agents that automate the generation of unit tests across your codebase.
Each agent is optimized for a specific integration point β pull requests, commits, or folders β and can run in any CI/CD system.
This chapter introduces the available agents and explains when to use which.
It also consolidates all shared configuration topics such as token permissions, npm setup, SCM support, and performance tuning.
βοΈ What is an Agent?β
An agent is a programmable entry point to Early AI's test generation engine.
It detects code changes or gaps in test coverage, generates high-quality unit tests using AI, and optionally commits the results.
You can think of agents as:
- π§© PR-focused: Run when code is reviewed
- π Commit-based: Run on every push
- π¦ Folder-based: Improve coverage for large areas of code
π Available Agentsβ
| Agent | Trigger Type | Ideal For | Typical CI/CD |
|---|---|---|---|
| GitHub PR Agent | PR event | Auto-generating tests during code review | GitHub Actions |
| CLI PR Agent | PR event | PR-based workflows in Jenkins/CircleCI | Jenkins, CircleCI |
| CLI Commit Agent | Commit | Commit-based flows or push events | GitHub, Jenkins |
| CLI Repo Agent | Manual/Sched | Raising coverage across a folder | All CI/CD |
π§ Need help choosing? See: When to Use Which Agent β
π Shared Conceptsβ
These topics are common across all agents and documented in detail in this section:
| Topic | Description |
|---|---|
| NPM Authentication | How to install the CLI from GitHub Packages using a classic NPM_TOKEN. |
| GitHub & SCM Tokens | What TOKEN is, which scopes are required, and how to support GitHub, Bitbucket, etc. |
| Supported SCM Providers | Which SCMs are supported and how to configure them (--scm-provider). |
| Concurrency & Performance | How to optimize MAX_CONCURRENCY and CI runtime. |
| Lint & Formatting Hooks | How to configure LINT_COMMAND and PRETTIER_COMMAND for compliant commits. |
| Memory Tuning | Preventing OOM errors with NODE_OPTIONS. |
π§© Whatβs Next?β
π Start with: When to Use Which Agent β
Then continue to the agent-specific section that fits your workflow.
Looking to skip straight to a shared concept? Use the left sidebar.