Skip to content

Comments

🚀 Feat: pipeline execution constraints + adapt pydantic objects#44

Merged
nicofretti merged 9 commits intodevelopfrom
feat/pipeline-config
Nov 22, 2025
Merged

🚀 Feat: pipeline execution constraints + adapt pydantic objects#44
nicofretti merged 9 commits intodevelopfrom
feat/pipeline-config

Conversation

@nicofretti
Copy link
Owner

@nicofretti nicofretti commented Nov 22, 2025

Description

  • New lib/entities/pipeline.py module with Pydantic models: ExecutionResult, Constraints, and Usage
  • Constraint enforcement in two paths: multiplier pipelines (workflow.py) and normal pipelines (job_processor.py)
  • Storage layer migration from dicts to PipelineRecord and Job Pydantic models
  • Frontend UI for setting constraints and displaying usage stats with theme-compatible styling
  • Comprehensive test coverage for constraint enforcement (13 new tests in test_constraints.py)

Related Issue

Checklist

  • Code follows project style guidelines
  • Comments explain "why" not "what"
  • Documentation updated (if needed)
  • No debug code or console statements
  • make format passes
  • make pre-merge passes
  • PR update from develop branch
  • Copilot review run and addressed

@nicofretti nicofretti self-assigned this Nov 22, 2025
@nicofretti nicofretti changed the title 🚀 Feat: pipeline execution constraints 🚀 Feat: pipeline execution constraints + adapts pydantic objects Nov 22, 2025
@nicofretti nicofretti changed the title 🚀 Feat: pipeline execution constraints + adapts pydantic objects 🚀 Feat: pipeline execution constraints + adapt pydantic objects Nov 22, 2025
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR introduces pipeline execution constraints (token limits, execution time limits) and migrates storage/API responses from dict-based to Pydantic-based data models for better type safety and structure.

Key Changes:

  • New lib/entities/pipeline.py module with Pydantic models: ExecutionResult, Constraints, and Usage
  • Constraint enforcement in two paths: multiplier pipelines (workflow.py) and normal pipelines (job_processor.py)
  • Storage layer migration from dicts to PipelineRecord and Job Pydantic models
  • Frontend UI for setting constraints and displaying usage stats with theme-compatible styling
  • Comprehensive test coverage for constraint enforcement (13 new tests in test_constraints.py)

Reviewed changes

Copilot reviewed 33 out of 33 changed files in this pull request and generated 11 comments.

Show a summary per file
File Description
lib/entities/pipeline.py New Pydantic models for execution results, constraints, and usage tracking
lib/workflow.py Updated to return ExecutionResult, added constraint checking for multiplier pipelines
lib/job_processor.py Added constraint checking for normal pipelines, usage accumulation
lib/storage.py Migrated from dict returns to PipelineRecord/Job Pydantic models
lib/job_queue.py Added usage tracking initialization, JSON parsing for usage updates
models.py New Job and PipelineRecord Pydantic models
app.py Updated endpoints to work with Pydantic models
tests/test_constraints.py Comprehensive constraint enforcement tests (729 lines)
tests/test_*.py Updated assertions to use ExecutionResult instead of tuple unpacking
frontend/* UI for constraints configuration and usage display with proper theme variables
llm/*.md Updated documentation for new constraint feature
debug_pipeline.py Updated to use new Pydantic model (incomplete)

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@nicofretti nicofretti merged commit 8f6943f into develop Nov 22, 2025
1 check passed
@nicofretti nicofretti deleted the feat/pipeline-config branch December 15, 2025 20:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant