[Canonical page](<https://docs.dhtmlx.com/planning-engine/rust/api/assign/overview/>)
[Full documentation index](<https://docs.dhtmlx.com/planning-engine/llms.txt>)


# plen_assign

The `plen-assign` crate turns a pool of workers with skills and a list of task requirements into the [`Slot`](<https://docs.dhtmlx.com/planning-engine/rust/api/core/suggest/slot.md>) list that [`Project::suggest_assignments`](<https://docs.dhtmlx.com/planning-engine/rust/api/core/project/project.md#suggest_assignments>) takes. The core crate never sees skills. This crate is the only place they exist.

```bash
cargo add plen-assign
```

The crate depends on `plen-core`. It's pure Rust, with no I/O, no feature flags and no `serde` support. Every item is exported at the crate root.

```rust
use plen_assign::{slots, MatchError, Pool, Requirement, Skill, SkillMatch, SkillOp, Worker};
```

The entry point is the [`slots`](<https://docs.dhtmlx.com/planning-engine/rust/api/assign/slots.md>) function. [`Pool`](<https://docs.dhtmlx.com/planning-engine/rust/api/assign/pool.md>), [`Worker`](<https://docs.dhtmlx.com/planning-engine/rust/api/assign/worker.md>) and [`Skill`](<https://docs.dhtmlx.com/planning-engine/rust/api/assign/skill.md>) describe who can be assigned. [`Requirement`](<https://docs.dhtmlx.com/planning-engine/rust/api/assign/requirement.md>), [`SkillMatch`](<https://docs.dhtmlx.com/planning-engine/rust/api/assign/skill-match.md>) and [`SkillOp`](<https://docs.dhtmlx.com/planning-engine/rust/api/assign/skill-op.md>) describe what each task needs. [`MatchError`](<https://docs.dhtmlx.com/planning-engine/rust/api/assign/match-error.md>) is the error `slots` returns. It converts into `plen_core::Error`, so `?` works inside functions that return the core error.

For a walk-through, see [Skills and requirements](<https://docs.dhtmlx.com/planning-engine/rust/resources-and-assignment/skills-and-requirements.md>).

:::category-index
:::