如何维护基于emacs的知识库?

发布于 2024-08-17 04:06:16 字数 523 浏览 7 评论 0原文

我已经使用组织模式有一段时间了,我现在保持它非常简单,只有两个文件:
一个充当收件箱,具有记住模式
另一个地方是我保留从收件箱处理过的所有内容

,这对于管理有些“可操作”的项目非常有用,但我不断添加更一般性的内容,这些内容是我日常不需要的(操作方法、阅读笔记等),因此它变得缓慢且难以管理。

我所关注的材料不适合/项目/任务/子任务范例,它们更像是选定主题的小知识块,本质上分类和管理起来更加复杂。

我一直想知道可以使用什么样的结构来处理此类信息(分类和检索),以及是否有其他模式可以帮助完成这项工作?


我想这个问题没有预先设定的答案,因为每个人可能有不同的需求。
Noufal 给出了很好的概念性提示,我认为请记住,但总的来说,接受的答案对此提供了更务实的观点,链接的资源是一个很好的阅读。

I've been using org-mode for a little while, I've kept it really simple for now, with only two files :
one to act as an inbox, with remember-mode
another where I stick just about anything that's been processed from the inbox

This is great for managing somewhat 'actionable' items, but I keep adding things of a more general nature, that I won't be needing on a day-to-day basis (how-tos, reading notes etc), so it's getting slow and hard to manage.

The material I'm concerning myself with doesn't fit the /projects/tasks/sub-tasks paradigms, they are more like little knowledge nuggets on selected topics, which are inherently more complex to classify and manage.

I've been wondering what kind of structure could be used to handle that kind of information (classification and retrieval), and if there are maybe other modes that could help with the job ?


I guess there is no pre-made answer to this question, since everyone may have different needs.
Noufal gave good conceptual tips that I'll keep in mind, but overall, the accepted answer provided more pragmatic views on this, the linked resource was a GREAT read.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(8

惜醉颜 2024-08-24 04:06:16

我认为这份关于如何充分发挥 org-mode 潜力的优秀文档将对您非常有帮助: “组织模式:用纯文本组织你的生活”。这是很长的阅读,但相信我,完全值得付出努力。

更新:
您可以根据您的用例使用文档中提到的 remember-mode 部分 。 (我将它用于相同的用例)记住模式对于快速记笔记非常方便。当我必须存储随机观察结果或不会转移到其他地方的信息时,我会使用它。我使用以下模板来记住:

(setq org-default-notes-file (concat org-directory "/remember-notes.org"))
(setq org-remember-templates
  `(("Todo"    ?t "* TODO %?\n  %i\n" ,(concat org-directory "/remember-notes.org") bottom)
    ("Misc"    ?m "* %?\n  %i\n"      ,(concat org-directory "/Notes.org")   "Misc")
    ("iNfo"    ?n "* %?\n  %i\n"      ,(concat org-directory "/Notes.org")   "Information")
    ("Idea"    ?i "* %?\n  %i\n"      ,(concat org-directory "/Notes.org")   "Ideas")
    ("Journal" ?j "* %T %?\n\n  %i\n" ,(concat org-directory "/journal.org") bottom)
    ("Blog"    ?b "* %T %? :BLOG:\n\n  %i\n" ,(concat org-directory "/journal.org") bottom)
    ))

如您所见,杂项注释和其他信息位于notes.org 文件中的“杂项”和“信息”标题下。如果我所做的笔记不属于上面定义的任何类别,它会被归档到默认文件 (remember-notes.org) 中,并且我随时可以在方便的时候将其重新归档到另一个位置。这使得我做笔记、记下随机想法等事情变得非常简单,而不会分散我对当前工作的注意力。

I think this excellent document on how to use org-mode to it's fullest potential will be very helpful to you: "Org Mode: Organize Your Life In Plain Text". It is lengthy reading, but trust me, completely worth the effort.

UPDATE:
You can use the remember-mode section mentioned in the document for your use-case. (I use it for the same use-case) Remember-mode is extremely handy to make quick notes. I use it when I have to store random observations or information that won't go anywhere else. I use the following templates for remember:

(setq org-default-notes-file (concat org-directory "/remember-notes.org"))
(setq org-remember-templates
  `(("Todo"    ?t "* TODO %?\n  %i\n" ,(concat org-directory "/remember-notes.org") bottom)
    ("Misc"    ?m "* %?\n  %i\n"      ,(concat org-directory "/Notes.org")   "Misc")
    ("iNfo"    ?n "* %?\n  %i\n"      ,(concat org-directory "/Notes.org")   "Information")
    ("Idea"    ?i "* %?\n  %i\n"      ,(concat org-directory "/Notes.org")   "Ideas")
    ("Journal" ?j "* %T %?\n\n  %i\n" ,(concat org-directory "/journal.org") bottom)
    ("Blog"    ?b "* %T %? :BLOG:\n\n  %i\n" ,(concat org-directory "/journal.org") bottom)
    ))

