visualproof 0.6.0 → 0.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/dist/extractor/Extract.lean +13 -3
- package/dist/server/agent.js +102 -2879
- package/dist/server/agentactivity.js +72 -0
- package/dist/server/agentadvice.js +115 -0
- package/dist/server/agentdocs.js +1 -1
- package/dist/server/agententry.js +180 -0
- package/dist/server/agentexport.js +469 -0
- package/dist/server/agentfollow.js +384 -0
- package/dist/server/agentgraph.js +128 -0
- package/dist/server/agentlean.js +144 -0
- package/dist/server/agentlibrary.js +1 -1
- package/dist/server/agentplaces.js +242 -0
- package/dist/server/agentread.js +569 -0
- package/dist/server/agenttalk.js +282 -0
- package/dist/server/agenttcb.js +378 -0
- package/dist/server/agentviews.js +2 -2
- package/dist/server/app.js +377 -0
- package/dist/server/appaccess.js +127 -0
- package/dist/server/appagent.js +110 -0
- package/dist/server/appgraph.js +176 -0
- package/dist/server/appshare.js +179 -0
- package/dist/server/appsite.js +120 -0
- package/dist/server/apptalk.js +178 -0
- package/dist/server/artcmd.js +1 -1
- package/dist/server/events.js +1 -1
- package/dist/server/history.js +51 -3
- package/dist/server/historyapi.js +34 -2
- package/dist/server/hover.js +11 -7
- package/dist/server/identity.js +1 -1
- package/dist/server/libraryroute.js +3 -3
- package/dist/server/live.js +61 -2
- package/dist/server/main.js +17 -1746
- package/dist/server/options.js +350 -0
- package/dist/server/outside.js +311 -0
- package/dist/server/pastdoc.js +22 -3
- package/dist/server/project.js +28 -4
- package/dist/server/send.js +259 -0
- package/dist/server/talk.js +13 -7
- package/dist/server/tokens.js +3 -3
- package/dist/server/view.js +3 -1
- package/dist/server/views.js +1 -1
- package/dist/shared/artrecipe.js +3 -3
- package/dist/shared/collab.js +1 -1
- package/dist/shared/comment.js +1 -1
- package/dist/shared/doc/build.js +30 -14
- package/dist/shared/doc/latex.js +7 -2
- package/dist/shared/doc/model.js +4 -2
- package/dist/shared/doc/sections.js +21 -4
- package/dist/shared/outside.js +16 -0
- package/dist/shared/pastgraph.js +11 -2
- package/dist/shared/scope.js +1 -1
- package/dist/web/bundle/app.js +49580 -49284
- package/dist/web/src/selection.js +1 -1
- package/dist/web/src/theme.js +1 -1
- package/dist/web/src/visitors.js +1 -1
- package/docs/agent-api/export.md +8 -5
- package/docs/agent-api/history.md +3 -1
- package/docs/agent-api/reading.md +8 -2
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -9,9 +9,9 @@
|
|
|
9
9
|
</p>
|
|
10
10
|
<p align="center"><sub>Five Lean codebases, drawn by <code>visualproof artwork</code>.</sub></p>
|
|
11
11
|
|
|
12
|
-
https://github.com/user-attachments/assets/
|
|
12
|
+
https://github.com/user-attachments/assets/941b6599-5b4d-4364-aa81-fc25b8991eeb
|
|
13
13
|
|
|
14
|
-
<p align="center"><sub>A review of Sphere-Packing-Lean in
|
|
14
|
+
<p align="center"><sub>A review of Sphere-Packing-Lean in 71 seconds. The whole tour — three and a half minutes in thirteen chapters, with captions — is in the page under <b>?</b> → Tips, and <a href="https://visualproof-demo.yingte.io/#tips">on the live demo</a>.</sub></p>
|
|
15
15
|
|
|
16
16
|
[](https://visualproof-demo.yingte.io)
|
|
17
17
|
|
|
@@ -23,7 +23,9 @@ Output, schema 1:
|
|
|
23
23
|
the parser and `_aux_` declarations it generates (decision 2), under a name of its
|
|
24
24
|
own: the syntax kind it declares, or `<kind>.macro_rules` and the like for a rule
|
|
25
25
|
(`leanName` is the Lean constant, `display` what a card calls it).
|
|
26
|
-
externals constants outside the project that a node refers to directly, folded the same way
|
|
26
|
+
externals constants outside the project that a node refers to directly, folded the same way,
|
|
27
|
+
each with its doc and its range in its own package's or Lean's source, as the
|
|
28
|
+
`.olean` records them.
|
|
27
29
|
edges [src, dst, sites], `sites` a bit set: 1 = statement, 2 = definition body,
|
|
28
30
|
4 = inside a proof, 8 = on grammar: into a notation unit that only declares syntax
|
|
29
31
|
(flagged `grammar`), which no TCB follows. A macro or elaborator depends on the
|
|
@@ -1123,8 +1125,16 @@ def run (out : System.FilePath) (projectDir : String) (roots : Array Name)
|
|
|
1123
1125
|
let kind := match env.find? c with
|
|
1124
1126
|
| some ci => kindOf env ci
|
|
1125
1127
|
| none => "unknown"
|
|
1126
|
-
|
|
1127
|
-
("module", modName c), ("ax", nodeAx[nodes.size + j]!)]
|
|
1128
|
+
let mut fields : List (String × Json) := [("name", c.toString), ("kind", kind),
|
|
1129
|
+
("module", modName c), ("ax", nodeAx[nodes.size + j]!)]
|
|
1130
|
+
-- where it is written in its package or in Lean's core, as the `.olean` records it, and its
|
|
1131
|
+
-- doc: the source window shows an outside declaration's source too (ReviewSpec, "The source
|
|
1132
|
+
-- window", the owner's decision of 2026-10-20), which the server finds by its module
|
|
1133
|
+
if let some d ← findDocString? env c then fields := fields ++ [("doc", Json.str d)]
|
|
1134
|
+
if let some r ← findDeclarationRanges? c then
|
|
1135
|
+
fields := fields ++ [("range", Json.arr #[r.range.pos.line, r.range.pos.column,
|
|
1136
|
+
r.range.endPos.line, r.range.endPos.column])]
|
|
1137
|
+
extJs := extJs.push (Json.mkObj fields)
|
|
1128
1138
|
let metaUnits : Nat := nodes.foldl (init := 0) fun k c =>
|
|
1129
1139
|
if !notationUnits.contains c && ((env.find? c).map isMetaDecl).getD false then k + 1 else k
|
|
1130
1140
|
let axioms := (← get).axioms
|