Skip to content

GSoC 2025 ‐ LSP

Philip edited this page Nov 10, 2025 · 12 revisions
Student Philip
Organization JabRef e.V.
Primary repositories JabRef/jabref & JabRef/lsp-vscode-extension
Project name JabRef for Visual Studio Code (JabRef4VSCode)
Project mentors @koppor, @InAnYan, @subhramit
Project page Google Summer of Code 2025 Project Page
Status Done

Project summary

JabRef is a popular open-source bibliography reference manager that helps researchers and academics organize and manage their references efficiently. This project aims to develop three things:

  • A Cite As You Write (CAYW) endpoint that can be used as an alternative to Better-BibTeX's CAYW feature for Zotero which can run alongside JabRef or as a part of JabSrv (JabRefs' HTTP-server, which offers an API for working with the bibliographies opened in JabRef).
  • A Language Server Protocol (LSP) server that provides different features for editing .bib, .bibtex, .md and .tex files in editors, including VSCode. Which can run inside JabRef or as a standalone server.
  • A VSCode extension that integrates with the LSP server to provide a seamless experience for users working with bibliography files in VSCode. The VSCode extension connects to the running LSP server (or can start a standalone version if JabRef isn't running) and provides features such as integrity checks, hover information, jump to definition, select the key in JabRef (when running) or opening the CAYW endpoint.

Core features summarized

  • Automatically connect to the LSP server when JabRef's GUI is running.
  • Automatically start and update the LSP server when JabRef's GUI is not running.
  • Provide hover information for citation keys in .md and .tex files. see here
  • Provide jump to definition for citation keys in .md and .tex files. see here
  • When running along the GUI you can jump to the entry in the GUI. see here
  • Provide integrity checks for .bib, .bibtex files. see here
  • Provide consistency checks for .bib, .bibtex files. see here
  • Provide a CAYW endpoint that can be used as an alternative to Better-BibTeX's CAYW feature for Zotero. see here

Screenshots

LSP integrity/consistency check

Integrity check raising errors Integrity check raising warnings LSP raising error when parsing went wrong

LSP lookup/jump to definition

Hover over citation keys in LaTeX files to see the definition in the bibliography ctrl+click to jump to the entry in the bibliography opens the attached pdf in the preview

Hover over citation keys in markdown files to see the definition in the bibliography

Open attached pdf files

Jump to the entry in the GUI

CAYW

Use Cite as you write

Future work

While the current features are already useful, there are still many things that could be improved and added.

For the Extension many other files could be supported other than .tex and .md files while those two are the most commonly used. More unique features form JabRef GUI could be added:

  • having a grouping view
  • a preview of the entry
  • reformatting the entry or whole bib file
  • suggest quick fixes for errors
  • ...

On a technical perspective tests for many classes should be added to make sure everything works as expected.

Things I learned during the project

Always keep in mind that the codebase is not just a few files and classes. It's a complex system that has to be maintained and extended. For that it is important to take the time to deeply think about how everything should/could be implemented and write maintainable clean code, not just for myself but also for others. Could be really frustrating to work on code others or myself wrote which is not thought through completely and makes extending challenging.

Pull requests

Pull requests for the LSP Server

#14275 - Feat: Add the ability to open linked pdf files in bib files

#14260 - Feat: Add definition links for TeX Files

#14162 - Fix: update group and version for JabRef language server

#14096 - Fix: condition to check if jumpToKey is not blank

#14032 - Feat: Add definition links for Markdown Files

#13968 - Chore: Rework json ADR for consistency check options

#13910 - Feat: Add more consistency check options

#13880 - Feat: Add 'unknown' field check to consistency check

#13862 - Fix: Refactor BibtexParser to use ranges of articles and work with them in the LSP instead of string matching

#13697 - Feat: Add Language Server to the UI and add the core integrity/consistency check functionality

#13612 - Feat: Initial implementation of an LSP for integrity checks

Pull requests for the VSCode Extension

#70 - Feat: Add the ability to call the LSP for tex language files

#69 - Feat: Add keybinding for calling the CAYW endpoint

#68 - Feat: Add messages for the user and states to the ui

#63 - Feat: Add logic for connecting to the LSP server or downloading and starting it if it's not running

#61 - Feat: Add the ability to call the LSP for markdown files

#40 - Feat: Add more consistency check options

#31 - Feat: first initial release

#25 - Feat: enhance connection handling and configuration options

#11 - Chore: Port the js current version to typescript

#10 - Feat: Added settings support for enabling/disabling features

Outside core scope (because it was a new repository)

#71 - Chore: Add Dependabot auto merge

#30 - Fix: Adapt workflow to test a successful build

#29 - Fix: Adapt pipeline to test a successful build

#28 - Chore: Rename scripts and adapt pipeline for successful builds

#26 - Chore: Add build ci to test for a successful build

#13 - Chore: Add dependabot configuration

#12 - Chore: Add MIT License

Pull requests for the CAYW Endpoint

#13554 - Feat: Add select entries CAYW feature and command endpoint

#13514 - Fix: Refactor PushToApplications and split into logic and GUI

#13478 - Fix: Errors in CAYW endpoint

#13466 - Fix: jbang run failing

#13459 - Fix: jbang jabsrvlauncher build failing

#13447 - Feat: Refine and add more options to the CAYW endpoint

#13185 - Feat: Implement a basic Zotero picker compatible CAYW endpoint

#13183 - Fix: Refactor DatabaseSearcher

Outside core scope

#13848 - Feat: Add integrity check to cli

#13593 - Chore: add fallback and re-enable defaultcomeslast for openrewrite

Before GSoC

#12783 - Chore: workflow added for detecting changelog modification

#12739 - Fix: changed preferences and keybind search

#12668 - Fix: search and groups in sidebar get disabled when no library is opened

Thanks

I sincerely thank @koppor, @InAnYan, @subhramit, @calixtus and @Siedlerchr and the whole team behind JabRef for their great support and guidance throughout the project. It was a pleasure working with them, and I'm thrilled to have been a part of JabRef's GSoC 2025 and looking forward to be part of JabRef after GSoC.

Clone this wiki locally