As you can see, misc notes and other information goes in the notes.org file under the headings Misc and Information. If the note I'm making doesn't fall in any of the categories defined above, it gets filed in the default file (remember-notes.org) and I can always refile it to another location at a convenient time. This makes my note-taking, jotting down random ideas, and such things extremely simple, without taking away the focus from the job I'm currently doing.

薔薇婲 2024-08-24 04:06:16

我个人保留了一个结构有些相似的项目目录列表。每个都有一个tasklist.org,一个跟踪子目录(我在其中进行项目估算和时间跟踪,并始终维护一本日记,这是该项目的主要内容 - 它将包含指向该项目的其他文件的链接),一个文档子目录,通常包含我要发布的内容(项目文档、提案等)。我将议程文件发送到每个子目录中的 tasklist.org,以便我的议程正常运行。


我认为在您的情况下,数据的组织会发生一些变化(也许是“函数式编程”等主题)。我对分层结构有多大帮助表示怀疑,因为这会限制您查看事物的一种方式(再次是标签与文件夹)。以下是我想到的一些事情。

  1. 保留一个“主”组织文件,其中包含其他内容的所有“有趣”顶级部分的链接(类似于我上面提到的日记)。
  2. 正确标记所有材料(一段时间后您将确定一组有用的标签),然后使用标签搜索功能快速搜索文件。不过,这假设所有文件都在您的agenda-files中。
  3. 最后,如果您的数据太奇特而无法放入结构中,您可以考虑使用全文索引器(如 xapian)并将其集成到您的 Emacs 中。 此处对此进行了一些讨论。

更新:2019 年 11 月 26 日

我最近遇到了 hyperbole 软件包,该软件包声称是信息组织者。我还没有使用过它,但我很想使用它,并且会在使用时更新它。

I personally keep a list of project directories with somewhat similar structure. Each has a tasklist.org, a tracking subdirectory (where I do project estimates and time tracking and always maintain a diary which is the main thing for the project - it will have links to other files for the project), a docs subdirectory which usually consist of stuff I'm going to publish (docs for the project, proposals etc.). I get my agenda-files to the tasklist.org in each of the subdirectories so that my agenda works fine.


