Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

文档树模仿SuperMemo19,实现无限层级、扩容笔记理论数量、任意移动超深笔记库。 #11821

Closed
Zacharia2 opened this issue Jun 25, 2024 · 11 comments

Comments

@Zacharia2
Copy link

Zacharia2 commented Jun 25, 2024

In what scenarios do you need this feature?

解除文件系统深度的限制,想怎么移动怎么移动,层级想多少就多少,笔记理论数量随着深度的增加而增加,原来的不足都因为在软件这个层面抽象了一个数据存储结构而被扩展和改进。

适用于创建大量层级、增大笔记理论数量、适配卢曼卡片笔记编码树的情况。模仿SuperMemo的知识树的无限层级。

image

Describe the optimal solution

SuperMemo的知识树可以支持无限多的层级,取决于他使用了单独的文件位于systems\coll_name\info文件夹下的contents.dat文件记录了这种树形结构,,并结合了Element Number这种元素ID属性。

下面的例子是
image
这个按钮导出的。

这些选项全部勾选了。
image

#1: ABC of SuperMemo 19 (78) (78 el.) (Burden=16 which is 100%) (Structure: Parent=0 FirstChild=3 LastChild=72 PrevSibling=0 NextSibling=0)
....#3: How does SuperMemo work? (Burden=0 which is 0%) (Structure: Parent=1 FirstChild=0 LastChild=0 PrevSibling=0 NextSibling=13)
....#13: Repetitions (9) (9 el.) (Burden=0 which is 0%) (Structure: Parent=1 FirstChild=18 LastChild=19 PrevSibling=3 NextSibling=6)
........#18: Remember! Repetition is the key weapon against forgetting Hint: brown color ... (4) (4 el.) (Burden=0 which is 0%) (Structure: Parent=13 FirstChild=23 LastChild=10 PrevSibling=0 NextSibling=17)
............#23: Repetition cycle (1) (1 el.) (Burden=0 which is 0%) (Structure: Parent=18 FirstChild=24 LastChild=24 PrevSibling=0 NextSibling=21)
................#24: Exemplary repetition (Burden=0 which is 0%) (Structure: Parent=23 FirstChild=0 LastChild=0 PrevSibling=0 NextSibling=0)
............#21: SuperMemo will often ask you to fill the missing part of a sentence. For example: . [.] is the key weapon against forgetting. Hint: Try to remember what is the key weapon . (Burden=0 which is 0%) (Structure: Parent=18 FirstChild=0 LastChild=0 PrevSibling=23 NextSibling=10)
............#10: Repetition is the key weapon against [...] (Burden=0 which is 0%) (Structure: Parent=18 FirstChild=0 LastChild=0 PrevSibling=21 NextSibling=0)
........#17: Remember! Everything you learn with SuperMemo will come back to you for review and . (1) (1 el.) (Burden=0 which is 0%) (Structure: Parent=13 FirstChild=22 LastChild=22 PrevSibling=18 NextSibling=19)
............#22: Everything you learn with SuperMemo will come back to you for repetition. Every day, you should select the button [.](name of the button that begins repetitions) (Burden=0 which is 0%) (Structure: Parent=17 FirstChild=0 LastChild=0 PrevSibling=0 NextSibling=0)
........#19: Remember! After you choose Learn you should go through all your material scheduled for . (1) (1 el.) (Burden=0 which is 0%) (Structure: Parent=13 FirstChild=25 LastChild=25 PrevSibling=17 NextSibling=0)
............#25: Remember: After you choose Learn you should go through all your material scheduled for ... (Burden=0 which is 0%) (Structure: Parent=19 FirstChild=0 LastChild=0 PrevSibling=0 NextSibling=0)
....#6: Learning with SuperMemo (18) (18 el.) (Burden=0 which is 0%) (Structure: Parent=1 FirstChild=7 LastChild=35 PrevSibling=13 NextSibling=2)
........#7: You only need to learn two key combinations: Alt+A and Ctrl+L (4) (4 el.) (Burden=0 which is 0%) (Structure: Parent=6 FirstChild=11 LastChild=75 PrevSibling=0 NextSibling=14)
............#11: You only need two key combinations: Alt+A - Add new [.](shortcut) - make repetitions of . (Burden=0 which is 0%) (Structure: Parent=7 FirstChild=0 LastChild=0 PrevSibling=0 NextSibling=8)
............#8: You only need 2 key combinations: [.](shortcut) - to add new questions and answers (Add . (Burden=0 which is 0%) (Structure: Parent=7 FirstChild=0 LastChild=0 PrevSibling=11 NextSibling=9)
............#9: You only need 2 key combinations: Alt+A - to [.] new questions and answers Ctrl+L - make repetitions (Burden=0 which is 0%) (Structure: Parent=7 FirstChild=0 LastChild=0 PrevSibling=8 NextSibling=75)
............#75: You only need 2 key combinations: . Alt+A - add new questions and answers (Add new) . Ctrl+L - to [.] of the learned material (Learn) (Burden=0 which is 0%) (Structure: Parent=7 FirstChild=0 LastChild=0 PrevSibling=9 NextSibling=0)
........#14: Try it now! Add a new item with Alt+A (7) (7 el.) (Burden=0 which is 0%) (Structure: Parent=6 FirstChild=41 LastChild=15 PrevSibling=7 NextSibling=35)
............#41: Repetitions are scheduled by SuperMemo (1) (1 el.) (Burden=0 which is 0%) (Structure: Parent=14 FirstChild=42 LastChild=42 PrevSibling=0 NextSibling=31)
................#42: When does a repetition occur? (Burden=0 which is 0%) (Structure: Parent=41 FirstChild=0 LastChild=0 PrevSibling=0 NextSibling=0)
............#31: You can return to the previously visited pages by using the Back button at the top of this window. You can also press Alt+Left arrow to obtain the same effect. Conversely, you . (2) (2 el.) (Burden=0 which is 0%) (Structure: Parent=14 FirstChild=33 LastChild=32 PrevSibling=41 NextSibling=15)
................#33: You can return to the previously visited pages by clicking [.](button equivalent to pressing Alt+Left arrow) (Burden=0 which is 0%) (Structure: Parent=31 FirstChild=0 LastChild=0 PrevSibling=0 NextSibling=32)
................#32: You return to the previously visited pages with [.](shortcut) Hint: The same key combination . (Burden=0 which is 0%) (Structure: Parent=31 FirstChild=0 LastChild=0 PrevSibling=33 NextSibling=0)
............#15: After you finish typing the question, you can press Esc to move to typing the answer (1) (1 el.) (Burden=0 which is 0%) (Structure: Parent=14 FirstChild=16 LastChild=16 PrevSibling=31 NextSibling=0)
................#16: After you finish typing the question, you can use [...](key) to move to typing the answer (Burden=0 which is 0%) (Structure: Parent=15 FirstChild=0 LastChild=0 PrevSibling=0 NextSibling=0)
........#35: 95% retention (4) (4 el.) (Burden=0 which is 0%) (Structure: Parent=6 FirstChild=36 LastChild=39 PrevSibling=14 NextSibling=0)
............#36: Remember! If you complete your repetitions every day (button Learn), SuperMemo will make ... (2) (2 el.) (Burden=0 which is 0%) (Structure: Parent=35 FirstChild=37 LastChild=38 PrevSibling=0 NextSibling=39)
................#37: If you make all your repetitions every day, SuperMemo will make sure you remember ... (Burden=0 which is 0%) (Structure: Parent=36 FirstChild=0 LastChild=0 PrevSibling=0 NextSibling=38)
................#38: SuperMemo will make sure you remember 95% of the learned material as long as you [.]. (Burden=0 which is 0%) (Structure: Parent=36 FirstChild=0 LastChild=0 PrevSibling=37 NextSibling=0)
............#39: Repetitio mater studiorum est (Burden=0 which is 0%) (Structure: Parent=35 FirstChild=0 LastChild=0 PrevSibling=36 NextSibling=0)
....#2: Dismiss learning material (3) (3 el.) (Burden=0 which is 0%) (Structure: Parent=1 FirstChild=4 LastChild=27 PrevSibling=6 NextSibling=20)
........#4: Dismiss or Delete unwanted pages (1) (1 el.) (Burden=0 which is 0%) (Structure: Parent=2 FirstChild=5 LastChild=5 PrevSibling=0 NextSibling=27)
............#5: To dismiss a page/element that you do not want to learn, press [.](shortcut) (Burden=0 which is 0%) (Structure: Parent=4 FirstChild=0 LastChild=0 PrevSibling=0 NextSibling=0)
........#27: Try it now! Dismiss this page (Burden=0 which is 0%) (Structure: Parent=2 FirstChild=0 LastChild=0 PrevSibling=4 NextSibling=0)
....#20: Backup (3) (3 el.) (Burden=0 which is 0%) (Structure: Parent=1 FirstChild=26 LastChild=26 PrevSibling=2 NextSibling=34)
........#26: Remember to back up! (2) (2 el.) (Burden=0 which is 0%) (Structure: Parent=20 FirstChild=28 LastChild=28 PrevSibling=0 NextSibling=0)
............#28: Use Ctrl+Shift+C to back up (1) (1 el.) (Burden=0 which is 0%) (Structure: Parent=26 FirstChild=29 LastChild=29 PrevSibling=0 NextSibling=0)
................#29: You can use [.](option/shortcut) to copy your learning material to some location on your hard disk (for back-up purposes) (Burden=0 which is 0%) (Structure: Parent=28 FirstChild=0 LastChild=0 PrevSibling=0 NextSibling=0)
....#34: Incremental reading (22) (22 el.) (Burden=0 which is 0%) (Structure: Parent=1 FirstChild=43 LastChild=63 PrevSibling=20 NextSibling=71)
........#43: Importing articles (6) (6 el.) (Burden=0 which is 0%) (Structure: Parent=34 FirstChild=44 LastChild=44 PrevSibling=0 NextSibling=58)
............#44: To import a single web article to SuperMemo: . In your web browser, copy the selected text (e.g. Ctrl+C) . In SuperMemo, use  (Ctrl+N) (5) (5 el.) (Burden=0 which is 0%) (Structure: Parent=43 FirstChild=47 LastChild=56 PrevSibling=0 NextSibling=0)
................#47: To import a web article to SuperMemo: copy the selected text in your web browser (e.g. ... (Burden=0 which is 0%) (Structure: Parent=44 FirstChild=0 LastChild=0 PrevSibling=0 NextSibling=48)
................#48: To import a web article to SuperMemo: copy the selected text in your web browser press ... (Burden=0 which is 0%) (Structure: Parent=44 FirstChild=0 LastChild=0 PrevSibling=47 NextSibling=30)
................#30: To import a web article to SuperMemo: . In [.](browser or SuperMemo?), copy the selected text . In SuperMemo, use  (Ctrl+N) (Burden=0 which is 0%) (Structure: Parent=44 FirstChild=0 LastChild=0 PrevSibling=48 NextSibling=49)
................#49: To import a web article to SuperMemo:. In your web browser, copy the selected text . In [.](browser or SuperMemo?), use  (Ctrl+N) (Burden=0 which is 0%) (Structure: Parent=44 FirstChild=0 LastChild=0 PrevSibling=30 NextSibling=56)
................#56: Try Ctrl+N (Burden=0 which is 0%) (Structure: Parent=44 FirstChild=0 LastChild=0 PrevSibling=49 NextSibling=0)
........#58: Extracting fragments (2) (2 el.) (Burden=0 which is 0%) (Structure: Parent=34 FirstChild=59 LastChild=60 PrevSibling=43 NextSibling=45)
............#59: How to extract a fragment? (Burden=0 which is 0%) (Structure: Parent=58 FirstChild=0 LastChild=0 PrevSibling=0 NextSibling=60)
............#60: Try it now! Extract a fragment (Burden=0 which is 0%) (Structure: Parent=58 FirstChild=0 LastChild=0 PrevSibling=59 NextSibling=0)
........#45: You can import many articles from Internet Explorer (3) (3 el.) (Burden=0 which is 0%) (Structure: Parent=34 FirstChild=55 LastChild=64 PrevSibling=58 NextSibling=63)
............#55: You can import many articles from the [.] if you select Edit : Web import from the main menu (alternatively, press Shift+F8). (Burden=0 which is 0%) (Structure: Parent=45 FirstChild=0 LastChild=0 PrevSibling=0 NextSibling=66)
............#66: You can import many articles from the web browser if you select Edit : [.] from the main menu (alternatively, press Shift+F8). (Burden=0 which is 0%) (Structure: Parent=45 FirstChild=0 LastChild=0 PrevSibling=55 NextSibling=64)
............#64: You can import many articles from the web browser if you select Edit : Web import from the main menu (alternatively, press [.]). (Burden=0 which is 0%) (Structure: Parent=45 FirstChild=0 LastChild=0 PrevSibling=66 NextSibling=0)
........#63: Converting extracts to questions and answers (7) (7 el.) (Burden=0 which is 0%) (Structure: Parent=34 FirstChild=65 LastChild=65 PrevSibling=45 NextSibling=0)
............#65: Cloze tools (6) (6 el.) (Burden=0 which is 0%) (Structure: Parent=63 FirstChild=52 LastChild=61 PrevSibling=0 NextSibling=0)
................#52: To create a cloze question, select a keyword and use  (Alt+Z) (2) (2 el.) (Burden=0 which is 0%) (Structure: Parent=65 FirstChild=40 LastChild=67 PrevSibling=0 NextSibling=61)
....................#40: To create a cloze question, select [...](which portion of the text) with the mouse or keyboard, and press Alt+Z (Burden=0 which is 0%) (Structure: Parent=52 FirstChild=0 LastChild=0 PrevSibling=0 NextSibling=67)
....................#67: To create a cloze question, select a keyword and use [.](button or shortcut) (Burden=0 which is 0%) (Structure: Parent=52 FirstChild=0 LastChild=0 PrevSibling=40 NextSibling=0)
................#61: After you create a cloze question you can view it by clicking the < button or pressing Alt+Left arrow (2) (2 el.) (Burden=0 which is 0%) (Structure: Parent=65 FirstChild=70 LastChild=69 PrevSibling=52 NextSibling=0)
....................#70: After you create a cloze question you can view it by clicking the button [.](which one) or pressing Alt+Left arrow (Burden=0 which is 0%) (Structure: Parent=61 FirstChild=0 LastChild=0 PrevSibling=0 NextSibling=69)
....................#69: After you create a cloze question you can view it by clicking the < button or pressing [.](shortcut) (Burden=0 which is 0%) (Structure: Parent=61 FirstChild=0 LastChild=0 PrevSibling=70 NextSibling=0)
....#71: Further reading (Burden=0 which is 0%) (Structure: Parent=1 FirstChild=0 LastChild=0 PrevSibling=34 NextSibling=72)
....#72: 2024:06:25 14:35:42: #72 (abc of supermemo 19) (15) (15 el.) (Burden=16 which is 100%) (Structure: Parent=1 FirstChild=46 LastChild=46 PrevSibling=71 NextSibling=0)
........#46: 2024:06:25 14:36:14: #46 (abc of supermemo 19) (14) (14 el.) (Burden=15 which is 93.75%) (Structure: Parent=72 FirstChild=53 LastChild=53 PrevSibling=0 NextSibling=0)
............#53: 2024:06:25 14:36:14: #53 (abc of supermemo 19) (13) (13 el.) (Burden=14 which is 87.5%) (Structure: Parent=46 FirstChild=50 LastChild=50 PrevSibling=0 NextSibling=0)
................#50: 2024:06:25 14:36:14: #50 (abc of supermemo 19) (12) (12 el.) (Burden=13 which is 81.25%) (Structure: Parent=53 FirstChild=77 LastChild=77 PrevSibling=0 NextSibling=0)
....................#77: 2024:06:25 14:36:14: #77 (abc of supermemo 19) (11) (11 el.) (Burden=12 which is 75%) (Structure: Parent=50 FirstChild=78 LastChild=78 PrevSibling=0 NextSibling=0)
........................#78: 2024:06:25 14:36:14: #78 (abc of supermemo 19) (10) (10 el.) (Burden=11 which is 68.75%) (Structure: Parent=77 FirstChild=62 LastChild=62 PrevSibling=0 NextSibling=0)
............................#62: 2024:06:25 14:36:14: #62 (abc of supermemo 19) (9) (9 el.) (Burden=10 which is 62.5%) (Structure: Parent=78 FirstChild=79 LastChild=79 PrevSibling=0 NextSibling=0)
................................#79: 2024:06:25 14:36:14: #79 (abc of supermemo 19) (8) (8 el.) (Burden=9 which is 56.25%) (Structure: Parent=62 FirstChild=80 LastChild=80 PrevSibling=0 NextSibling=0)
....................................#80: 2024:06:25 14:36:14: #80 (abc of supermemo 19) (7) (7 el.) (Burden=8 which is 50%) (Structure: Parent=79 FirstChild=81 LastChild=81 PrevSibling=0 NextSibling=0)
........................................#81: 2024:06:25 14:36:14: #81 (abc of supermemo 19) (6) (6 el.) (Burden=7 which is 43.75%) (Structure: Parent=80 FirstChild=82 LastChild=82 PrevSibling=0 NextSibling=0)
............................................#82: 2024:06:25 14:36:14: #82 (abc of supermemo 19) (5) (5 el.) (Burden=6 which is 37.5%) (Structure: Parent=81 FirstChild=76 LastChild=76 PrevSibling=0 NextSibling=0)
................................................#76: 2024:06:25 14:36:14: #76 (abc of supermemo 19) (4) (4 el.) (Burden=5 which is 31.25%) (Structure: Parent=82 FirstChild=83 LastChild=83 PrevSibling=0 NextSibling=0)
....................................................#83: 2024:06:25 14:36:14: #83 (abc of supermemo 19) (3) (3 el.) (Burden=4 which is 25%) (Structure: Parent=76 FirstChild=84 LastChild=84 PrevSibling=0 NextSibling=0)
........................................................#84: 2024:06:25 14:36:14: #84 (abc of supermemo 19) (2) (2 el.) (Burden=3 which is 18.75%) (Structure: Parent=83 FirstChild=85 LastChild=85 PrevSibling=0 NextSibling=0)
............................................................#85: 2024:06:25 14:36:14: #85 (abc of supermemo 19) (1) (1 el.) (Burden=2 which is 12.5%) (Structure: Parent=84 FirstChild=54 LastChild=54 PrevSibling=0 NextSibling=0)
................................................................#54: 2024:06:25 14:36:14: #54 (abc of supermemo 19) (Burden=1 which is 6.25%) (Structure: Parent=85 FirstChild=0 LastChild=0 PrevSibling=0 NextSibling=0)

Describe the candidate solution

No response

Other information

No response

@Zacharia2 Zacharia2 changed the title 文档树脱离系统目录树,采用虚拟文件系统,实现无限层级。 文档树模仿SuperMemo,脱离系统目录树,采用虚拟文件系统,实现无限层级。 Jun 25, 2024
@mozhux
Copy link

mozhux commented Jun 25, 2024

首先不讨论作为笔记软件这么多层级的意义以及展开、观看的复杂性。然后你可以设置勾选解除限制,但是如果你要导出笔记本,建议记得这个设置,避免出现数据丢失问题。
image

@TCOTC
Copy link
Contributor

TCOTC commented Jun 25, 2024

脱离系统目录树,采用虚拟文件系统

本地找文件的难度太大了。而且现在已经有目录了,那就改不了了

@Zacharia2
Copy link
Author

Zacharia2 commented Jun 25, 2024

哦哦,好吧,确实,现有的存储架构已经确定了,不太好改。

关于找文件的方面,现在的存储是json格式,这个用户完全用不到这存储格式去查找,而是在软件中找文件。

开发者的话,不知道是否容易,理想情况下,只要设计合理,程序一般可以找到。数据存储还是用目录树,只不过文档树不依靠目录树实现。用JSON存储笔记的话,约莫存储的方式也可以进行再次抽象一下。主要想法是:让软件创建一个新的数据存储结构取代原来的系统目录树的数据存储结构,实现无限层级

