# lawref.screen

*module*

Population screening filter (DECISION-0120).

This first slice owns the pinned source binding.  The binding is both a map
for a future host renderer and an exact contract of predicates that this data
source may assert.  Unlisted predicates are therefore derived-only for this
integration; silently accepting one would recreate the open input boundary
that stopped DECISION-0119.

## lawref.screen.DISCLAIMER

*attribute* · *module attribute*

```python
DISCLAIMER = 'Фильтр не есть правовой ответ: он задаёт только необходимое условие-надмножество; право по каждой прошедшей строке обязан полностью посчитать движок с proof-графом на том же снимке данных.'
```

[View source](https://github.com-arxohq/arxo-io/law/blob/2edc2b92ce22b52e03f4081d2769a58229684379/engines/lawref/lawref/screen.py#L23-L25)

## lawref.screen.SCHEMA_VERSION

*attribute* · *module attribute*

```python
SCHEMA_VERSION = 'law.screen/0.1'
```

[View source](https://github.com-arxohq/arxo-io/law/blob/2edc2b92ce22b52e03f4081d2769a58229684379/engines/lawref/lawref/screen.py#L22-L22)

## lawref.screen.ScreenError

*class*

```python
class ScreenError(ValueError)
```

Bases: `ValueError`

Stable screening diagnostic with a machine-readable code.

[View source](https://github.com-arxohq/arxo-io/law/blob/2edc2b92ce22b52e03f4081d2769a58229684379/engines/lawref/lawref/screen.py#L28-L33)

### lawref.screen.ScreenError.code

*attribute* · *instance attribute*

```python
code = code
```

[View source](https://github.com-arxohq/arxo-io/law/blob/2edc2b92ce22b52e03f4081d2769a58229684379/engines/lawref/lawref/screen.py#L33-L33)

## lawref.screen.binding_content_hash

*function*

```python
def binding_content_hash(binding: dict) -> str
```

Canonical hash of a binding excluding its own `contentHash`.

[View source](https://github.com-arxohq/arxo-io/law/blob/2edc2b92ce22b52e03f4081d2769a58229684379/engines/lawref/lawref/screen.py#L36-L38)

## lawref.screen.build

*function*

```python
def build(document: dict, goal: str, binding: dict, legal_time: str | None = None, *, coverage_omit: set[str] | None = None) -> dict
```

Build a typed necessary-condition tree and its widening manifest.

[View source](https://github.com-arxohq/arxo-io/law/blob/2edc2b92ce22b52e03f4081d2769a58229684379/engines/lawref/lawref/screen.py#L511-L570)

## lawref.screen.contract_island

*function*

```python
def contract_island(document: dict, binding: dict) -> dict
```

Static DECISION-0119 island under this exact assertable contract.

This deliberately reports rule membership, not a cache speedup: runtime
solve/application/CPU profiling belongs to a future cache decision.  A
non-zero result proves only that the open-input blocker of 0119 is gone.

[View source](https://github.com-arxohq/arxo-io/law/blob/2edc2b92ce22b52e03f4081d2769a58229684379/engines/lawref/lawref/screen.py#L111-L130)

## lawref.screen.load_binding

*function*

```python
def load_binding(path: str | Path, document: dict, source_schema_hash: str | None = None) -> dict
```

Read and validate a binding; malformed JSON is a stable loud refusal.

[View source](https://github.com-arxohq/arxo-io/law/blob/2edc2b92ce22b52e03f4081d2769a58229684379/engines/lawref/lawref/screen.py#L101-L108)

## lawref.screen.render_text

*function*

```python
def render_text(report: dict) -> str
```

[View source](https://github.com-arxohq/arxo-io/law/blob/2edc2b92ce22b52e03f4081d2769a58229684379/engines/lawref/lawref/screen.py#L577-L595)

## lawref.screen.report_bytes

*function*

```python
def report_bytes(report: dict) -> bytes
```

[View source](https://github.com-arxohq/arxo-io/law/blob/2edc2b92ce22b52e03f4081d2769a58229684379/engines/lawref/lawref/screen.py#L573-L574)

## lawref.screen.validate_binding

*function*

```python
def validate_binding(binding: Any, document: dict, source_schema_hash: str | None = None) -> dict
```

Validate shape, self pin, source pin and CLIR declaration agreement.

[View source](https://github.com-arxohq/arxo-io/law/blob/2edc2b92ce22b52e03f4081d2769a58229684379/engines/lawref/lawref/screen.py#L45-L98)