I think the organisation of the data would change a little in your case (perhaps topics like "functional programming" etc.). I'm sceptical of how much a hierarchical structure would help since that would confine you into one way of looking at things (tags vs. folders again). Here are some things that come to mind.

  1. Keep a 'master' org file that has links to all the 'interesting' top level pieces of the other content (similar to the diary I mentioned above).
  2. Tag all your material properly (you'll settle on a set of useful tags after a while) and then use the Tag search feature to search through the files quickly. This assumes that all the files are in your agenda-files though.
  3. Finally, if your data is too exotic to put into a structure, you can consider using a full text indexer (like xapian) and integrate that into your Emacs. There was some discussion of this over here.

Update : 26/Nov/2019

I recently came across the hyperbole package which claims to be a information organiser. I haven't used it but I'm quite tempted to and will update this when I do.

一场春暖 2024-08-24 04:06:16

[org-mode] 非常适合管理一些“可操作”的项目,但我不断添加更通用的内容,这些内容是我日常不需要的(操作方法、阅读注释等),因此它变得缓慢且难以管理。

我是 David Allen 及其把事情做好方法论的追随者。我正在使用 Emacs 来处理他推荐的三个列表:

  • 下一步操作

  • 项目资源

  • 有一天/也许列表

我所关注的材料不符合/项目/任务/子任务范式,它们更像是选定主题的小知识块,本质上分类和管理起来更加复杂。

我一直想知道可以使用什么样的结构来处理此类信息(分类和检索),以及是否有其他模式可以帮助完成这项工作?

对于此类信息,我已不再使用 emacs。相反,我保留一个目录~/etc/howto,并在该目录中放置包含“选定主题的小知识块”的文件,其中关键标准是信息具有长期-术语值

我可以用 Emacs 搜索这个目录,但我的 Emacs Lisp 不太热,所以我写了一个 howto shell 脚本(为了清楚起见,省略了一些错误检查):

case $# in
  1) ;;
  *) echo "Usage: $0 <topic>" 1>&2; exit 2 ;;
esac

topic="$1"

# Note the ordering: first exact matches, then beginning matches, then any matches

set xxx `find $HOME/etc/howto/. -name "$topic"     -not -type d -print` \
        `find $HOME/etc/howto/. -name "${topic}?*" -not -type d -not -name '*~' -print` \
        `find $HOME/etc/howto/. -name "?*$topic*"  -not -type d -not -name '*~' -print`
shift

case $# in
  0) echo "No file found matching *$topic*" 1>&2 ; exit 1 ;;
  *) for i
     do
       less "$i"
     done
     ;;
esac

示例包括:

  • howto Football 提出了三个金块,按以下顺序:

    • 向我妻子提供如何在计算机上录制足球比赛的说明

    • 当我持有足球比赛门票时,我需要携带什么以及如何着装等详细说明

    • 对足球比赛进行转码以便可以通过网络传输并在外出时观看的说明

  • howto filesystem 显示有关如何复制文件系统的说明

  • < code>howtobattery 显示推荐的可充电电池列表

我不使用 Emacs 的一个原因是我的真实脚本比上面看到的稍微复杂一些:它还处理 PDF 和 djvu 文件,因此例如 howto razor 会显示我的电动剃须刀附带的手册的 djvu 文档。

我的主目录或子目录中有超过 500 个项目,即使在这种规模下,该系统对我来说也运行得很好。我希望您也会发现它有帮助。

[org-mode] is great for managing somewhat 'actionable' items, but I keep adding things of a more general nature, that I won't be needing on a day-to-day basis (how-tos, reading notes etc), so it's getting slow and hard to manage.

I'm a follower of David Allen and his Getting Things Done methodology. I'm using Emacs for three of the lists he recommends:

  • Next Actions

  • Project Resources

  • The Someday/Maybe list

The material I'm concerning myself with doesn't fit the /projects/tasks/sub-tasks paradigms, they are more like little knowledge nuggets on selected topics, which are inherently more complex to classify and manage.

I've been wondering what kind of structure could be used to handle that kind of information (classification and retrieval), and if there are maybe other modes that could help with the job ?

For this kind of information I've migrated away from emacs. Instead I keep a directory ~/etc/howto, and in that directory I put files that contain "little knowledge nuggets on selected topics", where the key criterion is that the information has long-term value.

I could search this directory with Emacs, but my Emacs Lisp is not so hot, so I wrote a howto shell script instead (some error checking omitted for clarity):

case $# in
  1) ;;
  *) echo "Usage: $0 <topic>" 1>&2; exit 2 ;;
esac

topic="$1"

# Note the ordering: first exact matches, then beginning matches, then any matches

set xxx `find $HOME/etc/howto/. -name "$topic"     -not -type d -print` \
        `find $HOME/etc/howto/. -name "${topic}?*" -not -type d -not -name '*~' -print` \
        `find $HOME/etc/howto/. -name "?*$topic*"  -not -type d -not -name '*~' -print`
