trace-pilot
When text is copied in VS Code or captured by the Trace-Pilot Chrome extension, Trace-Pilot stores the original source data in a Git-backed repository and keeps a trace marker with the copied content. Later, inside VS Code, that marker can be resolved back to the original source so you can inspect where the content came from and recover its surrounding context. This helps teams keep copied code and text explainable, auditable, and easier to maintain over time. StatusTrace-Pilot is still under development and has not been publicly released yet. PlatformThis tool currently runs on Linux. Related ProjectThe Chrome extension side of Trace-Pilot is provided as the companion project https://github.com/otinpan/trace-pilot-chrome It captures content from the browser, stores source data, and passes trace markers that can later be resolved by this VS Code extension. What This Repository ContainsThis repository contains the VS Code extension side of Trace-Pilot. Its responsibilities include:
Supported SourcesThe VS Code extension currently works with source data from:
How It Works
Main FeaturesTrace-Pilot adds commands to the editor title area in VS Code. From left to right:
Copy And StoreWhen you copy selected text in a VS Code editor, Trace-Pilot stores both the copied text and its original source data in Git, then writes a trace marker back to the clipboard. This works for normal text files as well as PDFs opened in VS Code. Copy Text From A VS Code EditorWhen you copy text from a file in VS Code, Trace-Pilot stores the copied selection together with the full source file.
Copy Text From A PDF In VS CodeWhen you copy text while viewing a PDF in VS Code, Trace-Pilot stores the copied selection together with the original PDF data.
Open SourceWhen Trace-Pilot markers are present in a file, VS Code shows CodeLens and hover actions such as Selecting
Open PromptCardsFor prompt-based sources such as ChatGPT captures and coding-agent traces, Trace-Pilot can show PromptCards display stored prompt/output pairs from Git. You can browse the collected cards and open the related source data for each one.
Guess PromptAfter you modify files, clicking Trace-Pilot also generates links for the changed locations so the inferred prompt can be inspected alongside the affected code. This feature requires an OpenAI API key. You can set it from the Command Palette with
Save DiffTrace-Pilot watches file edits and can flush recorded diffs into its trace data using This helps preserve the relationship between code changes and the prompts or actions that likely produced them. Why Use ItCopied text and code often lose their source context. Trace-Pilot helps preserve that context by storing:
It is also more resilient to link rot because the source data is preserved in your own Git repository rather than relying only on external URLs. This is especially useful for:
UsageTrace-Pilot has not been released yet, but the intended workflow is:
OpenAI API Key
To set it in VS Code:
The key is stored securely using VS Code secret storage. If you prefer, you can also launch VS Code with Features By SourceVS Code FilesFor normal files opened in VS Code, Trace-Pilot stores the selected text together with the full source file so the original context can be restored later. PDFs In VS CodeFor PDFs opened in VS Code, Trace-Pilot stores the copied selection together with the original PDF and can reopen it with the copied region highlighted. ChatGPTWhen trace data captured from ChatGPT by
Google SheetsWhen trace data captured from Google Sheets by
Chrome PDFsWhen trace data captured from PDFs in Chrome by
Static Web PagesWhen trace data captured from static web pages by
DevelopmentIf you are working on the extension locally:
|








