Stanford Bootcamp · April 2026
Building AI Agents in Law
Aparna Sinha
Host · EnterpriseAlignedAI.com
Overview
What We'll Cover
- 01 · The AI Evolution — models, RAG, agents, where we are in 2026
- 02 · Legal Impact — how AI is reshaping legal work today
- 03 · Architecture of Agents — the enterprise tech stack, Skills, MCP
- 04 · Live Demo — Claude → Cowork → Code → Integrate → Build → Deploy
- 05 · Conclusions — what this means for law students, business students, and engineers
Key insight
Whether you write code or not — what I'm going to show you matters for how you work.
Section 01
The AI Evolution
AI models, agents, and where we are today
Section 01
The AI Evolution: 2022 → 2026
2022 – 2023
Chat Models — Instruction following, conversational AI. Hallucination and bias risks.
2023 – Early 2024
The RAG Era — Grounding with vector and hybrid search, greater summarization accuracy, citations, evals and guardrails.
Late 2024
Long Context — 200K–1M token windows. Stuff an entire contract in context. Reasoning models, improvements in OCR, voice, video, multi-modal models.
2025
The Agentic Shift — Vibe coding. Multi-step workflows that plan, use tools, and iterate. Model Context Protocol (MCP).
2026
Agent Autonomy — OpenClaw, Skills, Agentic Harness Engineering, Guided autonomy.
Section 01
Key Trends Shaping 2026
Technical
- Scaling laws still work, but... new scaling = post-training + inference time
- Specialized models — long thinking, research, coding, role play, tool calling
- Agent Harness Engineering — sandbox, memories, secure tool use, context and token efficiency
- Multimodality — text, vision, audio, docs in one context
Industry
- Open models proliferating — more in 2026 than 2025
- AI as collaborator — partner, not a tool you query
- The governance gap — tech outpaces organizations
- Cost inversion — inference is the real cost now
Source: Lex Fridman #490 — Nathan Lambert & Sebastian Raschka, Feb 2026
Section 01
My Take
The technology is no longer the bottleneck in enterprises.
Governance, training, and workflow integration are.
We're in the electricity moment — everyone knows AI matters,
most orgs still haven't rewired how they work.
Section 02
Legal Impact
How AI is reshaping legal work today
Section 02
AI's Impact on Legal Work
$5B+
Legal AI funding
2024–2026
80%
Law firms using
or exploring AI
$10–15B
Projected legal AI
market by 2030
Key players
- Harvey — $11B · $1B raised · Sequoia + GIC
- Legora — $5.55B · $816M raised · Accel
- EvenUp — $2B+ · $385M raised · Bessemer
- Eve — $1B · $164M raised · Spark Capital
- Spellbook — $350M · $80M+ raised · Khosla
Thesis shift: "AI for legal research" → AI as operating system for legal work
The incumbent counterpunch · Thomson Reuters
- ~$11B AI capital capacity through 2028
- $200M+/yr productized AI spend
- Proprietary legal LLM — claims to beat GPT-5 & Opus 4.5
- CoCounsel at 1M users · Casetext acquired for $650M
Funding: Crunchbase, PitchBook · Market: MarketsandMarkets, Lucintel · Survey: ILTA 2025 · Company data: press releases (Apr 2026)
Section 02
What's Actually Getting Automated
| Task | Time Reduction | Status |
| Contract review & due diligence | 30–80% | High-volume ceiling up to 80%; ~30% firm-wide on mixed workload (A&O / Harvey) |
| Legal research | 30–50% | Still needs human verification |
| Initial drafting | ~30% | First drafts only; peer-reviewed RCT (Choi et al. 2024) |
| Compliance monitoring | Ongoing | Only ~13% of orgs deployed today (KPMG 2025) |
| Document classification | 50–80% | Intake, categorization, routing |
Sources: Choi et al. 2024 (Minn. L. Rev.); Thomson Reuters Future of Professionals 2025; Harvey AI; Everlaw Am Law 100 case study; KPMG 2025.
The billable hour paradox
AI makes tasks faster → less billable time → but remaining human time is more valuable. Value-based pricing captures this. Hourly billing doesn't.
Section 02
The Autonomy Spectrum
| Level | How It Works | Legal Example | Risk |
| Scripted | Predefined steps, constrained tools | Clause review against checklist | Low |
| Guided | AI chooses strategy, human approves | Research agent proposes, lawyer confirms | Medium |
| Autonomous | AI plans and executes independently | Full due diligence from data room | High |
The reliability math
95% reliable per step × 10 steps = ~60% end-to-end. This is why human-in-the-loop matters.
Sweet spot today
Guided agents for enterprise legal work. Enough autonomy to be useful, enough checkpoints to be governed.
Section 02
The Claude-Native Law Firm
Zack Shapiro's Thesis
- Solo firm, ~200 startups at half BigLaw rates
- 2,000-word prompts — treats Claude like a senior associate
- Skills = "your judgment encoded, scaled like software"
- General-purpose AI beats specialized tools
- 7.5M views — hit a nerve
The Debate
- Supporters: Practical roadmap for solo/small firms
- Critics: Only works for low-complexity work
- U.S. v. Heppner (Rakoff, J., SDNY, Feb 2026): Defendant used consumer Claude without counsel's direction — not privileged, not work product. Enterprise, attorney-directed use analyzed differently.
Section 03
Architecture of Agents
Building agentic AI for legal work
Section 03
Agent Tech Stack
⇅
⇄
⇄
⇅
Orchestration
multi-step workflows
What We Built at Vercel
- AI Gateway — centralized routing, model selection, cost tracking
- AI Sandbox — safe isolated runtimes for AI-generated code
Key insight
The "magic" isn't just the model — it's the infrastructure around it.
Section 03
Agents, Skills & the Evolution
MCP
Connect agents to the world
- Databases, APIs, doc stores
- Westlaw, Lexis, DMS
- Standardized protocol
Skills / Plugins
Reusable encoded expertise
- "How a partner thinks about M&A diligence"
- Lightweight vs. fine-tuning
- One expert's judgment → scales to the firm
Agents
Autonomous loops with model tool calls
- Plan and execute tasks
- Use tools: search, code, APIs
- Iterate and recover from errors
Section 04
Live Demo
Question → Analyze → Build → Integrate → Deploy
Section 04
Question → Analyze → Build → Integrate → Deploy
| Step | Mode | What You'll See | Tool |
| 1 | Chat | Ask a legal question, get an instant answer | Claude.ai |
| 2 | Cowork | Contract review — GREEN / YELLOW / RED flags | /review-contract |
| 3 | Code | Run a custom contract review agent | Anthropic SDK |
| 4 | Integrate | Draft an email, check calendar | Google Workspace MCP |
| 5 | Deploy | Push a live dashboard to Cloudflare | Frontend Skill + Wrangler |
From question to deployed app in 6 minutes
Claude writes the code · You provide the judgment
Section 04
Step 2 · Cowork — The Legal Plugin
> /review-contract Contract_TechVentures.docx
Loading firm playbook v2.0…
Reviewing 14 sections…
🟢 §1 Definitions OK
🟢 §2.1 Scope & Deliverables OK
🔴 §3.1 IP Ownership CRITICAL
🟡 §3.3 Open Source CAUTION
🟢 §4 Confidentiality OK
🔴 §6.1 Liability Cap CRITICAL
🔴 §6.3 Data Liability CRITICAL
🔴 §7.2 Indemnification CRITICAL
🟡 §8.1 Termination CAUTION
8 issues flagged · 4 critical · See redlines →
The Claude Legal Plugin
- /review-contract — clause-by-clause review
- /triage-nda — NDA pre-screening
- /vendor-check — compliance tracking
- Plus /brief, /respond, more
Market signal
Launched Feb 3, 2026. RELX (LexisNexis parent) had its steepest single-day drop since 1988. Anthropic moved from model supplier to workflow owner.
Section 04
How the Agent Works
while not done:
response = claude.messages.create(
model="claude-sonnet-4-6",
tools=tools,
messages=messages
)
if response.stop_reason == "tool_use":
result = execute_tool(tool_call)
messages.append(result)
elif response.stop_reason == "end_turn":
done = True
Agent Tools
- read_contract — load the contract text
- read_playbook — load acceptable terms
- flag_clause — flag a risky clause
- generate_report — produce the final summary
Key insight
Claude decides which tools to call and in what order. You define the tools and the judgment criteria.
Section 04
Step 4 · Connect to Your Workflow
Find my next TechVentures meeting today.
Draft a reply to their counsel summarizing
the top 3 redlines from the contract review.
The Integration Story
Same Claude. Same context. Now operating across calendar, email, documents — through MCP.
Section 04
Claude reads my calendar…
Found · Google Calendar MCP
TechVentures × CodeCraft
Contract Review Call
Today · 4:00 – 4:30 PM PT
Counsel: [email protected]
Discuss outstanding redlines on the software development agreement — focus on IP ownership, liability cap, and indemnification.
Section 04
…and drafts the email
Gmail · Draft
To: [email protected]
Subject: TechVentures × CodeCraft — Top 3 redlines for 4pm call
Hi counsel,
Ahead of this afternoon's call, the three issues we need to resolve in the SDA:
1. §3.1 — IP Ownership. Developer retains all work product despite Client's $450K investment. We need work-for-hire with full assignment to Client.
2. §7.2 — Indemnification. Client cannot indemnify Developer for Developer's own negligence. This clause must be deleted and replaced with mutual indemnification.
3. §6.1 — Liability Cap. A 3-month-fees cap is too low for a mission-critical ERP build. We need total fees paid, with carve-outs for IP infringement.
Talk soon,
Aparna
Safety
Draft saved. Not sent. Human-in-the-loop before anything leaves your inbox.
Section 04
Step 5 · Deploy to the World
Contract Review · Live Dashboard
TechVentures × CodeCraft
Software Development Agreement · $450K
The Frontend Design Skill
- 277K+ installs — the most popular Claude skill
- Bold aesthetics, distinctive typography
- Production-grade UIs, not generic templates
- Auto-activates in Claude Code for frontend tasks
npx wrangler pages deploy ./dashboard \
--project-name=techventures-review \
--branch=main
Section 05
Conclusions
Law students · Business students · Engineers
Section 05
What This Means For You
Law Students
- Most valuable skill: directing AI, not competing with it
- Encode your judgment — it becomes leverage
- AI fluency is now a core competency
Business Students
- The billing model transition is the business opportunity
- Vertical AI wins — go deep, not wide
- Governance is a product, not a policy
Engineers
- Legal AI: massive market, unsolved infra problems
- Agent orchestration + evaluation are open frontiers
- Model + gateway + RAG + agents + review
That's what's possible.
Now it's your turn.
What's next today
- Next up: Deep dive on Claude — hands-on workshop
- Then: You build — today and tomorrow
- Goal: Hackathon — build something real
Q&A — 15 minutes
Resources
References & Further Reading
Papers & research
- Choi, Monahan & Schwarcz, "Lawyering in the Age of AI" — Minn. L. Rev. 109 (Nov 2024); peer-reviewed RCT, 12–32% speed gains
- Generative AI in the Legal Landscape — Stanford Law (2024 & 2026 updates, co-authored)
- Thomson Reuters Institute — 2025 Future of Professionals Report (n=2,275)
- LexisNexis — 2025 Future of Work Report (n>1,800)
- Clio — 2025 Legal Trends Report
- McKinsey — "Legal Innovation and Generative AI"
- Goldman Sachs — "How will AI affect the global workforce?" (2025)
- KPMG — How AI is Poised to Reshape Compliance Functions (Jul 2025)
- White & Case — 2025 Global Compliance Risk Benchmarking Survey
- ILTA 2025 Technology Survey — law firm AI adoption
- MarketsandMarkets & Lucintel — legal AI market forecasts through 2030
- Wolters Kluwer Future Ready Lawyer 2026
Cases & legal analysis
- U.S. v. Heppner, S.D.N.Y. (Rakoff, J., Feb 10, 2026) — AI privilege & work product
- Heppner client alerts: Gibson Dunn, Debevoise, Akin, McDermott, Proskauer (Feb–Mar 2026)
- Harvard Law Review — United States v. Heppner note (Mar 2026)
Company press & primary sources
- Harvey — harvey.ai/blog (methodology: "How Harvey Saves Lawyers Time"; "Contract Intelligence Benchmark"); CNBC Mar 2026 ($11B)
- Everlaw — Am Law 100 doc-review case study (50–67% reduction, 90%+ accuracy)
- Legora — legora.com, TechCrunch Mar 2026 ($5.55B Series D)
- EvenUp — Fortune Oct 2025 ($2B Series E)
- Eve — eve.legal/press (Sept 2025, $1B)
- Spellbook — Law.com (Oct 2025, $350M)
- Rains LLP — rains.law (Claude-native boutique)
- Thomson Reuters / CoCounsel — LawSites "1M users" (Feb 2026)
Podcasts & commentary
- Lex Fridman #490 — Nathan Lambert & Sebastian Raschka (Feb 2026)
- Zack Shapiro — "Claude-native law firm" X thread (~7.7M views)
- agents.law — "Inside the Claude-Native Law Firm" (Matt Pollins)
- LawDroid Manifesto — "The Claude-Native Lawyer: Zack Shapiro" (Tom Martin)
- Artificial Lawyer · LawSites (Ambrogi) — ongoing coverage
- EnterpriseAligned AI podcast — enterprisealignedai.com
Funding, market & technical docs
- Crunchbase News & PitchBook — funding rounds & valuations
- Fortune, Bloomberg, CNBC, TechCrunch — startup coverage
- Claude Agent SDK — docs.anthropic.com
- Model Context Protocol — modelcontextprotocol.io
- Claude Skills & Legal Plugin documentation
Appendix
Appendix
Additional reference material