shift

case $# in
  0) echo "No file found matching *$topic*" 1>&2 ; exit 1 ;;
  *) for i
     do
       less "$i"
     done
     ;;
esac

Examples include:

  • howto football brings up three nuggets, in this order:

    • Instructions to give to my wife on how to record a football game on the computer

    • Instructions for me as exactly what to take and how to dress when I have tickets to a football game

    • Instructions for transcoding a football game so it can be transmitted over the net and viewed away from home

  • howto filesystem brings up instructions on how to copy a filesystem

  • howto batteries brings up a list of recommended rechargeable batteries

One reason I don't use Emacs is that my real script is a little more complicated than what you see above: it also handles PDF and djvu files, so for example howto razor brings up a djvu document of the manual which came with my electric razor.

I have over 500 items in the main directory or in subdirectories, and even at this scale the system works quite well for me. I hope you may find it helpful too.

偏闹i 2024-08-24 04:06:16

我过去尝试过多种方法来管理知识库。我有一堆关于各种不同主题的“知识块”(顺便说一句,谢谢,我非常喜欢这个词),从如何设置 apache tomcat ssl 证书,到每月家庭预算的清单,再到保持锻炼中完成的重量和次数列表。

我尝试过使用笔和纸等将它们保存在 WordPress 博客、个人 wiki 上。

最后,emacs 和 org-mode 对我来说显然是赢家。我喜欢能够从简单的开始,并根据需要构建更复杂的功能。我使用了 蔡蔡

就我而言,我总是会得到一堆笔记(更正式和有组织)与行动项目(不太正式)混合在一起。一般来说,我维护一个主“行动项目”列表,然后为每个主题的注释创建一个单独的文件。到目前为止,grep 可以很好地帮助我快速找到包含注释的文件。我经常会创建一个 emacs 书签 Cx r m 来快速导航到笔记文件。

简单的博客、CMS 和 wiki(例如 Drupal 和 Wordpress)擅长分类和检索。也许您可以将 org 文件导出为 html 并将其发布到博客、cms 或 wiki?连接到 blog/wiki/cms 标记功能可能不会太困难。

I have tried several ways to manage a knowledge base in the past. I have a bunch of "knowledge nuggets" (btw, thanks, I like that term a lot) on all sorts of diverse topics ranging from how to set up apache tomcat ssl cert, to checklists for doing a monthly family budget, to keeping a list of weights and reps completed on workouts.

I've tried keeping these in a wordpress blog, on a personal wiki, using pen and paper, etc.

In the end, emacs and org-mode is the clear winner for me. I love to have the ability to start simple, and build more complex functionality as I need it. I've used a lot of the tips described by Sacha Chua.

In my case, I always end up with a bunch of notes (more formal and organized) mixed in with action items (less formal). In general I maintain one master "action item" list and then create a separate file for notes on each topic. So far, grep has worked well for me to quickly find the file containing notes. I'll often create a emacs bookmark C-x r m to quickly navigate to notes files as well.

Simple Blogs, CMS, and wikis (like Drupal and Wordpress) are good at classification and retrieval. Maybe you could export org files to html and publish them to a blog, cms or wiki? It might not be too difficult to hook into the blog/wiki/cms tagging capability.

寄离 2024-08-24 04:06:16

在工作中,我们为此使用一个 wiki(实际上有几个 - 一个全局 wiki 加上每个项目一个 wiki)。它非常适合非分层数据,但也可用于分层数据。它是可格式化的、超文本的、可链接的、可搜索的、可共享的,而且也是可拥有的,它保留历史记录和其他好东西。

就我个人而言,我曾经也使用过 wiki。但现在,我通常只是忘记事情。容易多了。

At work, we use a wiki (actually, several - a global wiki plus a wiki per project) for this. It's ideal for non-hierarchical data, but can also be used for hierarchical data. It's formattable, hypertextual, linkable-to, searchable, shareable but also ownable, it maintains history, and other good stuff.

