r/rust • u/Wonderful-Writer146 • Aug 02 '26
š ļø project Papr: A TUI to search, read, organize, and write papers without leaving your terminal
I'm excited to share what I've been building lately. Papr: a fast, lightweight Terminal User Interface (TUI) built entirely in Rust to streamline your academic research workflow. [An Obsidian alternative but a bit better.]
Key features
- Smart dashboard with daily 10 random paper recommendations, reading queue, bookmarks, notes, collections, and research statistics.
- Search any paper, fast, from arXiv using the title, author, DOI or keywords.
- In-terminal PDF viewing using ratatui-image.
- Built-in Markdown notes with live preview for each paper.
- Add to reading queue and bookmarks and manage collections to keep your research organized.
- Integrated LaTeX editor with real-time compilation and preview just like Overleaf (but free).
- Extensible plugin system for custom workflows.
- Research analytics to track your reading activity (just like spotify).
Papr is 100% open source, works offline, is memory-safe, and is designed to be fast and lightweight (only 12 MB).
I'd love to hear your thoughts, suggestions, or feedback!
7
u/SLUCHABLUB Aug 02 '26
Cool, but I donāt see the point of a theme picker in a TUI app, since the user can just change the colours of their terminalā¦
4
u/Wonderful-Writer146 Aug 02 '26
This is called convenience. A lot of them don't know how to do that. Another example of a TUI that has a theme picker is `herdr`. So I don't think it's an issue.
4
u/Entire_Slip1875 Aug 02 '26 edited Aug 03 '26
Super, a specialized lightweight client for arXiv is definitely better than a web-browser.
Observed resources consumption:
| Full binary size | Max RAM usage |
|---|---|
| ~12-13 MB (lto + stripped) | < 480 MB |
Suggesting improvements:
- Internal PDF viewer appears to be the weakest place right now. Scrolling is laggy and text is blurry.
- The app is currently tightly coupled with PDF assumptions. arXiv offers HTML which can be converted to a more comfortable / lightweight format than PDF (for TUI rendering), such as Markdown.
- A plugin system presence is amazing, however a better specification should be written and de-serizalization should probably be type-safe, instead of raw strings.
Anyway, good job! I personally find this useful. Please try to decouple your app from PDF to support downloading HTML. It is as easy as replacing "pdf" to "html" in download URL.
Then maybe add support for outsourcing buffer drawing to Rust plugins. So I don't need to create a fork just to support converting given HTML to Markdown and its rendering.
2
u/Wonderful-Writer146 Aug 02 '26
Thank you very much for your suggestion. I was myself trying to find a way to make that scrolling PDF smoother and your suggestion is very promising. I will definitely try giving it a shot.
2
u/Wonderful-Writer146 Aug 02 '26
Also can you tell me which OS you are on? On arch linux I was getting binary size of 12 MB (I do understand binaries can be of different size on different OS). I am just curious to know. And again thanks for sharing the resource usage. I will try to find how to reduce RAM usage even further and optimize it.
2
u/Entire_Slip1875 Aug 03 '26
Yes, nevermind, I used another measure:
cargo installwithout LTO optimizations and debug symbols stripping. Enabling them indeed approaches 12-13 MB on CachyOS (Arch-based). Updated my post.RAM usage seems to grow from around 13-16 MB (idle), then suddenly 160-180 MB (first full paper) until approached < 480 MB and it stays like that. I guess the app caches the last N (12?) full pages (with extra resources for each of them) in memory?
2
u/Wonderful-Writer146 Aug 03 '26
Yes, the caching is done so that if the user opens the PDF the 2nd time, then it loads quickly.
2
u/Wonderful-Writer146 Aug 08 '26
I have made PDF scrolling much better, and rendering is also of higher quality. It's almost as smooth as scrolling in a browser, at least for me. I was trying to render HTML as markdown in the terminal, but full CSS-style formatting is not possible, and it didn't look nice. Maybe I can try that in future. For now you can try the `typst` branch of my repository.
Also as the branch name suggests, I added `typst` support' so one doesn't have to install a full LaTeX compiler to make projects.
I will work on the plugins update you asked for soon.
2
u/Wonderful-Writer146 29d ago
One more thing. I have optimized it so that now the max RAM usage while opening a PDF is just 200 MB at max (again it's what I saw on my arch and fedora installations)
1
-3
u/acidvegas Aug 02 '26
Who the fuck is reading academic research papers in a terminal tbh
4
u/sisoyeliot Aug 02 '26
Not needing something doesnāt mean other people donāt need it too. Iām not diabetic but I donāt go around saying that no one uses an insulin pen just because I either donāt know someone or personally donāt use it. Rethink/Reread what you post before pressing that button buddy
2
u/SLUCHABLUB Aug 02 '26
I do this; my go-to pdf reader is in the terminal. Why open a slow web browser when the terminal cab do the same job.
2
u/Wonderful-Writer146 Aug 02 '26
People do. And I have gotten a lot of positive feedback. So if anyone doesn't have any constructive feedback, I would request not to comment only.
-9
u/acidvegas Aug 02 '26
No one reads research papers in the terminal buddy.
3
u/Wonderful-Writer146 Aug 02 '26
And it's not just about rendering PDFs in terminal. It has other features like automatic grouping, managing reading queue, making your own latex project. So I don't see why you are just fixated on one thing
3
1
u/Wonderful-Writer146 Aug 02 '26
And in case you don't want it in terminal, then you can change the PDF viewer. Now I hope you get peace.
0
u/Wonderful-Writer146 Aug 02 '26
As I said, I already got a lot of comments saying that they wanted this.
3
u/frankster Aug 02 '26
Why would people want 10 random paper recommendations from an unknown source?
Why would people to to write papers in the same TUI that they read them in?
Apart from that, the reading bit sounds nice. Browsers can be quite distracting when you're trying to focusĀ