An open-source, privacy-first, self-hosted knowledge workspace where humans and AI agents work together 开源、隐私优先、自托管的知识工作空间,让人与智能体在此协作
TypeScript agentic-aiai-agentknowledge-baselocal-firstmarkdownmcpmindmapnote-takingself-hostedsiyuanworkspace
:art: 支持间隔复习 https://github.com/siyuan-note/siyuan/issues/6710
Liang Ding74b4385d379a
diff --git a/kernel/go.mod b/kernel/go.modindex a018555325..52167d1d75 100644--- a/kernel/go.mod+++ b/kernel/go.mod@@ -39,7 +39,7 @@ require (github.com/patrickmn/go-cache v2.1.0+incompatiblegithub.com/radovskyb/watcher v1.0.7github.com/shirou/gopsutil/v3 v3.22.11- github.com/siyuan-note/dejavu v0.0.0-20221221065751-91ea22509756+ github.com/siyuan-note/dejavu v0.0.0-20221222064045-9ad75d85c281github.com/siyuan-note/encryption v0.0.0-20220713091850-5ecd92177b75github.com/siyuan-note/eventbus v0.0.0-20220916025349-3ac6e75522dagithub.com/siyuan-note/filelock v0.0.0-20221117095924-e1947438a35e@@ -62,7 +62,7 @@ require (github.com/alecthomas/chroma v0.10.0 // indirectgithub.com/andybalholm/cascadia v1.3.1 // indirectgithub.com/asaskevich/EventBus v0.0.0-20200907212545-49d423059eef // indirect- github.com/aws/aws-sdk-go v1.44.164 // indirect+ github.com/aws/aws-sdk-go v1.44.165 // indirectgithub.com/cespare/xxhash/v2 v2.2.0 // indirectgithub.com/dlclark/regexp2 v1.7.0 // indirectgithub.com/dsnet/compress v0.0.1 // indirectdiff --git a/kernel/go.sum b/kernel/go.sumindex 4d65effa62..291486d09a 100644--- a/kernel/go.sum+++ b/kernel/go.sum@@ -46,8 +46,8 @@ github.com/araddon/dateparse v0.0.0-20210429162001-6b43995a97de h1:FxWPpzIjnTlhPgithub.com/araddon/dateparse v0.0.0-20210429162001-6b43995a97de/go.mod h1:DCaWoUhZrYW9p1lxo/cm8EmUOOzAPSEZNGF2DK1dJgw=github.com/asaskevich/EventBus v0.0.0-20200907212545-49d423059eef h1:2JGTg6JapxP9/R33ZaagQtAM4EkkSYnIAlOG5EI8gkM=github.com/asaskevich/EventBus v0.0.0-20200907212545-49d423059eef/go.mod h1:JS7hed4L1fj0hXcyEejnW57/7LCetXggd+vwrRnYeII=-github.com/aws/aws-sdk-go v1.44.164 h1:qDj0RutF2Ut0HZYyUJxFdReLxpYrjupsu2JmDIgCvX8=-github.com/aws/aws-sdk-go v1.44.164/go.mod h1:aVsgQcEevwlmQ7qHE9I3h+dtQgpqhFB+i8Phjh7fkwI=+github.com/aws/aws-sdk-go v1.44.165 h1:yaeKEU28EiSCp1T5XXinVA/qx9JFGbVZGUmj5COAMXI=+github.com/aws/aws-sdk-go v1.44.165/go.mod h1:aVsgQcEevwlmQ7qHE9I3h+dtQgpqhFB+i8Phjh7fkwI=github.com/beorn7/perks v0.0.0-20180321164747-3a771d992973/go.mod h1:Dwedo/Wpr24TaqPxmxbtue+5NUziq4I4S80YR8gNf3Q=github.com/bradfitz/go-smtpd v0.0.0-20170404230938-deb6d6237625/go.mod h1:HYsPBTaaSFSlLx/70C2HPIMNZpVV8+vt/A+FMnYP11g=github.com/buger/jsonparser v0.0.0-20181115193947-bf1c66bbce23/go.mod h1:bbYlZJ7hK1yFx9hf58LP0zeX7UjIGs20ufpu3evjr+s=@@ -373,8 +373,8 @@ github.com/shurcooL/reactions v0.0.0-20181006231557-f2e0b4ca5b82/go.mod h1:TCR1lgithub.com/shurcooL/sanitized_anchor_name v0.0.0-20170918181015-86672fcb3f95/go.mod h1:1NzhyTcUVG4SuEtjjoZeVRXNmyL/1OwPU0+IJeTBvfc=github.com/shurcooL/users v0.0.0-20180125191416-49c67e49c537/go.mod h1:QJTqeLYEDaXHZDBsXlPCDqdhQuJkuw4NOtaxYe3xii4=github.com/shurcooL/webdavfs v0.0.0-20170829043945-18c3829fa133/go.mod h1:hKmq5kWdCj2z2KEozexVbfEZIWiTjhE0+UjmZgPqehw=-github.com/siyuan-note/dejavu v0.0.0-20221221065751-91ea22509756 h1:lp8ihGlC8Mlqn8zI8CeFzWzoi90EaFTWBuCFUwGC5fg=-github.com/siyuan-note/dejavu v0.0.0-20221221065751-91ea22509756/go.mod h1:bemsV89S70xPIoY6CX9SkL3IX6YkCwS8nK09KTKg/S4=+github.com/siyuan-note/dejavu v0.0.0-20221222064045-9ad75d85c281 h1:BgUWOAGXlYCKWzSlUXrPssgaViQihGL92ty2GxQacik=+github.com/siyuan-note/dejavu v0.0.0-20221222064045-9ad75d85c281/go.mod h1:bemsV89S70xPIoY6CX9SkL3IX6YkCwS8nK09KTKg/S4=github.com/siyuan-note/encryption v0.0.0-20220713091850-5ecd92177b75 h1:Bi7/7f29LW+Fm0cHc0J1NO1cZqyJwljSWVmfOqVZgaE=github.com/siyuan-note/encryption v0.0.0-20220713091850-5ecd92177b75/go.mod h1:H8fyqqAbp9XreANjeSbc72zEdFfKTXYN34tc1TjZwtw=github.com/siyuan-note/eventbus v0.0.0-20220916025349-3ac6e75522da h1:/jNhl7LC+9BhkWvNxuJDdsNfA/2wvfuj9mqWx4CbV90=diff --git a/kernel/model/flashcard.go b/kernel/model/flashcard.goindex 75a7721272..6d908cd1ac 100644--- a/kernel/model/flashcard.go+++ b/kernel/model/flashcard.go@@ -86,6 +86,9 @@ func GetDueFlashcards(deckID string) (ret []string, err error) {}ret = append(ret, blockID)}+ if 1 > len(ret) {+ ret = []string{}+ }return}@@ -108,6 +111,9 @@ func getAllDueFlashcards() (ret []string, err error) {blockIDs[blockID] = true}}+ if 1 > len(ret) {+ ret = []string{}+ }return}