Personally, i used to also use a wiki for this. But these days, i generally just forget things instead. Far easier.

放赐 2024-08-24 04:06:16

您可以通过将笔记保存在单独的文件(或每个广泛主题一个)中来加速组织模式,该文件不包含在通常的议程文件列表中。自定义 org-agenda-files 来查看列表。

使用 org-remember 快速输入注释,而不会中断您的流程。要么当时标记它们,要么将它们保存在某个地方以便稍后重新归档。您可以使用记住模板中的标签(自定义org-remember-templates)来标记要重新归档的笔记,并使用自定义议程搜索(org-agenda-custom-commands >) 列出它们。

用相关主题标记每个笔记,然后使用议程视图的搜索功能来查找它们。您可以定义一个自定义搜索,它知道要查找正确的文件,或者您可以访问该文件并将议程搜索限制为仅该文件。

我保存了一个笔记文件,你的问题激励我回去开始标记它们。工作很享受!

You can speed up org-mode by keeping your notes in a separate file (or one for each broad topic) which is not included in the usual list of agenda files. Customise org-agenda-files to see the list.

Use org-remember to enter notes quickly without interrupting your flow. Either tag them at the time, or save them somewhere to be refiled later. You can use a tag in the remember template (customise org-remember-templates) to mark notes for refiling, and use a custom agenda search (org-agenda-custom-commands) to list them.

Tag each note with relevant topics, and use the agenda view's search facilities to find them. You can define a custom search which knows to look in the right files, or you can visit the file and restrict the agenda search to just that file.

I keep a file of notes, and your question has just inspired me to go back and start tagging them all. Works a treat!

烟花易冷人易散 2024-08-24 04:06:16

我将提示保存在单个目录中的 .rst(reStructuredText)文件中。每个文件都有自己的主题。

对于搜索,我使用Mx发生,或Mx lgrep,或Mx ack

网络托管示例: http://tips.defun.work/frame.html 这很容易将这些页面变成类似博客的解决方案。

带有构建脚本的原始来源: http://hg.defun.work/tips/

主要优点 < em>reStructuredText 格式:

  • TOC 支持。
  • include 语法。
  • 能够在 HTML 站点中构建基于 JavaScript 的全文离线搜索索引,其中包含 TOC、索引、Sphinx 的引用!
  • 请记住,Markdown 的可扩展性很糟糕,RST 具有通过标记标记数据的常规语法,并将任何纯文本格式作为内联内容包含到文档中。考虑带有 dot 的图表、prog lang 语法突出显示等。

I hold tips in .rst (reStructuredText) files in single directory. Each file have own topic.

For search I use M-x occur, or M-x lgrep, or M-x ack.

Web hosted example: http://tips.defun.work/frame.html and it is easy to turn that pages into blog like solution.

Original sources with build script: http://hg.defun.work/tips/

Main advantage of reStructuredText format:

  • TOC support.
  • include syntax.
  • Ability to build JavaScript based full text offline search index in HTML site with TOC, index, reference by Sphinx!!
  • Remember Markdown suck at extensibility, RST have regular syntax for marking data by your tokens and include any plain text format as inline into your document. Thinks about graphs with dot, prog lang syntax highlighting, etc.
灼疼热情 2024-08-24 04:06:16
  • 我所关注的材料不符合/项目/任务/子任务范式,它们更像是选定主题的小知识块,本质上分类和管理起来更加复杂。

使用书签和Bookmark+。除了单个文件之外,您还可以为文件和目录创建书签,并且您可以标记书签或文件,就像delicious ,用于组织和搜索目的。

  • The material I'm concerning myself with doesn't fit the /projects/tasks/sub-tasks paradigms, they are more like little knowledge nuggets on selected topics, which are inherently more complex to classify and manage.

Use bookmarks and Bookmark+. You can create bookmarks for sets of files and directories, in addition to individual files, and you can tag bookmarks or files, a la delicious, for organization and search purposes.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文