propose

package
v1.9.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 3, 2026 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Overview

Package propose implements human-gated requirement decomposition.

The machine proposes atomic children of a coarse requirement; it never auto-approves them. Proposed children land in a non-claimable "proposed" state, inherit the parent's acceptance tests, are bounded by a depth limit and a child cap, and are each tagged machine-authored in the audit trail. See skills/decomposition/SKILL.md.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Bounds

type Bounds struct {
	// MaxDepth is the maximum decomposition depth (1 = direct children only).
	MaxDepth int
	// MaxChildren is the maximum number of children per parent.
	MaxChildren int
}

Bounds limits a decomposition so a split cannot run away.

func DefaultBounds

func DefaultBounds() Bounds

DefaultBounds returns conservative decomposition bounds.

type Proposal

type Proposal struct {
	// Parent is the requirement that was decomposed.
	Parent string
	// Children are the proposed atomic children, all in StatusProposed.
	Children []rtmx.Requirement
}

Proposal is the result of decomposing a parent requirement.

type Proposer

type Proposer struct {
	// Bounds limits the split.
	Bounds Bounds
	// Audit records machine-authored provenance for every child.
	Audit *audit.Log
}

Proposer turns coarse requirements into bounded, human-gated proposals.

func New

func New(bounds Bounds, log *audit.Log) *Proposer

New returns a Proposer with the given bounds and audit log.

func (*Proposer) Propose

func (p *Proposer) Propose(ctx context.Context, parent rtmx.Requirement, childTitles []string) (*Proposal, error)

Propose decomposes parent into atomic child requirements described by titles. Each child inherits the parent's tests, is set to StatusProposed (not claimable), and is recorded machine-authored in the audit trail. Exceeding the child cap is a hard stop that asks for a human decision.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL