feat(agent): expand ops/developer/bridge tools and harden xAI compatibility

Add second-wave agent capabilities for initd/journal/network/IPC diagnostics, allowlisted maintenance + contract-check automation, and policy-gated HRPC bridge actions with emergency-stop controls. Harden xAI provider support by applying provider-aware request defaults, parsing reasoning-summary/tool-call streaming variants, and updating seeded docs/skills/tests to reflect max-autonomy safeguards and trace-first observability.
This commit is contained in:
Raven Scott
2026-04-26 04:57:00 -04:00
parent 55bc3c3c09
commit f5e9473f7b
27 changed files with 2148 additions and 41084 deletions
@@ -0,0 +1,37 @@
---
name: xai-compat
version: 1.0.0
description: Keep agent requests and tool loops compatible with xAI chat/responses semantics, reasoning summaries, and streaming behavior.
tags: [xai, compatibility, streaming, tools, reasoning]
requires: [edit_agent_config, run_command]
---
# xai-compat
Use this skill when provider is `xai` or when debugging xAI tool/reasoning behavior.
## Baseline configuration
1. Ensure:
- `provider = "xai"`
- `rest_base_url = "https://api.x.ai/v1"`
2. Prefer `reasoning_mode = "trace"` for observability when summaries are sparse.
3. Keep `stream = true` for tool-call visibility and progressive diagnostics.
## Tool calling expectations
- xAI supports OpenAI-compatible function tools on chat completions.
- `parallel_tool_calls` can be enabled; process all returned tool calls before continuing.
- Keep tool schemas explicit and bounded.
## Reasoning expectations
- Reasoning models may expose `reasoning_content` summaries, but availability can vary by model/endpoint.
- In trace mode, rely on local process lines even when no reasoning summary deltas arrive.
## Debug checklist
1. Verify provider/base URL in `~/.agent/config.json`.
2. Run with `reasoning_mode=trace`.
3. Check for tool-call chunks and usage tokens in stream output.
4. If reasoning deltas are absent, treat this as provider/model behavior and continue with trace-level progress lines.