One binary: the lint and the trainer are commands of portal #7

Merged
bl merged 112 commits from one-binary into main 2026-09-30 13:33:14 +00:00
Showing only changes of commit 2622fdac88 - Show all commits
+17 -1
View File
@@ -84,7 +84,10 @@ needs:
# aggregates.yaml already has, so its records keep replaying
attended_by: > # ONLY for a stage no desk button moves: the automation that does
what moves it, in a sentence
max_fields: 4 # how many required fields THIS person will tolerate, from what
max_fields: 4 # decide this BEFORE writing collects, from what the intake
# says about the person; a budget that equals the form's size
# is counted, not decided, and is reported as such
# how many required fields THIS person will tolerate, from what
# the intake says about them: someone on a phone with gloves
# on gets 3, a first enquiry 4 to 6, a firm's paperwork 5 to 6
collects: # the form; name is snake_case ASCII, type one of
@@ -225,6 +228,19 @@ pub fn run(argv: &[String]) -> anyhow::Result<()> {
if !strangers.is_empty() {
eprintln!(" {} persona(s) name a need this plan does not have; set their `need:` to one of the ids above before building:\n {}", strangers.len(), strangers.join("\n "));
}
// A budget that equals the form is the tell of a model
// that counted the form and called it the person's
// tolerance. One such need is a form that uses its
// room; most of them is the number being invented.
let tight: Vec<&str> = plan
.needs
.iter()
.filter(|n| n.collects.iter().filter(|f| !f.optional).count() == n.max_fields)
.map(|n| n.id.as_str())
.collect();
if tight.len() * 2 > plan.needs.len() && tight.len() > 1 {
eprintln!(" {} of {} need(s) have max_fields equal to their required fields ({}): check each against what the intake says about that person, not the form", tight.len(), plan.needs.len(), tight.join(", "));
}
println!(
"plan written to {}; read it before building from it",
out.join("plan.yaml").display()