Downloads · 30 days
23
3% of all-time downloads
scholarly360/contracts-extraction-flan-t5-base
contracts-extraction-flan-t5-base is a machine learning model from scholarly360. Use it for the machine learning task on the model card, and read the license before you ship it in a product. It is set up for transformers. The card lists the license as cc-by-sa-4.0.
This modelcard aims to be a base template for new models. It has been generated using this raw template.
Downloads · 30 days
23
3% of all-time downloads
All-time downloads
669
Public
Repo size
2 GB
Likes
3
Public
Click a slice to open those files.
.bin990 MB · 100%
From the Hugging Face model README
This modelcard aims to be a base template for new models. It has been generated using this raw template.
Instruction fine tuned Flan-T5 on Contracts
This model is fine-tuned using Alpaca like instructions. The base data for instruction fine-tuning is a legal corpus with fields like Titles , agreement date, party name, and addresses.
There are many type of models trained on above DataSet (DataSet will be released soon for the community) An encoder-decoder architecture like Flan-T5 is used because the author found it to be better than a decoder only architecture given the same number of parameters.
Just like any ChatGPT equivalent model (For Contracts Domain)
Users (both direct and downstream) should be made aware of the risks, biases and limitations of the model. More information needed for further recommendations.
Use the code below to get started with the model.
>>> from transformers import AutoModelForSeq2SeqLM, AutoTokenizer
>>> model_name = "scholarly360/contracts-extraction-flan-t5-base"
>>> model = AutoModelForSeq2SeqLM.from_pretrained(model_name)
>>> tokenizer = AutoTokenizer.from_pretrained(model_name)
>>> ### Example 1
>>> prompt = """ what kind of clause is "Neither Party shall be liable to the other for any abatement of Charges, delay or non-performance of its obligations under the Services Agreement arising from any cause or causes beyond its reasonable control (a Force Majeure Event) including, without limitation """
>>> inputs = tokenizer(prompt, return_tensors="pt")
>>> outputs = model.generate(**inputs)
>>> print(tokenizer.batch_decode(outputs, skip_special_tokens=True))
>>> ### Example 2
>>> prompt = """ what is agreement date in 'This COLLABORATION AGREEMENT (Agreement) dated November 14, 2002, is made by and between ZZZ, INC., a Delaware corporation' """"
>>> inputs = tokenizer(prompt, return_tensors="pt")
>>> outputs = model.generate(**inputs)
>>> print(tokenizer.batch_decode(outputs, skip_special_tokens=True))
>>> ### Example 3
>>> prompt = """ ### Instruction: \n\n what is agreement date ### Input: \n\n This COLLABORATION AGREEMENT (Agreement) dated November 14, 2002, is made by and between ZZZ, INC., a Delaware corporation """"
>>> inputs = tokenizer(prompt, return_tensors="pt")
>>> outputs = model.generate(**inputs)
>>> print(tokenizer.batch_decode(outputs, skip_special_tokens=True))
[More Information Needed]
DataSet will be released soon for the community
[More Information Needed]
[More Information Needed]
[More Information Needed]
[More Information Needed]
[More Information Needed]
[More Information Needed]
[More Information Needed]
Carbon emissions can be estimated using the Machine Learning Impact calculator presented in Lacoste et al. (2019).
[More Information Needed]
[More Information Needed]
[More Information Needed]
[More Information Needed]
BibTeX:
[More Information Needed]
APA:
[More Information Needed]
[More Information Needed]
[More Information Needed]
[More Information Needed]