pullfrog 0.1.67 β 0.1.69
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +72 -150
- package/dist/cli.mjs +236 -77
- package/dist/effort.d.ts +10 -0
- package/dist/external.d.ts +18 -1
- package/dist/index.js +234 -75
- package/dist/internal/index.d.ts +1 -1
- package/dist/internal.js +91 -8
- package/dist/mcp/reviewComments.d.ts +42 -0
- package/dist/toolState.d.ts +1 -1
- package/dist/utils/apiKeys.d.ts +19 -0
- package/dist/utils/billingErrors.d.ts +1 -2
- package/dist/utils/buildPullfrogFooter.d.ts +4 -1
- package/dist/utils/payload.d.ts +1 -0
- package/dist/utils/providerErrors.d.ts +8 -0
- package/dist/utils/proxy.d.ts +24 -0
- package/dist/utils/runContext.d.ts +7 -0
- package/dist/utils/runContextData.d.ts +9 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
<!-- test preview system -->
|
|
2
1
|
<p align="center">
|
|
3
2
|
<h1 align="center">
|
|
4
3
|
<picture>
|
|
@@ -8,145 +7,110 @@
|
|
|
8
7
|
Pullfrog
|
|
9
8
|
</h1>
|
|
10
9
|
<p align="center">
|
|
11
|
-
|
|
10
|
+
The BYOK CodeRabbit that runs in your GitHub Actions
|
|
12
11
|
</p>
|
|
13
12
|
</p>
|
|
14
13
|
|
|
15
|
-
<
|
|
16
|
-
|
|
17
|
-
>
|
|
14
|
+
<p align="center">
|
|
15
|
+
<a href="https://pullfrog.com">pullfrog.com</a> Β· <a href="https://docs.pullfrog.com">Docs</a> Β· <a href="https://pullfrog.com/console">Console</a> Β· <a href="https://discord.gg/8y96raFg8e">Discord</a>
|
|
16
|
+
</p>
|
|
18
17
|
|
|
19
18
|
<br/>
|
|
20
19
|
|
|
20
|
+
> **New** β Pullfrog is now [free for personal and open-source usage](https://pullfrog.com/blog/free-for-open-source).
|
|
21
|
+
|
|
21
22
|
## What is Pullfrog?
|
|
22
23
|
|
|
23
|
-
Pullfrog is
|
|
24
|
+
Pullfrog is the BYOK CodeRabbit that runs in your GitHub Actions. It listens for GitHub events β PRs opened, issues created, reviews submitted, CI failures β and triggers agent runs based on your configuration, via a `pullfrog.yml` workflow that uses this open-source action. You control the infrastructure, the keys, and the costs.
|
|
24
25
|
|
|
25
|
-
|
|
26
|
-
- **Prompt from the web** βΒ Trigger arbitrary tasks from the Pullfrog dashboard
|
|
27
|
-
- **Automated triggers** β Configure Pullfrog to trigger agent runs in response to specific events. Each of these triggers can be associated with custom prompt instructions.
|
|
28
|
-
- issue created
|
|
29
|
-
- issue labeled
|
|
30
|
-
- PR created
|
|
31
|
-
- PR review created
|
|
32
|
-
- PR review requested
|
|
33
|
-
- and more...
|
|
26
|
+
Pullfrog is not an agent itself. It wraps vanilla **[Claude Code](https://github.com/anthropics/claude-code)**, **[Codex](https://github.com/openai/codex)**, and **[OpenCode](https://github.com/anomalyco/opencode)**, selecting the one that matches your BYOK or bring-your-own-subscription configuration β so every run uses the vendor's real agent, and it reads the repo-level config you already keep for it: `CLAUDE.md` or `AGENTS.md`, skills, custom commands, and repo-level MCP servers.
|
|
34
27
|
|
|
35
|
-
|
|
28
|
+
Out of the box, it can:
|
|
36
29
|
|
|
37
|
-
-
|
|
38
|
-
-
|
|
39
|
-
-
|
|
40
|
-
- **
|
|
30
|
+
- **Review new PRs** β auto-review every incoming PR; the review verdict can gate merges via requireable status checks.
|
|
31
|
+
- **Address reviews** β leave review comments on a Pullfrog PR as you would for a human colleague, and it addresses them.
|
|
32
|
+
- **Autofix CI** β Pullfrog detects CI failures on its own PRs and attempts a fix. It can be configured to fix human PRs too.
|
|
33
|
+
- **Autofix merge conflicts** β keep PRs mergeable without hand-resolving.
|
|
34
|
+
- **Triage issues** β respond to common questions, apply labels, link related issues and PRs, or draft implementation plans.
|
|
35
|
+
- **Anything ad hoc** β tag `@pullfrog` in any issue, PR, or comment. It pulls in the surrounding context and figures out what to do. Prompt from the [console](https://pullfrog.com/console) for anything else.
|
|
41
36
|
|
|
42
|
-
|
|
43
|
-
- **Agent-agnostic** β Switch between agents with the click of a radio button.
|
|
44
|
-
- ** -->
|
|
37
|
+
Each automation can be toggled from the dashboard and customized with per-trigger instructions.
|
|
45
38
|
|
|
46
|
-
<!--
|
|
47
39
|
## Get started
|
|
48
40
|
|
|
49
|
-
|
|
41
|
+
Run one command in any local repo:
|
|
50
42
|
|
|
51
|
-
|
|
43
|
+
```sh
|
|
44
|
+
npx pullfrog init
|
|
45
|
+
```
|
|
52
46
|
|
|
53
|
-
|
|
54
|
-
|
|
47
|
+
Or [install from the browser](https://pullfrog.com/console). Setup takes about two minutes: install the GitHub App, add the `pullfrog.yml` workflow with one click, and pick a model. See [getting started](https://docs.pullfrog.com/getting-started).
|
|
48
|
+
|
|
49
|
+
## Runs on the subscription you already pay for
|
|
50
|
+
|
|
51
|
+
No API key required. Connect a coding-agent plan once and every run bills against it:
|
|
55
52
|
|
|
56
|
-
|
|
53
|
+
| Plan | Connect with |
|
|
54
|
+
| --- | --- |
|
|
55
|
+
| [Claude Pro/Max](https://docs.pullfrog.com/claude-auth) | `npx pullfrog auth claude` |
|
|
56
|
+
| [ChatGPT Codex](https://docs.pullfrog.com/codex-auth) | `npx pullfrog auth codex` |
|
|
57
|
+
| [Grok](https://docs.pullfrog.com/grok-auth) | `npx pullfrog auth grok` |
|
|
58
|
+
| [Kimi Code](https://docs.pullfrog.com/kimi-code) | a Kimi Code key as `KIMI_API_KEY` |
|
|
59
|
+
| [OpenCode Go](https://docs.pullfrog.com/models#opencode-zen-and-opencode-go) | an OpenCode key as `OPENCODE_API_KEY` |
|
|
57
60
|
|
|
58
|
-
|
|
61
|
+
## Or bring your own model
|
|
59
62
|
|
|
60
|
-
|
|
63
|
+
Pullfrog works with any LLM provider: Anthropic, OpenAI, Google, xAI, Mistral, DeepSeek, OpenRouter, and more. Switch models with a config change. Two more ways to pay for tokens:
|
|
61
64
|
|
|
62
|
-
|
|
65
|
+
- **Your own API key** β stored in Pullfrog's encrypted secret store or in GitHub Actions secrets, your choice.
|
|
66
|
+
- **Router** β Pullfrog's built-in model access, billed at raw provider cost with no markup.
|
|
67
|
+
|
|
68
|
+
## Batteries included
|
|
69
|
+
|
|
70
|
+
- π οΈ **MCP tools for GitHub** β a purpose-built MCP server for git and GitHub operations: creating PRs, leaving reviews and comments, reading CI logs, managing issues. Every operation goes through Pullfrog's permission layer.
|
|
71
|
+
- π‘οΈ **Secure shell access** β shell commands run in an isolated subprocess without access to sensitive environment variables.
|
|
72
|
+
- π **Headless browser** β for end-to-end tests, screenshots, and UI iteration, with screenshot uploads out of the box.
|
|
73
|
+
- π **Short-lived credentials** β all GitHub operations use an installation token that is auto-revoked when the run completes. Keys are auto-masked in logs, and only the minimum necessary environment variables pass through to the agent.
|
|
74
|
+
- πͺ **Hooks** β setup, post-checkout, pre-push, and stop scripts that run inside the agent's permission boundary. A stop script that exits non-zero resumes the agent with the failure as context, so it fixes its own broken push instead of opening a red PR.
|
|
75
|
+
- π **GitHub-native permissions** β GitHub remains the single source of truth for access control. Users only see repos they already have access to; org settings require an org owner.
|
|
76
|
+
|
|
77
|
+
## Pricing
|
|
78
|
+
|
|
79
|
+
Pullfrog is free for developers on personal GitHub accounts and free for open-source repos. Pro is $30/month for the whole organization with no per-run or per-seat billing β required for an org's private repos, optional everywhere else. Pullfrog also covers model cost for impactful open-source projects β [apply here](https://pullfrog.com/for-oss).
|
|
80
|
+
|
|
81
|
+
## Standalone usage
|
|
82
|
+
|
|
83
|
+
The same `pullfrog/pullfrog@v0` action that powers the automations above also works as a step in your own workflows β an agent as one stage of a larger pipeline. The action takes a `prompt` and the provider key of your choice; the only permission it needs is `id-token: write`, which lets it mint its own short-lived GitHub token.
|
|
63
84
|
|
|
64
85
|
```yaml
|
|
65
|
-
#
|
|
66
|
-
name:
|
|
86
|
+
# .github/workflows/agent.yml β run any prompt on demand
|
|
87
|
+
name: Agent
|
|
67
88
|
on:
|
|
68
89
|
workflow_dispatch:
|
|
69
90
|
inputs:
|
|
70
91
|
prompt:
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
permissions:
|
|
75
|
-
contents: read
|
|
92
|
+
description: What should the agent do?
|
|
93
|
+
required: true
|
|
76
94
|
|
|
77
95
|
jobs:
|
|
78
|
-
|
|
96
|
+
agent:
|
|
79
97
|
runs-on: ubuntu-latest
|
|
80
98
|
permissions:
|
|
81
99
|
id-token: write
|
|
82
100
|
contents: read
|
|
83
101
|
steps:
|
|
84
|
-
-
|
|
85
|
-
|
|
86
|
-
with:
|
|
87
|
-
fetch-depth: 1
|
|
88
|
-
- name: Run agent
|
|
89
|
-
uses: pullfrog/pullfrog@v0
|
|
102
|
+
- uses: actions/checkout@v4
|
|
103
|
+
- uses: pullfrog/pullfrog@v0
|
|
90
104
|
with:
|
|
91
105
|
prompt: ${{ inputs.prompt }}
|
|
92
106
|
env:
|
|
93
|
-
# add API keys for the LLM provider(s) you want to use
|
|
94
107
|
ANTHROPIC_API_KEY: ${{ secrets.ANTHROPIC_API_KEY }}
|
|
95
|
-
OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }}
|
|
96
|
-
GEMINI_API_KEY: ${{ secrets.GEMINI_API_KEY }}
|
|
97
|
-
XAI_API_KEY: ${{ secrets.XAI_API_KEY }}
|
|
98
|
-
DEEPSEEK_API_KEY: ${{ secrets.DEEPSEEK_API_KEY }}
|
|
99
|
-
OPENROUTER_API_KEY: ${{ secrets.OPENROUTER_API_KEY }}
|
|
100
|
-
MOONSHOT_API_KEY: ${{ secrets.MOONSHOT_API_KEY }}
|
|
101
|
-
KIMI_API_KEY: ${{ secrets.KIMI_API_KEY }}
|
|
102
|
-
|
|
103
108
|
```
|
|
104
109
|
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
#### 2. Create `triggers.yml`
|
|
108
|
-
|
|
109
|
-
Create a file at `.github/workflows/triggers.yml`. This workflow listens for GitHub events and calls the `pullfrog.yml` workflow with the event data.
|
|
110
|
-
|
|
111
|
-
```yaml
|
|
112
|
-
name: Agent Triggers
|
|
113
|
-
|
|
114
|
-
on:
|
|
115
|
-
issue_comment:
|
|
116
|
-
types: [created]
|
|
117
|
-
pull_request_review_comment:
|
|
118
|
-
types: [created]
|
|
119
|
-
issues:
|
|
120
|
-
types: [opened, assigned]
|
|
121
|
-
pull_request_review:
|
|
122
|
-
types: [submitted]
|
|
123
|
-
# add other triggers as needed
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
jobs:
|
|
127
|
-
pullfrog:
|
|
128
|
-
|
|
129
|
-
# trigger conditions (e.g. only run if @pullfrog is mentioned)
|
|
130
|
-
if: contains(github.event.comment.body, '@pullfrog') || contains(github.event.issue.body, '@pullfrog')
|
|
110
|
+
The action also exposes a `result` output that subsequent steps can consume. See [CI integration](https://docs.pullfrog.com/headless-action) for the full guide.
|
|
131
111
|
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
contents: read
|
|
135
|
-
uses: ./.github/workflows/pullfrog.yml
|
|
136
|
-
with:
|
|
137
|
-
# pass the full event payload as the prompt
|
|
138
|
-
prompt: ${{ toJSON(github.event) }}
|
|
139
|
-
secrets: inherit
|
|
140
|
-
```
|
|
141
|
-
|
|
142
|
-
</details>
|
|
143
|
-
-->
|
|
144
|
-
|
|
145
|
-
## Standalone Usage
|
|
146
|
-
|
|
147
|
-
You can also use `pullfrog/pullfrog` as a step in your own workflows. The action exposes a `result` output that can be consumed by subsequent steps.
|
|
148
|
-
|
|
149
|
-
### Example: Auto-generate release notes on new tags
|
|
112
|
+
<details>
|
|
113
|
+
<summary><strong>Example: auto-generate release notes on new tags</strong></summary>
|
|
150
114
|
|
|
151
115
|
```yaml
|
|
152
116
|
name: Release
|
|
@@ -189,7 +153,10 @@ jobs:
|
|
|
189
153
|
NOTES: ${{ steps.notes.outputs.result }}
|
|
190
154
|
```
|
|
191
155
|
|
|
192
|
-
|
|
156
|
+
</details>
|
|
157
|
+
|
|
158
|
+
<details>
|
|
159
|
+
<summary><strong>Example: prompt from a file</strong></summary>
|
|
193
160
|
|
|
194
161
|
For longer prompts you want to version and reuse, commit the prompt text to the repo and pass its path with `prompt_file` instead of inlining it. The path is resolved relative to `GITHUB_WORKSPACE`, and it is mutually exclusive with `prompt` β set exactly one.
|
|
195
162
|
|
|
@@ -203,56 +170,11 @@ For longer prompts you want to version and reuse, commit the prompt text to the
|
|
|
203
170
|
ANTHROPIC_API_KEY: ${{ secrets.ANTHROPIC_API_KEY }}
|
|
204
171
|
```
|
|
205
172
|
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
You can force the agent to return structured JSON output by providing a JSON schema. This allows you to reliably parse and use the agent's response in subsequent workflow steps.
|
|
209
|
-
|
|
210
|
-
You can define your JSON schema directly or you can use any validation library that converts to JSON Schema. Here's an example using [Zod](https://zod.dev):
|
|
211
|
-
|
|
212
|
-
```yaml
|
|
213
|
-
name: Release Check
|
|
214
|
-
on:
|
|
215
|
-
pull_request:
|
|
216
|
-
types: [closed]
|
|
217
|
-
|
|
218
|
-
jobs:
|
|
219
|
-
check-release:
|
|
220
|
-
if: github.event.pull_request.merged == true
|
|
221
|
-
runs-on: ubuntu-latest
|
|
222
|
-
steps:
|
|
223
|
-
- uses: actions/checkout@v4
|
|
173
|
+
</details>
|
|
224
174
|
|
|
225
|
-
|
|
226
|
-
|
|
175
|
+
<details>
|
|
176
|
+
<summary><strong>Structured output</strong></summary>
|
|
227
177
|
|
|
228
|
-
|
|
229
|
-
id: schema
|
|
230
|
-
run: |
|
|
231
|
-
node -e '
|
|
232
|
-
import { z } from "zod";
|
|
233
|
-
import { setOutput } from "@actions/core";
|
|
234
|
-
const schema = z.object({
|
|
235
|
-
version: z.string().describe("Semantic version number (e.g. 1.0.0)"),
|
|
236
|
-
isBreaking: z.boolean().describe("Whether this release contains breaking changes"),
|
|
237
|
-
changelog: z.array(z.string()).describe("List of changes in this release"),
|
|
238
|
-
});
|
|
239
|
-
setOutput("schema", JSON.stringify(z.toJSONSchema(schema)));
|
|
240
|
-
'
|
|
241
|
-
|
|
242
|
-
- name: Analyze PR
|
|
243
|
-
id: analysis
|
|
244
|
-
uses: pullfrog/pullfrog@v0
|
|
245
|
-
with:
|
|
246
|
-
prompt: |
|
|
247
|
-
Analyze this PR and determine semantic versioning impact.
|
|
248
|
-
Return a JSON object matching the provided schema.
|
|
249
|
-
output_schema: ${{ steps.schema.outputs.schema }}
|
|
250
|
-
env:
|
|
251
|
-
ANTHROPIC_API_KEY: ${{ secrets.ANTHROPIC_API_KEY }}
|
|
178
|
+
Pass a JSON Schema via the `output_schema` input to make the agent's output required and validated β the bridge between an agent's reasoning and the hard steps that follow it. See [capturing agent output](https://docs.pullfrog.com/headless-action#capturing-agent-output) for the details and a worked example.
|
|
252
179
|
|
|
253
|
-
|
|
254
|
-
run: |
|
|
255
|
-
# Parse the JSON result using fromJSON()
|
|
256
|
-
echo "Version: ${{ fromJSON(steps.analysis.outputs.result).version }}"
|
|
257
|
-
echo "Breaking: ${{ fromJSON(steps.analysis.outputs.result).isBreaking }}"
|
|
258
|
-
```
|
|
180
|
+
</details>
|