Skip to content

zealtv/gremlin

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

120 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

๐Ÿ‘€ gremlin

A gremlin is a folder you can talk to. Drop .gremlin/ into any directory and that directory becomes an agent โ€” persistent, scheduleable, and addressable from the TUI, Telegram, or a shell pipe.

No daemon. No database. No framework. No language runtime. Just bash, markdown, and the filesystem. A gremlin is a folder you can cp -r, git diff, and mv.

Quick start

Install into the current directory:

curl -fsSL https://raw.githubusercontent.com/zealtv/gremlin/main/install.sh | bash -s

Point it at a model. .gremlin/models/default.sh is just an executable that reads a prompt on stdin and writes a reply on stdout โ€” edit it for whichever CLI you use (Claude Code, Codex, Open Code, a local model, anything):

#!/usr/bin/env bash
exec claude -p --model claude-sonnet-4-6 --allowedTools "Bash"

Start the runner and open the TUI:

.gremlin/gremlin start
.gremlin/gremlin tui

Run /help for commands.

Talk to it from Telegram

  1. Create a bot with @BotFather and copy the token.
  2. Get your numeric chat id from @myidbot.
  3. Copy .gremlin/bridges/telegram/config.example to config, fill in TELEGRAM_BOT_TOKEN and TELEGRAM_CHAT_ID, then .gremlin/gremlin telegram start.

Features

  • The agent is a folder. Copy it, fork it, version it, delete it. There is no hidden state.
  • Almost no dependencies. Bash, coreutils, and whatever CLI talks to your model. Updating is /update โ€” an overlay that preserves your identity, transcripts, memory, and queues.
  • Bring your own model. A model preset is just stdin โ†’ stdout. Swap models with /model <alias>. Non-LLM scripts work too.
  • One inbox, many sources. TUI, Telegram, scheduled ticks, peer gremlins, and gremlin say all funnel through .nest/in/. One tender loop, one dispatch rule.
  • Composition is adjacency. Multiple gremlins = multiple folders. Delegation is mv item ../other/.gremlin/.nest/in/.
  • Scheduled and persistent. Background tend + tick loops give you reminders, nightly summaries, and self-initiated work without a separate scheduler.
  • Append-only transcript. transcript.md is the source of truth. Bridges tail it. Debugging is cat.
  • Memory you control. Glean stores findings as flat markdown; the catalog is broadcast by default, bodies are fetched on demand, and selected findings can be promoted into full context with a symlink.
  • Everything is a file. Skills, tools, commands, model presets, bridges โ€” every extension point is a directory of small scripts or markdown.

Layout

your-folder/
โ””โ”€โ”€ .gremlin/
    โ”œโ”€โ”€ gremlin.md           identity, personality, voice
    โ”œโ”€โ”€ context/             always-loaded context, including managed system/ links
    โ”œโ”€โ”€ skills/              markdown procedures with triggers
    โ”œโ”€โ”€ tools/               bash tools the gremlin can run
    โ”œโ”€โ”€ models/              stdin โ†’ stdout model presets
    โ”œโ”€โ”€ commands/            slash commands
    โ”œโ”€โ”€ bridges/             TUI, Telegram, โ€ฆ
    โ”œโ”€โ”€ .nest/               inbox / claimed / completed items
    โ”œโ”€โ”€ .groundhog/          scheduled work
    โ”œโ”€โ”€ .glean/              memory workbench
    โ”œโ”€โ”€ transcript.md        append-only conversation log
    โ””โ”€โ”€ gremlin              the executable

More

User-facing docs live inside the installed gremlin:

  • .gremlin/README.md โ€” full usage guide
  • .gremlin/docs/protocol.md โ€” loops, transcript, dispatch, models
  • .gremlin/docs/composition.md โ€” multiple gremlins, delegation, sandboxing

The underlying file-based protocols are vendored and documented on their own:

  • ๐Ÿชบ nestlings โ€” queueing and actioning work
  • ๐Ÿฆซ groundhog โ€” scheduling recurring tasks
  • ๐Ÿ”ฎ glean โ€” memory distillation and retrieval
  • ๐Ÿชก loom โ€” planning structured work

Sandboxing

The protocol does not enforce a sandbox. Host a gremlin where broad shell and file access is acceptable. For real isolation, wrap .gremlin/bin/llm.sh with a separate UNIX user, container, VM, sandbox-exec, bwrap, or equivalent.

About

๐Ÿ‘€ A tiny AI agent built from text files and bash scripts. Put a gremlin in a folder to chat to it, issue commands, and schedule tasks

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages