npm.io
0.20.0 • Published 6d agoCLI

@makefinks/daemon

Licence
MIT
Version
0.20.0
Deps
15
Size
1.2 MB
Vulns
0
Weekly
392
Stars
5
Install scriptsThis package runs scripts during installation (preinstall/install/postinstall)

DAEMON

DAEMON (pronounced "day-mon") is an opinionated terminal-based AI agent with distinct sci-fi theming, delivered through a highly performant TUI powered by OpenTUI.

It supports text and voice interaction, can be fully controlled through hotkeys and offers vim-like controls.

DAEMON is focused on information-gathering workflows that benefit from grounded responses but can also interact with and control your system through the terminal with scoped permissions.

https://github.com/user-attachments/assets/ee806e99-d522-445c-a617-60cbd29bbabc

Installation

npm i -g @makefinks/daemon --loglevel=error

# Additional installs (Audio)
brew install sox

Note: DAEMON requires Bun to be installed and available on your PATH.

Then run with:

daemon

Important Notes

  1. Development also uses Bun (curl -fsSL https://bun.sh/install | bash).
  2. Windows is currently not supported (Only by using WSL - with minor issues)

See full installation details below for configuration and system dependencies.

Highlights

Interactive Avatar

At the core of the TUI is DAEMON's animated avatar, reacting to what it's doing in real time: listening to audio input, reasoning about questions, calling tools, and generating an answer.

The avatar was deliberately designed to feel slightly ominous and alien-like playing into sci-fi depictions.

LLMs

DAEMON supports three model backends:

  • OpenRouter (API key based)
  • OpenAI Codex (ChatGPT OAuth)
  • GitHub Copilot (GitHub-authenticated via Copilot CLI / SDK) (Experimental!)

For OpenRouter, DAEMON can fetch and browse available models and route to a specific OpenRouter inference provider. For GitHub Copilot, DAEMON can use your Copilot subscription and list available Copilot models when authenticated.

Model Picker

Voice capabilities

Low-latency streaming transcription is achieved by using OpenAI's realtime model gpt-realtime-whisper via the Realtime WebSocket API.

OpenAI's TTS model gpt-4o-mini-tts-2025-03-20 is used to generate voice output with as little latency as possible.

Web Search with Grounding

DAEMON uses the Exa search and fetch API for retrieving accurate and up-to-date information.

After fetching relevant information, DAEMON has the ability to ground statements with source links that contain highlightable fragments. The TUI comes with a menu for reading, verifying and opening sources for the current session.

grounding-menu For most statements, pressing Enter opens the source in your browser and highlights the passage that supports the claim.

grounding-highlight grounding-highlight

While DAEMON is encouraged to always cite sources you can always prompt to get groundings:

"Use the grounding tool" / "Ground your answers"

Session Persistence

DAEMON stores chat sessions locally (SQLite) and lets you resume past conversations.

Memory (mem0)

DAEMON can persist user-specific facts across sessions using mem0. Memory extraction runs automatically on user messages and relevant memories are injected into the conversation when helpful.

Feature List

Feature Description
Terminal TUI OpenTUI-powered interface with sci-fi styling and hotkey controls.
Text + Voice Supports text input and voice interaction with transcription and TTS.
Animated Avatar Sci-fi avatar reacts to listening, tool use, and response generation.
Multi-Model Support Works with OpenRouter, OpenAI Codex, and GitHub Copilot model backends.
Vision Paste images into the input bar for vision-capable models, or read local image files.
Session Persistence Preferences and chat sessions stored locally on disk.
Memory Automatic persistance of user-specific facts with persistent recall using mem0
Workspaces Session-scoped on-disk workspaces for the agent to work in.
Web Search Exa-based search and fetch for grounded, up-to-date info.
Code Search Exa-powered code examples, API usage, and technical references.
Grounding Text-fragment grounding with a dedicated UI.
Bash Execution Bash integration with approval scoping for potentially dangerous commands.
Background Jobs Long-running bash and subagent jobs run in the background.
Subagents Delegate parallel subtasks to isolated subagents.
Headless Mode Run daemon "your prompt" to execute a single prompt non-interactively.
Browser Tools Built-in Puppeteer MCP for headless rendered-page work, browser inspection, and frontend debugging.
MCP Model Context Protocol tools.
Agent Skills Progressive-disclosure skills loaded on demand from user-configured directories.

Install (npm)

DAEMON is published as a CLI package.

# Global npm install
npm i -g @makefinks/daemon --loglevel=error

# Then run
daemon

Note: Install Bun first if it is not already available on your PATH.

Configuration is done via environment variables (or the onboarding UI):

  • OPENROUTER_API_KEY (required when OpenRouter is selected; required for Memory writes when Memory is enabled) - response generation via OpenRouter models
  • EXA_API_KEY (optional) - enables web search + fetch grounding via Exa
  • OPENAI_API_KEY (optional) - enables voice transcription + TTS; required for Memory embeddings/search

For Codex, sign in once from the Settings → OpenAI Codex Auth menu (or during onboarding).

For Copilot, authenticate once with either GitHub CLI or Copilot CLI:

gh auth login
# or
copilot login

GitHub Copilot authentication support is experimental.

Keys entered via the onboarding UI are stored locally in ~/.config/daemon/credentials.json with restricted permissions (0600). For maximum security, use environment variables instead.

System dependencies

Voice input requires sox or other platform-specific audio libraries:

macOS
brew install sox
Linux (Debian/Ubuntu)
sudo apt install sox libsox-fmt-pulse
Linux (Fedora)
sudo dnf install sox sox-plugins-freeworld
Linux (Arch)
sudo pacman -S sox

MCP server setup (Model Context Protocol)

DAEMON can load MCP tools from external servers and expose them to the agent at runtime. Puppeteer MCP ships as a built-in default server and can be toggled from the Tools menu. Additional MCP servers are configured via a local config file.

Default config path:

  • macOS/Linux: ~/.config/daemon/config.json

Example config:

{
  "mcpServers": [
    {
      "id": "local-mcp",
      "type": "http",
      "url": "http://localhost:3333/mcp"
    },
    {
      "type": "sse",
      "url": "https://example.com/mcp/sse"
    },
    {
      "id": "custom-stdio",
      "type": "stdio",
      "command": "npx",
      "args": ["-y", "some-mcp-server@latest"]
    }
  ]
}

Notes:

  • The built-in Puppeteer server uses npx -y @modelcontextprotocol/server-puppeteer and launches headless by default so background browser work does not disrupt you.
  • DAEMON can switch Puppeteer to a visible browser for source highlighting or visual checks by changing Puppeteer launch options during browser navigation, then switch back to headless for background work.
  • type must be http, sse, or stdio.
  • url is required for http and sse servers.
  • command is required for stdio servers, and args, cwd, and env are optional.
  • id is optional; if omitted, DAEMON derives one from the host.
  • Defining a server with id: "puppeteer" overrides the built-in Puppeteer config.
  • MCP server status, source, and enablement appear in the Tools menu.

Agent Skills

DAEMON supports Agent Skills for progressive disclosure of specialized instructions and resources. Skill names and descriptions are injected into the system prompt; the agent loads full instructions and resources on demand.

Create a skill by adding SKILL.md to ~/.config/daemon/skills/<name>/:

---
name: my-skill
description: Helps with example tasks. Use when the user asks for example workflow guidance.
---

# My Skill

Follow this workflow when the skill is relevant.

Keywords