Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

13 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

ENTROPHY: Multi-modal User Interaction Data from Live Enterprise Business Workflows

License: CC BY-NC-SA 4.0 Python 3.11+

ENTROPHY is the first open, click-level record of how finance, legal, and HR workflows are carried out on real enterprise softwareβ€”modern SaaS, browsers, and legacy desktop apps alike. Nine domain professionals executed 283 authentic workflow runs over five working days, producing 33 hours of screen-level activity across 19 applications.

This repository contains the accompanying code for ENTROPHY that evaluates the zero-shot performance of frontier Large Language Models (LLMs) on workflow classification and segmentation tasks.


πŸ“– Table of Contents


🌟 Key Features

  • Multi-domain Workflow Analysis: Process user interaction data from diverse enterprise domains
  • Zero-shot LLM Evaluation: Test frontier models on workflow understanding without fine-tuning
  • Comprehensive Task Suite:
    • Classification: Identify workflow types from interaction sequences
    • Segmentation: Split concatenated workflows into individual process instances
    • Similarity Analysis: Compare workflow patterns using semantic embeddings
  • Multi-provider LLM Support: OpenAI, Anthropic, Google, Hugging Face models
  • Rich Visualizations: Generate publication-quality plots and analysis reports
  • Reproducible Research: Detailed configuration and comprehensive logging

πŸ—οΈ Project Structure

entrophy/
β”œβ”€β”€ πŸ“„ README.md                     # Comprehensive project documentation
β”œβ”€β”€ πŸ“„ LICENSE                       # CC BY-NC-SA 4.0 International License
β”œβ”€β”€ πŸ“„ requirements.txt              # Python dependencies with versions
β”‚
β”œβ”€β”€ πŸ“ src/                          # Source code
β”‚   β”œβ”€β”€ πŸ“„ __init__.py               # Package initialization
β”‚   β”œβ”€β”€ πŸ“„ data_processor.py         # Data loading and preprocessing utilities
β”‚   β”œβ”€β”€ πŸ“„ classification.py         # Workflow classification implementation
β”‚   β”œβ”€β”€ πŸ“„ segmentation.py           # Workflow segmentation implementation
β”‚   β”œβ”€β”€ πŸ“„ generate_plots.py         # Visualization and plotting utilities
β”‚   └── πŸ“ similarity_analysis/     # Similarity analysis modules
β”‚       β”œβ”€β”€ πŸ“„ similarities.ipynb   # Jupyter notebook for similarity analysis
β”‚       β”œβ”€β”€ πŸ“„ process_similarity_heatmap.pdf  # Generated heatmap
β”‚       β”œβ”€β”€ πŸ“„ finance_embeddings.csv         # Pre-computed embeddings
β”‚       β”œβ”€β”€ πŸ“„ legal_embeddings.csv           # Pre-computed embeddings
β”‚       └── πŸ“„ hr_embeddings.csv              # Pre-computed embeddings
β”‚
β”œβ”€β”€ πŸ“ configs/                      # Configuration files
β”‚   β”œβ”€β”€ πŸ“„ classification.yaml      # Classification task configuration
β”‚   └── πŸ“„ segmentation.yaml       # Segmentation task configuration
β”‚
β”œβ”€β”€ πŸ“ data/                         # Dataset files
β”‚   β”œβ”€β”€ πŸ“„ process_definitions.json # Workflow process definitions
β”‚   └── πŸ“ json/                    # Raw interaction data
β”‚       β”œβ”€β”€ πŸ“„ hr.json              # HR domain workflows (download from Kaggle)
β”‚       β”œβ”€β”€ πŸ“„ legal.json           # Legal domain workflows (download from Kaggle)
β”‚       └── πŸ“„ finance.json         # Finance domain workflows (download from Kaggle)
β”‚
β”œβ”€β”€ πŸ“ outputs/                      # Experimental results
└── πŸ“ figures/                      # Generated visualizations

⚑ Quick Start

Get up and running with ENTROPHY in under 5 minutes:

# 1. Clone the repository
git clone https://github.com/your-username/entrophy.git
cd entrophy

# 2. Set up environment
python3 -m venv venv
source venv/bin/activate  # On Windows: venv\Scripts\activate

# 3. Install dependencies
pip install -r requirements.txt

# 4. Run a quick classification experiment
python src/classification.py --config configs/classification.yaml

# 5. Generate similarity analysis (optional)
cd src/similarity_analysis && jupyter notebook similarities.ipynb

πŸ”§ Installation

Prerequisites

  • Python: 3.11 or higher
  • Memory: 8GB+ RAM recommended
  • Storage: 2GB+ available space
  • GPU: Optional but recommended for local model inference

Environment Setup

Option 1: Conda (Recommended)

# Create conda environment
conda create -n entrophy python=3.11
conda activate entrophy

# Install PyTorch with CUDA support (optional)
conda install pytorch torchvision torchaudio pytorch-cuda=12.1 -c pytorch -c nvidia

