compassbridge

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Sep 8, 2026 License: MIT Imports: 8 Imported by: 0

Documentation

Overview

Package compassbridge turns a compass-rice judge.Output into a prism-roadmap assessment.CompassAssessment, and implements the two-phase (LLM-proposed, PM-confirmed) profile assignment workflow — the runtime half of INIT-OMNIROADMAP-001's COMPASS-RICE integration, mirroring omnisignalbridge's role of owning the dependency on prism-roadmap's ranking types on behalf of an upstream producer.

Ingest never trusts a judge's self-reported confidence: it compares the Confidence tier compass-rice's Normalizer derived from the evidence struct's self-reported source counts against the Confidence tier compass-rice's provenance package derives independently from the judge's actual verified claims, and rejects the assessment if the evidence struct claims more confidence than the claims support.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AssignProfileDirectly

func AssignProfileDirectly(specID string, profileID rice.ProfileID, rationale, confirmedBy string, confirmedAt time.Time) (assessment.ProfileAssignment, error)

AssignProfileDirectly creates and immediately confirms a profile assignment in one step — the path for a PM who selects a profile directly, without a prior LLM proposal.

func ConfirmProfile

func ConfirmProfile(current assessment.ProfileAssignment, confirmedBy string, confirmedAt time.Time) (assessment.ProfileAssignment, error)

ConfirmProfile confirms a proposed profile assignment (the PM phase). Returns an error if current is not currently proposed — an already confirmed or rejected assignment must go through a new ProposeProfile cycle before it can be confirmed again.

func FirstCycleWithCompass

func FirstCycleWithCompass(id string, ref assessment.OpportunityRef, title string, assessedAt time.Time, c assessment.CompassAssessment) *assessment.OpportunityAssessment

FirstCycleWithCompass creates the first assessment cycle for an opportunity, with a COMPASS-RICE assessment already attached.

func Ingest

func Ingest(output judge.Output) (assessment.CompassAssessment, error)

Ingest converts a compass-rice judge.Output into a CompassAssessment: normalizes the evidence via the compass-rice catalog, verifies the evidence's self-reported confidence doesn't exceed what the judge's verified claims actually support, and captures whether the assessment needs human review before it can be trusted for scoring.

func IngestHumanEvidence

func IngestHumanEvidence(profileID rice.ProfileID, evidenceJSON json.RawMessage, enteredBy string, enteredAt time.Time) (assessment.CompassAssessment, error)

IngestHumanEvidence converts human-entered raw evidence directly into a CompassAssessment, bypassing the judge.Output/confidence-integrity path: a human who typed the evidence themselves is trusted at face value (no claims to cross-check), and the resulting assessment is marked as already human-reviewed -- there is no pending judge output to accept.

func NextCycleWithCompass

NextCycleWithCompass creates the next assessment cycle for prev's opportunity, with a COMPASS-RICE assessment already attached — the mechanism for re-scoring an opportunity (a corrected evidence document, or a PM's HumanReview acceptance) without mutating a past cycle.

prev.NextCycle itself only carries forward Opportunity/Title/Cycle (every other field starts blank, so a caller must explicitly re-supply what a genuinely new judgment changed). Since NextCycleWithCompass only intends to change Compass, it carries every other field forward unchanged first — otherwise re-scoring an opportunity would silently drop its MoSCoW answers, dimensions, OKR contributions, and capability references.

func ProposeProfile

func ProposeProfile(specID string, profileID rice.ProfileID, rationale, proposedBy string) (assessment.ProfileAssignment, error)

ProposeProfile creates a proposed profile assignment (the judge phase of the two-phase workflow) and validates it before returning.

func RejectProfile

func RejectProfile(current assessment.ProfileAssignment, rejectedBy string, rejectedAt time.Time, rationale string) (assessment.ProfileAssignment, error)

RejectProfile rejects a proposed profile assignment, recording why (e.g. the judge proposed the wrong profile and a new proposal is needed). Returns an error if current is not currently proposed.

Types

type IngestError

type IngestError struct {
	RepairPrompts []string
	// contains filtered or unexported fields
}

IngestError wraps an Ingest failure that a repair pass could address, carrying compass-rice's own RepairPrompts() for the reason codes attached to the judge output's categories.

func (*IngestError) Error

func (e *IngestError) Error() string

func (*IngestError) Unwrap

func (e *IngestError) Unwrap() error

Jump to

Keyboard shortcuts

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