Agents
Create AI agents with custom tools, skills, triggers, and chat. Attach them to tickets, run batch operations, or publish to the marketplace.
Agents extend JuhJuh beyond the default execution pipeline. You define specialized AI agents with custom instructions, connect them to your project resources, and attach them to tickets for targeted work. Run them on a schedule, fire them from a webhook, chat with them directly, or batch-execute them across dozens of tickets at once.
Agent types¶
Each agent operates in one of three modes.
Hook agents trigger at specific points in the execution pipeline. They run before or after steps, performing focused tasks like validation, cleanup, or context gathering without interrupting the main flow.
Autonomous agents run with their own decision-making loop. They evaluate the ticket, choose which tools to invoke, and iterate until the task is complete. No human prompting required between steps. Each iteration is tracked with token counts, cost, and duration.
Conversational agents are built for direct interaction. Open a chat session, ask questions, and get responses informed by the agent's instructions and connected resources. Conversational agents invoke tools mid-conversation, acting on your behalf while you talk.
Creating an agent¶
- Go to Agents in the sidebar
- Click Create Agent
- Name the agent and write its instructions. Instructions define the agent's behavior, constraints, and goals. See Instructions for how the hierarchy works.
- Choose the agent type: Hook, Autonomous, or Conversational
- Pick a category that describes the agent's focus area (Security, Quality, DevOps, Testing, Frontend, Backend, and 30+ more)
- Upload an icon to identify the agent in lists and chat
- Connect project resources: repositories, APIs, issue trackers, or messaging channels the agent needs access to
- Save
Agents are org-level resources. Once created, any project in your organization can use them.
Configuration options¶
| Setting | Default | What it controls |
|---|---|---|
| Max tool calls | 20 | Safety cap on tool invocations per execution session |
| Max iterations | 10 | Maximum reasoning loops for autonomous agents |
| Model override | (org default) | Use a specific model for this agent |
| Temperature | (model default) | Controls response randomness |
| Knowledge access | On | Whether the agent can read from your org's knowledge base |
Attaching agents to tickets¶
When you attach an agent to a ticket, you choose its execution timing. This determines when the agent runs relative to the main pipeline.
| Timing | When it runs |
|---|---|
| Standalone | The agent handles the entire ticket independently. No main pipeline runs. One per ticket. |
| Before all | Runs once before the main execution starts (setup, validation, context gathering) |
| After all | Runs once after execution completes (cleanup, notifications, verification) |
| Before each | Runs before every execution round in multi-round tickets |
| After each | Runs after every execution round in multi-round tickets |
| Autonomous | Self-directed execution with its own loop. One per ticket, replaces the main pipeline. |
| Parallel | Multiple autonomous agents run simultaneously on the same ticket |
You can attach multiple hook agents to a single ticket. Each runs at its configured timing. Use the priority field to control ordering within the same timing slot. Lower values run first.
Conditional execution¶
Each ticket-agent attachment supports an optional condition expression. The agent only fires when the condition evaluates to true. Available variables: ticket.type, ticket.execution_mode, ticket.priority, ticket.status, and ticket.tags.
Example: attach a security review agent that only runs when ticket.tags contains "security" or ticket.type equals "bug".
Context injection¶
Turn on context injection for any hook agent so its output feeds directly into the next step. A "before all" agent that gathers API documentation, for example, passes that context straight to the main execution. No manual copy-pasting.
Context injection keeps your pipeline composable. Chain multiple agents together. Each one builds on the previous agent's output.
Chat¶
Conversational agents support persistent chat sessions. Open a conversation, send messages, and the agent responds with its full context: instructions, connected resources, and tool access.
Each conversation maintains its own history. Start multiple conversations with the same agent to keep threads separate. Messages stream in real time over a live connection. Responses appear as they are generated.
Agents invoke tools during a conversation. Ask a conversational agent to check a repository, create a ticket, or query an API. It calls the appropriate tool, feeds the result back into the conversation, and continues.
Starting a conversation¶
- Open the agent's detail page
- Click Chat
- Type your message and send
Previous conversations are listed in the sidebar. Click any conversation to resume it.
Triggers¶
Triggers let agents activate without manual intervention. Four trigger types, each suited to a different pattern.
Schedule¶
Cron-based triggers run agents on a recurring cadence. Define a 5-field cron expression and a timezone. The agent fires automatically.
Examples: Run a code quality scan every Monday at 9 AM. Generate a weekly summary report every Friday at 5 PM. Check for stale PRs every 6 hours.
Webhook¶
Expose a unique URL that external services can POST to. Each webhook trigger generates its own path and HMAC secret for signature verification. When a valid request arrives, the agent fires with the webhook payload as context.
Examples: Trigger a deployment agent when your CI pipeline completes. Fire a notification agent when a monitoring alert trips. Start a review agent when an external code scanner reports findings.
Event¶
Event triggers fire when something happens inside JuhJuh. Four event types are available:
| Event | When it fires |
|---|---|
| Ticket created | A new ticket is added to a project |
| Ticket status changed | A ticket transitions between statuses |
| Ticket assigned | A ticket is assigned or reassigned |
| Ticket commented | A comment is added to a ticket |
Each event trigger includes an optional filter. Match on specific projects, statuses, assignees, or keywords to control exactly when the agent fires.
Slack mention¶
Monitor a Slack channel for @mentions of the agent. When someone mentions the agent in the configured channel, it fires with the message context. Useful for on-demand actions triggered from where your team already communicates.
Creating a trigger¶
- Open the agent's detail page
- Go to Triggers
- Click Add Trigger
- Choose the trigger type and configure it
- Save and activate
Each trigger tracks its fire count and last triggered timestamp. Trigger logs record every invocation with status, duration, and any errors.
Tools¶
Agents discover tools automatically from their connected resources. Each resource type exposes a set of operations: repository tools for file operations and PRs, issue tracker tools for ticket management, CI/CD tools for build triggers, and so on.
Tool schemas are defined per resource type and validated before execution. Every tool invocation is logged with the tool name, resource type, success status, and duration.
Built-in tools¶
Every agent has access to these tools regardless of connected resources:
| Tool | What it does |
|---|---|
| Post ticket comment | Adds a comment visible in the ticket timeline (up to 10,000 characters) |
| Save knowledge | Records a finding to the org's knowledge base with a title, content, and category |
| Send agent message | Sends a structured message to another agent on the same ticket (see agent-to-agent messaging) |
| Read agent messages | Reads messages from other agents, optionally filtered by type or sender |
| Use skill | Invokes an attached skill by name |
Tool call limits¶
You can cap the number of tool calls per execution session. The default is 20. Autonomous agents also have an iteration limit (default: 10) to prevent runaway loops. Both values are configurable per agent.
Skills¶
Skills are reusable capabilities you attach to agents. Each skill has a name, instructions, and a set of trigger patterns (keywords or phrases). When a new ticket matches those patterns, the skill's instructions are injected into the agent's prompt automatically.
Skill types¶
| Type | Behavior |
|---|---|
| Knowledge | Injects instructions into the agent's context when triggered. Read-only enrichment. |
| Action | Registers as a callable tool. The agent can invoke it to hit an HTTP endpoint. |
| Combo | Both: injects instructions and registers as a callable tool. |
Action skills¶
Action skills turn external APIs into agent-callable tools. Configure the endpoint URL, HTTP method, request headers, body template, authentication, and response mapping. The agent calls the skill like any other tool, and JuhJuh handles the HTTP request, authentication, and response parsing.
Supported auth types: Bearer token, API key, and Basic auth. Request bodies use template syntax with variables from the agent's context. Response mappings extract specific fields from the API response using JSONPath.
Skill chaining¶
Skills can reference other skills in a chain. When a chained skill is invoked, each skill in the chain executes in order, with each output feeding the next. Maximum chain depth is 5.
Sharing skills¶
By default, skills belong to their agent. Toggle Share to sync a skill to your organization's skill library. This makes it available to all agents in the org. Unshare to pull it back.
Skills track usage and success metrics. Over time, high-performing skills surface while underperforming ones can be deactivated.
Skill versioning¶
Every change to a skill's instructions creates a new version. The version history tracks what changed, a human-readable diff summary, and who made the edit. Roll back to a previous version if a change degrades performance.
Tool pipelines¶
Pipelines chain multiple tools into a single composite operation. Define the sequence of tools, how each step's output maps to the next step's input, and give the pipeline a name. Once saved, the pipeline appears as a single tool the agent can invoke.
Each step specifies:
- The tool to call
- Input parameters (can reference previous step outputs using $prev.field syntax)
- An output key for downstream steps
Pipelines are scoped to individual agents. Test them from the agent detail page before attaching to tickets.
Agent-to-agent messaging¶
When multiple agents work on the same ticket, they communicate through structured messages. Each message includes a type, payload, and summary.
| Message type | Purpose |
|---|---|
| Finding | Report a discovered issue or insight |
| Recommendation | Suggest an action for another agent |
| Blocker | Flag something preventing progress |
| Context | Share background information |
| Status | Report current progress |
| Data | Pass structured data between agents |
Messages can target a specific agent or broadcast to all agents on the ticket. Agents read messages using the built-in read_agent_messages tool, optionally filtering by type or sender.
Batch execution¶
Run an agent across multiple tickets in a single operation. Define filters to select the target tickets, then execute.
Filter options¶
| Filter | What it matches |
|---|---|
| Project | Tickets in a specific project |
| Status | Tickets matching one or more statuses (e.g., "review", "ready") |
| Type | Ticket types to include |
| Sprint | Tickets in a specific sprint |
| Assigned to | Tickets assigned to a specific user |
| Max tickets | Upper limit on how many tickets to process (default: 50) |
Running a batch¶
- Open the agent's detail page
- Go to Batch Execution
- Configure your filters
- Click Preview to see which tickets match
- Click Execute to start
Batch runs track progress with per-ticket status, total cost, and an aggregate summary. Cancel a running batch at any time. Partially completed work is preserved.
Self-improvement¶
After an autonomous execution completes, JuhJuh analyzes the session and proposes instruction refinements. Proposals include the original instructions, suggested changes, a reason for the change, and a human-readable diff.
Improvement proposals require human review. No instruction changes are applied automatically. Approve or reject each proposal from the agent's Improvements tab. On approval, the agent's instructions update atomically.
Execution tracking¶
Every autonomous execution creates a session with full observability:
| Metric | What it tracks |
|---|---|
| Iterations | Number of reasoning loops completed |
| Token usage | Input and output tokens per step and total |
| Cost | Per-step and total cost in USD |
| Duration | Time per step and total session time |
| Tool calls | Which tools were invoked and whether they succeeded |
| Status | Pending, running, completed, failed, or cancelled |
| Source | What triggered the execution: UI, API, Slack, schedule, webhook, event, or batch |
Sessions record each reasoning step individually: the prompt sent, the response received, tools called, and per-step token and cost breakdowns. You can trace exactly what triggered each execution and review the full chain of reasoning.
Progress broadcasts in real time. When an autonomous agent is running, each step and status change streams to the ticket view. Your team can watch the agent work.
Connections¶
Agents connect to the same project resources your projects already use:
- Code repositories. Read and write access for file operations and pull requests.
- Issue trackers. Create, update, and manage tickets across projects.
- CI/CD pipelines. Trigger builds, monitor runs, and gate deployments.
- Communication channels. Post summaries, alerts, and status updates to Slack or Teams.
- Infrastructure. Execute deployment actions, run commands on VMs, and manage environments.
Connections are configured at the agent level. When you attach an agent to a ticket, it inherits access to the resources you have linked.
Configuration overrides¶
Each ticket-agent attachment can carry its own configuration, overriding the agent's defaults for that specific execution. A deployment agent might target staging on one ticket and production on another.
Overrides are scoped to the attachment. They do not modify the agent's base configuration. Other tickets with the same agent are unaffected.
Marketplace¶
The agent marketplace lets you share and discover agent configurations across organizations.
Publishing¶
- Open the agent you want to share
- Click Publish to Marketplace
- Add a long description, suggested resource connections, and default settings
- Choose visibility: Public (anyone can install) or Private (your org only)
- Confirm and publish
Published templates include the agent's instructions, type, category, suggested connections, default tool call and iteration limits, and any pre-configured tool pipelines.
Installing¶
- Go to Marketplace from the Agents page
- Browse or search templates by category, type, or keyword
- Click a template to see its details, install count, and ratings
- Click Install to create a new agent from the template
Installed agents are fully editable. The template is a starting point, not a locked configuration.
Skill marketplace¶
Skills have their own marketplace. Browse shared skill templates, install them into your org, and attach them to any agent. Skill templates include instructions, trigger patterns, and action configuration (for action and combo skills).
Ratings¶
Rate agents, skills, and templates on a 1 to 5 scale. Ratings are per-user. Your rating updates if you rate the same item again. Average ratings appear on detail pages and in marketplace listings.
API access¶
The API provides full CRUD access to agents.
| Method | Endpoint | Action |
|---|---|---|
GET |
/api/v1/orgs/{slug}/agents/ |
List agents (filter by type, category, or keyword) |
POST |
/api/v1/orgs/{slug}/agents/ |
Create an agent |
GET |
/api/v1/orgs/{slug}/agents/{id}/ |
Get agent details |
PATCH |
/api/v1/orgs/{slug}/agents/{id}/ |
Update an agent |
DELETE |
/api/v1/orgs/{slug}/agents/{id}/ |
Deactivate an agent |
POST |
/api/v1/orgs/{slug}/agents/{id}/chat/ |
Start a chat session |
GET |
/api/v1/orgs/{slug}/agents/{id}/sessions/ |
List execution sessions |
Use cases¶
Pre-execution validator. Attach a "before all" hook that checks ticket requirements, verifies linked resources exist, and confirms the target branch is clean. All of this runs before any AI writes a single line of code.
Post-execution reviewer. Attach an "after all" hook that runs linting, type checking, and your custom code quality rules against the generated changes. Flag issues before the PR is created.
Deployment agent. An autonomous agent that monitors PR approvals, handles staging deployment, runs migrations, and verifies health checks. Trigger it on a schedule or via webhook from your CI pipeline.
Documentation agent. Attach "after each" to auto-generate or update documentation based on the code changes produced in each execution round.
Notification agent. An "after all" hook that posts execution summaries, cost breakdowns, and diff links to your team's Slack channel. Everyone stays informed without checking the dashboard.
On-call responder. A conversational agent connected to your infrastructure resources. Chat with it to diagnose issues, check service health, or trigger rollbacks. All from the agent's chat interface.
Scheduled scanner. A cron-triggered autonomous agent that runs nightly code quality checks, opens tickets for any issues found, and posts a summary to Slack.
Cross-agent pipeline. Attach a security agent (before all), the main execution, and a QA agent (after all) to every ticket. The security agent's findings feed into execution context. The QA agent reviews the output. Each agent specializes in its domain.
Batch code review. Select all tickets in "review" status across a project and batch-execute a review agent. Get consistent, automated reviews on every open ticket in minutes.
Related¶
- Skills: reusable capabilities with trigger patterns, HTTP actions, and a marketplace
- Agent Pipelines: hook timing, tool chains, context injection, and batch execution
- Agent Marketplace: browse, install, and publish reusable agent and skill templates
- Instructions: define the rules your agents follow at org, project, team, and user levels
- Prompt Templates: reusable prompt patterns that complement agent instructions
- Vault: give agents secure access to credentials and environment variables
- Tickets: attach agents to tickets to run them during execution
- Resources: connect agents to your repositories and infrastructure
- Slack: trigger and monitor agents directly from Slack channels
- Automation: broader automation patterns that work alongside agents
- MCP Server: interact with agents from Claude Code and Claude Desktop
- API: manage agents programmatically