-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdaemon.yaml.example
More file actions
164 lines (153 loc) · 7.17 KB
/
Copy pathdaemon.yaml.example
File metadata and controls
164 lines (153 loc) · 7.17 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
# =============================================================================
# OpenCOAT Runtime — daemon configuration (annotated production sample)
# =============================================================================
#
# Save this file anywhere (commonly ~/.opencoat/daemon.yaml) and start the
# daemon with:
#
# opencoat runtime up --config ~/.opencoat/daemon.yaml
#
# The bundled default (packages/opencoat-runtime/opencoat_runtime_daemon/
# config/default.yaml) is the canonical reference for every setting; this
# file shows the values most operators want to override and explains what
# each one means in plain English.
#
# Precedence (high → low):
#
# CLI flags > OPENCOAT_* env vars > this file > bundled default
#
# So any field you omit here just falls through to the bundled default.
#
# LLM credentials file: on startup ``python -m opencoat_runtime_daemon``
# (including ``opencoat runtime up`` and the ``opencoat service`` unit)
# merges an **allow-list** of LLM-related keys from ``~/.opencoat/opencoat.env``
# into the process environment via ``os.environ.setdefault`` **before** YAML
# is loaded. Values already exported in the shell win over the file. Keys in
# the file that are not on the allow-list are ignored (they cannot reconfigure
# unrelated daemon toggles). See ``merge_user_llm_env_file`` in
# ``opencoat_runtime_daemon.config.loader``.
# -----------------------------------------------------------------------------
# 1. Runtime — turn-loop budgets and the heartbeat cadence
# -----------------------------------------------------------------------------
runtime:
schema_version: "0.2"
loops:
# How often the background scheduler calls OpenCOATRuntime.tick().
# 30s is plenty for human-scale agents; tighten to 5–10s for high traffic.
heartbeat_interval_seconds: 30
# Set false to disable the background heartbeat thread (tests / embedded).
heartbeat_enabled: true
# M6 workers: decay, merge/archive, conflict scan tuning.
maintenance:
merge_min_keyword_overlap: 3
archive_cold_decay_threshold: 0.85
archive_cold_max_score: 0.15
budgets:
# How many concerns can be active in one Concern Vector. Above
# this the coordinator drops the lowest-priority ones.
max_active_concerns: 12
# Token budget the weaver gets when projecting advice into the
# host prompt. Stay under ~10% of the host's prompt window.
max_injection_tokens: 800
# Per-concern advice cap — keeps any one concern from monopolising
# the injection.
max_advice_per_concern: 2
# -----------------------------------------------------------------------------
# 2. Storage — where concerns and DCN history live
# -----------------------------------------------------------------------------
#
# The bundled default uses sqlite under ~/.opencoat/ (see
# packages/opencoat-runtime/.../default.yaml). Override paths or use
# ``kind: memory`` only for hermetic tests / embedded use.
storage:
concern_store:
kind: sqlite
# Tilde and $HOME expansion both work. Use an absolute path in
# production deployments so the daemon doesn't accidentally
# write to $CWD.
path: ~/.opencoat/concerns.sqlite
dcn_store:
kind: sqlite
path: ~/.opencoat/dcn.sqlite
# -----------------------------------------------------------------------------
# 3. LLM — the brain behind ConcernExtractor + AdviceGenerator
# -----------------------------------------------------------------------------
#
# ``auto`` (the default since the v0.1 release) probes the environment for
# the first available real provider, in this order:
#
# 1. BAI_API_KEY → b.ai (https://api.b.ai/v1)
# 2. OPENAI_API_KEY → openai
# 3. ANTHROPIC_API_KEY → anthropic
# 4. AZURE_OPENAI_API_KEY + AZURE_OPENAI_DEPLOYMENT → azure
#
# If none of those env vars are present the daemon falls back to a stub LLM
# and logs a WARNING — every LLM-driven path (concern extract, advice
# generation) then returns empty results. The CLI banner shows ``llm:
# stub-fallback (degraded — …)`` so you can't miss it.
#
# Operators who want the daemon to *refuse* to start without credentials
# should pin the provider explicitly here (``provider: openai`` etc.); the
# fallback only fires for ``provider: auto``.
llm:
provider: auto
# Per-request timeout for every provider call (extraction, advice,
# verification). Raise for slow corporate proxies / Azure deployments.
timeout_seconds: 30
# ---- Per-provider knobs (only the matched provider's keys are read) ----
#
# Any of these can also be sourced from the environment — see the
# comments next to each.
# B.AI (OpenAI-compatible — see docs/config/bai-llm.md) ---------------
# model: gpt-5.2 # or BAI_MODEL
# api_key: null # prefer BAI_API_KEY in env
# base_url: null # BAI_BASE_URL — default https://api.b.ai/v1
# OpenAI ---------------------------------------------------------------
# model: gpt-4o-mini # or OPENAI_MODEL
# api_key: null # prefer OPENAI_API_KEY in env
# base_url: null # OPENAI_BASE_URL — for vLLM /
# # OpenRouter / TogetherAI / etc.
# Anthropic ------------------------------------------------------------
# model: claude-3-5-haiku-latest # or ANTHROPIC_MODEL
# api_key: null # prefer ANTHROPIC_API_KEY
# base_url: null # ANTHROPIC_BASE_URL
# Azure OpenAI ---------------------------------------------------------
# deployment: null # or AZURE_OPENAI_DEPLOYMENT
# endpoint: null # or AZURE_OPENAI_ENDPOINT
# api_key: null # or AZURE_OPENAI_API_KEY
# api_version: "2024-10-21" # or AZURE_OPENAI_API_VERSION /
# # OPENAI_API_VERSION
# -----------------------------------------------------------------------------
# 4. IPC — how hosts talk to the daemon
# -----------------------------------------------------------------------------
ipc:
inproc:
enabled: true
unix_socket:
enabled: false
path: /run/opencoat.sock
# HTTP JSON-RPC is the default transport for everything the host SDK
# and CLI talk to. Disable explicitly only for pure-embedded use
# (see ADR 0005).
http:
enabled: true
host: 127.0.0.1 # use 0.0.0.0 only with auth in front (reverse proxy)
port: 7878
path: /rpc
grpc:
enabled: false
# -----------------------------------------------------------------------------
# 5. Observability
# -----------------------------------------------------------------------------
observability:
log_level: INFO
# OpenTelemetry OTLP endpoint — wires runtime spans/metrics into your
# collector. Leave null to keep logging local.
otel_endpoint: null
# -----------------------------------------------------------------------------
# 6. Plugins — out-of-tree hosts / matchers / advisors
# -----------------------------------------------------------------------------
plugins:
hosts: [] # e.g. ["openclaw", "langgraph"]
matchers: []
advisors: []