Skip to content

Proposal: Launching LLM server as a daemon #89

@blmarket

Description

@blmarket

Proof-of-concept: https://github.com/blmarket/llm-ls

Hi,

I'm wondering llm-ls can incorporate dedicated LLM server provider within LSP server, preferably as a shared instance via daemonize. Idea was inspired by bazel client/server.

It works as following:

  • There's a lock file to ensure only 1 LLM server is running
  • If there's no usage of LLM (i.e. LSP exits) for 10 seconds, LLM server is terminated
    • There is a heartbeat to let LLM process know there is a client
  • Multiple LSP instances will share single LLM server

Still many things are hardcoded (such as LLM path, various file path, model path), but it's usable with existing llm.XXX editor plugins.

Want to know whether this is something llm-ls would like to support as one of its backends, or better be kept as different project.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions