GitHub's cross-repository code-review preview can use related public repositories for context. That does not mean every private repository you can access becomes available to the feature, nor does technical access imply permission to publish code from it. Keep retrieval scope, authorisation and public explanation as three separate decisions.
Read the supported source scope
The announcement describes a reviewer drawing on related public repositories, including dependent code and documentation. That can help explain an interface used elsewhere. It is not a blanket statement about all repositories belonging to a user or organisation.
Check the current documentation and settings before designing a workflow around cross-repository context. A future expansion of support would require a new review of access and data handling. Do not let a feature name stand in for an actual permission map.
Distinguish visibility from relevance
A public repository may be readable but irrelevant. A useful review should connect the proposed change to a concrete consumer, contract or documented behaviour. Pulling in a large unrelated codebase can increase confusion without improving evidence.
For an API change, identify the public interface and the specific dependent use that could break. Check versions and branches. A consumer on an old release may not describe the current contract. Context is useful when its relationship to the change is explicit.
Three boundaries around code context
A conceptual information-flow review, not a claim that a feature reads every repository in an account.
Retrieval
- Supported source scope
Check which repositories the current feature can use.
- Effective access
Verify the account and organisation controls that apply.
Publication
- Necessary context
Share only what the task actually requires.
- Public output
Review licences and confidentiality before quoting or linking.
Permission to read code and permission to publish it are different questions.
Public does not mean untrusted text becomes instructions
A public README, issue or code comment can contain inaccurate or malicious directions. Treat retrieved content as task data, not as authority to change tool permissions or reveal secrets. The reviewer's instruction hierarchy and application permissions should remain intact.
Use a harmless fixture if you want to evaluate this boundary. Place an obviously unrelated instruction in a disposable public document and check whether the review stays on task. Do not use real credentials or attempt to exploit another project's live automation.
Scroll the table horizontally to see all columns.
| Question | Evidence | Mistake to avoid |
|---|---|---|
| Can the feature use this source? | Current supported scope and settings | Assuming every accessible repo is included |
| Is the source relevant? | Concrete dependency or documented contract | Treating search similarity as impact |
| Is it current? | Version, branch and date | Mixing incompatible releases |
| May the output quote it? | Licence and confidentiality review | Equating read access with publication rights |
| Is the instruction trustworthy? | Source role and task boundary | Following commands embedded in retrieved data |
Explain private lessons with independent examples
If a private project taught you about cache identity, migrations or retries, the public lesson can use an invented application and freshly written code. Keep the algorithmic concept while removing internal names, paths, prompts, endpoints and customer context. Avoid a cosmetic rename of an otherwise private source excerpt.
Review screenshots too. A crop can still expose browser tabs, project identifiers or data in the background. An explanatory diagram is often more useful than a production dashboard when the lesson concerns a general state transition or trust boundary.
Review the final diff and final answer
Check what the agent actually changed and what it plans to report. A clean code patch can be followed by a summary that accidentally includes a private URL or credential-shaped value. Confidentiality review should cover generated documents, references and image captions as well as source files.
For public code references, link to the exact relevant project or documentation and respect its licence. Do not claim authorship of a third-party implementation. For private examples, cite public standards that support the general lesson rather than exposing the original repository.
Keep a bounded evidence claim
A useful conclusion says that a specific public consumer or document suggests a compatibility risk, with the relevant version and line of reasoning. It does not claim exhaustive impact analysis across every private dependency.
Cross-repository context can improve review quality when it is relevant and permitted. Its safe use depends on the same principles as any information flow: know the source, preserve the boundary and publish only what you are authorised to share.
Frequently asked questions
Does this preview automatically read all my private repositories? The November 17 announcement describes cross-repository context in public preview for public repositories. Do not infer broader private-repository support from that statement.
Can I publish a private code excerpt if my account can read it? Not merely because you have technical access. Publication needs the appropriate ownership, licence and confidentiality permission, and unnecessary sensitive details should be omitted.
How can I explain a private engineering lesson publicly? Describe the general problem and use an independently written toy example with invented names and data. Review it to ensure private code, endpoints, prompts and identifying details have not carried over.
Sources
- GitHub, November 17: adaptive review and secret detection
- GitHub: repository licensing
- Related practical guide
Technical references checked .



