Skip to content

Commit c13c565

Browse files
autogame-17WeZZardGolden-Koi
committed
feat: merge community PRs #164 and #167
PR #164 (WeZZard): document A2A_NODE_ID setup in SKILL.md, warn when unset PR #167 (Golden-Koi): cron keepalive best practice in README.md Co-authored-by: WeZZard <wezzard@users.noreply.github.com> Co-authored-by: Golden-Koi <263994476+Golden-Koi@users.noreply.github.com>
1 parent 2378340 commit c13c565

3 files changed

Lines changed: 36 additions & 0 deletions

File tree

README.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -129,6 +129,17 @@ node src/ops/lifecycle.js status # show running state
129129
node src/ops/lifecycle.js check # health check + auto-restart if stagnant
130130
```
131131

132+
### Cron / external runner keepalive
133+
If you run a periodic keepalive/tick from a cron/agent runner, prefer a single simple command with minimal quoting.
134+
135+
Recommended:
136+
137+
```bash
138+
bash -lc 'node index.js --loop'
139+
```
140+
141+
Avoid composing multiple shell segments inside the cron payload (for example `...; echo EXIT:$?`) because nested quotes can break after passing through multiple serialization/escaping layers.
142+
132143
## Public Release
133144

134145
This repository is the public distribution.

SKILL.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,10 +37,31 @@ To run in an infinite loop (e.g., via cron or background process), use the `--lo
3737
node index.js --loop
3838
```
3939

40+
## Setup
41+
42+
Before using this skill, register your node identity with the EvoMap network:
43+
44+
1. Run the hello flow (via `evomap.js` or the EvoMap onboarding) to receive a `node_id` and claim code
45+
2. Visit `https://evomap.ai/claim/<claim-code>` within 24 hours to bind the node to your account
46+
3. Set the node identity in your environment:
47+
48+
```bash
49+
export A2A_NODE_ID=node_xxxxxxxxxxxx
50+
```
51+
52+
Or in your agent config (e.g., `~/.openclaw/openclaw.json`):
53+
54+
```json
55+
{ "env": { "A2A_NODE_ID": "node_xxxxxxxxxxxx" } }
56+
```
57+
58+
Do not hardcode the node ID in scripts. `getNodeId()` in `src/gep/a2aProtocol.js` reads `A2A_NODE_ID` automatically -- any script using the protocol layer will pick it up without extra configuration.
59+
4060
## Configuration
4161

4262
| Environment Variable | Default | Description |
4363
|---|---|---|
64+
| `A2A_NODE_ID` | (required) | Your EvoMap node identity. Set this after node registration -- never hardcode it in scripts. Read automatically by `getNodeId()` in `a2aProtocol.js`. |
4465
| `EVOLVE_ALLOW_SELF_MODIFY` | `false` | Allow evolution to modify evolver's own source code. **NOT recommended for production.** Enabling this can cause instability -- the evolver may introduce bugs into its own prompt generation, validation, or solidify logic, leading to cascading failures that require manual intervention. Only enable for controlled experiments. |
4566
| `EVOLVE_LOAD_MAX` | `2.0` | Maximum 1-minute load average before evolver backs off. |
4667
| `EVOLVE_STRATEGY` | `balanced` | Evolution strategy: `balanced`, `innovate`, `harden`, `repair-only`, `early-stabilize`, `steady-state`, or `auto`. |

src/gep/a2aProtocol.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,10 @@ function getNodeId() {
8383
return _cachedNodeId;
8484
}
8585

86+
console.warn('[a2aProtocol] A2A_NODE_ID is not set. Computing node ID from device fingerprint. ' +
87+
'This ID may change across machines or environments. ' +
88+
'Set A2A_NODE_ID after registering at https://evomap.ai to use a stable identity.');
89+
8690
const deviceId = getDeviceId();
8791
const agentName = process.env.AGENT_NAME || 'default';
8892
const raw = deviceId + '|' + agentName + '|' + process.cwd();

0 commit comments

Comments
 (0)