Skip to content

Guide · Agent skill

How to use the Inspect Workspace Tool Policies agent skill

Updated · written with AI from the project's own documentation and checked against our catalogue data

The policy skill teaches an AI agent how its safety guard works in a workspace. It lets the agent read the per-workspace overlay file .lha/policies.jsonl, explain which destructive or sensitive tool calls are blocked, and show you the exact line to add or remove if you want a rule changed. This guide covers what the skill does, how to install it, how to trigger it, and its limits.

Inspect Workspace Tool Policiesgoogle/adk-recipes · Apache-2.0

Quick start

  1. 1Install the skill. Unzip the downloaded ZIP into ~/.claude/skills/ or a project's .claude/skills/ folder, or upload it under Settings → Capabilities → Skills in the Claude apps.
  2. 2Confirm the runtime. Make sure you run the long-horizon-harness agent runtime (horizon package) with its policies_guard callback, since the skill depends on it.
  3. 3Ask what is in force. Ask the agent which policies apply in your workspace. It will read .lha/policies.jsonl if the file exists.
  4. 4Ask about a blocked call. Describe the blocked command. The agent will explain the rule or seed coverage behind it.
  5. 5Request a rule change. Ask the agent to add or remove a rule. It will give you the exact JSON line or line number.
  6. 6Make the edit yourself. Open .lha/policies.jsonl, add or delete the line, and save. Create the file if it does not exist yet.
  7. 7Retry the command. Run the same command again to confirm the new rule takes effect on the next tool call.

What an agent skill is and what this one does

An agent skill is a folder with a SKILL.md file that gives an AI agent extra instructions for a specific task. This skill is about the guardrail system of the long-horizon harness: the policies_guard callback checks a JSONL policy file on every tool call.

The skill does not add a new capability such as document editing. It makes the agent able to inspect the policy layers and explain them. The agent can read the workspace overlay, but it is told not to write it. You make any change yourself.

  • Reads the overlay at .lha/policies.jsonl under the workspace root.
  • Explains the default seed coverage, which is summarized in the skill rather than read from disk.
  • Explains why a blocked call was blocked.
  • Gives you the exact JSON line to add, or the line number to delete.

Install the policy skill

Download the ZIP from the skill's page and unzip it. To make it available to every project on your machine, place the policy folder in ~/.claude/skills/. To limit it to one project, place it in that project's .claude/skills/ folder.

In the Claude apps you can instead upload the ZIP under Settings → Capabilities → Skills.

  • Personal: ~/.claude/skills/policy
  • Project only: <your-project>/.claude/skills/policy
  • Claude apps: Settings → Capabilities → Skills, then upload the ZIP

Check the requirements before you rely on it

The skill is written for the long-horizon-harness agent runtime (the horizon package) and its policies_guard callback. Without that runtime, the policy file and callbacks will not exist, so the skill has nothing to inspect.

The workspace overlay file is optional. If .lha/policies.jsonl is missing, only the default seed applies, and the agent will say so.

  • Requires the long-horizon-harness runtime (horizon package) with policies_guard.
  • Requires a workspace with .lha/policies.jsonl only if you want overlay rules; otherwise only the seed is active.
  • Runs scripts: no. Uses network: no.

Trigger the skill with natural requests

You do not need a special command. Ask in plain language about the policies in force, or ask to block or unblock something. The agent will read the overlay file first and then respond with the relevant lines.

If a call was just blocked and you want a one-time approval, the source says to type /grant <command> yourself. The agent cannot invoke that slash command.

  • "What policies are currently in force in this workspace?"
  • "Block npm publish from the terminal."
  • "Remove the overlay rule that blocks rm -rf node_modules."
  • "Why was this command blocked?"

Add or remove a rule

To add a rule, the agent reads the current overlay so the suggestion appends correctly, then gives you one JSON line. Add it to .lha/policies.jsonl yourself and create the file if it does not exist. Each rule is one JSON object per line, and every rule must include canonical_tool_name.

