cp-sat-modeling

Design CP-SAT scheduling models with OR-Tools primitives and constraints.

Updated May 6, 2026
One-click install
npx skills add https://github.com/Takfes/indie-scaffolder --skill cp-sat-modeling
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: cp-sat-modeling
Source: https://github.com/Takfes/indie-scaffolder/tree/main/components/agent-skills-commands/.agents/skills/cp-sat-modeling
Command: npx skills add https://github.com/Takfes/indie-scaffolder --skill cp-sat-modeling

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill helps you turn scheduling requirements into a correct CP-SAT model instead of guessing at primitives or overusing boolean decompositions.

Core Features & Use Cases

  • Model construction discipline: Choose intervals, no-overlap, cumulative, circuit, automaton, and alternative-resource patterns.
  • Constraint design: Decide which rules should be hard or soft, and encode penalties with reification and objective tiers.
  • Scaling choices: Set time granularity, horizon bounds, and decomposition strategy for realistic scheduling problems.
  • Use cases: Build a factory schedule, add sequence-dependent setup times, retrofit an existing OR-Tools model, or compare modeling alternatives before coding.

Quick Start

Ask the AI to model your scheduling problem in CP-SAT, identify the right primitives, and propose the objective and decomposition strategy.

Frequently Asked Questions about cp-sat-modeling

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I model a scheduling problem in CP-SAT?

Model a CP-SAT scheduling problem by selecting native primitives like interval variables, no-overlap, and cumulative constraints, then define hard or soft rules using reification and objective tiers to structure the solver's search space.

When should I use no-overlap versus cumulative constraints in OR-Tools?

Use no-overlap constraints for single-machine scheduling where tasks cannot run simultaneously, and apply cumulative constraints for multi-capacity resources to prevent overlapping jobs from exceeding shared capacity limits.

What is the best way to handle soft constraints and penalties in Google OR-Tools?

Handle soft constraints in Google OR-Tools by applying reification to conditionally trigger penalties, then stacking these penalties into objective tiers to prioritize rule violations correctly during optimization.

Can I use CP-SAT for factory scheduling with sequence-dependent setup times?

Yes, CP-SAT handles factory scheduling with sequence-dependent setup times by leveraging circuit or automaton primitives to dictate valid transitions and accurately capture routing penalties between consecutive jobs.

Why does my CP-SAT solver take too long to find a feasible schedule?

Solver performance drops when time granularity is too fine or horizon bounds are unbounded, so applying disciplined decomposition and realistic horizon sizing dramatically reduces the CP-SAT search space.

Do I need to decompose my OR-Tools scheduling model?

Decomposition is necessary for large OR-Tools scheduling models, splitting complex problems into manageable sub-problems to prevent solver timeouts and ensure the CP-SAT engine finds optimal solutions efficiently.