Optimize workforce policy tree
Optimize staged team/role capacity actions through uncertain demand by Monte Carlo backward induction.
What it's for
Hiring and staffing decisions are staged, and demand is uncertain. This solves the staged problem backwards, so today's decision accounts for the ones that follow it.
Adds quantified hire, contract, redeploy, freeze, and aggregate capacity scenarios with adaptive checkpoints.
What you give it
Inputs split into evidence read from your connected systems, calibration your team owns, and numerical controls that affect precision but never the result's meaning.
| Field | Type | Role | Required |
|---|---|---|---|
| actions | array of objects (9 fields) | Evidence | Yes |
| checkpoint_week | integer ≥ 1 | Your calibration | Yes |
| current_capacity | number ≥ 0 | Your calibration | Yes |
| demand_scenarios | array of objects (5 fields) | Evidence | Yes |
| excess_cost_per_capacity_week | number ≥ 0 | Your calibration | Yes |
| horizon_weeks | integer ≥ 2 | Your calibration | Yes |
| seed | integer | Numerical control | Optional |
| shortage_cost_per_capacity_week | number ≥ 0 | Your calibration | Yes |
| simulations | integer ≥ 100 | Numerical control | Optional |
| value_per_capacity_week | number ≥ 0 | Your calibration | Yes |
| weekly_discount_rate | number ≥ 0 | Your calibration | Optional |
Each actions
record
| Field | Type | Required |
|---|---|---|
| capacity_delta_high | number | Yes |
| capacity_delta_likely | number | Yes |
| capacity_delta_low | number | Yes |
| id | string (non-empty) | Yes |
| incompatible_with | array of string | Optional |
| ramp_weeks | number (≥ 0) | Yes |
| stage | one of "now", "checkpoint", "both" | Optional |
| upfront_cost | number (≥ 0) | Yes |
| weekly_cost | number | Yes |
{
"actions": [
{
"capacity_delta_high": 3,
"capacity_delta_likely": 2,
"capacity_delta_low": 1,
"id": "hire_pair",
"ramp_weeks": 6,
"stage": "now",
"upfront_cost": 30,
"weekly_cost": 8
},
{
"capacity_delta_high": 4,
"capacity_delta_likely": 3,
"capacity_delta_low": 2,
"id": "contractor",
"ramp_weeks": 1,
"stage": "checkpoint",
"upfront_cost": 10,
"weekly_cost": 12
}
],
"checkpoint_week": 5,
"current_capacity": 6,
"demand_scenarios": [
{
"demand_high": 8,
"demand_likely": 7,
"demand_low": 6,
"id": "base",
"probability": 0.6
},
{
"demand_high": 14,
"demand_likely": 12,
"demand_low": 10,
"id": "growth",
"probability": 0.4
}
],
"excess_cost_per_capacity_week": 8,
"horizon_weeks": 16,
"seed": 19, Truncated for display — the full payload is 48 lines.
What you get back
This is the actual output of running the example above — computed by the same function the platform calls, not an illustration.
{
"decision_tree": [
{
"branches": [
{
"checkpoint_action": "hold",
"expected_npv": 1893.07,
"npv": {
"p10": 1713.077,
"p50": 1918.599,
"p75": 1984.971,
"p90": 2031.905
},
"probability": 0.6,
"probability_negative_npv": 0,
"scenario": "base"
},
{
"checkpoint_action": "contractor",
"expected_npv": 1494.99,
"npv": {
"p10": 846.042,
"p50": 1535.592,
"p75": 1977.361,
"p90": 2095.443
},
"probability": 0.4,
"probability_negative_npv": 0.01,
"scenario": "growth"
}
],
"expected_npv": 1733.84,
"npv": {
"p10": 1148.02,
"p50": 1870.79,
"p90": 2051.89
},
"root_action": "hire_pair"
},
{
"branches": [
{
"checkpoint_action": "contractor",
"expected_npv": 1638.79, Truncated for display — the full payload is 92 lines.
How it works
Constrained optimization — Pick the best feasible option under real limits — budget, headcount, dependencies, capacity — rather than ranking a list and hoping it fits.
- 1 Optimize staged team/role capacity actions through uncertain demand by Monte Carlo backward induction.
- 2 Evaluate the method-specific diagnostics and gates returned by the function, then abstain unless the declared decision clears them under locally governed thresholds.
Before you trust it
Every tool in the catalog ships with the conditions under which its answer is meaningful — and the conditions under which it should abstain instead of guessing.
Assumptions & guardrails
- Objectives use commensurable locally governed value units, constraints reflect real feasibility, and uncertainty covers plausible adverse inputs.
- The recommendation is optimal only for its stated objective, feasible set, evidence, and solver guarantee; it is not a universal management optimum.
Minimum evidence
- demand_scenarios: required and organization-defined
- actions: required and organization-defined
- current_capacity: required and organization-defined
- horizon_weeks: required and organization-defined
- checkpoint_week: required and organization-defined
- value_per_capacity_week: required and organization-defined
- shortage_cost_per_capacity_week: required and organization-defined
- excess_cost_per_capacity_week: required and organization-defined
How to validate it
Backtest the chosen action against simple feasible baselines on held-out scenarios, sweep costs/constraints/risk tolerance, and require constraint feasibility under adverse inputs.
Calibrating it to your org
Same for everyone
The mathematical kernel, validation rules, method version, and JSON output semantics are organization-independent; no tenant-trained coefficients or company benchmark is embedded in the function.
Specific to you
- metric/outcome definitions, entity grain, observation window, costs, thresholds, priors, and constraints represented by the function inputs
Calibration workflow
- 1 Define the management decision, target outcome, aggregate unit, privacy boundary, cadence, and prediction/intervention horizon for this organization.
- 2 Build a tenant-scoped historical cohort using only information available before each prediction or decision; preserve zero periods, censoring, assignment probabilities, and unresolved outcomes when the method requires them.
- 3 Estimate statistical parameters on training history, but obtain costs, utilities, risk tolerance, practical-effect thresholds, capacity, and policy constraints from accountable decision owners.
- 4 Validate on later time windows or held-out aggregate units at the deployment grain, against a simple baseline and the function-specific validation strategy.
- 5 Deploy only if the returned decision clears evidence, overlap, calibration, robustness, and guardrail checks; warning, unsupported, schema-gap, and fallback decisions are abstentions.
- 6 Monitor realized outcomes, data drift, coverage, and decision regret; recalibrate at a governed cadence or after a detected regime/definition change, never merely because a stakeholder dislikes the result.
Call it from your AI
You don't wire up 388 tools in your MCP client. The GitRevio MCP server exposes 18 tools, three of which let an agent search the catalog, read a tool's schema, and run it — so the assistant finds this one on its own.
gitrevio_capabilities_search
{ "q": "optimize staged teamrole capacity actions through" }
→ finds "optimize_workforce_policy_tree"
gitrevio_capability_describe
{ "capability_id": "optimize_workforce_policy_tree" }
→ returns the input schema and agent guidance shown on this page
gitrevio_capability_run
{ "capability_id": "optimize_workforce_policy_tree", "arguments": { ... } }
→ returns the result shown above Works in Claude Desktop, Claude Code, Cursor, Cline, Continue.dev, Goose and Aider. See the MCP server.
Related tools
Fit team behavior regime HMM
Learn persistent privacy-safe team operating regimes and transitions with a Gaussian hidden Markov model.
MCMC project completion forecast
Forecast live task and project completion with a censored Bayesian lognormal model, MCMC uncertainty, dependencies, and finite parallelism.
Simulate contextual thompson bandit
Simulate Bayesian contextual Thompson sampling and quantify intervention reward, regret, and policy uncertainty.
Allocate attention budget
Use exact knapsack optimization to allocate limited expert-review time by expected avoided loss.
Allocate capacity by marginal value
Allocate indivisible aggregate capacity across initiative-specific diminishing marginal-value scenario curves, activation thresholds, hard minimum commitments, unit cost, and portfolio CVaR with discrete next-unit value and explicit solver certainty.
Allocate capacity nash bargaining
Allocate discrete shared capacity by weighted Nash social welfare over concave team utility curves, with disagreement guarantees and a utilitarian counterfactual.