This Tool stores and organizes your custom code snippets within Houdini, allowing you to build and maintain a personalized expression library. It also allows you to quickly browse your collection, and instantly copy any expression with a single click to significantly speed up your workflow.
Expression Manager

Explore my full suite of Python panels for an enhanced workflow. All of these tools share a globally linked color UI, ensuring that your custom interface preferences and accent colors are instantly synced across every panel in the collection.
Installation Guide

1 / 8
Documentation
Expression Manager — Documentation
A Houdini Python Panel for organizing, browsing, and quickly copying HScript expressions and VEX snippets. Part of the tfrog toolset for Houdini 21.
Installation
- Open Houdini
- In Houdini, go to Windows → Python Panel Editor
- Click the New Interface button to create a new interface
- Name it
Expression_Managerand Label itExpression Manager - Activate Include in Pane Tab Menu
- Paste the entire script into the Script tab
- Click Apply / Accept
- Open the panel via New Pane Tab → Python Panel → Expression Manager
Tip: Dock the panel alongside your Parameter Editor or Network Editor for quick access while working.
Interface Overview
The Expression Manager is divided into four main areas:
- Header Bar — Title, tfrog.de label, Scratchpad menu, Import/Export buttons, and Colors button
- Library View — Search bar, category controls, context filter, and expression cards
- Status Bar — Shows the current expression count, scope, and active context filter
- Scratchpad — An editable workspace for modifying expressions before copying them
Managing Categories
Creating a Category
Click the Categories button in the toolbar row and select New Category from the dropdown menu. Enter a name in the dialog that appears. The new category is immediately available in the dropdown.
Switching Categories
Use the dropdown on the left side of the toolbar row. Select All Categories to see every expression across all categories, or pick a specific category to filter.
Renaming a Category
Select the category you want to rename from the dropdown, then click the Categories button and choose Rename. Enter the new name in the dialog.
Sorting Categories
Click the Categories button and select Sort Categories. A dialog opens where you can reorder categories by dragging them or using the arrow buttons (▲▲ top, ▲ up, ▼ down, ▼▼ bottom). Click Apply Order to save the new arrangement.
Deleting a Category
Select the category from the dropdown and click the red Del button. A confirmation dialog will appear. Deleting a category also removes all expressions inside it.
Managing Expressions
Adding an Expression
- Click + Add Expression (green button on the right)
- Fill in the fields:
- Name — A short, descriptive title (e.g. "Noise Displace") - Expression — The HScript expression or VEX snippet (e.g. sin($FF * ch('freq') * 360) * ch('amp')) - Description (optional) — A brief explanation of what the expression does - Context — Select where the expression applies (see Context Tags below)
- Click Save
If you're viewing "All Categories", you'll be asked which category to add the expression to.
Editing an Expression
Click the Edit button on any expression card. The edit dialog opens with the current name, expression, description, and context pre-filled. A Category dropdown is also available — you can use it to move the expression to a different category. Make your changes and click Save.
Deleting an Expression
Click the X button on any expression card. A confirmation dialog will appear before the expression is removed.
Copying an Expression
Click the Copy Expression button on any card. The expression text is copied to your clipboard, and the button briefly shows "Copied!" as confirmation. You can then paste it directly into any Houdini parameter field.
Reordering Expressions (Drag & Drop)
You can reorder expressions within a category by dragging and dropping expression cards. Click and hold on a card (not on a button), then drag it to a new position. A colored indicator line shows where the card will be inserted. The panel auto-scrolls when you drag near the top or bottom edge of the list.
In All Categories view, dragging reorders the expression within its own category based on the visual position. Expressions cannot be moved across categories via drag and drop — use the Edit dialog's category dropdown for that.
Context Tags
Each expression can be tagged with one or more context labels to indicate where it's used:
| Context | Description |
|---|---|
| Global | General-purpose expression — shown in all context filters (default) |
| Point | Runs in a Point context (e.g. Point Wrangle) |
| Primitive | Runs in a Primitive context (e.g. Primitive Wrangle) |
| Vertex | Runs in a Vertex context |
| Detail | Runs in a Detail context |
When adding or editing an expression, context checkboxes are shown. Global is the default. Checking a specific context (Point, Primitive, etc.) automatically unchecks Global, and vice versa. Multiple specific contexts can be selected at the same time. The Global checkbox is disabled while any specific context is active — re-enable it by unchecking all specific contexts first.
Context Filter
Use the context filter dropdown next to the category selector to filter the displayed expressions:
- Global — Shows all expressions (no filtering)
- Point / Primitive / Vertex / Detail — Shows only expressions tagged with that specific context
Context tags appear as small colored badges on each expression card. The active context filter is also reflected in the Status Bar at the bottom of the panel.
Search
Type in the search bar at the top to filter expressions in real time. The search uses Houdini-style fuzzy matching against the expression name: each character group in your query is matched against the beginning of a word in the name. The order of groups does not matter — for example, "nd" matches "Noise Displace" because "n" matches Noise and "d" matches Displace. As a fallback, a simple case-insensitive substring match is also applied. Clear the search field to show all expressions again.
Note: The search only matches against expression names. Description and expression code text are not searched.
Import & Export
The Expression Manager supports sharing expression libraries between users or machines via JSON files.
Exporting Expressions
- Click the Export button (arrow-up icon) in the header bar
- In the Export dialog, check or uncheck the categories you want to include. Use Select All / Select None for quick toggling.
- Click Preview next to any category to see a read-only list of its expressions before exporting
- Click Export Selected and choose a save location. The default filename is
tfrog_expressions.json
Importing Expressions
- Click the Import button (arrow-down icon) in the header bar
- Select a
.jsonfile that was previously exported - In the Import dialog, check which categories to import. Each category shows its expression count and a Preview button.
- Use the Rename To field to change a category's name during import (useful to avoid conflicts with existing categories)
- Click Import Selected
During import, if a category with the same name already exists, its expressions are merged — only expressions with new names are added. Duplicates (matched by name) are skipped.
Scratchpad
The Scratchpad is a dedicated editing workspace where you can modify a copy of an expression before copying it. The original expression in the library is never changed.
Scratchpad Modes
Click the Scratchpad button in the header bar to open a menu with three display modes:
| Mode | Behaviour |
|---|---|
| Inline | Shows the scratchpad as a resizable panel docked at the bottom of the Expression Manager |
| Pop-out | Opens the scratchpad as a separate, free-floating window |
| Both | Opens both the inline panel and the pop-out window simultaneously |
The selected mode is saved persistently in expression_manager_settings.json and restored the next time you open the panel. A checkmark in the menu indicates the active mode.
Opening the Scratchpad
Double-click any expression card to load that expression into the scratchpad and open it according to the current mode setting. When both Inline and Pop-out are visible at the same time, they stay bidirectionally in sync — any edit made in one editor is immediately reflected in the other.
Inline Scratchpad
When open in inline mode, the scratchpad shows:
- Header row — The label "Scratchpad", the source expression name (e.g. "from: Noise Displace"), and Clear / Close buttons
- Size buttons — Quick font size presets: 9, 11, 14, 18, 24
- Editor — A monospace text editor where you can freely modify the expression
- Copy from Scratchpad button — Copies the current editor content to your clipboard
The divider between the Library View and the Scratchpad is draggable. Hover over the border between them and drag up or down to adjust the height.
Clicking the X button hides the inline panel but does not reset the saved mode setting.
Pop-out Window
The pop-out is a standalone floating window with its own editor. It contains:
- Size buttons — Same font size presets as the inline panel (9, 11, 14, 18, 24)
- 📌 Pin button — Toggles Always on Top so the window stays visible above Houdini's other panels. The button stays highlighted while pinning is active; click again to disable.
- Editor — Fully editable, keeps in sync with the inline panel in real time
- Copy from Scratchpad button — Copies the current editor content to your clipboard
If the pop-out is already open when you double-click another card, the existing window is raised and its content is updated rather than a second window being opened. If the window was minimized, it is restored automatically.
Closing the pop-out window does not reset the scratchpad mode — it remains set to "Pop-out" or "Both". Double-clicking a card again reopens the window.
Font Size
You can change the editor font size in two ways:
- Click one of the Size buttons (9, 11, 14, 18, 24) for preset sizes
- Hold Ctrl and scroll the mouse wheel over the editor for fine-grained control (range: 6pt to 36pt)
Focus Behavior
When you hover your mouse away from the Expression Manager panel and back, keyboard focus is automatically restored to whichever input field last had it — either the search bar or the inline Scratchpad editor. This means you can select text, hover over another panel to check something, come back, and immediately continue typing without needing to click first.
Color Settings
Click the Colors button in the header bar to open the Color Settings dialog. These settings are shared across all tfrog tools (Expression Manager, Preset Manager, Shelf Manager, and Relink Paths). Changing a color in one tool updates all others when you hover over them.
Available Color Options
| Setting | What it controls |
|---|---|
| Background | Main panel background color |
| Title | Header title text color |
| Accent (Copy, Apply, Run) | Copy Expression buttons, Scratchpad copy button, focus highlights |
| Accent Text | Text color on accent-colored buttons |
| Secondary (Add, Save) | "+ Add Expression" button and similar action buttons |
| Secondary Text | Text color on secondary buttons |
| Success Feedback | "Copied!" feedback flash color |
| Success Text | Text color on the success flash |
| Code / Expression Text | Expression code text color (the monospace text on each card) |
Click any color swatch to open a color picker. Click Reset to Defaults to restore the original color scheme. Click Save to apply your changes.
Colors are stored in tfrog_colors.json inside your Houdini preferences folder under tfrog/.
Default Expressions
The panel ships with five default categories:
- Math & Noise — Sin Wave, Fit Range, Smooth Step, Pingpong, Random Seed
- Paths & Strings — Render Output, Sim Cache Path, Point Count, Detail Attrib Value
- VEX - Point — Noise Displace, Random Cd, Height Gradient, Random pscale, Orient from Normal, Delete Random Points
- VEX - Primitive — Random Cd per Prim, Delete Small Prims, Group by Normal
- VEX - Detail — Bounding Box, Average Position, Min/Max Attribute
These are written to the JSON on first use and can be freely edited or deleted.
Data Storage
All expression data is saved automatically whenever you make changes. The data files are stored in your Houdini user preferences directory:
$HOUDINI_USER_PREF_DIR/tfrog/expression_manager.json — Your expressions and categories $HOUDINI_USER_PREF_DIR/tfrog/expression_manager_settings.json — Panel settings (e.g. scratchpad mode) $HOUDINI_USER_PREF_DIR/tfrog/tfrog_colors.json — Shared color settings
Keyboard Shortcuts
| Action | Shortcut |
|---|---|
| Search expressions | Click the search bar and type |
| Clear search | Click the X inside the search bar |
| Zoom Scratchpad text | Ctrl + Mouse Wheel (over the editor) |
| Copy from Scratchpad | Edit text, then click "Copy from Scratchpad" |
Tips
- Build your own library — Add expressions you use frequently, organized by category (e.g. "Animation", "Attributes", "USD", "Procedural").
- Use context tags — Tag VEX snippets with their intended context (Point, Primitive, Detail) so you can quickly filter for what you need.
- Choose your Scratchpad mode — Use Inline if you want to stay within the panel, Pop-out for a larger floating editor, or Both to see everything at once.
- Pin the pop-out — Click the 📌 button in the pop-out window to keep it on top of Houdini while you work in other panels.
- Edits sync live — When Inline and Pop-out are both open, they mirror each other in real time. Copy from whichever is more convenient.
- Reorder by dragging — Drag expression cards to rearrange them within a category. Use Sort Categories to reorder the categories themselves.
- Move expressions between categories — Use the Edit dialog's category dropdown to reorganize expressions into different categories.
- Share libraries — Export your expression categories to a JSON file and share them with colleagues. They can import and optionally rename the categories to fit their setup.
- Preview before importing — Use the Preview button in the Import/Export dialogs to inspect a category's expressions before committing.
- Consistent colors — Set your preferred color scheme once in any tfrog tool — it applies everywhere.
- Dock it — The Expression Manager works best docked as a side panel next to your Parameter Editor, so you can quickly copy expressions while adjusting node parameters.