嗯,只能说,这只是提出一个可能的改进型解决方案,去实现无限层级。

@Zacharia2
Copy link
Author

Zacharia2 commented Jun 25, 2024

具体的实现方式,我认为,可以用一个文件存储和记录索引文档树的层级结构。然后笔记数据就可以按照合理的方式存放起来。

比如说全部存放到一个文件夹下。或者存放到一个数据库中,或者按系统目录树的条件灵活存储等等。

Logseq采用的存储方式是分类存储,所有类型相同的笔记放在一起,比如日记,就全部放在journals文件夹下。页面文件就全部放在pages文件夹下。

这样的话就创造了一个由软件控制的数据存储结构

用这种抽象出系统目录树,灵活创建另一种形式的数据访问树的方式,优点是无限层级,容量增加,缺点是代码量增加。

@Zacharia2 Zacharia2 changed the title 文档树模仿SuperMemo,脱离系统目录树,采用虚拟文件系统,实现无限层级。 文档树模仿SuperMemo19,实现无限层级。 Jun 25, 2024
@Zacharia2
Copy link
Author

首先不讨论作为笔记软件这么多层级的意义以及展开、观看的复杂性。然后你可以设置勾选解除限制,但是如果你要导出笔记本,建议记得这个设置,避免出现数据丢失问题。

