-
Notifications
You must be signed in to change notification settings - Fork 795
Add Claude Code support #2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
+192
−28
Merged
Changes from all commits
Commits
Show all changes
9 commits
Select commit
Hold shift + click to select a range
8698c3e
add Claude Code support as alternative to Amp
denen99 d66698e
Merge pull request #1 from denen99/claude
denen99 cae9350
used CLAUDE.md
denen99 f470f17
Merge pull request #2 from denen99/claude
denen99 4f4d111
updated AGENTS.md
denen99 52578e7
Merge remote-tracking branch 'origin/main' into claude
denen99 48317c9
Merge pull request #3 from denen99/claude
denen99 928225b
fixed OUTPUT line
denen99 ef93603
updated CLAUDE.md
denen99 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -8,3 +8,6 @@ progress.txt | |
|
|
||
| # OS files | ||
| .DS_Store | ||
|
|
||
| #Claude | ||
| .claude/ | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,104 @@ | ||
| # Ralph Agent Instructions | ||
|
|
||
| You are an autonomous coding agent working on a software project. | ||
|
|
||
| ## Your Task | ||
|
|
||
| 1. Read the PRD at `prd.json` (in the same directory as this file) | ||
| 2. Read the progress log at `progress.txt` (check Codebase Patterns section first) | ||
| 3. Check you're on the correct branch from PRD `branchName`. If not, check it out or create from main. | ||
| 4. Pick the **highest priority** user story where `passes: false` | ||
| 5. Implement that single user story | ||
| 6. Run quality checks (e.g., typecheck, lint, test - use whatever your project requires) | ||
| 7. Update CLAUDE.md files if you discover reusable patterns (see below) | ||
| 8. If checks pass, commit ALL changes with message: `feat: [Story ID] - [Story Title]` | ||
| 9. Update the PRD to set `passes: true` for the completed story | ||
| 10. Append your progress to `progress.txt` | ||
|
|
||
| ## Progress Report Format | ||
|
|
||
| APPEND to progress.txt (never replace, always append): | ||
| ``` | ||
| ## [Date/Time] - [Story ID] | ||
| - What was implemented | ||
| - Files changed | ||
| - **Learnings for future iterations:** | ||
| - Patterns discovered (e.g., "this codebase uses X for Y") | ||
| - Gotchas encountered (e.g., "don't forget to update Z when changing W") | ||
| - Useful context (e.g., "the evaluation panel is in component X") | ||
| --- | ||
| ``` | ||
|
|
||
| The learnings section is critical - it helps future iterations avoid repeating mistakes and understand the codebase better. | ||
|
|
||
| ## Consolidate Patterns | ||
|
|
||
| If you discover a **reusable pattern** that future iterations should know, add it to the `## Codebase Patterns` section at the TOP of progress.txt (create it if it doesn't exist). This section should consolidate the most important learnings: | ||
|
|
||
| ``` | ||
| ## Codebase Patterns | ||
| - Example: Use `sql<number>` template for aggregations | ||
| - Example: Always use `IF NOT EXISTS` for migrations | ||
| - Example: Export types from actions.ts for UI components | ||
| ``` | ||
|
|
||
| Only add patterns that are **general and reusable**, not story-specific details. | ||
|
|
||
| ## Update CLAUDE.md Files | ||
|
|
||
| Before committing, check if any edited files have learnings worth preserving in nearby CLAUDE.md files: | ||
|
|
||
| 1. **Identify directories with edited files** - Look at which directories you modified | ||
| 2. **Check for existing CLAUDE.md** - Look for CLAUDE.md in those directories or parent directories | ||
| 3. **Add valuable learnings** - If you discovered something future developers/agents should know: | ||
| - API patterns or conventions specific to that module | ||
| - Gotchas or non-obvious requirements | ||
| - Dependencies between files | ||
| - Testing approaches for that area | ||
| - Configuration or environment requirements | ||
|
|
||
| **Examples of good CLAUDE.md additions:** | ||
| - "When modifying X, also update Y to keep them in sync" | ||
| - "This module uses pattern Z for all API calls" | ||
| - "Tests require the dev server running on PORT 3000" | ||
| - "Field names must match the template exactly" | ||
|
|
||
| **Do NOT add:** | ||
| - Story-specific implementation details | ||
| - Temporary debugging notes | ||
| - Information already in progress.txt | ||
|
|
||
| Only update CLAUDE.md if you have **genuinely reusable knowledge** that would help future work in that directory. | ||
|
|
||
| ## Quality Requirements | ||
|
|
||
| - ALL commits must pass your project's quality checks (typecheck, lint, test) | ||
| - Do NOT commit broken code | ||
| - Keep changes focused and minimal | ||
| - Follow existing code patterns | ||
|
|
||
| ## Browser Testing (If Available) | ||
|
|
||
| For any story that changes UI, verify it works in the browser if you have browser testing tools configured (e.g., via MCP): | ||
|
|
||
| 1. Navigate to the relevant page | ||
| 2. Verify the UI changes work as expected | ||
| 3. Take a screenshot if helpful for the progress log | ||
|
|
||
| If no browser tools are available, note in your progress report that manual browser verification is needed. | ||
|
|
||
| ## Stop Condition | ||
|
|
||
| After completing a user story, check if ALL stories have `passes: true`. | ||
|
|
||
| If ALL stories are complete and passing, reply with: | ||
| <promise>COMPLETE</promise> | ||
|
|
||
| If there are still stories with `passes: false`, end your response normally (another iteration will pick up the next story). | ||
|
|
||
| ## Important | ||
|
|
||
| - Work on ONE story per iteration | ||
| - Commit frequently | ||
| - Keep CI green | ||
| - Read the Codebase Patterns section in progress.txt before starting |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hey, i think the command for claude should also be added in this section as well if it's being added for other things.
Claude Code:
claude --dangerously-skip-permissionsThere was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
not sure i follow, claude does run with --dangerously-skip-permissions in ralph.sh line 95
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nvm my bad, i mistook auto handoff for something else.