To remove a rule, the agent identifies the line by its 0-based index among rules (ignoring blank and comment lines) and tells you which line to delete. Confirm the target before deleting, because overlay rules usually exist to plug a gap.

  • Blank lines and # comments are skipped by the parser.
  • Fields such as destructive, destructive_commands, destructive_commands_regex, destructive_paths and destructive_path_patterns can be combined on one rule.
  • Malformed lines are skipped with a warning, so double-check your edit.
{"canonical_tool_name": "bash", "destructive_commands": {"command": ["npm publish"]}}

Safety notes: scripts, network and what the agent cannot change

The skill itself runs no scripts and makes no network calls. Its main safety property is that the agent cannot loosen its own guardrails. The overlay file and the .lha/ folder are hard-denied for write and edit, and writes into .lha/ through bash are also blocked.

The default seed is read-only and lives outside the workspace, so the agent can summarize it but cannot read the exact contents. If you need a full audit of the seed, read it directly from the runtime instead of asking the skill.

  • The agent cannot write .lha/policies.jsonl; you make edits.
  • Overlay rules add restrictions on top of the seed; they do not remove seed blocks.
  • Edits take effect on the next tool call because the overlay is mtime-cached.

Tips for getting useful answers

Ask about a specific blocked command rather than the whole policy set when you are debugging. Mention the workspace root so the agent reads the correct .lha/policies.jsonl. After you edit the file, retry the same command to confirm the change.

Approval modes are also worth knowing. The /yolo command toggles between default and yolo modes, and yolo auto-approves only the demotable ask verdicts. It does not bypass the exfil guard or the hard-deny rules. The mode is per-session and is not saved.

  • Name the exact command or path pattern you want to block or allow.
  • Keep one rule per line and avoid trailing commas.
  • Remember that permission rules for ask_user or deny live in .lha/permissions.jsonl, not in the policy overlay.

What people use it for

  • Finding out why an agent's rm -rf or git push --force call was stopped and what rule caused it.
  • Blocking a project-specific command such as npm publish from the agent's terminal.
  • Removing an overlay rule that no longer makes sense after a project change.
  • Reviewing which credential-read and catastrophic-command blocks apply to a workspace before running a long task.

Frequently asked questions

Is the policy agent skill free to use?

This page does not state a price or licence terms beyond the listed licence, which is Apache-2.0. Check the licence in the source repository for the full terms. The skill itself runs no scripts and makes no network calls.

What do I need to run the policy skill?

You need the long-horizon-harness agent runtime (the horizon package) with its policies_guard callback. A workspace containing .lha/policies.jsonl is optional; without it only the default seed applies.

How do I install the policy skill?

Download the ZIP from the skill page and unzip it into ~/.claude/skills/ for personal use or into a project's .claude/skills/ folder. In the Claude apps you can upload the ZIP under Settings → Capabilities → Skills.

Why can't the agent add a rule for me?

The agent is designed not to edit its own guard configuration. The .lha/ folder is hard-denied for write and edit, and bash writes into it are blocked too. The agent gives you the exact line to add yourself.

Can the skill make the agent safer or looser on its own?

No. The skill explicitly forbids the agent from changing safety rules, so it cannot loosen its own guardrails. Overlay rules only add restrictions on top of the default seed.

Is this skill a good alternative to editing permissions for my project?

It is a different tool. Policy overlay rules are hard blocks. To force a prompt or block a command through the permission layer, add ask_user or deny rules to .lha/permissions.jsonl, as the source describes.

New agent skills, repos and AI tools — every week

The best new skills and open-source projects, the fastest-growing repos, and one free prompt. Five minutes to read. Unsubscribe anytime.

Our verdict

Use this skill if you run the long-horizon harness and want to understand or adjust which commands are blocked in a workspace. It is not useful for general Claude users, since the policy file and callbacks will not exist there, and it will not change safety rules for you. For a full audit of the default seed, read the runtime directly because the skill only summarizes it.

Download the skill