> ## Documentation Index
> Fetch the complete documentation index at: https://docs.uniac.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# NodeSpec

> Shared parent of Service and System.

`uniac.NodeSpec` is the internal base class that both [`Service`](/sdk/service) and [`System`](/sdk/system) extend. User code rarely references it directly, but the two hooks it provides are what makes the framework non-magical.

## Methods

### `_uniac_validate()`

Called once by [`load`](/sdk/load) after construction. Walks every class-level annotation across the MRO; for each annotation typed as a [`Node`](/sdk/node) subclass, asserts that the corresponding instance attribute is set and is the right type. Raises [`UniacValidationError`](/sdk/exceptions) on mismatch. Records the owner relationship on each owned Node.

### `_uniac_walk()`

Yields the directly-owned `Node` instances in declaration order. The CLI uses this during `uniac deploy` to extract the topology.

## Why this matters

There is no annotation auto-instantiation. The annotation says *"this slot must hold a Node of type X"*; your `__init__` puts the value there. `_uniac_validate` enforces the contract loudly at startup so wiring bugs surface immediately instead of at first request.
