- Notifications
You must be signed in to change notification settings - Fork 0
Examples
The following examples provide a practical look at how LegaleseScript can be used to draft different types of contracts. These samples demonstrate the language's syntax and how its various features can be applied to create structured and testable legal documents.
This example illustrates a basic employment contract with defined terms, obligations, rights, and a signature clause.
sectionEmploymentContract {
Partyemployer = "Acme Corporation";
Partyemployee = "John Doe";
Textposition = "Software Developer";
CurrencyannualSalary = Currency("GBP", 50000);
DatestartDate = Date("2023-01-01");
obligationpaySalary(WholeNumberdayOfMonth) {
// Logic to pay the employee's salary on the specified day of the month
}
righttoReceiveSalary() {
// Logic for the employee to receive the salary
}
signaturesignContract() {
// Logic to confirm that both parties have signed the contract
}
}This example shows a lease agreement with clauses pertaining to rent, term, and termination.
sectionLeaseAgreement {
Partylessor = "Jane Smith";
Partylessee = "John Doe";
TextpropertyAddress = "123 Main Street";
CurrencymonthlyRent = Currency("USD", 1200);
DateleaseStartDate = Date("2023-01-01");
DurationleaseTerm = Duration("Months", 12);
obligationpayRent() {
// Logic for lessee to pay rent
}
obligationprovideProperty() {
// Logic for lessor to provide the property to the lessee
}
righttoTerminateLease() {
// Logic for terminating the lease under certain conditions
}
signaturesignLease() {
// Logic to confirm that both parties have signed the lease
}
}This example demonstrates a non-disclosure agreement with confidentiality obligations.
sectionNonDisclosureAgreement {
PartydisclosingParty = "XYZ Corporation";
PartyreceivingParty = "John Consultant";
TextdefinitionOfConfidentialInformation = "All financial data, trade secrets, and other information not publicly available.";
obligationmaintainConfidentiality() {
// Logic for the receiving party to maintain confidentiality
}
righttoDiscloseInformation() {
// Logic under which the receiving party may disclose information
}
signaturesignNDA() {
// Logic to confirm that both parties have signed the NDA
}
}Remember to write tests for your contracts to ensure that they behave as expected. Refer to the Testing Contracts section for guidance on writing test cases.
These examples provide a snapshot of what you can accomplish with LegaleseScript. As you become more familiar with the language, you can tackle more complex contracts and utilize the full range of LegaleseScript's capabilities.