LOT Notebooks for VS Code — v0.8.13
LOT Notebooks is the official Visual Studio Code extension for the Language of Things (LOT) DSL by Coreflux. It turns .lotnb files into rich interactive notebooks that talk directly to your Coreflux MQTT broker — edit, upload, monitor, and manage your entire IoT system without leaving your editor.
What's in this release
| Area |
Headline |
| Cell execution |
Run (▶) downloads broker code into the cell — per-cell upload button pushes |
| Cell status bar |
$(cloud-upload) Upload to broker or $(check) On broker per cell |
| Data Viewer |
Timeline scrubber, multi-topic cards, drag-and-drop, Markdown & HTML rendering |
| Payload rendering |
JSON tree, images, audio, maps, Markdown, HTML, Protobuf decode (beta) |
| MQTT Graph |
Live D3 force-directed topic network graph with message-rate pulse animation |
| MQTT Publish |
Dedicated publish panel with QoS/retain, 50-item history, one-click re-publish |
| Camera Studio |
Camera/video studio opened inside VS Code via local HTTP server |
| ACTION trace |
Debug trace timeline for ACTION cells (requires broker ≥ 1.10.1) |
| Projects |
Zip a local folder and upload; ▶ Run / ■ Stop on each broker project |
| Topic links |
WITH SOURCE_TOPIC / WITH DESTINATION_TOPIC are clickable & highlighted |
| Octopus terminal |
AI-powered broker terminal built into the sidebar |
Core features
1. LOT Language notebook
Create or open .lotnb files to get a notebook UI with full LOT syntax support.
- Code cells for
DEFINE MODEL, DEFINE ACTION, DEFINE RULE, DEFINE ROUTE, DEFINE VISU, and Python scripts
- Markdown cells with a formatting toolbar (bold, italic, code, headings, tables, lists…)
- Syntax highlighting, code completions (
Ctrl+Space), and clickable topic links
2. Broker sync — pull and push, not execute
Run (▶) on a cell downloads the entity code from the broker into that cell:
- If the cell already matches the broker, nothing changes (idempotent).
- If the broker doesn't have the entity yet, the output explains how to upload.
Per-cell upload button ($(cloud-upload) Upload to broker) in the cell status bar sends the cell content to the broker with -addModel / -addAction / -addRule / -addRoute / -addVisu / -addPython. It only appears when the cell differs from the broker.
Per-cell check ($(check) On broker) appears when the cell is in sync — no action needed.
3. Coreflux Explorer
A sidebar panel showing every entity on the connected broker in real time:
- Entities: Models, Actions, Rules, Routes, Python Scripts — with sync status vs notebook cells
- Broker: License info, active sessions, connected clients
- Configuration: Environment variables and secrets
- Projects: Broker-side project list with inline Run / Stop controls
Right-click any entity to: copy code, go to cell, push cell to broker, pull from broker, create a definition, remove from broker, or remove all of a category.
4. Data Viewer
Live MQTT topic tree in the sidebar — subscribes and shows payloads as they arrive, with a blink decoration on updates.
| Button |
What it does |
$(add) Subscribe… |
Subscribe to a specific topic |
$(globe) Subscribe to # |
Receive every topic the broker delivers to this client |
$(clear-all) Unsubscribe All |
Clear all manual subscriptions |
Click any topic value to open a rich payload viewer (JSON tree, image preview, HTML iframe, audio player, charts for numeric streams).
5. Project management
Broker-side projects (collections of .lotnb files stored on the broker) are managed directly:
| Command / Button |
MQTT command sent |
| ▶ Run on a project |
-loadProject <name> — starts the project, replaces current entities |
| ■ Unload on active project |
-unloadProject |
| Switch Broker Project |
quick pick → -unloadProject then -loadProject <new> |
| Add Project |
-addProject <git-url \| path \| zip64:…> [branch \| name \| load] |
| Remove Project |
-removeProject <name> |
| Refresh Broker Projects |
-listProjects |
| Zip Folder and Send to Broker |
Zips the workspace (or any folder) and sends -addProject zip64:… with upload-only or upload+load |
After a zip upload-only upload, the project row appears in the explorer — click ▶ Run to start it.
6. Topic links
Every MQTT topic string in a LOT cell is underlined and clickable (opens a subscribe/publish menu):
PUBLISH TOPIC "…"
ON TOPIC "…", WITH TOPIC "…", KEEP TOPIC "…", GET TOPIC "…"
WITH SOURCE_TOPIC "…" and WITH DESTINATION_TOPIC "…" (ROUTE keywords)
INTERACTION_TOPIC "…" (agent routes)
SOURCE_TOPIC and DESTINATION_TOPIC are also syntax-highlighted as route keywords.
7. Octopus AI terminal
The Octopus terminal (sidebar or Coreflux: Open Octopus Terminal) connects to the broker's AI agent endpoint. It supports multi-session management and streams responses in real time with an animated octopus character.
8. FluxLoT visual editor
Open any LOT cell with Open FluxLoT Visual Editor ($(symbol-structure) in the cell toolbar) to see a visual node graph for that entity alongside the text editor.
9. Python scripting
Python cells are fully managed entities on the broker:
# Script Name: MyScript
def greet(name="World"):
return f"Hello, {name}!"
The # Script Name: header is required. Run (▶) pulls from the broker; the upload button in the cell status bar pushes with -addPython.
Getting started
- Install the extension and open (or create) a
.lotnb file.
- Connect to your Coreflux broker — click the status bar item or run
Coreflux: Connect to MQTT Broker.
- Write LOT code in a cell, e.g.:
DEFINE ACTION Heartbeat
ON EVERY 5 SECONDS DO
PUBLISH TOPIC "system/heartbeat" WITH "alive"
- Check the cell status bar: Missing + Upload to broker → click it to deploy.
- Once deployed, the status becomes Synced $(check) On broker.
- Press ▶ at any time to pull the latest broker version back into the cell.
MQTT credential configuration
Run LOT Notebook: Change Credentials from the command palette to set:
- Broker URL (e.g.
mqtt://localhost:1883 or mqtts://…)
- Username / password
- Optional TLS/mTLS certificates
Credentials are stored in VS Code's secret storage.
Commands reference
Notebook & cells
| Command |
Description |
| LOT Notebook: Create |
Create a new .lotnb notebook |
| LOT Notebook: Change Credentials |
Configure broker URL and credentials |
| Upload LOT Cell to Broker |
Push the active LOT cell to the broker |
| lot.openVisualEditor |
Open FluxLoT visual editor for the active cell |
| lot-notebook.lot.topicMenu |
Subscribe / publish quick-pick for the active cell |
| Subscribe to Selected Topic |
Subscribe to the selected topic text |
| Subscribe with Wildcard |
Subscribe to selected topic /# |
| Quick Subscribe |
Type any topic to subscribe |
| Publish to Selected Topic |
Publish a payload to the selected topic |
Entity management
| Command |
Description |
| Coreflux: Refresh |
Refresh the entity tree |
| Coreflux: Copy Code |
Copy entity code to clipboard |
| Coreflux: Update Cell from Coreflux |
Pull broker code → cell |
| Coreflux: Update Coreflux from Cell |
Push cell code → broker |
| Coreflux: Create Definition in Notebook |
Insert a DEFINE statement at cursor |
| Coreflux: Remove Entity from Coreflux |
Remove entity from broker |
| Coreflux: Remove All Models / Actions / Rules / Routes / Python Scripts |
Bulk remove by category |
Data Viewer
| Command |
Description |
| Subscribe to Topic |
Subscribe to a specific topic |
| Subscribe to # |
Subscribe to all topics (# wildcard) |
| Unsubscribe All |
Clear all subscriptions |
Project management
| Command |
Description |
| Run Project on Broker |
-loadProject on the selected project |
| Load Project |
Same as Run — load a project by name |
| Unload Active Broker Project |
-unloadProject |
| Switch Broker Project |
Quick pick to switch between broker projects |
| Add Project to Broker |
Add via Git URL or path |
| Zip Folder and Send to Broker |
Zip local folder and upload as zip64 |
| Remove Project |
Delete project from broker |
| Refresh Broker Projects |
Refresh project list |
Requirements
Known issues
- Cells without a valid
DEFINE … header show Invalid status — add the proper LOT definition to resolve.
- Python cells require the
# Script Name: … first line; missing it shows a clear error in the cell output.
- Very large project folders may produce large
zip64 MQTT payloads; broker payload size limits apply.
Further reading
Made by the Coreflux team with a LOT of love ❤️