# Install other dependencies
pip install -r requirements.txt

Option 2: Virtual Environment

# Create virtual environment
python3 -m venv venv
source venv/bin/activate  # On Windows: venv\Scripts\activate

# Upgrade pip and install dependencies
pip install --upgrade pip
pip install -r requirements.txt

Verification

# Test the installation
python -c "import torch; print(f'PyTorch: {torch.__version__}')"
python -c "import transformers; print(f'Transformers: {transformers.__version__}')"
python -c "from src.data_processor import WorkflowDataProcessor; print('βœ… Installation successful!')"

πŸ“Š Dataset

Overview

ENTROPHY contains real-world workflow data from three enterprise domains:

Domain Workflows Size Description
Finance 94 instances 14MB Invoice processing, payments, revenue accounting
Legal 89 instances 9.6MB MSA/SOW creation, contract iterations
HR 100 instances 13MB Employee onboarding, leave management

βš™οΈ Configuration

Configuration Files

ENTROPHY uses YAML configuration files for reproducible experiments:

Classification Configuration (configs/classification.yaml)

Segmentation Configuration (configs/segmentation.yaml)


πŸš€ Usage

Workflow Classification

Classify individual workflow instances into predefined categories:

# Using configuration file
python src/classification.py --config configs/classification.yaml

Workflow Segmentation

Segment concatenated workflows into individual process instances:

# Using configuration file
python src/segmentation.py --config configs/segmentation.yaml

Similarity Analysis

Analyze workflow similarities using semantic embeddings:

Interactive Analysis

# Open Jupyter notebook
cd src/similarity_analysis
jupyter notebook similarities.ipynb

Generating Visualizations

Create publication-quality plots and analysis reports:

Generate All Plots

python src/generate_plots.py --input_root outputs/ --output_dir figures/

Available Visualizations

  • Classification Performance: Accuracy, precision, recall, F1-score
  • Confusion Matrices: Model performance breakdown by class
  • Segmentation Metrics: Boundary detection accuracy, edit distance
  • Cross-domain Comparisons: Performance across HR, Legal, Finance
  • Similarity Heatmaps: Workflow pattern similarities

πŸ§ͺ Experiments & Evaluation

Evaluation Metrics

Classification Metrics

  • Accuracy: Overall classification correctness
  • Precision/Recall/F1: Per-class and macro-averaged metrics
  • Confusion Matrix: Detailed error analysis
  • Support: Number of instances per class

Segmentation Metrics

  • Boundary Precision/Recall: Accuracy of workflow boundary detection
  • Edit Distance: Sequence alignment cost between predicted and true segments
  • Tolerance-based Accuracy: Boundary detection within tolerance window

πŸ“ˆ Results & Outputs

Output Structure

outputs/
β”œβ”€β”€ finance/
β”‚   β”œβ”€β”€ classification/
β”‚       β”œβ”€β”€gpt-4.1/
β”‚           β”œβ”€β”€ report.json                     # Classification metrics
β”‚           β”œβ”€β”€ confusion_matrix.json           # Confusion matrix data
β”‚           β”œβ”€β”€ detailed_results.json           # Per-instance results
β”‚           └── prompt_and_generated_text.json  # Raw model outputs
β”‚       β”œβ”€β”€deepseek-r1/
β”‚           β”œβ”€β”€ ...
β”‚   └── segmentation/
β”‚       β”œβ”€β”€gpt-4.1/
β”‚           β”œβ”€β”€ segmentation_results.json      # Segmentation metrics
β”‚           β”œβ”€β”€ prompts_and_responses.json     # Raw model outputs
β”‚           └── visualization_sequence_*.png   # Per-instance visuals
β”‚       β”œβ”€β”€deepseek-r1/
β”‚           β”œβ”€β”€ ...
β”œβ”€β”€ hr/
β”‚   β”œβ”€β”€ ...
└── legal/
    β”œβ”€β”€ ...

πŸ“„ License

This project is licensed under the Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.

Key Points:

  • βœ… Attribution: Credit must be given to the original authors
  • βœ… NonCommercial: Only non-commercial use is allowed
  • βœ… ShareAlike: Adaptations must use the same license
  • βœ… Academic Research: Permitted and encouraged
  • ❌ Commercial Use: Not permitted without explicit permission

For the complete license text, see LICENSE or visit https://creativecommons.org/licenses/by-nc-sa/4.0/


πŸ™ Acknowledgments

  • Workfabric Team for dataset collection and curation
  • Domain Experts who participated in workflow data collection

Β© 2025 Workfabric. ENTROPHY is licensed under CC BY-NC-SA 4.0 International.

About

ENTROPHY: Multi-modal User Interaction Data from Live Enterprise Business Workflows

Resources

Stars

0 stars

Watchers

3 watching

Forks

Releases

Packages

Contributors

Languages