Show HN: Trilium Notes – Scriptable note-taking application
github.com
github.com
I think contributing to it should be easy enough, one just has to edit this [1] HTML file. It was a plain Markdown/ASCII table earlier, but since it's quite wide it wasn't looking too good.
[1] https://github.com/fabiospampinato/notable/blob/master/resou...
It's iOS specific but the features might let you filter by features you need;
Free and open source preferably but if it has to be paid (I don't mind paying if somebody builds a perfect tool for me, I'll donate if it's free) - it is to be single-time payment, not any kind of subscription.
100%-internet-independent. An option to synchronize data over the internet is a nice thing to have but it must be E2E-encrypted (I feel like a manually-set private key symmetric encryption is ok) and support P2P-synchronization via local network.
It should better work on all the platforms but desktop Linux is the most important and minimally-sufficient.
It is to store the data in a format easy to read and modify programmatically. E.g. SQLite (seems the best choice, also does great storing attached files as BLOBs within the DB), XML, JSON or whatever with sane scheme.
A node can be folder/document, a document section with a heading (including subsections), a paragraph (with support for marking particular spans as non-breakable and inserting manual line breaks), a picture (svg, png or jpg), a numbered or bulleted list (of whatever a depth) or its element, a video, an audio, a table, a formula, a piece of code, an attached file (stored within or alongside the database), a link to a node or to an external URL. Something else too perhaps.
It should be possible to attach tags and custom properties to the nodes. Every node should have a UUID. The tagging system should support implications (e.g. if I tag something with "python" tag "programming" tag is applied implicitly). It should be possible to rename tags and merge tags into one.
Full text search (and replace) by content, tag, property etc.
Drag&Drop nodes migration and reordering.
Export a node with all its subnodes into a file, execute a command line with its name substituted and import it back. I am going to use this feature mostly to author documents (markdown, latex, epub etc) and blog posts via Python scripts.
What I want to use it for:
Writing down random ideas and notes, mindmapping, organizing reasonably small files and scanned stuff, writing lecture notes, papers, blog posts and books and all these with all their hierarchy elements (to the sane depth, treating every word as an node or looking inside attached files would be too much) should be 1-st class nodes displayed in the tree and available for the operations.
* Open-source, self-hosted
* Storing the data in some very plain format, as long as it doens't conflict with other features. In fact, I'd wish for it to be plain markdown in individual files on the disk, but (aside from performance problems) I don't imagine it being fully possible. So I'm not sure where the right balance should be, but the point is it is something to strive for, since personal notes is something that should be easily editable/recoverable within minutes in any situation.
* Clients for Android, web, preferrably simple enough API to be able to write plugins for vim/atom/whatever.
* The main document format (let's call it .note further): ok, maybe not really markdown, but something intentionally simple still. The only not-markdown feature I can remember right now that is really necessary is text coloring. Must support block-quotes and tables well. Otherwise, it shouldn't be possible to make any html document you want in the editor.
* Editor UI: pretty much one of the Evernote. Embed images by drag'n'drop (automatically copying them to the server), preserve simple formatting when copying HTML markup from somewhere (like Google Docs do).
* Even though only .note files must be editable, pretty much anything should be easily attachable as a first-class note: picture, audio-file, PDF, etc. Even if the only thing app can do with the file is to upload/download, this still should be considered as much a note as a .note file.
* Auth, obviously. I doubt it's a viable feature to build, but if I'm writing it myself, I'd eventually configure it to log-in the proper user using SSL user-certificate.
* Primary purpose of notetaking app is, actually, reading the notes, not writing them, so this should be simple. The default UI for any saved note should be read-only, w/o unnecessary buttons taking up the space on the screen (especially critical when using the phone).
* Tags attachable to every note (of any format). Search using tags. Tags can be non-ASCII. Tags must be easily searchable and editable in bulk.
* Full-text search.
* Some tags can be marked as "labels", and the label should be the only possible way to organize data: treat them approx. as Gmail does, don't clutter the app with both tree-style navigation and tags. To satisfy the user who really likes trees, treat some symbol in the label (- / |) as the separator, so that "university/biology" and "university/math" would form a tree in the UI.
* Pretty much everything else I can imagine right now is anti-feature. Simple is gold. Well, maybe some sort of versioning is actually useful, but if it's implemented it should not only "just work", but also be obvious for the user to see how it works.
* Treat conflicting changes well (for example, if you lose internet connection on a mobile). Maybe something similar to how git does it: let the use choose?
* Oh, yeah, about lost connections: caching on the clients. All cached data should always be encrypted on the disk (hm, I guess it would conflict with auth by SSL?).
Which IMHO is the reason why no software for personal managment of stuff will ever be good enough. We all want the perfect tailor-made suit to work with, but we don't wanna go to the tailor and pay for it. And even worst, we grow, we change, so custom-made solution today might not do it tomorrow.
I think for that reason applications with a programatic approach are the real solution for organization like notes or tasks. Something scriptable is a good start for this.
But, it reminds me, there also must be a way to easily link one note to the other you wrote. Which isn't always available.
I'm curious about whether there's synchronization between the local desktop application and the hosted web version. Also about how responsive the web version is, and how well it works on a phone.
Hosted web version actually serves a dual purpose - it is a full online app (for both desktop and mobile) and also acts as a central sync server for desktop clients.
There's a fully featured web version which is tailored for desktop and isn't responsive. There's a separate frontend for touch based devices which doesn't have a complete feature set, but scales nicely for both smartphone and tablet layouts. But this is a brand new feature released just days ago so it has probably rough edges.
That if you mean something like this: http://notes.sciter.com/wp-content/uploads/2019/01/notes-dra...
Works with any browser, no plugins required.
(I suppose other OS's have similar shortcuts as well, so if you use something else, this might be worth Googling for.)
Otherwise, I think Pocket might be exactly scrapbook-collector-type thing you're looking for?
I personally use Zim [0] at work, which is pretty dependable, extensible and mature. Zim also builds a personal knowledge base with exports, so you can learn from its approaches I think.
However, I personally don't prefer to use electron applications, so Trillium is not a real candidate for me, sorry. Wish it wasn't on Electron, so I'd try it.
[0]: http://zim-wiki.org/
I'm extremely annoyed by the fact of running a complete browser engine and sacrifice half gigabytes of memory and a lot of storage (I cannot remember the exact size of Atom) just for a text editor or any other software with the same caliber.
Also, Electron consumes more resources than it needs. When running on any Electron app on my Mac, I generally get a notification about its power usage too.
e.g.: Atom is not as powerful as Eclipse, but needs more resources per feature. BBEdit is much lighter and compact, and is nearly as useful for me as Atom, and I can run Eclipse if I need a full fledged IDE.
Server-only deployment is nice, but I'd rather sync the data, because I'm not always online while taking notes, and if I'm going to keep my data centralized, I'd rather keep it at my home, and I don't have enough upload bandwidth to serve anything like Trillium.
BTW, Why are you trying to replace Zim? I'm interested in your reasons.
I'm open to and interested in discussion and, I'd happily stand corrected if I'm mistaken.
Because NixNote 2 uses 145MBs, Zim Wiki uses 60MBs, nvPy uses 45 MBs, and Atom uses 660MBs on start.
> It's not.
Can you provide the memory consumption data?
> Upload bandwidth? For syncing data? Unless you keep full video files in it, I can't imagine how that would come into play unless you are using only cell data at below 3G speeds.
Sorry, but my home ISP is providing extremely asymmetric network speeds. I have 1Mbps upstream bandwidth for every 16Mbps downstream. This is barely keeping up if your home network is shared inside the home, consumed by 2 desktops, a laptop, three mobile phones at minimum. This network also needs to keep up with the daily usage needs. It's not realistic to peg the upload bandwidth just because I can.
> It seems as if your objections are more based on principle than actual in this case...
My principles are born out of actual cases. I'm not that conservative to try new technologies or applications, but I'm against wasting resources on my personal devices because hardware is cheap. I believe that efficient applications (in resource utilization) are always better in the long run. At least you can run more applications with the same hardware. I won't dive into details about how heavy applications like Atom or frameworks like Electron increases background CPU and power usage with interrupts, wakes, small spikes and such.
Also, applications/cliens like nvALT, nvPY provide a very very fast workflow for instinctive note taking and recalling.
I see there may be relevant CKEditor plugins. Could these be used?
I use CKEditor 5 which is very very nice, but still a bit immature in its plugin ecosystem.
LaTex support is definitely something I've been thinking about, but I'm still not sure about how to approach it.
This might be also one of the showcases for the scripting support. User can load e.g. KaTex as a script, bind it to the "code note" which it will render into a view e.g. above the code editor. But that's not very user friendly for sure.
Edit: I should add neither of these support code execution. I would really love if someone could point to a Wikipedia / knowledge base composed of Jupyter notebooks but have the functionality inverted — primarily focused on note taking and secondarily on code execution.
I'm using it extensively myself :)
I'd be incredibly impressed if you could render full LaTeX though - e.g. via a renderer switch and a PDF viewer like PDF.js.
It seems pretty great, but there's no code available as far as I can tell.
I haven't looked at the code, but can anyone say something informed about the sync server auth and transport security? Is it running over TLS?
Sync auth is done through HMAC of a timestamp with shared secret. Sync uses HTTP so if sync server is properly configured with TLS, then it is used of course.
Native solution has an advantage of being able to resolve edit conflicts on a very granular level (individual notes, attributes etc.)
Trilium Notes automatically versions notes by kind of taking a snapshot every few minutes. It allows you to browse those "revisions", but there isn't a diff built in yet. It is one of those features which I thought I might implement some day but there's always something more important.
For the edit conflict resolution - no diff is being used. Newer change just overwrite the old one. But since you have historical revisions from both sides of edit conflicts, there's a good chance you didn't lose the data completely. And in practical terms this happens quite rarely if you sync often (i.e. - are online) since the sync is granular enough.
Ive been itching for a scriptable personal knowledge base where I can store arbitrary datastructures and executable code in addition to the typical richtext note taking. Will be diving into the code asap. Cheers!
Wow, this is actually exactly what Trilium Notes is. Perfect match!
The only thing I would really love is a more open way to store notes, like text files in a directory. Love how DevonThink does their file indexing. Can imagine it being a headache though with the cloning etc. so good you have export to at least have openly accessible backups.
I'm guessing it would need to be another type of note, separate from the CKEditor ones, or maybe some kind of drawing area plugin making space within a rich text note.
But this does work with mobile which is key...
Besides that there's an OPML file export which contains a tree structure with plain text. Its import seems to be supported widely among outliners.
But you're right that the exported note doesn't rewrite the link to correctly point to the local exported image.
I was especially keen on the syncing to work, but unfortunately kept getting a 'DB not initialized' error on the server. I'll raise an issue for it.
Wonderful application overall. Congratulations.
Two questions:
1. Any plans to support OCR processing similar to Evernote?
2. Any plans on offering a paid service for syncing the encrypted notes to? I'll gladly pay $5 / mo for a more secure, open source Evernote if it means I don't have to manage my own server.
Will check out Trillium
Do you have plans to build import functions to take data from OneNote and Evernote?
It's not viable unless you have a lot of paying users and there's a lot of competition.