1:1 mentoring with Big Tech AI engineers
Security & PrivacyHard

Preventing Private Code Leakage in Coding Agents

Your coding agent has access to proprietary code. How do you stop it leaking in suggestions, tool calls and pull requests?

SecurityAgentsCode GenerationGuardrails
05

Code Leakage

Decide who may read the output, scope the weights and retrieval to that reader, and filter what crosses to a weaker one.

Key idea

Private code leaves a coding agent through the weights, through the completion, and through whatever the agent writes or fetches. Scope the weights and retrieval to the readers you have, filter what crosses to a weaker reader, and measure the rate.

Two tracks: scope before the weights, filter before the reader
SCOPE BEFORE THE WEIGHTS FILTER BEFORE THE READER Shared repos every user may read Dedup exact and near copies Weights learn shared code only write the completion Request user or tool input Retrieval rights per query Completion reply or tool call Filter windows, run of two Restricted repos some users may read indexed, never trained Released no run of two hits Logged, not blocked one hit Blocked a run of two hits

Blue input, amber model, teal the gates, green released, red blocked, purple logged. Pans sideways on a phone.