Files
didactyl/genesis.jsonc.example
T

130 lines
6.1 KiB
Plaintext

{
// SAFE EXAMPLE ONLY
// Do not commit real secrets (nsec, API keys, private relays, or private admin data).
// ─── Agent Identity Key ─────────────────────────────────────────────
// Use your real Nostr nsec locally in genesis.jsonc (gitignored).
"key": {
"nsec": "nsec1REPLACE_WITH_YOUR_AGENT_NSEC"
},
// ─── Administrator ──────────────────────────────────────────────────
// Admin pubkey may be npub or hex.
"admin": {
"pubkey": "npub1REPLACE_WITH_ADMIN_PUBKEY"
},
// ─── Signer Provider (optional) ────────────────────────────────────
// Omit this block (or set mode="local") to use the nsec above in-process.
// In any nsigner_* mode the nsec is optional/ignored; the agent pubkey is
// learned from the signer via nostr_signer_get_public_key(). See docs/SIGNER.md.
//
// "signer": {
// "mode": "nsigner_unix", // local | nsigner_unix | nsigner_tcp | nsigner_serial | nsigner_fds | nsigner_qrexec
// "socket_name": "", // nsigner_unix: abstract socket name (without @); "" = auto-discover
// "role": "main", // n_signer role selector (required for all nsigner_* modes)
// "role_path": "m/44'/1237'/0'/0/0", // full BIP-44 derivation path (required for all nsigner_* modes)
// "timeout_ms": 15000, // per-call timeout
// "auth_privkey_hex": "", // nsigner_tcp only: kind-27235 auth envelope privkey
// "tcp_host": "127.0.0.1", // nsigner_tcp host
// "tcp_port": 11111, // nsigner_tcp port
// "serial_device": "/dev/ttyACM0", // nsigner_serial device path
// "target_qube": "nostr_signer", // nsigner_qrexec: target Qubes qube name
// "service_name": "qubes.NsignerRpc" // nsigner_qrexec: qrexec service name (default qubes.NsignerRpc)
// // nsigner_fds: fds_read_fd/fds_write_fd are CLI-only (--signer-fds), NOT persisted here
// // derive_index: CLI-only (--signer-derive-index), NOT persisted here
// },
// ─── Encrypted Startup Config Events ───────────────────────────────
// These are published as NIP-44 encrypted kind 30078 self-events on first run.
"encrypted_events": [
{
"kind": 30078,
"d_tag": "user-settings",
"content": "{\"v\":2,\"updatedAt\":0,\"global_llm\":{\"provider\":\"openai\",\"api_key\":\"sk-REPLACE_WITH_API_KEY\",\"model\":\"gpt-4o-mini\",\"base_url\":\"https://api.openai.com/v1\",\"max_tokens\":512,\"temperature\":0.7},\"didactyl\":{\"admin_pubkey\":\"npub1REPLACE_WITH_ADMIN_PUBKEY\",\"dm_protocol\":\"both\",\"max_turns\":40}}"
// Other supported providers (use instead of openai block above):
// ppq.ai: "provider":"ppq", "base_url":"https://api.ppq.ai/v1"
// routstr: "provider":"routstr", "base_url":"https://api.routstr.com/v1"
}
],
// ─── HTTP Admin API ────────────────────────────────────────────────
"api": {
"enabled": true,
"port": 8484,
"bind_address": "127.0.0.1"
},
// ─── Startup Events ────────────────────────────────────────────────
// The wizard generates these automatically. The examples below show the
// structure; the actual content (name, relays, skills) is built interactively.
"startup_events": [
{
"kind": 0,
"content_fields": {
"name": "Didactyl",
"display_name": "Didactyl",
"about": "I am a Didactyl agent living on Nostr"
},
"tags": []
},
{
"kind": 3,
"content": "",
"tags": [
["p", "ADMIN_HEX_PUBKEY"]
]
},
{
"kind": 10002,
"content": "",
"tags": [
["r", "ws://localhost:7777"],
["r", "wss://laantungir.net/relay"],
["r", "ws://npub1crpldvy49ef8z34wlacwujnfudy4nd7k96aqdx5wgn6ckztz7z8q9t59ud.fips/relay/"],
["r", "wss://relay.damus.io"],
["r", "wss://nos.lol"],
["r", "wss://relay.primal.net"],
["r", "wss://relay.zapstore.dev"]
]
},
{
"kind": 10050,
"content": "",
"tags": [
["relay", "ws://localhost:7777"],
["relay", "wss://laantungir.net/relay"],
["relay", "ws://npub1crpldvy49ef8z34wlacwujnfudy4nd7k96aqdx5wgn6ckztz7z8q9t59ud.fips/relay/"],
["relay", "wss://relay.damus.io"],
["relay", "wss://nos.lol"],
["relay", "wss://relay.primal.net"],
["relay", "wss://relay.zapstore.dev"]
]
},
{
"kind": 31124,
"content": "# AGENT_NAME\n\nYou are {{my_kind0_profile}}\n\nYour npub: {{my_npub}}\n\nAdmin npub: ADMIN_NPUB\n\n## Rules\n\n- Communicate through encrypted Nostr direct messages\n- Keep responses concise and clear\n- Be helpful and technically accurate\n- If unsure, state uncertainty directly\n- Use tools when a request requires taking action\n- After a tool call, base your answer on the actual tool result\n- Never claim a tool was run if no tool was executed\n- Maintain your task list as short-term working memory\n- Never reveal your private key (nsec)\n- You may share your public key (npub) with anyone",
"tags": [
["d", "identity_and_rules"],
["app", "didactyl"],
["scope", "private"],
["description", "Agent identity and behavioral rules"],
["trigger", "dm"],
["filter", "{\"from\":\"admin\"}"]
]
},
{
"kind": 31124,
"content": "## Recent Conversation\n\n{{nostr_dm_history({\"format\":\"text\",\"limit\":12})}}",
"tags": [
["d", "dm_history"],
["app", "didactyl"],
["scope", "private"],
["description", "DM conversation history for context continuity"],
["trigger", "dm"],
["filter", "{\"from\":\"admin\"}"]
]
}
]
}