Skip to content

Add comprehensive scope keys documentation #1122

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

Draft
wants to merge 4 commits into
base: develop
Choose a base branch
from

Conversation

codegen-sh[bot]
Copy link
Contributor

@codegen-sh codegen-sh bot commented Jun 3, 2025

This PR adds detailed documentation explaining how Codegen's scope keys work and why they're important for context inheritance.

What's Added

📚 New Documentation Page: docs/architecture/scope-keys.mdx

  • Clear explanation of what scope keys are and why they matter
  • Platform-specific scope key formats (Slack, Linear, GitHub, API)
  • Real-world examples showing good vs bad interaction patterns
  • Best practices and troubleshooting guide
  • Technical implementation details

🗂️ Updated Navigation: Added new "Architecture" section to docs navigation

Key Concepts Covered

  • Slack: slack-{thread_timestamp} - Groups messages in same thread
  • Linear: linear-{issue_id} - Groups work on same ticket
  • GitHub: github-pr-{pr_number}-{repo_id} - Groups work on same PR
  • API: Derived from task timeline or falls back to run ID

Why This Matters

This documentation addresses the common user confusion about when Codegen creates new PRs vs updating existing ones. Users will now understand:

  • How to continue conversations in the same scope
  • Why context inheritance works the way it does
  • How to avoid accidentally breaking scope chains
  • Best practices for working with Codegen across platforms

The examples clearly show the difference between good scope usage (updating existing PRs) and bad scope usage (creating unnecessary new PRs), which directly addresses the issue mentioned in the Slack thread.


💻 View my workAbout Codegen

- Created detailed explanation of how scope keys work across platforms
- Added examples for Slack, Linear, GitHub, and API interactions
- Explained why scope keys matter for context inheritance
- Included best practices and troubleshooting guide
- Updated docs navigation to include new architecture section
@codegen-sh codegen-sh bot requested a review from jayhack June 3, 2025 18:26
codegen-sh bot added 3 commits June 3, 2025 18:26
- Renamed from 'scope-keys' to 'context-inheritance'
- Removed technical terms like 'scope key' throughout
- Focused on when users should expect context vs fresh starts
- Added clear examples of good vs bad interaction patterns
- Emphasized practical scenarios and troubleshooting
Copy link

codecov bot commented Jun 3, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

✅ All tests successful. No failed tests found.

🚀 New features to boost your workflow:
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

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.

0 participants