The cdp:chatgpt adapter uses Chrome DevTools Protocol (CDP) to submit tracked queries to the ChatGPT web UI. It reads the rendered answer and citations.
| File | Role |
|---|---|
src/adapter.ts |
Exports cdpChatgptAdapter — the ProviderAdapter object |
src/normalize.ts |
Response normalization to standard NormalizedQueryResult |
src/connection.ts |
CDPConnectionManager — manages browser connections via CDP. healthcheck(signal?) reads Chrome’s /json/version itself (CDP.Version takes no signal) at the host’s resolved address, so an aborted connection test cancels its request |
src/screenshot.ts |
captureElementScreenshot() — captures page element screenshots |
src/targets/ |
Target-specific automation scripts |
src/targets/chatgpt.ts |
ChatGPT UI automation — navigation, query input, response extraction |
src/targets/types.ts |
CDPProviderError and target type definitions |
src/index.ts |
Re-exports public API |
This provider follows the same ProviderAdapter interface but has a more complex implementation due to browser automation:
CDPConnectionManager handles connecting to/disconnecting from Chrome instances via the DevTools Protocol.canonry cdp connect --host <host> --port <port>.retrievalStatus: unknown. The searchQueries array holds the submitted query, which supplies no evidence of a search.GroundingSource format.docs/providers/README.md — provider system overviewpackages/contracts/src/provider.ts — ProviderAdapter interface definition