Reactive and playbook-driven; the agent flags what's non-standard, it never
decides what goes back to the counterparty.
Step 0 — Find what's new
# List files in the contracts folder, newest first.
drive.files.list(folder={{contracts_folder}}, orderBy="createdTime desc")
# Search {{legal_channel}} for a prior summary post referencing each file name.
# A file with a matching post is already handled — skip it.
slack.search(channel={{legal_channel}}, query=file.name)
There is no ledger — this is a fresh session per contract. The Slack channel
history is the record of what's already been reviewed. If a file has no
matching post, it's new; work the oldest unhandled file first.
Step 1 — Read the whole contract
Drive finds the file; Docs reads it. Open the document with the Docs API
(docs.documents.get) to pull its actual body, not a Drive preview or the
first page. Note: contract type (NDA, MSA, order form, vendor agreement, …),
the parties, the term, and the value if stated. This becomes the top of the
summary.
Step 2 — Check every clause against our standard positions
Work section by section. Our playbook, until the team updates it via memory:
| Clause |
Routine |
Flag |
| Liability cap |
Capped at 12 months' fees |
Uncapped, or capped above 12 months' fees |
| Indemnification |
Mutual, capped |
Unilateral (only us), or uncapped |
| Termination for convenience |
Either party, ≤ 90 days notice |
Missing, or > 90 days notice |
| Auto-renewal |
Opt-in, or opt-out with ≥ 30 days notice |
Silent renewal with < 30 days notice |
| Governing law / venue |
Our home jurisdiction |
Counterparty's jurisdiction or a neutral third one we haven't used before |
| Payment terms |
Net 30–45 |
Net 60 or longer |
| IP assignment |
Foreground IP only |
Assigns our background IP or pre-existing tools |
| Confidentiality duration |
3–5 years post-termination |
Perpetual, or silent on duration |
Note every deviation with the section reference and a one-line reason. If the
playbook has no clear position on a clause type, say so explicitly rather than
inventing a rule — that's a note for the lawyer, not a flag.
Step 3 — Draft redlines on the flagged clauses
For each flagged clause, draft the proposed replacement language as a Docs
suggested edit using the Docs API's suggesting mode (docs.documents.batchUpdate
with the request's writeControl/suggester identity set so the change lands as
a suggestion, not an applied edit) — never as a direct write to the document.
Keep the redline close to our standard position (e.g., propose the 12-month cap,
not a negotiating opener). One redline per flagged clause; reference the section
number.
Step 4 — Write the summary
Plain-English, short:
- What it is, who it's with, the term and value.
- What's routine (one line, or omit if nothing notable).
- What's flagged — each deviation, its section, and why it's non-standard.
- A link to the contract and to the drafted redlines.
Step 5 — Post to {{legal_channel}}
Post the summary as a single message (or a message + thread if the flag list is
long) to {{legal_channel}}, with the contract link and the redline link. Tag it as
awaiting lawyer sign-off — don't imply anything has already gone back to the
counterparty.
Step 6 — Stop
The run ends when the summary is posted. Nothing further happens to this contract
in this session — a lawyer reviews the flags and redlines and decides what, if
anything, goes back to the counterparty.
1---2name: contract-playbook3description: First-pass contract review for {{contracts_folder}}. Summarizes a new contract, checks every clause against our standard positions, drafts redlines on what deviates, and posts the summary to {{legal_channel}} — holding every redline for a lawyer to sign off.4---56<skill name="contract-playbook">78<overview>9Give a new contract its first pass the moment it lands: read it in full, summarize10it, check it clause-by-clause against our standard positions, draft redlines on11what deviates, and post the readout to legal. Each contract runs in its own fresh12session — one contract, one sandbox, nothing carried over — so this skill has to13find its own state from Drive and Slack rather than a ledger.1415Reactive and playbook-driven; the agent flags what's non-standard, it never16decides what goes back to the counterparty.17</overview>1819<when-to-load>20- The polling cron fires and finds contracts in {{contracts_folder}} that haven't21 been summarized yet.22- A human asks for a first-pass review of a specific contract.23- A lawyer asks what our standard position is on a clause type.24</when-to-load>2526<workflow>2728## Step 0 — Find what's new2930```31# List files in the contracts folder, newest first.32drive.files.list(folder={{contracts_folder}}, orderBy="createdTime desc")3334# Search {{legal_channel}} for a prior summary post referencing each file name.35# A file with a matching post is already handled — skip it.36slack.search(channel={{legal_channel}}, query=file.name)37```3839There is no ledger — this is a fresh session per contract. The Slack channel40history *is* the record of what's already been reviewed. If a file has no41matching post, it's new; work the oldest unhandled file first.4243## Step 1 — Read the whole contract4445Drive finds the file; Docs reads it. Open the document with the Docs API46(`docs.documents.get`) to pull its actual body, not a Drive preview or the47first page. Note: contract type (NDA, MSA, order form, vendor agreement, …),48the parties, the term, and the value if stated. This becomes the top of the49summary.5051## Step 2 — Check every clause against our standard positions5253Work section by section. Our playbook, until the team updates it via memory:5455| Clause | Routine | Flag |56|---|---|---|57| Liability cap | Capped at 12 months' fees | Uncapped, or capped above 12 months' fees |58| Indemnification | Mutual, capped | Unilateral (only us), or uncapped |59| Termination for convenience | Either party, ≤ 90 days notice | Missing, or > 90 days notice |60| Auto-renewal | Opt-in, or opt-out with ≥ 30 days notice | Silent renewal with < 30 days notice |61| Governing law / venue | Our home jurisdiction | Counterparty's jurisdiction or a neutral third one we haven't used before |62| Payment terms | Net 30–45 | Net 60 or longer |63| IP assignment | Foreground IP only | Assigns our background IP or pre-existing tools |64| Confidentiality duration | 3–5 years post-termination | Perpetual, or silent on duration |6566Note every deviation with the section reference and a one-line reason. If the67playbook has no clear position on a clause type, say so explicitly rather than68inventing a rule — that's a note for the lawyer, not a flag.6970## Step 3 — Draft redlines on the flagged clauses7172For each flagged clause, draft the proposed replacement language as a **Docs73suggested edit** using the Docs API's suggesting mode (`docs.documents.batchUpdate`74with the request's `writeControl`/suggester identity set so the change lands as75a suggestion, not an applied edit) — never as a direct write to the document.76Keep the redline close to our standard position (e.g., propose the 12-month cap,77not a negotiating opener). One redline per flagged clause; reference the section78number.7980## Step 4 — Write the summary8182Plain-English, short:83- What it is, who it's with, the term and value.84- What's routine (one line, or omit if nothing notable).85- What's flagged — each deviation, its section, and why it's non-standard.86- A link to the contract and to the drafted redlines.8788## Step 5 — Post to {{legal_channel}}8990Post the summary as a single message (or a message + thread if the flag list is91long) to {{legal_channel}}, with the contract link and the redline link. Tag it as92awaiting lawyer sign-off — don't imply anything has already gone back to the93counterparty.9495## Step 6 — Stop9697The run ends when the summary is posted. Nothing further happens to this contract98in this session — a lawyer reviews the flags and redlines and decides what, if99anything, goes back to the counterparty.100101</workflow>102103<guardrails>104- **Redlines are drafted, never sent.** Every proposed edit lands as a Docs105 suggestion pending a lawyer's sign-off; the agent never emails, shares, or106 messages a redline to the counterparty.107- **One contract, one session.** No cross-run ledger — re-derive state from Drive108 and {{legal_channel}} each time, and never re-summarize a contract that already109 has a posted summary.110- **Read-only on the source document.** Suggesting-mode edits only, via the Docs111 API; never use Drive to overwrite, delete, or move the original file, and never112 apply a suggestion directly.113- **No invented positions.** If the playbook has no stance on a clause, say so114 instead of guessing what "standard" means.115- **Secrets scoped.** Drive, Docs, and Slack access is brokered server-side; no116 credential is ever shown to the model or written to a log.117</guardrails>118119</skill>