-
Notifications
You must be signed in to change notification settings - Fork 10
Expand file tree
/
Copy pathconfig.example.yaml
More file actions
711 lines (683 loc) · 29.6 KB
/
Copy pathconfig.example.yaml
File metadata and controls
711 lines (683 loc) · 29.6 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
# Example config for mistermorph
#
# Usage:
# ./mistermorph run --config ./assets/config/config.example.yaml --task "..."
#
# YAML scalar values support ${ENV_VAR} syntax for environment variable expansion.
# Secret scalar values can also use AWS Secrets Manager refs: ${aws-sm:<secret-id>} or ${aws-sm:<secret-id>#<field>}.
# Mapping keys and comments are not expanded.
# Example: api_key: "${OPENAI_API_KEY}"
#
# Env vars (override config):
# - Preferred: MISTER_MORPH_LLM_PROVIDER, MISTER_MORPH_LLM_ENDPOINT, MISTER_MORPH_LLM_MODEL, MISTER_MORPH_LLM_API_KEY
# - Cloudflare: MISTER_MORPH_LLM_CLOUDFLARE_ACCOUNT_ID, MISTER_MORPH_LLM_CLOUDFLARE_API_TOKEN
# Global User-Agent for outbound HTTP requests (tools like url_fetch, web_search, etc).
user_agent: "mistermorph/1.0 (+https://github.com/quailyquaily)"
auto_update:
# Shared update policy. Desktop startup checks use this setting, and
# --check-update uses it to decide whether to download verified packages.
enabled: false
llm:
# Human-facing inference provider. This derives the protocol provider and API Base.
# Supported: openai|openai_codex|gemini|anthropic|bedrock|cloudflare|mistermorph_pro|xai|xai_oauth|meta|deepseek|kimi|openrouter|groq|sakana|openai_chat_compatible|openai_response_compatible|anthropic_compatible.
inference_provider: openai
# Protocol provider. Usually derived from inference_provider; kept for older configs and advanced overrides.
provider: openai_resp
# Default model used by the main agent loop.
model: "gpt-5.4"
# Optional model context window, in tokens. Empty or 0 uses the built-in catalog when known.
# context_window_tokens: 100000
# API Base. Required for *_compatible inference providers. For openai_codex,
# this is an optional override; empty uses the default Codex endpoint.
endpoint: "https://api.openai.com"
# Provider API key. For openai_codex, this is used only when endpoint is
# also non-empty; otherwise authentication uses Codex OAuth.
# Use ${ENV_VAR} to avoid committing secrets.
api_key: "${OPENAI_API_KEY}" # or set via MISTER_MORPH_LLM_API_KEY
# Optional custom HTTP headers for LLM requests.
# headers:
# YOUR-HEADER: "${YOUR_HEADER_VALUE}"
# "-X-ABC-TOKEN": "${ABC_TOKEN}"
# Cache hint shared across providers.
# Values:
# - off
# - short
# - long
# - Go duration strings such as "5m", "1h", "24h"
# The runtime maps this to provider-supported cache buckets automatically.
cache_ttl: "short"
# Optional prefix added to generated prompt_cache_key values for providers that support it.
# Change this value to force a new cache group during testing.
cache_key_prefix: ""
# Per-LLM HTTP request timeout (0 uses provider default).
request_timeout: "90s"
# Optional default temperature. If empty/unset, do not call uniai.WithTemperature(...).
# temperature: 0.2
# Optional default reasoning effort. If empty/unset, do not call uniai.WithReasoningEffort(...).
# Values: none | minimal | low | medium | high | max | xhigh
reasoning_effort: ""
# Optional default reasoning budget tokens. If empty/unset, do not call uniai.WithReasoningBudgetTokens(...).
# reasoning_budget_tokens: 8192
# Optional local pricing catalog YAML to override uniai's embedded default prices.
# Relative paths resolve from the config.yaml directory.
# pricing_file: "./pricing.yaml"
# Tool-call emulation mode for providers/models without native tool calling.
# Values: off | fallback | force
tools_emulation_mode: "off"
# Provider-specific settings for Azure OpenAI.
azure:
deployment: "" # Azure OpenAI deployment name
# Provider-specific settings for AWS Bedrock.
# Authentication methods (in order of precedence when multiple are set):
# 1. Named profile: set aws_profile to use ~/.aws/config
# 2. Static credentials: set aws_key + aws_secret (+ optional aws_session_token)
# 3. Default chain: leave all credential fields empty to use env vars / instance metadata
bedrock:
aws_key: "${AWS_ACCESS_KEY_ID}"
aws_secret: "${AWS_SECRET_ACCESS_KEY}"
aws_session_token: "" # Optional: for STS temporary credentials / SSO
aws_profile: "" # Optional: named AWS profile from ~/.aws/config
region: ""
model_arn: ""
# Provider-specific settings for Cloudflare Workers AI.
cloudflare:
account_id: ""
api_token: "${CLOUDFLARE_API_TOKEN}"
# Optional image model configuration for image_generate and image_edit.
# If empty, image config can inherit top-level llm.* only when llm.provider is openai or gemini and llm.api_key is set.
# openai_codex and xai_oauth can accept image inputs in chat, but do not provide
# credentials for image_generate or image_edit. Configure llm.image explicitly for those tools.
image:
provider: ""
endpoint: ""
api_key: ""
model: ""
request_timeout: "180s"
options:
openai: {}
gemini: {}
cloudflare: {}
# Optional named LLM profiles. Each profile is independent and does not inherit
# provider, endpoint, credentials, model, or other LLM fields from top-level llm.*.
# profiles:
# cheap:
# inference_provider: openai
# model: "gpt-4.1-mini"
# api_key: "${OPENAI_API_KEY}"
# supports_image_parts: false # optional override for custom aliases or mixed-capability routes
# context_window_tokens: 100000 # optional explicit value for this profile
# cache_ttl: "long"
# cache_key_prefix: "cheap-test"
# reasoning:
# inference_provider: xai
# model: "grok-4.1-fast-reasoning"
# api_key: "${XAI_API_KEY}"
# reasoning_effort: "high"
# grok_subscription:
# inference_provider: xai_oauth
# model: "grok-4.5"
# reasoning_effort: "high"
# Optional route map. Supported purposes:
# main_loop | addressing | awareness | heartbeat | think | plan_create
# `heartbeat` is kept as a legacy alias for `awareness`.
# `/think <task>` uses routes.think when set, otherwise the default profile,
# then temporarily applies reasoning_effort: "xhigh" for that task.
# routes:
# main_loop:
# candidates:
# - profile: default
# weight: 1
# - profile: cheap
# weight: 1
# fallback_profiles: ["reasoning"]
# addressing:
# profile: cheap
# fallback_profiles: ["default"]
# awareness: cheap
# think: reasoning
# plan_create: reasoning
logging:
# debug|info|warn|error
# - info: emits high-level progress (run_start, tool_call, tool_done, final)
# - debug: also logs thoughts and extra details
level: "info"
# text|json
format: "text"
# Include source file:line in each log record.
add_source: false
file:
# Local JSONL log output directory. Empty means <file_state_dir>/logs.
dir: ""
# Delete log files older than this duration. Files are named by local date.
max_age: "168h"
# If true, logs the model's "thought" fields (may contain sensitive info).
include_thoughts: true
# If true, logs tool_call parameters (redacted and truncated).
include_tool_params: true
# Even if include_tool_params=false, logs a small per-tool args summary (for example url_fetch.url, web_search.q, contacts_send/agent_send.contact_id).
# For bash, the full command is only logged when include_tool_params=true.
# If true, logs loaded SKILL.md contents (truncated).
include_skill_contents: false
# Limits for logged content.
max_thought_chars: 2000
max_json_bytes: 32768
max_string_value_chars: 2000
max_skill_content_chars: 8000
# Extra parameter keys to redact in logs (in addition to built-in defaults like token/api_key/password).
redact_keys: []
# Secrets / auth profiles
#
# Goal: allow safe credential injection without ever putting secrets into:
# - SKILL.md
# - tool params / logs
# - LLM context
#
# When at least one allowlisted auth profile is configured, `bash` still works, but `curl` is
# rejected by default to avoid "bash + curl" carrying authenticated HTTP requests. Use
# `url_fetch` + `auth_profile` instead.
secrets:
# Allowlisted profile ids. Default empty means no profiles can be used.
allow_profiles: []
# Optional AWS Secrets Manager source for ${aws-sm:...} config refs.
# Credentials still come from the AWS SDK default credential chain.
aws_secrets_manager:
region: "" # Optional; empty uses AWS_REGION / shared config / SDK defaults.
profile: "" # Optional; empty uses AWS_PROFILE / shared config / SDK defaults.
# Auth profiles are referenced by tools via `auth_profile: "<id>"`.
#
# NOTE: Use ${ENV_VAR} or ${aws-sm:<secret-id>} syntax for secrets to avoid committing them to config files.
auth_profiles:
# jsonbill:
# credential:
# kind: api_key
# secret: "${JSONBILL_API_KEY}" # or "${aws-sm:mistermorph/jsonbill#api_key}"
# allow:
# url_prefixes: ["https://api.jsonbill.com/tasks/docs"]
# methods: ["POST"]
# follow_redirects: false
# allow_proxy: false
# deny_private_ips: true
# bindings:
# url_fetch:
# inject:
# location: header
# name: Authorization
# format: bearer
# allow_user_headers: true
# user_header_allowlist: ["Accept", "Content-Type", "User-Agent"]
# Guard (M1)
#
# Guard is a lightweight, content/workflow safety layer:
# - outbound destination allowlists (primarily url_fetch)
# - redaction for tool outputs + final outputs
# - async approvals + audit trail (JSONL), with approvals state in file storage
guard:
enabled: true
# Directory name under file_state_dir for guard state.
dir_name: "guard"
network:
url_fetch:
# Allow outbound HTTP only to these URL prefixes (fail-closed when empty).
allowed_url_prefixes: ["https://"]
# Deny localhost and literal private IP destinations.
deny_private_ips: true
# Redirects are a common allowlist bypass; keep disabled by default.
follow_redirects: false
# Ignore HTTP(S)_PROXY by default to avoid unexpected routing/MITM.
allow_proxy: false
redaction:
enabled: true
# Optional additional regex patterns (built-in redactors always apply).
patterns: [] # [{name: "...", re: "..."}]
audit:
# JSONL audit log path (append-only). When empty, defaults to <file_state_dir>/<guard.dir_name>/audit/guard_audit.jsonl.
jsonl_path: ""
rotate_max_bytes: 104857600
approvals:
enabled: false
tools:
# For tools, enabled=false means "not exposed by default".
# A user can still opt in for the current task with $name, such as $bash or $image_generate.
# This does not bypass guard rules, sandbox limits, credentials, or runtime prerequisites.
read_file:
# Enable the read_file tool (reads a local file).
# Note: currently always enabled; this section configures limits/policy.
max_bytes: 262144
# Denylist for sensitive local files. Basenames match anywhere (e.g. "config.yaml" blocks "./x/config.yaml").
deny_paths:
- "config.yaml"
write_file:
# Enable the write_file tool (writes text to a local file).
# Note: writes are restricted to `file_cache_dir` or `file_state_dir`.
enabled: true
# Max bytes allowed per write_file call.
max_bytes: 524288
spawn:
# Enable the spawn tool.
# This controls the explicit spawn tool only; subtask remains a runtime mechanism.
enabled: true
coder:
# Enable the coder tool.
# It runs local Codex / Claude Code CLI subtasks with approval and permission prompts bypassed.
enabled: false
# Extra directories prepended to PATH when launching codex / claude for the coder tool.
# Use this when those CLIs are installed outside the service manager's PATH.
# path_extra:
# - "/opt/coder/bin"
path_extra: []
acp_spawn:
# Enable the acp_spawn tool.
# This controls the explicit ACP subtask entry only.
enabled: false
contacts_send:
# Enable contacts_send tool.
enabled: true
todo_update:
# Enable cron task update tool (todo_update).
enabled: true
plan_create:
# Enable planning tool (plan_create) in run/serve/telegram runtimes.
enabled: true
# Default max steps
max_steps: 6
image_generate:
# Enable image generation. The tool is registered only when the current task has explicit image intent.
enabled: true
image_edit:
# Enable image editing. The tool is registered only when the current task has explicit image intent or retained image-tool state.
enabled: true
url_fetch:
# Enable the url_fetch tool (HTTP(S) GET/POST/PUT/DELETE, truncated output).
enabled: true
# Per-request timeout.
timeout: "30s"
# Max response bytes to read (tool will truncate beyond this).
max_bytes: 524288
# Max response bytes to read when download_path is set.
max_bytes_download: 104857600
web_search:
# Enable the web_search tool (DuckDuckGo HTML by default).
enabled: true
# DuckDuckGo HTML endpoint.
base_url: "https://duckduckgo.com/html/"
# Per-request timeout.
timeout: "20s"
# Default max results (tool also enforces a hard cap).
max_results: 5
# Dangerous: enables local shell execution.
# Platform auto-detection: On Windows, PowerShell is enabled by default and Bash is disabled.
# On Linux/macOS, Bash is enabled by default and PowerShell is disabled.
# You can override these defaults by explicitly setting enabled: true/false.
bash:
# Enable the bash tool.
# Note: when allowlisted auth profiles are configured, bash is allowed but `curl` is denied by default.
# Default: auto (true on Linux/macOS, false on Windows).
# enabled: true
# Default timeout for each bash command.
timeout: "30s"
# Max combined output bytes kept per stream (stdout/stderr) before truncation.
max_output_bytes: 262144
# Denylist for sensitive local files. If a command references one of these paths, the tool errors.
# (Best-effort string match; not a full sandbox.)
deny_paths:
- "config.yaml"
# Extra directories prepended to PATH for bash execution.
# Useful when the service manager starts mistermorph with a minimal PATH.
# path_extra:
# - "/opt/my-tools/bin"
path_extra: []
# Extra environment variables to inject into bash execution.
# Each entry can be either a variable name (looked up from the parent process)
# or an object with a fixed value written into config.yaml.
# injected_env_vars:
# - OPENAI_API_BASE
# - name: MY_FIXED_TOKEN
# value: "xxxxxx"
injected_env_vars: []
# Optional command prefix before execution, for tools such as RTK.
# Example: binary "rtk" turns `git status` into `rtk git status`.
rewrite:
enabled: false
binary: ""
# Dangerous: enables local PowerShell execution (Windows).
powershell:
# Enable the powershell tool.
# Default: auto (true on Windows, false on Linux/macOS).
# enabled: true
# Default timeout for each powershell command.
timeout: "30s"
# Max combined output bytes kept per stream (stdout/stderr) before truncation.
max_output_bytes: 262144
# Denylist for sensitive local files. If a command references one of these paths, the tool errors.
deny_paths:
- "config.yaml"
# Extra environment variables to inject into powershell execution.
# Each entry can be either a variable name or an object with name/value.
injected_env_vars: []
# MCP (Model Context Protocol) servers.
# Connect to external MCP tool servers. Tools are namespaced as mcp_<name>__<tool>.
mcp:
servers: []
# - name: "filesystem"
# enable: true # set false to disable; default true
# type: "stdio" # stdio (default) | http
# command: "npx"
# args: ["-y", "@modelcontextprotocol/server-filesystem", "/tmp"]
# env:
# NODE_OPTIONS: "--max-old-space-size=4096"
# allowed_tools: [] # empty = all tools from this server
# - name: "remote"
# enable: true
# type: "http"
# url: "https://mcp.example.com/mcp"
# headers: # custom HTTP headers (e.g. auth); values support ${ENV_VAR}
# Authorization: "Bearer ${MCP_REMOTE_TOKEN}"
# allowed_tools: ["search"]
# ACP external agents.
# ACP tools are engine-scoped. Enable `tools.acp_spawn.enabled` to expose the explicit entry.
# Each ACP profile runs as a local child process over stdio.
acp:
agents: []
# - name: "codex"
# # Published adapter on npm:
# command: "npx"
# args: ["-y", "@archkk/acp-codex"]
# # Or install globally and call the bin directly:
# # command: "mistermorph-acp-codex"
# # args: []
# # Or use another compatible adapter:
# # command: "codex-acp"
# # args: []
# env: {}
# cwd: "."
# read_roots: ["."]
# write_roots: ["."]
# session_options: {} # forwarded to session/new._meta; advertised config ids also receive session/set_config_option
# # Example for adapters that advertise these config ids:
# # session_options:
# # mode: "auto"
# # reasoning_effort: "low"
# - name: "claude"
# # Published adapter on npm:
# command: "npx"
# args: ["-y", "@archkk/acp-claude"]
# # Or install globally and call the bin directly:
# # command: "mistermorph-acp-claude"
# # args: []
# env: {}
# cwd: "."
# read_roots: ["."]
# write_roots: ["."]
# session_options:
# permission_mode: "dontAsk"
# allowed_tools: ["Read", "Edit", "Write", "Bash", "Glob", "Grep"]
# max_turns: 8
# # Set bare: true only when you authenticate with API keys or explicit settings.
# # Claude Code bare mode skips OAuth and keychain reads.
# - name: "cursor"
# # Cursor CLI already speaks ACP directly.
# command: "agent"
# args: ["acp"]
# env: {}
# # Optional: pass flags before the final `acp` subcommand, e.g.:
# # args: ["--api-key", "${CURSOR_API_KEY}", "acp"]
# cwd: "."
# read_roots: ["."]
# write_roots: ["."]
# Message bus
bus:
# In-process bus (M1).
max_inflight: 1024
# Platform identities allowed to start Agent pairing in a private chat.
# Telegram usernames must already exist in Contacts.
admins:
- tg:@admin
- slack:T123:U234
# Contacts business state (proactive sharing profiles/candidates/audit).
contacts:
# Directory name under file_state_dir for contacts domain storage.
dir_name: "contacts"
proactive:
# Max turns for one proactive conversation session (contact + conversation_id).
max_turns_per_session: 6
# Cooldown after reaching max turns before auto-reply can resume.
session_cooldown: "10m"
# Cooldown applied when proactive/direct send fails (e.g. peer unavailable).
failure_cooldown: "1h"
# Task projections and journal settings.
tasks:
# Directory name under file_state_dir for task projection snapshots.
dir_name: "tasks"
# Targets whose task projections are restored after restart.
# Accepted task and topic changes from every target are still written to the journal.
# Supported values: console, telegram, slack, line, lark
persistence_targets: ["console"]
# Maximum size of each task journal segment.
rotate_max_bytes: 67108864
skills:
# Directory name under file_state_dir for skills.
dir_name: "skills"
# If false, skills are not loaded automatically or from the load list.
# A $name reference in the task still loads that skill for the run.
enabled: true
# Skills to load (by skill name or id).
# Empty means load all discovered skills.
# Unknown entries are ignored.
load: [] # e.g. [] | ["skill-creator", "my-skill-id"]
# Shared runtime server settings.
server:
# Bearer token required for submit/get endpoints.
# Also used by channel runtime APIs (telegram/slack/line/lark/console runtime API server).
# Prefer env var: MISTER_MORPH_SERVER_AUTH_TOKEN.
auth_token: ""
# Max queued tasks (in-memory).
max_queue: 100
# Console mode (`mistermorph console serve`).
console:
# Bind address for console API + SPA.
listen: "127.0.0.1:9080"
# Base path for console routes and static files.
base_path: "/"
# Optional static directory for SPA build artifacts.
# Can be overridden by --console-static-dir.
static_dir: ""
# Prefer password_hash in production; set via env when possible.
password: "" # or set via MISTER_MORPH_CONSOLE_PASSWORD
# Bcrypt hash string, e.g. "$2a$..."
password_hash: "" # or set via MISTER_MORPH_CONSOLE_PASSWORD_HASH
# Session TTL for console bearer token.
session_ttl: "12h"
# Channel runtimes managed in-process by `mistermorph console serve`.
# Managed runtimes are merged into Console itself:
# - they do not appear as separate endpoints
# - they do not run their own heartbeat
# Supported values today: telegram, slack, lark
managed_runtimes: [] # e.g. ["telegram", "slack", "lark"]
# Console always includes one built-in local runtime endpoint in-process.
# Additional external runtime endpoints shown in Console endpoint selector.
# Use ${ENV_VAR} syntax in auth_token to reference environment variables.
endpoints:
- name: "Telegram Instance"
url: "http://127.0.0.1:8787/runtime"
auth_token: "${MISTER_MORPH_ENDPOINT_TELEGRAM_TOKEN}"
- name: "Slack Instance"
url: "http://127.0.0.1:8788/runtime"
auth_token: "${MISTER_MORPH_ENDPOINT_SLACK_TOKEN}"
# Telegram bot mode (`mistermorph telegram`).
telegram:
# Bot token from @BotFather. Prefer env var: MISTER_MORPH_TELEGRAM_BOT_TOKEN
bot_token: ""
# Optional allowlist of chat ids (strings). If empty, allows all.
allowed_chat_ids: []
# Group trigger mode:
# - strict: only replies and @mentions trigger in groups.
# - smart: every group message goes through addressing LLM classification; `addressed=true` is required.
# - talkative: every group message goes through addressing LLM classification; does not require `addressed=true`.
group_trigger_mode: "talkative"
# Persist valid group messages rejected by group trigger to the shared journal.
record_untriggered: false
# Group reply policy is fixed to humanlike (not configurable).
# Minimum confidence required to accept the LLM addressing classification.
addressing_confidence_threshold: 0.7
# Maximum interject allowed to accept the LLM addressing classification.
addressing_interject_threshold: 0.6
# Long polling timeout.
poll_timeout: "30s"
# Per-message agent timeout (0 uses top-level timeout).
task_timeout: "0s"
# Max number of chats processed concurrently (each chat remains serial).
max_concurrency: 3
# Runtime API listen address for Telegram runtime (standard base path: `/runtime`).
# Protected by server.auth_token.
serve_listen: ""
# Note: file handling is always enabled; files are downloaded under file_cache_dir/telegram/ (max size is hardcoded).
# Slack bot mode (`mistermorph slack`, Socket Mode only).
slack:
# Slack Web API base URL (override for mock/testing only).
base_url: "https://slack.com/api"
# Bot token with chat:write + history scopes. Add files:read for Slack image input.
# Prefer env var: MISTER_MORPH_SLACK_BOT_TOKEN
bot_token: ""
# App-level token for Socket Mode. Prefer env var: MISTER_MORPH_SLACK_APP_TOKEN
app_token: ""
# Optional allowlist of workspace IDs. Empty means allow the bot home workspace.
allowed_team_ids: []
# Optional allowlist of channel IDs. Empty means allow all channels in allowed teams.
# Also used as heartbeat notification targets in `mistermorph slack`.
allowed_channel_ids: []
# Group trigger mode:
# - strict: only explicit triggers (app_mention/@bot mention) in groups.
# - smart: every group message goes through addressing LLM classification; `addressed=true` is required.
# - talkative: every group message goes through addressing LLM classification; does not require `addressed=true`.
group_trigger_mode: "smart"
# Persist valid group messages rejected by group trigger to the shared journal.
record_untriggered: false
# Minimum confidence required to accept the LLM addressing classification.
addressing_confidence_threshold: 0.6
# Minimum interject required to accept the LLM addressing classification.
addressing_interject_threshold: 0.6
# Per-message agent timeout (0 uses top-level timeout).
task_timeout: "0s"
# Max number of conversations processed concurrently.
max_concurrency: 3
# Runtime API listen address for Slack runtime (standard base path: `/runtime`).
# Protected by server.auth_token.
serve_listen: ""
# LINE bot mode (`mistermorph line`, webhook, group + private in V1).
line:
# LINE Messaging API base URL (override for mock/testing only).
base_url: "https://api.line.me"
# Channel access token. Prefer env var: MISTER_MORPH_LINE_CHANNEL_ACCESS_TOKEN
channel_access_token: ""
# Channel secret used to verify webhook signature. Prefer env var: MISTER_MORPH_LINE_CHANNEL_SECRET
channel_secret: ""
# Webhook HTTP listen address.
webhook_listen: "localhost:18080"
# Webhook path.
webhook_path: "/line/webhook"
# Optional allowlist of group IDs. Empty means allow all groups.
allowed_group_ids: []
# Group trigger mode:
# - strict: only explicit triggers in groups.
# - smart: every group message goes through addressing LLM classification; `addressed=true` is required.
# - talkative: every group message goes through addressing LLM classification; does not require `addressed=true`.
group_trigger_mode: "smart"
# Persist valid group messages rejected by group trigger to the shared journal.
record_untriggered: false
# Minimum confidence required to accept the LLM addressing classification.
addressing_confidence_threshold: 0.6
# Minimum interject required to accept the LLM addressing classification.
addressing_interject_threshold: 0.6
# Per-message agent timeout (0 uses top-level timeout).
task_timeout: "0s"
# Max number of conversations processed concurrently.
max_concurrency: 3
# Runtime API listen address for LINE runtime (standard base path: `/runtime`).
# Protected by server.auth_token.
serve_listen: ""
# Lark bot mode (`mistermorph lark`, WebSocket long connection, group + private).
lark:
# Feishu Open API base URL. Use https://open.larksuite.com/open-apis for Lark global.
base_url: "https://open.feishu.cn/open-apis"
# App ID. Prefer env var: MISTER_MORPH_LARK_APP_ID
app_id: ""
# App secret. Prefer env var: MISTER_MORPH_LARK_APP_SECRET
app_secret: ""
# In the Feishu/Lark developer console, select long connection mode and subscribe to im.message.receive_v1.
# Webhook settings are not used.
# For image input and Lark runtime tools, grant the needed message resource/upload permissions.
# Optional allowlist of chat IDs. Empty means allow all chats.
allowed_chat_ids: []
# Group trigger mode:
# - strict: only explicit triggers in groups.
# - smart: every group message goes through addressing LLM classification; `addressed=true` is required.
# - talkative: every group message goes through addressing LLM classification; does not require `addressed=true`.
group_trigger_mode: "smart"
# Persist valid group messages rejected by group trigger to the shared journal.
record_untriggered: false
# Minimum confidence required to accept the LLM addressing classification.
addressing_confidence_threshold: 0.6
# Minimum interject required to accept the LLM addressing classification.
addressing_interject_threshold: 0.6
# Per-message agent timeout (0 uses top-level timeout).
task_timeout: "0s"
# Max number of conversations processed concurrently.
max_concurrency: 3
# Runtime API listen address for Lark runtime (standard base path: `/runtime`).
# Protected by server.auth_token.
serve_listen: ""
# Heartbeat (periodic awareness/checkpoint).
# Heartbeat is scheduled by the cron service; set cron.enabled: true to run it.
heartbeat:
# Enable heartbeats by default.
enabled: true
# Interval between heartbeats (use "0m" to disable without changing enabled).
# Delivery target is runtime-specific:
# - `mistermorph telegram`: `telegram.allowed_chat_ids`
# - `mistermorph slack`: `slack.allowed_channel_ids`
interval: "30m"
# Cron task service (`file_state_dir/cron.yaml`).
cron:
# Enable cron scheduling. Missing cron.yaml is treated as an empty schedule.
enabled: true
# Agent loop limits.
# - max_steps: maximum tool-call steps in the ReAct loop.
max_steps: 64
# - parse_retries: how many times to ask the model to retry if it emits invalid JSON.
parse_retries: 2
# - max_token_budget: stop the loop once cumulative tokens exceed this (0 disables).
max_token_budget: 0
# - tool_repeat_limit: maximum executions per tool name within one run.
tool_repeat_limit: 64
# Context checkpoint compaction for conversation-bound runtimes.
context_compaction:
# Generate checkpoints before the prompt reaches the model context limit.
enabled: true
# Trigger after the latest main-loop input reaches this share of the usable input window.
trigger_ratio: 0.80
# Reserved output tokens. 0 uses the runtime default.
output_reserve_tokens: 0
# Overall run timeout.
timeout: "10m"
# Chat display settings.
chat:
# Compact mode: omit user/assistant name prefixes in prompts and output.
# When true, shows a green bullet (•) for user prompt and plain text for assistant.
# Default: false (chat-style display with colored name prefixes).
compact_mode: false
# Default project directory for scopes without a workspace attachment.
# The directory must already exist and be readable. Empty disables the default.
workspace_dir: ""
# Base directory for local state (tasks/contacts/skills/heartbeat).
file_state_dir: "~/.morph"
# Prompt profile context injection.
# Global temporary file cache directory used for inbound/outbound file handling (e.g. Telegram/Slack tools).
file_cache_dir: "~/.cache/morph"
file_cache:
# Note: cleanup runs on startup (best-effort).
# Max age for cached files (0 disables age-based cleanup).
max_age: "168h"
# Max number of cached files (0 disables count-based cleanup).
max_files: 1000
# Max total bytes of cached files (0 disables size-based cleanup).
max_total_bytes: 536870912