--- license: apache-2.0 task_categories: - text-classification - zero-shot-classification - feature-extraction language: - en tags: - legal - finance size_categories: - 10K Created by **LexPipe**, which sourced time entries from public records. LexPipe found examples of full attorney invoices as exhibits to Motion for Attoneys Fees. The result is the first set of public royalty free time entries for research and commerce. Whether you’re a law firm, ALSP, or researcher, email hello@lexpipe.com to: * advise on bespoke benchmarks * provide clean public data, or * integrate your private data securely. No cost consultation: https://www.lexpipe.com/meetings/lexpipe/meet-us --- ## Time Entry Dataset at a Glance * **31 litigation matters** * **≈13k unique time entries** * **≈20k hours of billed time** * **4 phases labeled**: Pleading, Discovery, Pretrial, Trial Law firm invoices were OCRed with tersseract 3.0, LLMs extracted time entries, with manual data cleaning. Source PDF documents available on request. ### Sample: New York Commercial Contract Case Time entries for an example matter are shown for a New York commercial contract dispute: | Title | Cowen and Company, LLC v. ReShape Lifesciences, Inc. | |------|-------------------| | Docket | 654817/2021 | | Court | New York State, New York County, Supreme Court | | Link | [NYSCEF Link to Docket](https://iapps.courts.state.ny.us/nyscef/DocumentList?docketId=3wCXmzuTkcsA66wmK09fdA==&display=all&courtType=New%20York%20County%20Supreme%20Court&resultsPageNum=1) | | Summary | Cowen and Company, LLC alleges that ReShape Lifesciences, Inc., breached a 2019 financial advisory agreement by failing to pay $1.35 million in fees after a merger. | | Phases | The case advanced through pleading from August 2021, discovery until June 2022, and pretrial motions leading to a money judgment on May 11, 2023, after which it was disposed. | Time entries for the case can be seen below, with the time coded according to the phase. image/png #### Sample Rows --- # Detailed Usage This repository contains both raw and cleaned data. - Cleaned data [CSV file direct download link](https://huggingface.co/datasets/LexPipe/time-entries-and-phases/resolve/main/cleaned_time_entries_and_phases.csv) - Detailed walkthrough in [data analysis notebook](https://huggingface.co/datasets/LexPipe/time-entries-and-phases/blob/main/notebooks/explore_time_entry_data.ipynb) - Raw data for experienced users accessible via Huggingface: ```python from datasets import load_dataset repo_id = "lexpipe/time-entries-and-phases" dataset = load_dataset(repo_id) ``` Each time entry has an associated duration, and (when available) a name for the phase of legal proceedings. The associated duration is the amount of time logged by the person filing the time entry. ## Narratives Each time entry has a "narrative", a textual descriptions of the work that was conducted by the timekeeper making the entry. Narratives vary in length and detail. In the cleaned data, the narratives have been processed with named entity recognition, with names of people and organizations scrubbed and replaced with "PERSON". The real names of the timekeepers are kept in the respective column. Certain phrases occur often in the narratives, and can be indicative of the phase of the legal matter. Word size indicates frequency of occurrence in the narratives: ## Data Columns For a description of the columns in the processed data, please see the [exploratory data analysis notebook](https://huggingface.co/datasets/LexPipe/time-entries-and-phases/blob/main/notebooks/explore_time_entry_data.ipynb) The (raw) dataset comprises the following columns: | **Column** | **Column Name** | **Description** | **Data Type** | | ------------------- | ---------------------- | -------------------------------------------------------------- | --------------- | | 1 | **EntryID** | Unique identifier of the entry. | Integer | | 2 | **Narrative** | Description of the work performed during the time entry. | Object (string) | | 3 | **PhaseName** | Name of the phase in the legal proceedings. | Object (string) | | 4 | **PhaseDurationDays** | Duration of the legal phase in days. | Float64 | | 5 | **EntryDurationHours** | Total duration of the legal services for the entry (in hours). | Float64 | | 6 | **Timekeeper** | Name of the person logging the time entry. | Object (string) | | 7 | **Rate** | Hourly rate of the timekeeper. | Float64 | | 8 | **Position** | Position or role of the timekeeper (e.g., associate, partner). | Object (string) | | 9 | **Partner** | Is the time keeper a partner in the firm or not | Bool | | 10 | **Firm** | Law firm name associated with the time entry. | Object (string) | | 11 | **Date** | Date of the time entry. | Object (string) | | 12 | **Docket** | Unique identifier for the case in the docket system. | Object (string) | | 13 | **SourceDocumentZip** | Name of the .zip file containing the source document. | Object (string) | | 14 | **SourceDocumentName** | Name of the source document (PDF). | Object (string) | | 15 | **QuerySlug** | Unique identifier or slug for the data entry. | Object (string) | | 16 | **Length** | Length of the document in tokens. | Integer | | 17 | **Pages** | Pages containing the time entry data. | Object (string) | | 18 | **Court** | Court presiding over the matter. | Object (string) | | 19 | **DocketEntry** | Text of the specific docket entry. | Object (string) | | 20 | **Link** | Link to the docket entry or relevant document. | Object (string) | | 21 | **LinkEx** | External link related to the time entry. | Object (string) | | 22 | **TextMatter** | Full or cleaned text related to the matter. | Object (string) | | 23 | **DaysFromStart** | Days from the start of the case to the time entry. | Float64 | | 24 | **Matter** | Identifier or name of the legal matter. | Object (string) | | 25 | **Cleaned** | Has the entry been cleaned or not. | Bool | | 26 | **Confidence** | Confidence score for the extracted data. | Object (string) | | 27 | **Analysis** | Additional analysis or notes on the time entry. | Object (string) | ### Statistics of data columns | Column Name | Mean | Median | Range (max minus min) | Cardinality | |-------------|------|--------|-------|-------------| | **PhaseDurationDays** | 365.15 | 367.00 | 2023.00 | 31 | | **EntryDurationHours** | 1.49 | 0.70 | 17.60 | 172 | | **Rate** | 578.78 | 590.00 | 1507.00 | 180 | | **Length** | 268666.61 | 201498.00 | 571675.00 | 46 | | **DaysFromStart** | 449.63 | 435.00 | 1942.00 | 613 | ## Data Splits No predefined splits for machine learning purposes have been made, users may create splits (e.g., train/test/validation) as needed. If treated cross-sectionally, predictive perforamnce of time entry narrative to phase name label drops progressively. From roughly ~2000 narratives predictive performance is adequate. image/png ## Contributions * Michael Sander, CEO / Founder, LexPipe, Inc. * Ruud van den Brink, Principal Data Scientist, LexPipe, Inc. ## Additional Information *Released under Apache-2.0, which gives broad commercial & research rights. Please attribute “LexPipe” and link back to this repo.* [https://lexpipe.com](https://lexpipe.com/)