The Contractual Complexity Challenge
A Geneva international law firm specializing in M&A and commercial transactions drafted dozens of complex contracts monthly: shareholder agreements, distribution contracts, partnership agreements, and service contracts. Each contract required several hours of drafting by senior lawyers, with much time spent adapting existing templates to specific client situations.
The firm had accumulated over fifteen years an impressive library of contractual clauses validated by practice and jurisprudence, but exploiting this knowledge remained manual and dependent on individual lawyers' memory. Junior lawyers lacked quick access to this expertise, and the risk of forgetting a protective clause or using an outdated formulation was real.
The firm sought a solution to accelerate contract drafting while capitalizing on collective legal expertise, ensuring consistency and quality while preserving lawyers' control over final output.
The AI-Assisted Drafting Solution
We developed an intelligent drafting assistant combining SharePoint, Azure AI Search, and Azure OpenAI Service. The architecture transforms the firm's contractual corpus into a searchable knowledge base that feeds an AI assistant integrated into Microsoft Word.
The first phase consisted of indexing all existing contracts and clause libraries into Azure AI Search with semantic chunking. Each contractual clause was tagged with metadata: contract type, jurisdiction, risk level, last validation date, and contextual notes. This indexation uses dense vector embeddings (text-embedding-ada-002) to enable semantic search that understands intent beyond keywords.
The second phase was developing a Word add-in using Office.js that integrates directly into the lawyer's drafting environment. When drafting a new contract, the lawyer specifies contract type, parties, object, and key terms in a form within Word. The add-in sends this context to Azure OpenAI Service (GPT-4) with instructions to generate a complete initial draft.
The crucial point is that the model uses RAG (Retrieval-Augmented Generation) to ground its generation on the firm's actual clauses. For each contract section, the system first searches Azure AI Search for the most relevant existing clauses, then asks GPT-4 to adapt these clauses to the specific context while maintaining legal rigor and the firm's proven style.
The generated draft is inserted directly into the Word document with highlighting that distinguishes standard clauses from adapted sections. For each clause, a comment indicates the source (which existing contract or clause library) and adaptation justification. The lawyer can accept, modify, or reject each section, maintaining total control.
Measured Benefits
After twelve months of use, impacts are significant on both productivity and quality. Initial drafting time for a standard contract decreased by 60%, dropping from an average of 6 hours to 2.5 hours. Junior lawyers can now produce contract first drafts matching senior quality, accelerating their learning curve.
Contract consistency improved, with identified homogenization of terminology and structure across different lawyers. The number of forgotten or inadequately drafted clauses decreased by 75%, reducing renegotiation and litigation risks.
The firm also noted an increase in billable hours per lawyer, as time saved on mechanical drafting is reinvested in strategic client advisory and complex negotiations. Partner satisfaction increased, appreciating being able to delegate more drafting to juniors while maintaining quality.
Clients appreciate receiving first drafts more quickly, shortening overall transaction cycles. The firm's Net Promoter Score increased by 15 points since deploying the solution.
Legal Validation and Liability
A crucial aspect was defining the validation process. The firm established a clear governance: all AI-generated contracts must be reviewed by a qualified lawyer before sending to clients. The system is positioned as a drafting assistant, not autonomous decision-maker.
To reinforce this, the add-in includes a mandatory validation checklist that lawyers must complete before finalizing the contract: verification of party-specific clauses, verification of applicable law consistency, verification of risk clauses, and final reading of the whole. This process is tracked in an audit log.
The firm also maintains a feedback loop: when a lawyer modifies a generated clause, they can indicate the reason (legal error, stylistic preference, specific client requirement). This feedback is analyzed quarterly to improve prompts and enrich the clause library.
Technical Architecture
The solution architecture is entirely based on Azure and Microsoft 365 services deployed in Switzerland North. The SharePoint library contains source contracts with automatic extraction of clauses by Azure AI Document Intelligence. Azure AI Search indexes these clauses with multiple search modes: semantic vector search for similarity, keyword search for precision, and hybrid search combining both.
The Word add-in communicates with an Azure Function that orchestrates calls to Azure AI Search and Azure OpenAI. This function also manages caching to avoid redundant calls and optimize costs. The GPT-4 model is deployed with contractual guarantees of non-use of data for external training.
Access to the system is restricted to firm lawyers via Azure AD authentication. All generations are logged with timestamps, user, context, and final result for professional liability purposes.
The monthly cost is approximately 600 CHF for all Azure resources, a marginal investment compared to the value of lawyer time saved.
Conclusion
This intelligent drafting assistant illustrates how AI can enhance lawyers' expertise rather than replace it. By capitalizing on collective knowledge and automating mechanical aspects of drafting, we free professionals to focus on legal strategy, negotiation, and client relationship—areas where human judgment remains irreplaceable.