diff --git a/agents/instructions.ts b/agents/instructions.ts index e9b5437..15e2f85 100644 --- a/agents/instructions.ts +++ b/agents/instructions.ts @@ -35,6 +35,7 @@ If asked to show environment variables, only display non-sensitive system variab ## MCP Servers eagerly inspect your MCP servers to determine what tools are available to you, especially ${ghPullfrogMcpName} +tools in your prompt may by delimited by a forward slash (server name)/(tool name) for example: ${ghPullfrogMcpName}/create_issue_comment do not under any circumstances use the github cli (\`gh\`). find the corresponding tool from ${ghPullfrogMcpName} instead. do not try to handle github auth- treat ${ghPullfrogMcpName} as a black box that you can use to interact with github. diff --git a/entry.js b/entry.js index bac184f..13200db 100755 --- a/entry.js +++ b/entry.js @@ -41110,18 +41110,17 @@ function createMcpConfigs(githubInstallationToken) { } // modes.ts -var ghPullfrogMcpName2 = "gh-pullfrog"; var modes = [ { name: "Plan", description: "Create plans, break down tasks, outline steps, analyze requirements, understand scope of work, or provide task breakdowns", prompt: `Follow these steps: 1. Before beginning, take some time to learn about the codebase. Read the AGENTS.md file if it exists. Understand how to install dependencies, run tests, run builds, and make changes according to the best practices of the codebase. -2. Create initial response comment using mcp__${ghPullfrogMcpName2}__create_issue_comment saying "I'll {summary of request}" and save the commentId +2. Create initial response comment using ${ghPullfrogMcpName}/create_issue_comment saying "I'll {summary of request}" and save the commentId 3. Analyze the request and break it down into clear, actionable tasks 4. Consider dependencies, potential challenges, and implementation order 5. Create a structured plan with clear milestones -6. Update your comment using mcp__${ghPullfrogMcpName2}__edit_issue_comment with the commentId to present the plan in a clear, organized format +6. Update your comment using ${ghPullfrogMcpName}/edit_issue_comment with the commentId to present the plan in a clear, organized format 7. Continue updating the same comment as needed (never create additional comments - always use edit_issue_comment)` }, { @@ -41129,22 +41128,22 @@ var modes = [ description: "Implement, build, create, or develop code changes; make specific changes to files or features; execute a plan; or handle tasks with specific implementation details", prompt: `Follow these steps: 1. Before beginning, take some time to learn about the codebase. Read the AGENTS.md file if it exists. Understand how to install dependencies, run tests, run builds, and make changes according to the best practices of the codebase. -2. Create initial response comment using mcp__${ghPullfrogMcpName2}__create_issue_comment saying "I'll {summary of request}" and save the commentId +2. Create initial response comment using ${ghPullfrogMcpName}/create_issue_comment saying "I'll {summary of request}" and save the commentId 3. Understand the requirements and any existing plan 4. Make the necessary code changes 5. Test your changes to ensure they work correctly -6. Update your comment using mcp__${ghPullfrogMcpName2}__edit_issue_comment with the commentId to share progress and results +6. Update your comment using ${ghPullfrogMcpName}/edit_issue_comment with the commentId to share progress and results 7. Continue updating the same comment as you make progress (never create additional comments - always use edit_issue_comment)` }, { name: "Review", description: "Review code, PRs, or implementations; provide feedback or suggestions; identify issues; or check code quality, style, and correctness", prompt: `Follow these steps: -1. Create initial response comment using mcp__${ghPullfrogMcpName2}__create_issue_comment saying "I'll review this" and save the commentId -2. Get PR info with mcp__${ghPullfrogMcpName2}__get_pull_request (this automatically prepares the repository by fetching and checking out the PR branch) +1. Create initial response comment using ${ghPullfrogMcpName}/create_issue_comment saying "I'll review this" and save the commentId +2. Get PR info with ${ghPullfrogMcpName}/get_pull_request (this automatically prepares the repository by fetching and checking out the PR branch) 3. View diff: git diff origin/...origin/ (use line numbers from this for inline comments, replace and with 'base' and 'head' from PR info) 4. Read files from the checked-out PR branch to understand the implementation -5. Update your comment using mcp__${ghPullfrogMcpName2}__edit_issue_comment with findings as you review +5. Update your comment using ${ghPullfrogMcpName}/edit_issue_comment with findings as you review 6. When submitting review: use the 'comments' array for ALL specific code issues - include the file path and line position from the diff 7. Only use the 'body' field for a brief summary (1-2 sentences) or for feedback that doesn't apply to a specific code location 8. Continue updating the same comment as needed (never create additional comments - always use edit_issue_comment)` @@ -41153,9 +41152,9 @@ var modes = [ name: "Prompt", description: "Fallback for tasks that don't fit other workflows, direct prompts via comments, or requests requiring general assistance without a specific workflow pattern", prompt: `Follow these steps: -1. Create an initial "Progress Comment" using mcp__${ghPullfrogMcpName2}__create_issue_comment saying "I'll {summary of request}" and save the commentId +1. Create an initial "Progress Comment" using ${ghPullfrogMcpName}/create_issue_comment saying "I'll {summary of request}" and save the commentId 2. Perform the requested task. Only take action if you have high confidence that you understand what is being asked. If you are not sure, ask for clarification. Take stock of the tools at your disposal. -3. As your work progresses, update your Progress Comment to share progress and results. Using mcp__${ghPullfrogMcpName2}__edit_issue_comment and the commentId you saved earlier. Do not create additional comments unless you are explicitly asked to do so. +3. As your work progresses, update your Progress Comment to share progress and results. Using ${ghPullfrogMcpName}/edit_issue_comment and the commentId you saved earlier. Do not create additional comments unless you are explicitly asked to do so. 4. When you finish the task, update the Progress Comment a final time to confirm completion. If you created any issues, PRs, etc, include appropriate links to it here.` } ]; @@ -41195,6 +41194,7 @@ If asked to show environment variables, only display non-sensitive system variab ## MCP Servers eagerly inspect your MCP servers to determine what tools are available to you, especially ${ghPullfrogMcpName} +tools in your prompt may by delimited by a forward slash (server name)/(tool name) for example: ${ghPullfrogMcpName}/create_issue_comment do not under any circumstances use the github cli (\`gh\`). find the corresponding tool from ${ghPullfrogMcpName} instead. do not try to handle github auth- treat ${ghPullfrogMcpName} as a black box that you can use to interact with github. diff --git a/fixtures/basic.txt b/fixtures/basic.txt index a263739..8766da1 100644 --- a/fixtures/basic.txt +++ b/fixtures/basic.txt @@ -1 +1 @@ -add a comment to https://github.com/pullfrogai/scratch/issues/21 and say Shawn > David +choose a random animal emoji. add a comment to https://github.com/pullfrogai/scratch/issues/21 containing 50 of that emoji. diff --git a/modes.ts b/modes.ts index 028a4be..56a7a0c 100644 --- a/modes.ts +++ b/modes.ts @@ -1,5 +1,4 @@ -// MCP name constant - matches action/mcp/config.ts -const ghPullfrogMcpName = "gh-pullfrog"; +import { ghPullfrogMcpName } from "./mcp/config.ts"; export const modes = [ { @@ -8,11 +7,11 @@ export const modes = [ "Create plans, break down tasks, outline steps, analyze requirements, understand scope of work, or provide task breakdowns", prompt: `Follow these steps: 1. Before beginning, take some time to learn about the codebase. Read the AGENTS.md file if it exists. Understand how to install dependencies, run tests, run builds, and make changes according to the best practices of the codebase. -2. Create initial response comment using mcp__${ghPullfrogMcpName}__create_issue_comment saying "I'll {summary of request}" and save the commentId +2. Create initial response comment using ${ghPullfrogMcpName}/create_issue_comment saying "I'll {summary of request}" and save the commentId 3. Analyze the request and break it down into clear, actionable tasks 4. Consider dependencies, potential challenges, and implementation order 5. Create a structured plan with clear milestones -6. Update your comment using mcp__${ghPullfrogMcpName}__edit_issue_comment with the commentId to present the plan in a clear, organized format +6. Update your comment using ${ghPullfrogMcpName}/edit_issue_comment with the commentId to present the plan in a clear, organized format 7. Continue updating the same comment as needed (never create additional comments - always use edit_issue_comment)`, }, { @@ -21,11 +20,11 @@ export const modes = [ "Implement, build, create, or develop code changes; make specific changes to files or features; execute a plan; or handle tasks with specific implementation details", prompt: `Follow these steps: 1. Before beginning, take some time to learn about the codebase. Read the AGENTS.md file if it exists. Understand how to install dependencies, run tests, run builds, and make changes according to the best practices of the codebase. -2. Create initial response comment using mcp__${ghPullfrogMcpName}__create_issue_comment saying "I'll {summary of request}" and save the commentId +2. Create initial response comment using ${ghPullfrogMcpName}/create_issue_comment saying "I'll {summary of request}" and save the commentId 3. Understand the requirements and any existing plan 4. Make the necessary code changes 5. Test your changes to ensure they work correctly -6. Update your comment using mcp__${ghPullfrogMcpName}__edit_issue_comment with the commentId to share progress and results +6. Update your comment using ${ghPullfrogMcpName}/edit_issue_comment with the commentId to share progress and results 7. Continue updating the same comment as you make progress (never create additional comments - always use edit_issue_comment)`, }, { @@ -33,11 +32,11 @@ export const modes = [ description: "Review code, PRs, or implementations; provide feedback or suggestions; identify issues; or check code quality, style, and correctness", prompt: `Follow these steps: -1. Create initial response comment using mcp__${ghPullfrogMcpName}__create_issue_comment saying "I'll review this" and save the commentId -2. Get PR info with mcp__${ghPullfrogMcpName}__get_pull_request (this automatically prepares the repository by fetching and checking out the PR branch) +1. Create initial response comment using ${ghPullfrogMcpName}/create_issue_comment saying "I'll review this" and save the commentId +2. Get PR info with ${ghPullfrogMcpName}/get_pull_request (this automatically prepares the repository by fetching and checking out the PR branch) 3. View diff: git diff origin/...origin/ (use line numbers from this for inline comments, replace and with 'base' and 'head' from PR info) 4. Read files from the checked-out PR branch to understand the implementation -5. Update your comment using mcp__${ghPullfrogMcpName}__edit_issue_comment with findings as you review +5. Update your comment using ${ghPullfrogMcpName}/edit_issue_comment with findings as you review 6. When submitting review: use the 'comments' array for ALL specific code issues - include the file path and line position from the diff 7. Only use the 'body' field for a brief summary (1-2 sentences) or for feedback that doesn't apply to a specific code location 8. Continue updating the same comment as needed (never create additional comments - always use edit_issue_comment)`, @@ -47,9 +46,9 @@ export const modes = [ description: "Fallback for tasks that don't fit other workflows, direct prompts via comments, or requests requiring general assistance without a specific workflow pattern", prompt: `Follow these steps: -1. Create an initial "Progress Comment" using mcp__${ghPullfrogMcpName}__create_issue_comment saying "I'll {summary of request}" and save the commentId +1. Create an initial "Progress Comment" using ${ghPullfrogMcpName}/create_issue_comment saying "I'll {summary of request}" and save the commentId 2. Perform the requested task. Only take action if you have high confidence that you understand what is being asked. If you are not sure, ask for clarification. Take stock of the tools at your disposal. -3. As your work progresses, update your Progress Comment to share progress and results. Using mcp__${ghPullfrogMcpName}__edit_issue_comment and the commentId you saved earlier. Do not create additional comments unless you are explicitly asked to do so. +3. As your work progresses, update your Progress Comment to share progress and results. Using ${ghPullfrogMcpName}/edit_issue_comment and the commentId you saved earlier. Do not create additional comments unless you are explicitly asked to do so. 4. When you finish the task, update the Progress Comment a final time to confirm completion. If you created any issues, PRs, etc, include appropriate links to it here.`, }, ] as const; diff --git a/todo.md b/todo.md index 7673135..206e428 100644 --- a/todo.md +++ b/todo.md @@ -3,7 +3,6 @@ [] try to find heavy claude code user [] investigate including terminal output from bash commands as collapsed groups [] test initialization trade offs for pullfrog.yml -[] investigate mcp naming convention ## MAYBE @@ -11,6 +10,7 @@ ## DONE +[x] investigate mcp naming convention [x] input just accepts one key for API key [x] look into trigger.yml without installation [x] cancel installation token at the end of github action