zgbrenner turns document review tables into a launchpad for action

A fork of Mike reworks bulk document review so a reviewer can triage a matter's files and kick off the right follow-up task without leaving the row.

workflowdiscovery

zgbrenner renamed the upstream bulk-review feature to the plainer "Review Table" and shipped a ready-made Matter Document Review template: eight columns built for U.S. legal work, including document type, dates, parties, a short summary, key issues, and a flag for whether a human attorney needs to look. The instructions behind those columns are deliberately conservative - they pull only from the uploaded document, never guess, mark anything missing as "Unknown," and err toward flagging for attorney review whenever privilege, deadlines, filings, settlement, or sensitive data are in play.

The second piece closes the loop: each row can suggest a saved legal task, and a reviewer can launch that task straight from the table. So triage and the next action live in one place instead of two. The work is well-tested rather than a quick sketch.

So what Legal-ops leads and litigators drowning in document review should look at the cautious, no-invention prompt design and the row-to-task shortcut.

View this fork on GitHub →

Spotted something wrong? Or know the PR text has fresher detail than the writeup above?

Commits in this thread

4 commits from zgbrenner/gary, oldest first. Source extracted verbatim from the harvested git log.

SHA Subject Author Date
42ef29ea Merge pull request #2 from foolish-bandit/claude/gary-us-simplification-AjDDT Zack Brenner 2026-05-19 ↗ GitHub
Add Matter Document Review template and lawyer-friendly Review Table
a23d4303 Merge pull request #5 from foolish-bandit/claude/gary-us-simplification-AjDDT Zack Brenner 2026-05-19 ↗ GitHub
Run a Saved Legal Task from a Review Table row
06f80d85 feat: add Matter Document Review template and lawyer-friendly Review Table Claude 2026-05-19 ↗ GitHub
commit body
Lightweight improvements to make uploaded matter documents easier to
understand at a glance.

- Rebrand the user-visible "Tabular Review / Tabular Reviews" copy to
  "Review Table / Review Tables" across the sidebar, project tabs,
  modal headers, breadcrumbs, page titles, owner-only-action messages,
  and the workflow-builder helper text. Internal type names and routes
  are unchanged.
- Rewrite both empty states to match the lawyer-friendly direction:
  title "Start a Review Table", body about Gary organizing uploaded
  documents into a table with dates, document types, people,
  summaries, and follow-up issues, primary button "Create Review
  Table", and a secondary note "Review all extracted information
  before relying on it."
- Add a built-in tabular workflow "Matter Document Review" with eight
  default U.S. legal review columns: Document Name, Document Type,
  Date, People / Parties, Short Summary, Key Issues, Suggested Saved
  Legal Task, and Needs Attorney Review. Column prompts are cautious:
  use only the uploaded content, do not invent, write "Unknown" when
  missing, default "Needs Attorney Review" to Yes when uncertain or
  when the document touches legal rights / privilege / deadlines /
  filings / settlement / sensitive data. The Suggested Saved Legal
  Task column tags map to the eight built-in Saved Legal Tasks.
- Pre-select Matter Document Review when launching the create-review
  modal from inside a matter, and pin it to the top of the tabular
  template dropdown.
- Surface a plain-English failure on create ("Gary could not create
  the Review Table. Check your AI connection and try again.")
  via a dismissible inline banner in the project Review Tables tab.
- Add a persistent attorney-review reminder banner above every Review
  Table: "Draft for attorney review. Review all extracted information
  before relying on it. Do not treat any cell as verified fact, legal
  advice, or a definitive privilege call."
- Document the Review Table flow in the U.S. lawyer setup guide and
  add a terminology-map entry for Matter Document Review.
- Add focused tests covering the new workflow's columns, tags,
  cautious prompts, and the absence of legacy "Tabular Review" /
  "Workflow Template" copy in built-in workflows.

Row-to-Saved-Legal-Task launching from a row is intentionally deferred
to a follow-up PR; the Suggested Saved Legal Task column is purely
informational today and is documented as such in the setup guide.
b01092b7 feat: run a Saved Legal Task from a Review Table row Claude 2026-05-20 ↗ GitHub
commit body
Make the "Suggested Saved Legal Task" column actionable. When Gary
suggests a recognized task for a document, a lawyer can launch that
task in the assistant prefilled with the row's context.

- suggestedTask.ts: maps the eight recognized task names to built-in
  Saved Legal Task ids. Matching tolerates whitespace, case, tag
  brackets, and trailing punctuation but is never fuzzy - an
  unrecognized value resolves to null rather than guessing. Also
  builds the row-context prompt (task name, matter, document name,
  extracted fields, and attorney-review safety language).
- RunSuggestedTaskModal.tsx: a simple "Run Saved Legal Task?"
  confirmation with a prompt preview and Open in Assistant / Cancel.
- TRSidePanel: shows a "Run Suggested Task" action - only on the
  Suggested Saved Legal Task column's cell, and only when the value
  resolves to a recognized task and the cell has finished generating.
- TabularReviewView: resolves the row's suggested task, builds the
  row-context prompt from the row's other cells, and on confirm
  creates a chat, prefills an assistant draft, and opens it.
- Prefill, not auto-run: a new newChatDraft channel on
  ChatHistoryContext carries a draft (content + workflow + attached
  document) that ChatInput seeds its initial state from. The lawyer
  reviews and sends manually - nothing is auto-submitted. ChatView
  renders an empty-with-draft chat instead of the loading skeleton.
- The row's document is attached via the existing chat file
  mechanism; the document_id rides in the attachment, never in the
  visible prompt text. No raw internal ids appear in the prompt.
- Safety: the prompt instructs Gary to treat the row as draft and
  unverified, use the uploaded document, not invent facts / dates /
  legal authorities / deadlines / parties, and flag uncertainty.
- Docs: add "Running a Saved Legal Task from a Review Table" to the
  U.S. lawyer guide; add a terminology-map entry.
- Tests: suggestedTask.test.ts covers the eight-task mapping (and
  that each id is a real assistant built-in), match tolerance, the
  no-fuzzy-match guarantee, blank/Unknown/None handling, the prompt's
  attorney-review language, Unknown fallbacks, and the absence of raw
  internal ids and legacy terminology.

Capture this thread into my fork

Download a single Markdown prompt that tells Claude how to port every commit above into your working tree — adapting paths and structure to match your repo. Run it via claude -p < capture-thread-534.md from inside the repo you want the changes in.

⬇ Download capture-thread-534.md