{
  "markdown": "# ContextBridge\n\n[![npm version](https://img.shields.io/npm/v/%40contextbridge_ai%2Fmcp)](https://www.npmjs.com/package/@contextbridge_ai/mcp)\n[![MCP Registry](https://img.shields.io/badge/MCP%20Registry-active-0B5FFF)](https://registry.modelcontextprotocol.io/?q=io.github.prateekg7/context-bridge)\n\nContextBridge is a context portability tool for AI conversations. This package publishes the MCP server surface: it compresses an in-progress conversation into a structured context block that preserves the user's goal, confirmed decisions, current state, open threads, artifacts, constraints, recent pivots, and suggested next step, then formats that handoff so another AI can continue without forcing the user to restate everything.\n\nThe published npm artifact is the stdio MCP server for Claude Desktop, agent runtimes, and other MCP-compatible hosts. The browser extension runtime is developed in the same repository, but it is not part of this MCP Registry publishing flow.\n\n## Published Links\n\n- npm package: [@contextbridge_ai/mcp](https://www.npmjs.com/package/@contextbridge_ai/mcp)\n- MCP Registry search: [io.github.prateekg7/context-bridge](https://registry.modelcontextprotocol.io/?q=io.github.prateekg7/context-bridge)\n- MCP Registry API: [latest version JSON](https://registry.modelcontextprotocol.io/v0.1/servers/io.github.prateekg7%2Fcontext-bridge/versions/latest)\n- Source repository: [prateekg7/Context-Bridge](https://github.com/prateekg7/Context-Bridge)\n\n## Install In Claude Desktop\n\nAdd this to your Claude Desktop MCP config (`~/Library/Application Support/Claude/claude_desktop_config.json`):\n\n```json\n{\n  \"mcpServers\": {\n    \"contextbridge\": {\n      \"command\": \"npx\",\n      \"args\": [\"-y\", \"@contextbridge_ai/mcp\"],\n      \"env\": {\n        \"GROQ_API_KEY\": \"your_groq_api_key_here\"\n      }\n    }\n  }\n}\n```\n\nOr with OpenAI:\n\n```json\n{\n  \"mcpServers\": {\n    \"contextbridge\": {\n      \"command\": \"npx\",\n      \"args\": [\"-y\", \"@contextbridge_ai/mcp\"],\n      \"env\": {\n        \"OPENAI_API_KEY\": \"your_openai_api_key_here\",\n        \"OPENAI_MODEL\": \"gpt-4.1-mini\"\n      }\n    }\n  }\n}\n```\n\nFor a hosted no-key lane instead of BYOK:\n\n```json\n{\n  \"mcpServers\": {\n    \"contextbridge\": {\n      \"command\": \"npx\",\n      \"args\": [\"-y\", \"@contextbridge_ai/mcp\"],\n      \"env\": {\n        \"CONTEXTBRIDGE_HOSTED_URL\": \"https://your-hosted-endpoint.example/v1\",\n        \"CONTEXTBRIDGE_HOSTED_MODEL\": \"mistralai/Mistral-7B-Instruct-v0.2\"\n      }\n    }\n  }\n}\n```\n\n## Available MCP Tools\n\n### `compress_context`\n\nCompresses a raw transcript into a structured context block.\n\nParameters:\n- `transcript` (`string`, required): the raw conversation transcript to compress.\n- `provider` (`\"openai\" | \"openai-chat\" | \"google\" | \"groq\" | \"custom\" | \"hosted\"`, optional): provider override.\n- `model` (`string`, optional): model override for the selected lane.\n- `apiKey` (`string`, optional): BYOK API key override.\n- `baseUrl` (`string`, optional): API base URL override.\n- `hostedApiKey` (`string`, optional): optional auth key for the hosted lane.\n\n### `format_for_target`\n\nFormats a compressed context block for a destination platform.\n\nParameters:\n- `context_block` (`object`, required): a validated ContextBridge compressed context block.\n- `target` (`\"claude\" | \"chatgpt\" | \"gemini\"`, required): destination AI platform.\n\n### `resume_context`\n\nBuilds a destination-ready landing package from a compressed context block.\n\nParameters:\n- `context_block` (`object`, required): a validated ContextBridge compressed context block.\n- `target` (`\"claude\" | \"chatgpt\" | \"gemini\"`, required): destination AI platform.\n\n## BYOK Setup\n\nContextBridge auto-selects the OpenAI Responses lane when a BYOK key is present.\n\nEnvironment variables:\n\n```bash\nOPENAI_API_KEY=your_openai_api_key_here\nOPENAI_MODEL=gpt-4.1-mini\nOPENAI_BASE_URL=https://api.openai.com/v1\n```\n\nAdditional supported provider overrides:\n\n```bash\nGOOGLE_API_KEY=your_google_api_key_here\nGOOGLE_MODEL=gemini-2.5-pro\nGOOGLE_BASE_URL=https://generativelanguage.googleapis.com/v1beta/openai\n\nGROQ_API_KEY=your_groq_api_key_here\nGROQ_MODEL=llama-3.3-70b-versatile\nGROQ_BASE_URL=https://api.groq.com/openai/v1\n\nCONTEXTBRIDGE_API_KEY=your_custom_api_key_here\nCONTEXTBRIDGE_MODEL=your_custom_model_here\nCONTEXTBRIDGE_BASE_URL=https://your-endpoint.example/v1\nCONTEXTBRIDGE_PROVIDER=custom\n```\n\n## Hosted Lane Setup\n\nThe hosted lane is the no-key path for end users who do not bring their own provider credentials.\n\nEnvironment variables:\n\n```bash\nCONTEXTBRIDGE_HOSTED_URL=https://your-hosted-endpoint.example/v1\nCONTEXTBRIDGE_HOSTED_MODEL=mistralai/Mistral-7B-Instruct-v0.2\nCONTEXTBRIDGE_HOSTED_API_KEY=\n```\n\nSelection priority:\n1. Explicit `apiKey` option passed into compression uses the OpenAI Responses BYOK lane.\n2. `OPENAI_API_KEY` uses the OpenAI Responses BYOK lane.\n3. `CONTEXTBRIDGE_HOSTED_URL` uses the hosted lane.\n\n## Contributing\n\nContributions are welcome. The highest-leverage areas are extraction quality evaluation, browser collector resilience, destination formatting quality, hosted-lane infrastructure, and real-world handoff testing across platforms.\n\n## License\n\nMIT. See [LICENSE](./LICENSE).\n",
  "bytes": 5159,
  "sha": "2acac19feb38493fdeea2e0be16a2ea08007bd32a54280526e318a52d7fe44c3",
  "repo_slug": "prateekg7/context-bridge",
  "fonte": "repo",
  "truncated": false,
  "api": "https://agentalog.com/api/listings/mcp_io_github_prateekg7_context_bridge_32ed320c/readme"
}