export const frontmatter = {
  title: 'Create',
  description: 'Create widgets from natural language prompts and data sources.'
};

Create widgets from natural language prompts and data sources.

<WidgetPreview src="/widgets/bar_chart_revenue.js" height={380} />

```python
import vibe_widget as vw

widget = vw.create(
    "bar chart of revenue by region",
    df
)

widget
```

## Themes

Themes are natural-language design specs that guide code generation.

```python
vw.create("...", df, theme="financial_times")
```

Use `vw.theme(...)` to generate a custom theme description and pass it in.

## Inputs, outputs, and actions

You can also add inputs, outputs, and actions to wire widgets together or trigger behavior from
Python. For the full model and examples, see [Reactivity](/docs/reactivity).

## Safety warning

Widgets execute LLM-generated JavaScript in the notebook frontend. Treat generated code as untrusted. Use audits and your own verification when the output informs decisions.
