···19192020What makes this project worth looking at:
21212222-- Reusable Go core: run the agent as a CLI, or embed it as a library/subprocess in other apps.
2323-- Serious secure defaults: secrets stay out of prompts/tool params/logs via profile-based auth and redaction (see [docs/security.md](docs/security.md)).
2424-- Practical Skills system: discover + inject `SKILL.md`, with smart selection and optional auth profile declarations for safe API use (see [docs/skills.md](docs/skills.md)).
2222+- 🧩 Reusable Go core: Run the agent as a CLI, or embed it as a library/subprocess in other apps.
2323+- 🤝 Mesh Agent Exchange Protocol (MAEP): You and your amigos run multiple agents and want them to message each other: use the MAEP, a p2p protocol with trust-state and audit trails.
2424+- 🔒 Serious secure defaults: Profile-based credential injection, Guard redaction, outbound policy controls, and async approvals with audit trails (see [docs/security.md](docs/security.md)).
2525+- 🧰 Practical Skills system: Discover + inject `SKILL.md` from `~/.morph`, `~/.claude`, and `~/.codex`, with smart routing plus explicit control (see [docs/skills.md](docs/skills.md)).
25262627## Quickstart
27282828-### Build
2929+### Step 1: Install
29303031```bash
3131-go build -o ./bin/mistermorph ./cmd/mistermorph
3232+go install github.com/lyricat/mistermorph@latest
3233```
33343434-### Install the Agent
3535+### Step 2: Install the Agent requirements and built-in skills
35363637```bash
3737-./bin/mistermorph install
3838+mistermorph install
3839# or
3939-./bin/mistermorph install <dir>
4040+mistermorph install <dir>
4041```
41424242-the `install` command install required files and builtin skills and places them under `~/.morph/skills/` (or specified dir, if provided by `<dir>`).
4343+The `install` command installs required files and built-in skills under `~/.morph/skills/` (or a specified directory via `<dir>`).
43444444-### Setup an API key
4545+### Step 3: Setup an API key
45464647Open the config file `~/.morph/config.yaml` and set your LLM provider API key, e.g. for OpenAI:
4748···5354 api_key: "YOUR_OPENAI_API_KEY_HERE"
5455```
55565656-### Run
5757+Mister Morph also supports Azure OpenAI, Anthropic Claude, AWS Bedrock, and others (see `assets/config/config.example.yaml` for more options).
5858+5959+### Step 4: One-time Run
57605861```bash
5959-./bin/mistermorph run --task "Summarize this repo structure" --provider openai --model gpt-5 --api-key "$API_KEY" --endpoint "https://api.openai.com/v1"
6262+mistermorph run --task "Hello!"
6063```
61646262-### Human-in-the-loop
6565+## Telegram bot mode
63666464-Run with `--interactive`, then press Ctrl-C during the loop to pause and type extra context (end with an empty line).
6767+Run a Telegram bot (long polling) so you can chat with the agent from Telegram:
6868+6969+Edit the config file `~/.morph/config.yaml` and set your Telegram bot token:
7070+7171+```yaml
7272+telegram:
7373+ bot_token: "YOUR_TELEGRAM_BOT_TOKEN_HERE"
7474+ allowed_chat_ids: [] # add allowed chat ids here
7575+```
65766677```bash
6767-./bin/mistermorph run --interactive --task "..." --provider openai --model gpt-5.2 --api-key "$API_KEY" --endpoint "https://api.openai.com/v1"
7878+mistermorph telegram --log-level info
6879```
69808181+Notes:
8282+- Use `/id` to get the current chat id and add it to `allowed_chat_ids` for allowlisting.
8383+- Use `/ask <task>` in groups.
8484+- In groups, the bot also responds when you reply to it, or mention `@BotUsername`.
8585+- You can send a file; it will be downloaded under `file_cache_dir/telegram/` and the agent can process it. The agent can also send cached files back via `telegram_send_file`, and send a voice message via `telegram_send_voice` (requires a local TTS engine (e.g. `espeak-ng`) + `ffmpeg`/`opusenc`).
8686+- The last loaded skill(s) stay “sticky” per chat (so follow-up messages won’t forget SKILL.md); `/reset` clears this.
8787+- If you configure `telegram.aliases`, the default `telegram.group_trigger_mode=smart` only triggers on aliases when the message looks like direct addressing. Alias hits are LLM-validated in smart mode.
8888+- Use `/reset` in chat to clear conversation history.
8989+- By default it runs multiple chats concurrently, but processes each chat serially (config: `telegram.max_concurrency`).
9090+9191+7092## Daemon mode
71937294Run a local HTTP daemon that accepts tasks sequentially (one-by-one), so you don’t need to restart the process for each task.
···75977698```bash
7799export MISTER_MORPH_SERVER_AUTH_TOKEN="change-me"
7878-./bin/mistermorph serve --server-port 8787 --log-level info
100100+mistermorph serve --server-port 8787 --log-level info
79101```
8010281103Submit a task:
8210483105```bash
8484-./bin/mistermorph submit --server-url http://127.0.0.1:8787 --auth-token "$MISTER_MORPH_SERVER_AUTH_TOKEN" --wait \
106106+mistermorph submit --server-url http://127.0.0.1:8787 --auth-token "$MISTER_MORPH_SERVER_AUTH_TOKEN" --wait \
85107 --task "Summarize this repo and write to ./summary.md"
86108```
871098888-## Telegram bot mode
8989-9090-Run a Telegram bot (long polling) so you can chat with the agent from Telegram:
9191-9292-```bash
9393-export MISTER_MORPH_TELEGRAM_BOT_TOKEN="123456:ABC..."
9494-./bin/mistermorph telegram --telegram-allowed-chat-id 123456789 --log-level info
9595-```
9696-9797-Notes:
9898-- Use `/ask <task>` in groups.
9999-- In groups, the bot also responds when you reply to it, or mention `@BotUsername`.
100100-- Bot replies are sent with Telegram MarkdownV2.
101101-- You can send a file; it will be downloaded under `file_cache_dir/telegram/` and the agent can process it. The agent can also send cached files back via `telegram_send_file`, and send a voice message via `telegram_send_voice` (requires a local TTS engine (e.g. `espeak-ng`) + `ffmpeg`/`opusenc`).
102102-- The last loaded skill(s) stay “sticky” per chat (so follow-up messages won’t forget SKILL.md); `/reset` clears this.
103103-- If you configure `telegram.aliases`, the default `telegram.group_trigger_mode=smart` only triggers on aliases when the message looks like direct addressing. Alias hits are LLM-validated in smart mode.
104104-- You can tune smart addressing with `telegram.smart_addressing_max_chars` and `telegram.smart_addressing_confidence` for the trigger detection.
105105-- Use `/id` to print the current chat id (useful for allowlisting group ids).
106106-- Use `/reset` in chat to clear conversation history.
107107-- If you omit `--telegram-allowed-chat-id`, all chats can talk to the bot (not recommended).
108108-- By default it runs multiple chats concurrently, but processes each chat serially (config: `telegram.max_concurrency`).
109109-110110## Embedding to other projects
111111112112Two common integration options:
···132132- `telegram_send_voice`: send a voice message in Telegram.
133133- `telegram_react`: add an emoji reaction in Telegram.
134134135135+Please see [`docs/tools.md`](docs/tools.md) for detailed tool documentation.
136136+135137## Skills
136138137139`mistermorph` can discover skills under `~/.morph/skills`, `~/.claude/skills`, and `~/.codex/skills` (recursively), and inject selected `SKILL.md` content into the system prompt.
···142144143145```bash
144146# list available skills
145145-./bin/mistermorph skills list
147147+mistermorph skills list
146148# Use a specific skill in the run command
147147-./bin/mistermorph run --task "..." --skills-mode explicit --skill skill-name
149149+mistermorph run --task "..." --skills-mode explicit --skill skill-name
148150# install remote skills
149149-./bin/mistermorph skills install <remote-skill-url>
151151+mistermorph skills install <remote-skill-url>
150152```
151153152152-### Security Meachanisms for Skills
154154+### Security Mechanisms for Skills
1531551541561. Install audit: When installing remote skills, Mister Morph will preview the skill content and do a basic security audit (e.g., look for dangerous commands in scripts) before asking for user confirmation.
155155-2. Auth profiles2. Auth profiles: Skills can declare required auth profiles in `auth_profiles` field. The agent will only use skills whose auth profiles are configured on the host, preventing accidental secret leaks (see `assets/skills/moltbook` as the example, see `secrets` and `auth_profiles` sections in the config file).
157157+2. Auth profiles: Skills can declare required auth profiles in the `auth_profiles` field. The agent will only use skills whose auth profiles are configured on the host, preventing accidental secret leaks (see `assets/skills/moltbook` and the `secrets` / `auth_profiles` sections in the config file).
156158157159## Security
158160159159-Recommended systemd hardening and secret handling: `docs/security.md`.
161161+Recommended systemd hardening and secret handling: [`docs/security.md`](docs/security.md).
160162161163## Debug
162164···165167There is an argument `--log-level` set for logging level and format:
166168167169```bash
168168-./bin/mistermorph run --log-level debug --task "..."
170170+mistermorph run --log-level debug --task "..."
169171```
170172171173### Dump internal debug data
···173175There are 2 arguments `--inspect-prompt`/`--inspect-request` for dumping internal state for debugging:
174176175177```bash
176176-./bin/mistermorph run --inspect-prompt --inspect-request --task "..."
178178+mistermorph run --inspect-prompt --inspect-request --task "..."
177179```
178180179181These arguments will dump the final system/user/tool prompts and the full LLM request/response JSON as plain text files to `./dump` directory.