You are a senior automation engineer. Build the following optimized workflow. # Triage and route inbound contracts Spion recorded this as a manual browser process (6 steps, ~12 min per contract, daily) and redesigned it as a consolidated automation (4 steps). Build the OPTIMIZED workflow below, not a replay of the manual clicks. Overview: On a new inbound contract, identify the agreement type, check it against the standard playbook, surface the clauses that deviate, and route it to the right reviewer with a risk summary — so legal reads the exceptions, not every page. Tools: CLM (Ironclad / DocuSign CLM), Claude, Slack Trigger: CLM or shared-inbox event (When a new contract is received for review). Efficiency target: 6 manual steps down to 4 (33% fewer), saving ~12 min per contract, and routing the same day instead of when someone gets to the pile. ## Optimized workflow steps 1. [CLM] Read the contract What: Read the document text, counterparty, and value/term metadata. 2. [Claude] Classify and check against the playbook (added by Spion: net-new value) What: Identify the agreement type (NDA, MSA, DPA, order form, amendment); compare key clauses (liability cap, indemnity, governing law, auto-renewal, termination) to the standard playbook; list each deviation with a low / medium / high risk tag and a one-line "why". Why: turns an unread contract into a reviewable exception list — assistive only, never legal advice or a final position. 3. [CLM] Tag and route What: Apply the type, risk level, and a "needs review" flag; assign to the reviewer who owns that contract type and value band. 4. [Slack] Notify with the summary What: Post the assigned reviewer a digest: type, counterparty, value, and the ranked list of deviating clauses with links to each. ## Original manual process (reference only, do not replicate) 1. Open each new contract 2. Read it to work out what kind it is 3. Compare clauses to the standard terms by memory 4. Decide who should review it 5. Forward it with notes 6. Update the tracker ## What I need from you 1. Build the optimized workflow exactly as designed above: production-ready code (Python or JavaScript) or a platform recipe (Workato, Make, Zapier, or n8n), whichever fits these tools best. 2. Preserve the consolidation. Do not expand it back into the manual click-by-click process. 3. Recommend the right trigger and cadence (schedule, webhook, or event). If it recurs, state the exact schedule. 4. Define the data contract for each step: the exact input fields it reads, the output fields it produces, and how fields map between tools. 5. Specify every authentication requirement: which services need OAuth, API keys, or service accounts, and the exact scopes. 6. Treat the model output as an assistive triage only. It must not give legal advice, approve, or sign anything — a qualified reviewer makes every decision, and the playbook comparison is flagged as "for review", not "approved". 7. Add robust error handling (unreadable PDFs, auth failures, empty results, rate limits with retries) and make the workflow idempotent so it is safe to re-run. 8. Include a short test plan: a sample contract and the expected triage output, so I can verify it before going live. 9. Finish with exact, copy-and-paste setup instructions so I can run it today.