FabLL

Map Python node and trait declarations to a live TypeGraph and instance graph.

3.6k|225|Updated Dec 19, 2023
One-click install
npx skills add https://github.com/atopile/atopile --skill fabll
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: FabLL
Source: https://github.com/atopile/atopile/tree/main/.claude/skills/fabll
Command: npx skills add https://github.com/atopile/atopile --skill fabll

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

FabLL bridges Python node and trait declarations to the TypeGraph and the instance graph, enabling clean modeling of hardware components by preserving field invariants and trait semantics.

Core Features & Use Cases

  • Mapping Python node/trait declarations into the TypeGraph and the instance graph, with automatic maintenance of field and trait invariants.
  • Support for binding, validation, and instantiation of component graph structures.
  • Use Case: Define a Node subclass in Python and generate a bound typegraph instance for rapid prototyping and testing of hardware components.

Quick Start

  1. Create a GraphView and a TypeGraph g = graph.GraphView.create() tg = fbrk.TypeGraph.create(g=g)
  2. Define a Node subclass class App(fabll.Node): pass
  3. Bind and instantiate app = App.bind_typegraph(tg=tg).create_instance(g=g)

Frequently Asked Questions about FabLL

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I map Python node declarations to a TypeGraph for hardware component modeling?

To map Python node declarations to a TypeGraph, create a GraphView and TypeGraph, define a Node subclass, and use bind_typegraph to generate a bound instance for hardware modeling.

How does TypeGraph binding enforce field and trait invariants during component instantiation?

TypeGraph binding enforces field and trait invariants by automatically maintaining validation and resolution rules during instance creation, ensuring predictable composition and reuse for hardware components.

Can I use Python to bind and validate hardware component graph structures without manual graph updates?

Yes, you can bind and validate hardware component graph structures in Python by defining Node subclasses and relying on the TypeGraph backend to automatically maintain field and trait invariants.

What is the best way to instantiate a hardware component from a Python Node subclass in faebryk?

The best way to instantiate a hardware component from a Python Node subclass is to call bind_typegraph on your Node class, then invoke create_instance with the active GraphView.

Do I need to manually maintain trait semantics when generating an instance graph for hardware components?

No, you do not need to manually maintain trait semantics; the TypeGraph backend automatically preserves and enforces trait semantics and field invariants during instance graph generation.

When should I use TypeGraph instance creation for hardware component modeling instead of standard Python classes?

You should use TypeGraph instance creation instead of standard Python classes when you need strict type binding, automatic trait resolution, and enforced field invariants for complex hardware composition.