In-depth understanding of jupyter project 1

The Jupyter protocol is an HTTP-based application layer protocol, which defines the interaction between components in Jupyter (such as Notebook, Kernel, Hub, etc.).

The main components of the Jupyter protocol are:

  1. Messaging protocol: defines the format for passing messages between the kernel and the client (Notebook).

There are:

  • Execute : Execute a single code cell.
  • Execute Reply: The result feedback after execution.
  • Input : Kernel input.
  • Output: Kernel output.
  • Stream: Real-time streams such as standard output and standard error.
  1. Protocol version: defines the protocol version supported by Jupyter. Currently, there are mainly two generations of v4 and v5. v5 supports new features such as multi-window and column split.
  2. Trigger: defines when to trigger message delivery, such as triggering the Execute message when the cell is executed.
  3. Magic commands: Special commands starting with %, such as %load, %time, etc.
  4. Content representation: define the data structure representation inside Notebook, such as code cell, text cell, etc.
  5. Security: Defines the authentication and encryption methods used by Jupyter.
  6. Backward Compatibility: In order to maintain compatibility, the newly released version of the protocol still supports the old version.

In general, the Jupyter protocol realizes the communication of various components in the Jupyter ecosystem, such as Notebook and Internal, by defining a standardized interface specification between the kernel and the client.

And to maintain backward compatibility and flexibility, Jupyter supports multiple protocol versions.

The main differences between JupyterLab and Jupyter Notebook are as follows:
  1. Function
  • Jupyter Notebook mainly provides the notebook function, and the operation is relatively simple, and it can only run the notebook.
  • JupyterLab can not only run notebooks, but also provides

Guess you like

Origin blog.csdn.net/zhangzhechun/article/details/131567815