Files
lora/training/14_tools_pty.json
T
marauder-actual 0e88c3c2ae add v5 substrate training data (40 examples)
Manual hand-crafted examples for generic substrate LoRA:
- 01: identity/self-model
- 02-18: tool categories (159 tools grouped by function)
- 19-26: tricky tool disambiguation
- 27-32: framing (substrate vs persona, HMT, psychoacoustic trust)
- 33-40: EEMS deep-dive (architecture, recall, store, graph, legacy)

Pretty-printed JSON, compiled to JSONL via build pipeline.
System prompt uses generic assistant, not BT persona.
2026-05-31 14:32:19 +02:00

17 lines
1.9 KiB
JSON

{
"messages": [
{
"role": "system",
"content": "You are a helpful AI assistant with access to tools. Use tools when they help answer the user's question. Be concise and accurate."
},
{
"role": "user",
"content": "What are PTY sessions and when do I use them?"
},
{
"role": "assistant",
"content": "<think>\nPTY tools — persistent background terminal sessions. Unlike bash which is synchronous, PTY sessions persist and support interactive I/O.\n</think>\n\nPTY sessions are persistent interactive pseudo-terminals that run in the background. Unlike the `bash` tool which runs a command synchronously and waits for it to finish, PTY sessions persist and let you interact over time. Five tools:\n\n- **pty_spawn** — start a new PTY session with a command and args. Set working directory, env vars, title. Optional timeout to auto-kill. Optional `notifyOnExit` to get a notification when the process exits.\n- **pty_write** — send input to a running PTY. Text, commands, or escape sequences (Enter: `\\n`, Ctrl+C: `\\x03`, Ctrl+D: `\\x04`, arrow keys).\n- **pty_read** — read output from a PTY's buffer. Supports offset/limit pagination and regex pattern filtering. Lines are numbered for reference.\n- **pty_list** — list all PTY sessions (active and exited) with status, PID, and line counts.\n- **pty_kill** — terminate a PTY session. Optional cleanup to free the buffer.\n\nUse PTY when you need:\n- **Long-running processes** — dev servers, watch modes, builds that take minutes\n- **Interactive programs** — REPLs, prompts that need input, TUI applications\n- **Multiple concurrent terminals** — run tests in one PTY while a dev server runs in another\n- **Exit notifications** — spawn with `notifyOnExit=true` and wait for the `<pty_exited>` message instead of polling\n\nUse `bash` for quick one-off commands that finish in seconds (git status, ls, npm install)."
}
]
}