neurosift-blog

December 2024

Neurosift blog main page

Chat Interface for NWB File Exploration

2024-12-12

Here’s how you can explore NWB files interactively using the Neurosift chat interface.

  1. Open an NWB File
    Use Neurosift to load an NWB file. For example, open this file from Dandiset 000473:
    NWB File Example

  2. Access the Chat Interface
    Click the chat icon on the left panel. The chat agent can:
    • Analyze the contents of the NWB file.
    • Generate and execute Python code for data exploration or plotting using your Jupyter kernel.
    • Embed resulting plots and interactive Neurosift views directly into the chat.
  3. Example Prompts
    Try these commands to explore the file:
    • Provide an overview of this NWB file.
    • Show an interactive raster plot.
    • Plot the face motion data (3 channels on the same axis).
    • Plot other behavioral data.
    • Plot the first second of the three plots, starting at the initial time.
    • Plot the first 100ms of one channel of the LFP data.
    • Plot one of the unit waveforms.
    • Show histograms for the peak onset time, peak to onset and some other colums of the units table
    • Plot the waveforms for the 5 units with the longest duration.
    • Show the raster plot for the 5 units that have the longest duration in the units table. (Doesn’t actually work, but you can see that it tries by doing a computation followed by an interactive plot)

Code execution. The chat agent will request permission to use your Jupyter kernel when executing code. You can review the scripts and view the outputs directly in the chat interface.

You can download your chats for later reference or save them to the cloud. You can also provide feedback on the chat agent’s performance to help improve its capabilities.

NWB File Exploration

Here are the natural language instructions to the chat agent: systemMessage.ts

And here are the tools that are available to it:

Interactive neurosift views embedded in a document: Dandiset 000473

2024-12-02

I’ve created a new interactive page for Dandiset 000473: https://figurl.github.io/dandiset-000473. It’s designed to showcase Neurosift widgets embedded in a markdown document.

The document features zoomable spike density plots and a units table for each session. These plots are built using multiscale arrays for smooth rendering, even when zooming in to explore spike structure. You can also toggle Rastermap ordering of units and view units tables directly on the page. For sessions with behavioral data, those details are integrated as well. Clicking on a session will take you to the full Neurosift view for deeper exploration.

image