Skip to content

API Reference parrot.models.compliance

github-actions[bot] edited this page Dec 2, 2026 · 4 revisions

parrot.models.compliance

View source

Class BrandComplianceResult

Result of brand logo compliance checking

Fields:

Field Type Default Description
expected_brand str
found_brand Optional[str] None
found bool False
confidence float 0.0

Class ComplianceResult

Final compliance check result

Fields:

Field Type Default Description
shelf_level str Shelf level being checked
expected_products List[str] Products expected on this shelf
found_products List[str] Products actually found
missing_products List[str] Expected but not found
unexpected_products List[str] Found but not expected
compliance_status ComplianceStatus Overall compliance for this shelf
compliance_score float Compliance score
text_compliance_results List[TextComplianceResult]
brand_compliance_result Optional[BrandComplianceResult] Result of the brand logo compliance check.
text_compliance_score float 1.0
overall_text_compliant bool True
assessment Optional[ShelfAssessment] None Additive assessment metadata; None for legacy producers.

Class ComplianceStatus

Possible compliance statuses for shelf checks

Class ShelfAssessment

Additive shelf assessment metadata (FEAT-574). Every field is optional so legacy producers need not set it.

Fields:

Field Type Default Description
assessment_status Optional[str] None complete | inconclusive | legacy_unmeasured
coverage Optional[float] None Resolved facings / expected facings on this shelf
strict_score Optional[float] None
lenient_score Optional[float] None
expected_facings Optional[int] None
resolved_facings Optional[int] None
unresolved_facing_ids List[str]
rule_results List[Dict[str, Any]]
info_results List[Dict[str, Any]]

Class TextComplianceResult

Result of text compliance checking

Fields:

Field Type Default Description
required_text str
found bool
matched_features List[str]
confidence float
match_type str

Class TextMatcher

N-gram + fuzzy text matcher for planogram text compliance.

"exact" requires the whole phrase on word boundaries (after normalization) and never falls back to fuzzy matching; "contains" is a plain substring test of the normalized text.

Method TextMatcher.check_text_match

check_text_match(required_text: str, visual_features: List[str], match_type: str = 'contains', case_sensitive: bool = False, confidence_threshold: float = 0.6, ngram_range: Tuple[int, int] = (1, 3), min_token_len: int = 2)

Parameter Type Default Description
required_text str
visual_features List[str]
match_type str 'contains'
case_sensitive bool False
confidence_threshold float 0.6
ngram_range Tuple[int, int] (1, 3)
min_token_len int 2

Architecture

Clients

Bots & Agents

Memory

Knowledge

Tools & Toolkits

Flows

Experts

Skills

Stores & Loaders

MCP & A2A

Server & APIs

Integrations

Outputs & A2UI

Prompts

Security

Operations

Migration

SDD Tooling

LLM Wiki

Deployment

Decisions

API Reference

Clone this wiki locally