adhoc

Run a single AI prompt against an sgai workspace via opencode run.

130|8|Updated Jan 23, 2026
One-click install
npx skills add https://github.com/sandgardenhq/sgai --skill adhoc
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: adhoc
Source: https://github.com/sandgardenhq/sgai/tree/main/docs/sgai-skills/adhoc
Command: npx skills add https://github.com/sandgardenhq/sgai --skill adhoc

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Ad‑hoc prompts let you execute a single AI request against a workspace without launching a full multi‑agent session, eliminating the overhead and waiting time for quick tasks like code reviews, documentation, or diagnostics.

Core Features & Use Cases

  • Instant Prompt Execution: Start, monitor, and stop one‑off AI prompts via simple API calls.
  • Status Monitoring: Retrieve real‑time output and completion status for running prompts.
  • Versatile Models: Supports any model compatible with sgai’s GOAL.md format.
  • Use Cases: Quick code review, generate README, fix failing test, or extract TODO comments.

Quick Start

Ask sgai to run an ad‑hoc prompt that reviews the authentication code for security issues.

Frequently Asked Questions about adhoc

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I run a quick code review without launching a full AI agent session?

Generating a README from existing code is done by executing an ad-hoc prompt against your workspace. It processes the workspace files through a specified model to instantly produce documentation output without needing a full agentic session.

What do I need to set up before running ad-hoc AI prompts in my workspace?

Running ad-hoc AI prompts requires a running sgai server and the opencode tool installed in your environment. This setup allows the system to invoke opencode run with your specified model to execute the quick task.

Does this approach support any AI model for rapid debugging tasks?

Rapid debugging supports any AI model compatible with sgai's GOAL.md format. You simply specify your desired model when invoking the prompt, and the system processes the debugging request using that model.

What is the best way to monitor a one-off AI prompt execution?

The best way to monitor a one-off AI prompt execution is by retrieving real-time output and completion status via API calls. This allows you to track the progress of your ad-hoc prompt until the task finishes.