Skip to content
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

Use rules (.sourcegraph/*.rule.md) in chat and auto-edit #6909

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

sqs
Copy link
Member

@sqs sqs commented Feb 1, 2025

(Experimental and WIP.)

For our code review agent (announced in EAP in https://sourcegraph.com/blog/introducing-enterprise-ai-agents), we're introducing rules that are *.rule.md files placed in .sourcegraph/ dirs in your codebase. The code review agent uses these rules to find and fix issues at code review.

This PR makes it so that Cody in the editor also reads the rules and uses them in chat, auto-edit, and inline edit for higher quality and consistency.

Docs and blog post coming soon after we've merged this and tested it in our own dev workflows.

cody-rules-chat-autoedit.mp4

image

image

TODOs

  • Editor (not sidebar) chat does not show the rules for the file in the other pane because it's not active
  • Node.js FS errors when looking for .sourcegraph

Test plan

TODO

@olafurpg olafurpg requested a review from a team February 3, 2025 09:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant