Skip to content

marcoderoni/contract-negotiation-simulator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

⚖️ Contract Negotiation Simulator

An AI-powered CLI tool that simulates real contract negotiations — with a live AI counterparty, turn-by-turn scoring, and senior counsel-level feedback.

Contract Negotiation Simulator demo


What it does

Contract Negotiation Simulator puts you across the table from an AI counterparty counsel. You defend your position on a real clause (liability cap, sub-processor approval, IP ownership, termination for convenience), the AI pushes back with professional legal language, and at the end of the session you receive a structured scorecard with coaching feedback.

Built for:

  • In-house counsel preparing for difficult negotiations
  • Legal teams training junior lawyers on commercial contracts
  • Legal tech enthusiasts exploring agentic AI in legal workflows

Features

Feature Description
Live AI counterparty Claude plays an experienced opposing counsel with a real mandate
Structured scorecard 4 dimensions: Playbook Adherence, Legal Precision, Strategy, Commercial Awareness
Senior counsel feedback Best move, missed opportunity, suggested closing position
Session export Every negotiation saved as .json for review
Difficulty levels Easy / Medium / Hard scenarios
Multi-round Configurable turn count per scenario

Scenarios

# Clause Contract Type Difficulty
1 Limitation of Liability (12-month ACV cap) SaaS MSA Medium
2 Sub-processor Approval (GDPR Art. 28) DPA Hard
3 IP Ownership & Work for Hire CSA Medium
4 Termination for Convenience MSA Easy

Quick start

1. Clone the repo

git clone https://github.com/marcoderoni/contract-negotiation-simulator.git cd contract-negotiation-simulator

2. Install dependencies

pip install -r requirements.txt

3. Set your API key

export ANTHROPIC_API_KEY="your-key-here"

4. Run

python simulator.py


How to play

  1. Choose a scenario — pick a clause type and difficulty
  2. Read the opening clause — this is your starting position
  3. Respond to the counterparty — propose redlines, make arguments, concede strategically
  4. Finish all turns (or type score to end early)
  5. Receive your scorecard — with dimensional scores and coaching feedback

Sample Scorecard

FINAL SCORE: 74/100  ·  Grade: B

  Playbook Adherence    ███████░░░  70   Defended the cap but accepted a carve-out outside mandate.
  Legal Precision       ████████░░  80   Clause language was clean and correctly scoped.
  Negotiation Strategy  ███████░░░  72   Good use of fallback; missed a sequencing opportunity.
  Commercial Awareness  ████████░░  75   Correctly tied liability cap to contract value.

Best move: Linking the liability cap to the premium paid for the service.
Missed opportunity: Proposing a mutual cap to reframe the asymmetry.
Senior counsel close: "We can accept a 24-month cap for data breach events only, mutual..."

Part of the Legal AI Toolkit

This simulator is part of a broader open-source collection of AI-powered legal tools:


Disclaimer

Training and educational purposes only. Not legal advice. All scenarios are fictional.


Author

Marco Deroni — Senior Legal Counsel (Commercial) | CIPP-E | LL.M.

LinkedIn: https://www.linkedin.com/in/marcoderoni GitHub: https://github.com/marcoderoni


License

MIT — see LICENSE

About

AI-powered contract negotiation simulator — practice SaaS, DPA and CSA clause negotiations against a live Claude counterparty, with scoring and senior counsel feedback.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages