feat(notebook): document session with shared kernels and view controls
D1/D2: 内核表/会话表 parsing, DocumentSession cell index, named/default kernels, shared state + isolation, run_cell/step/run_all/restart/assign, state bridge, journal, POST /api/session/*, and a live-view notebook bar with status badges, per-cell kernel selector, step/run-all and push/pull state form.
This commit is contained in:
1 parent
050d71927f
commit
3001ed7ba5
14 files changed
+1582
-8
No files matched your search
@@ -0,0 +1,35 @@
|
||||
---
|
||||
title: notebook shared state
|
||||
---
|
||||
|
||||
# main
|
||||
|
||||
`内核表` =
|
||||
|
||||
| 名称 | 语言 | 命令 | 说明 |
|
||||
|------|------|------|------|
|
||||
| 分析 | node | | 共享状态的内核 |
|
||||
| 绘图 | node | | 隔离的内核 |
|
||||
|
||||
`会话表` =
|
||||
|
||||
| 单元 | 内核 | 说明 |
|
||||
|------|------|------|
|
||||
| 设置 | 分析 | 写入共享变量 |
|
||||
| 读取 | 分析 | 读取共享变量 |
|
||||
| 隔离 | 绘图 | 看不到 shared |
|
||||
|
||||
`设置` =
|
||||
```node
|
||||
let shared = 41;
|
||||
```
|
||||
|
||||
`读取` =
|
||||
```node
|
||||
console.log(shared + 1);
|
||||
```
|
||||
|
||||
`隔离` =
|
||||
```node
|
||||
console.log(typeof shared === "undefined" ? "isolated" : "leaked");
|
||||
```
|
||||
Reference in new issue
Block a user