{"id":27804,"plugin_id":"plugin_asdk_app_6ab9f74baee0819183f0a726857cab76","kind":"skill","collection_source":"plugin_package","comparison_source":null,"observed_at":"2026-10-08T00:04:42.567Z","digest":"8c97d3360ff4d750d454581528e5fca6583473f8507d3c6f574b1388c3ee5696","against":null,"payload":{"description":"Plan chemical syntheses via the B12 Selenium route-search API. Use when asked to find synthetic routes / retrosynthesis for a molecule, assess whether a target is makeable, or compare disconnection strategies. Submits a target (SMILES), polls the async job, and returns ranked route families with feasibility and commercial-availability data.","included_files":[{"relative_path":"agent_loop.py","size_in_bytes":4584},{"relative_path":"reference.md","size_in_bytes":3734}],"name":"selenium-route-search","skill_md_contents":"---\nname: selenium-route-search\ndescription: Plan chemical syntheses via the B12 Selenium route-search API. Use when asked to find synthetic routes / retrosynthesis for a molecule, assess whether a target is makeable, or compare disconnection strategies. Submits a target (SMILES), polls the async job, and returns ranked route families with feasibility and commercial-availability data.\n---\n\n# Selenium Route Search\n\nPlan retrosynthetic routes for a target molecule through B12's Selenium API.\nThe API is **asynchronous**: you submit a target, it runs for minutes to hours,\nand you poll for results. Route families come back ranked, with per-reaction\nfeasibility bands and commercial-leaf data.\n\n## Prerequisites\n\nEither the hosted MCP server is registered (tools\n`quote_synthesis_assessment`, `start_synthesis_assessment`,\n`submit_synthesis_campaign`, `get_synthesis_assessment`, and the route-family\nread tools), **or** call the REST API directly with `SELENIUM_API_URL` plus a\nbearer key. Prefer the hosted MCP tools when present.\n\n## Core workflow\n\n1. **Quote once.** Call `quote_synthesis_assessment` with the SMILES, optional\n   `instructions`, and tier. An explicit request to run or assess the target is\n   authorization to proceed at the requested/default tier; do not ask for a\n   second conversational confirmation. Ask only when intent is ambiguous, the\n   quote exceeds a user-stated budget. If credits are insufficient, explain the\n   limit and stop the paid operation. The host's\n   billable tool approval remains the final approval boundary.\n2. **Start once.** Call `start_synthesis_assessment` with the returned quote id,\n   exact credit amount, and stable campaign/candidate references. Retrying the\n   same quote returns the original assessment without another debit.\n3. **For two to 100 candidates, batch once.** Call\n   `submit_synthesis_campaign` instead of fanning out quotes and starts.\n   Generate `request_reference` internally, reuse it unchanged for retries,\n   and never ask the user to invent it. Set `max_total_credits` only when the\n   user states a budget; the server validates, prices, and queues the batch.\n4. **Own progress checks.** Follow the monitoring guidance below; do not make\n   the user repeatedly ask for status. Recover batches with\n   `list_synthesis_assessments(campaign_reference=..., include_summaries=false)`.\n5. **Read progressively.** Start with the compact terminal assessment, list\n   route families, then open only the selected family that needs full detail.\n5. **Interpret the terminal state:**\n   - `completed` — all requested families solved.\n   - `partial` — some families solved (others incomplete or the job timed out);\n     the solved families are still valid results. This is common and useful.\n   - `failed` — no charge (auto-refunded). Report briefly and use the same safe\n     retry handle if the original request still applies; do not ask the user to\n     reconfirm an idempotent retry.\n   - `cancelled` — stopped on request.\n\n## Choosing a tier\n\nScout is deliberately narrower than the portfolio tiers. Basic, Standard, and\nExhaustive use the same chemistry stack with increasing breadth/depth.\n\n- **scout** — one bounded fast-lane direction (10 credits): one research pass,\n  one family, one target route, no research follow-up. Use for high-volume\n  triage. It may return one developed route hypothesis but does not guarantee\n  latency, literature evidence, or a solved route.\n- **basic** — \"is there a route?\" One research pass, up to 3 families. Cheapest;\n  use when a Scout direction is insufficient.\n- **standard** — \"what are my options?\" Ranked strategic alternatives. The default.\n- **exhaustive** — \"have we covered the space?\" For a high-value target you're\n  about to commit real lab time to.\n\nEscalate promising targets from scout → basic → standard/exhaustive when the\nuser zeroes in on the molecules they care about.\n\n## Reading the output\n\nEach result has `families[]`. A solved family has a `best_route` with:\n- `molecules[]` — target, intermediates, starting materials (with\n  `commercially_available` where known).\n- `reactions[]` — each with a human-readable `label`, `reaction_smiles`, and an\n  `assessment.band` (`likely_feasible` / `uncertain` / `high_risk`).\n- `scores` — `judge_combined_score` (0–100, the primary ranking) and a route\n  `feasibility_band`. Rank and present routes by the judge score, not by raw\n  feasibility (feasibility is noisier).\n- `stats` — `reaction_count`, `longest_linear_sequence`, `commercially_solved`.\n\nIncomplete families are returned as stubs (name + strategy summary, no route) —\nmention them as explored-but-unsolved so coverage is clear.\n\n## Guardrails\n\n- **Cost is real.** Every submit debits credits; `partial` still charges (compute\n  was spent), `failed` does not. Quote before runs, but mention price/balance\n  once rather than narrating every billing check.\n- **Never retry with a new quote or campaign request reference** — reuse the\n  durable handle so the server deduplicates the billable work.\n- **Respect caps.** `outstanding_job_limit_exceeded` /\n  `submission_rate_limit_exceeded` (429) mean wait or cancel a job, not retry\n  immediately. The execution limit itself queues internally.\n- **Bulk/agentic runs**: use one `submit_synthesis_campaign` call for up to 100\n  targets. Keep its generated campaign reference and recover the set through\n  the existing assessment-list tool; do not issue 100 independent starts.\n- **Don't surface internal identifiers** to the end user — present molecule\n  names, reaction labels, and feasibility bands, not opaque ids or raw scores.\n\n## Existing account access and purchases\n\nThe plugin uses the connected organization's existing credits. It does not sell\ncredits or subscriptions. If credits or permissions are insufficient, explain\nthe limit without promoting an upgrade, asking the user to buy credits, or\nlinking to checkout or a page that initiates a purchase. Do not invoke web\ncheckout endpoints through the REST fallback. Users may still inspect existing\nresults with their granted permissions. Keep result links focused on the\nrequested assessment or planning job.\n\n## Error handling\n\nPublic errors carry `detail.code` + `detail.request_id`. Actionable ones:\n`insufficient_credits` (402, explain the available balance and stop the paid operation), `invalid_smiles` / `unsupported_molecule` /\n`molecule_too_large` (422, fix the input), `route_search_not_found` (404).\nInclude `request_id` and the `job_id` in any support report.\n\nSee `reference.md` for the exact REST calls, and `agent_loop.py` for a runnable\nsubmit→poll→read example.\n\n\n## Standalone research and selected-strategy development\n\nWhen the hosted server lists the planning tools, choose by intent:\n- Competing synthesis strategies or focused literature research: use\n  `quote_synthesis_research`. SR stops at a persisted research report; it does not\n  launch RouteDev. Do not also start a full assessment.\n- Develop the user's specific strategy: use `quote_route_development` with the\n  exact target and `strategy.kind=user_strategy`, preserving their detailed proposal.\n- Develop one SR strategy: pass `strategy.kind=saved_strategy`, its `strategy_id`,\n  and the SR job's `receipt.result` artifact reference as `strategy.source`.\n- Paper-based route: use the bundled `selenium-paper-to-route` skill. Read and\n  describe the paper on the host; pass the detailed proposal and target to RouteDev.\n\nBoth quote tools are free. Start with `start_synthesis_planning` using the exact\nquoted credits and honoring the user's budget and host approval. Reuse the same\nquote for retries. Poll `get_synthesis_planning` at the returned interval; recover\njobs across chats with `list_synthesis_planning`. Inspect full report/route with\n`get_synthesis_planning_artifact`; cancel with `cancel_synthesis_planning`.\nKeep IDs internal. Research findings are hypotheses or cited precedent, not\nvalidated routes. Report partial development and deviations honestly. If planning\ntools are absent, explain that the server has not enabled them; never silently\nsubstitute a paid full assessment.\n\n## Monitoring and presenting results\n\nAfter admission, briefly state that work is queued/running and provide\n`session_url` as **Open in Selenium** when the server returns it. Use only a\nserver-returned link; never invent a UI hostname or substitute a job ID for a\nsession ID. If no link is returned, say that this server has not provided one.\n\nOwn monitoring of the existing job. While the turn is active, use the host's\nwait/sleep tool and honor `next_check_at` or `retry_after_seconds` before the next\nstatus call. Give updates on meaningful stage changes, not every poll.\n\nIf the user wants background updates (including a request to run and notify),\nand the host supports scheduled follow-ups, create one using the host's native\nscheduler. Follow that host's authorization rules. Store the existing job ID,\noperation, appropriate status tool, and returned minimum polling interval in the\nfollow-up prompt. Use an interval no shorter than that minimum or the scheduler's\nsupported minimum. The follow-up only reads that job: no new quotes, starts,\ncancellations, or paid retries. Stay quiet while unchanged. On completed, partial,\nfailed, or cancelled, notify once with a brief result and returned session link,\nthen disable the follow-up. A timer notification alone does not check job status.\n\nOnly claim background monitoring after the scheduler confirms creation. If the\nhost lacks scheduling, explain the limitation once and give the session link for\ninspection; do not promise to wake up after ending the turn. Do not use shell\nbackground processes or cron as a substitute for a supported host scheduler.\n\nFor final RouteDev results, lead with **Open in Selenium**, a short outcome, and\nkey uncertainties/deviations. Retrieve artifacts when needed to substantiate the\nsummary, but do not dump the route JSON or draw a graph unless requested. For SR,\nsummarize the research report; a session link does not imply a developed route.\n"},"changes":[],"summary":"First saved snapshot. No earlier version is available for comparison.","summary_kind":"deterministic","summary_metadata":{}}