PowerSolver Docs
Back to Wizard

PowerSolver 2.0 Quick Reference

2.0 cheat sheet. Variable types: basic or list. Constraint rules: unassigned_count (hard) and minimize_property (soft). Top-level: collections, variables, shadows, derivedShadows, constraints, config. The full markdown source is ../QUICK_REFERENCE.md.

Wizard Steps

Step Name Key Action
1 Problem Type Select template or custom
2 Entities Define items to plan
3 Values Define resources
4 Constraints Define rules
5 Preview Review configuration
6 Solve Run solver, view results

Constraint Levels

Level Icon Impact Use For
Hard ๐Ÿ”ด Must satisfy Requirements
Medium ๐ŸŸก Should satisfy Important preferences
Soft ๐ŸŸข Nice to have Optimization

Score Reading

-2hard / -1medium / -350soft
  โ”‚        โ”‚          โ”‚
  โ”‚        โ”‚          โ””โ”€โ”€ Soft penalties (optimization)
  โ”‚        โ””โ”€โ”€ Medium violations
  โ””โ”€โ”€ Hard violations (must be 0)

Feasible = Hard score is 0

Common Constraint Types

Constraint Level Description
Skill Match Hard Entity skills โІ Value skills
Capacity Hard Don't exceed limits
Deadline Hard Complete before deadline
No Overlap Hard Same resource, different times
Minimize Cost Soft Reduce total cost
Balance Workload Soft Distribute evenly

API Quick Reference

Solver API (Port 8001) โ€” synchronous

# Submit problem โ†’ returns the FULL solved envelope on the same response.
# 2.0 has no async-job machinery โ€” no polling, no /api/solve/{jobId}/* endpoints.
curl -X POST http://localhost:8001/api/solve \
  -H "Content-Type: application/json" \
  -d @problem.json

# Health check
curl http://localhost:8001/api/health

Support products

# PowerAdmin (wizard field definitions, system config)
curl https://admin-api.planningpowertools.com/health

# PowerAI (LLM-driven spec generation, validation, repair)
curl https://powerai-api.planningpowertools.com/health

# PowerOrchestrator (PDP pipeline runner)
curl https://orchestrator-api.planningpowertools.com/health

N-Variable Format

Variable Types

Type Use Case Example
basic One entity โ†’ One value Task โ†’ Developer
list One entity โ†’ Multiple values Vehicle โ†’ [Stop1, Stop2, Stop3]
Important

Vehicle Routing MUST use list type. All other problem types use basic.

ยง5bis JSON Structure

{
  "problemType": "task-assignment",
  "collections": {
    "resources": [ /* host items */ ],
    "tasks":     [ /* entity items */ ]
  },
  "variables": [
    {"id": "schedule", "type": "list", "on": "resources", "valueRange": "tasks"}
  ],
  "shadows": [
    {"on": "tasks", "name": "previous", "kind": "previousElement", "source": "schedule"},
    {"on": "tasks", "name": "host",     "kind": "inverseRelation", "source": "schedule"}
  ],
  "derivedShadows": [
    {"on": "tasks", "name": "startTime",
     "sources": ["previous.endTime", "host.startTime"],
     "expression": "previous?.endTime ?? host.startTime"},
    {"on": "tasks", "name": "endTime",
     "sources": ["startTime", "this.duration"],
     "expression": "startTime + this.duration"}
  ],
  "constraints": [
    {"name": "All tasks scheduled", "type": "hard", "rule": "unassigned_count",
     "params": {"inverse_field": "host"}, "weight": 100},
    {"name": "High-priority first", "type": "soft", "rule": "minimize_property",
     "params": {"property": "priority"}, "weight": 1}
  ],
  "config": {"timeoutSeconds": 5}
}

Note: 1.x shapes (valueRanges, top-level entities[], chained variable type, schedulingPattern: TIME_GRAIN) are rejected by the 2.0 API. See the 2.0 Quick Reference for the full migration table.

Keyboard Shortcuts

Shortcut Action
Ctrl+S Save problem
Ctrl+Enter Start solving
Escape Stop solving
? Help

Troubleshooting Quick Fixes

Problem Solution
No feasible solution Relax hard constraints or add more values
Poor score Add/adjust soft constraints
Solver slow Reduce timeout, simplify constraints
API offline Check port 8001 (solver), 6379 (redis)

File Locations

Component Path
Solver API powersolver-api/
Wizard powersolver-wizard/
Admin (support product) ../PowerAdmin/poweradmin-api/
AI (support product) ../PowerAI/powerai-api/
ยง5bis Templates timefold-templates/sequence/
Test Corpus powersolver-api/test-cases/
Deploy Scripts ../documentation/installation/
Tests timefold-tests/
Shared Utilities shared/
Docs timefold-guides/Documentation/

Environment URLs

Environment Wizard Solver API Config API
Local localhost:8080 localhost:8001 localhost:8002
Production planning.planningpowertools.com api.planningpowertools.com config.planningpowertools.com

Support