谢谢,我知道这个功能。

@Zacharia2 Zacharia2 changed the title 文档树模仿SuperMemo19,实现无限层级。 文档树模仿SuperMemo19,实现无限层级,扩容笔记理论数量。 Jun 25, 2024
@Zacharia2 Zacharia2 changed the title 文档树模仿SuperMemo19,实现无限层级,扩容笔记理论数量。 文档树模仿SuperMemo19,实现无限层级、扩容笔记理论数量、任意移动超深笔记库。 Jun 25, 2024
@mozhux
Copy link

mozhux commented Jun 25, 2024

其实我不清楚为啥用logseq举例呢。它没有层级啊。。全部平铺。。曾经还作为特色来,不需要考虑分类。如果要无限,自己获取一下文档树在一个文档里,也就是你说的介质里,用列表自己分一下也是无限。不用在乎它在文档树上的位置,同级也没关系。

@Zacharia2
Copy link
Author

Zacharia2 commented Jun 25, 2024

用Logseq举例是为了说明,不用系统目录树存储,作为思源文档树在系统目录树中实际存储形式的存储也是可以的嘛,笔记数据怎么存到系统目录树怎么存都可以呀。在这个基础上在抽象出新的存储的数据结构给软件使用不好嘛,而且思源也不用md文件而是json文件存数据,用系统目录树作为层级结构反而是浪费和限制。倒不如利用好系统文件树的优点,好好存数据,怎么组织思源的文档树的数据存储结构就交个软件 的自己在重新组织一个数据存储结构不好嘛。

笔记的数据层级结构被软件的数据存储结构记录下来,然后软件用自己组织的数据存储结构,以一种简单的方式存放到文件夹系统中。

@Zacharia2
Copy link
Author

Zacharia2 commented Jun 25, 2024

好处显而易见,笔记理论数量随着深度的增加而增加,而且,没有文件系统深度的限制,想怎么移动怎么移动,层级想多少就多少,原来的不足都因为在软件这个层面抽象了一个数据存储结构而被扩展和改进。

image

如果说不改进这些的话到也没啥,当前也够用。

@Zacharia2
Copy link
Author

源代码假设重构,重构的模块约莫是https://github.com/siyuan-note/siyuan/tree/master/kernel%2Ffilesys

@88250
Copy link
Member

88250 commented Jun 28, 2024

抱歉,这个改不了了,感谢提议和讨论。

如果需要其他“视图”,可以考虑用插件实现,谢谢。

@88250 88250 closed this as completed Jun 28, 2024
@Zacharia2
Copy link
Author

嗯嗯,确实,一旦修改就造成与旧版不兼容问题。视图无法兼顾存储问题。大概就这样吧。感谢回复。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants