Skip to content
Back to skills

Skill Context

ASecurity

This repo adds a third artifact type to `/new-skill`'s generic skill+agent creation: a **project Python tool** registered as a `valor-*` CLI entry point. The conventions below are this repo's; the global skill body covers skill and agent creation generically.

  • 26 stars
  • 0 votes
  • 0 copies
  • 3 views
  • Added September 2, 2026
ai-agentspythongobashapidatabasedocumentation

Works with

  • cli
  • api

Security analysis

A92/100
  • mediumInstalls packages at runtime which could introduce malicious dependencies

Pro scans all 21 files and shows the line behind each finding

Scanned September 2, 2026

npx -y skills add tomcounsell/ai --skill skill-context --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Skill Context?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Skill Context
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/tomcounsell-skill-context/badge)](https://www.skillsdirectory.com/skills/tomcounsell-skill-context)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
# new-skill context — this repo (ai)

This repo adds a third artifact type to `/new-skill`'s generic skill+agent creation: a **project
Python tool** registered as a `valor-*` CLI entry point. The conventions below are this repo's;
the global skill body covers skill and agent creation generically.

## Creating a project Python tool (Valor tools/)

Python tools live in `tools/<tool_name>/` and are registered as CLI entry points.

### Structure

```
tools/<tool_name>/
├── __init__.py       # Main implementation (REQUIRED)
├── README.md         # Documentation (REQUIRED)
├── manifest.json     # Tool metadata (recommended)
└── tests/
    ├── __init__.py
    └── test_<tool>.py
```

### `__init__.py` pattern

```python
"""
Tool Name - Brief description.

Usage:
    from tools.tool_name import main_function
    result = main_function(arg1, arg2)

CLI:
    valor-tool-name arg1 arg2
"""

import argparse
import sys


def main_function(arg1: str, arg2: str | None = None) -> dict:
    """Main tool function. Returns dict with 'result' or 'error' key."""
    try:
        result = do_work(arg1, arg2)
        return {"result": result}
    except Exception as e:
        return {"error": str(e)}


def main():
    """CLI entry point."""
    parser = argparse.ArgumentParser(description="Tool description")
    parser.add_argument("arg1", help="First argument")
    parser.add_argument("arg2", nargs="?", help="Optional second argument")
    args = parser.parse_args()

    result = main_function(args.arg1, args.arg2)
    if "error" in result:
        print(f"Error: {result['error']}", file=sys.stderr)
        sys.exit(1)
    print(result["result"])


if __name__ == "__main__":
    main()
```

### Register CLI

Add to `[project.scripts]` in `pyproject.toml`:

```toml
valor-tool-name = "tools.tool_name:main"
```

Then run: `uv pip install -e .`

### Bridge integration

- Files are auto-detected by `extract_files_from_response()` in the bridge.
- For explicit file sending, use: `<<FILE:/path/to/file>>`.
- For AI models, import from `config/models.py`: `MODEL_FAST`, `MODEL_REASONING`, `MODEL_IMAGE_GEN`, `MODEL_VISION`.

### Document in the command reference

Add a section to `docs/tools-reference.md` (the full command catalog). That file
documents each CLI as an H3 naming the tool and its module, followed by a short
description and a fenced bash block of example invocations:

````markdown
### Tool Name (`tools.tool_name`)

One or two sentences on what it does and when to reach for it.

```bash
valor-tool-name arg1              # what this invocation does
valor-tool-name arg1 --flag       # what the flag changes
```
````

### Checklist

- [ ] `tools/<name>/` created with `__init__.py` and `README.md`
- [ ] Main function returns `{"result": ...}` or `{"error": ...}`
- [ ] CLI entry point added to `pyproject.toml`, ran `uv pip install -e .`
- [ ] `docs/tools-reference.md` updated with the new tool's section
- [ ] Tests written and passing
- [ ] `black` and `ruff` pass
- [ ] Committed and pushed

### Reference implementations

| Tool | Pattern |
|------|---------|
| `tools/image_gen/` | API + file output |
| `tools/image_analysis/` | Vision + multi-mode |
| `tools/sms_reader/` | System access, CLI subcommands |
| `tools/telegram_history/` | Database query |

## Global vs project-only skill scope (this repo)

This repo is the canonical source for skills that ship to every machine. A new skill goes in one
of two places:

- `.claude/skills-global/<name>/` — a **global** skill, hardlinked into `~/.claude/skills/` on
  every machine by `scripts/update/hardlinks.py::sync_claude_dirs`. Write its body as a generic,
  repo-agnostic baseline and put any repo-specifics in `.claude/skill-context/<name>.md`.
- `.claude/skills/<name>/` — a **project-only** skill that is tightly coupled to this repo's
  infra and is never synced.

Adding a directory with a `SKILL.md` under `skills-global/` is all that's required to sync it —
no registration step. When moving a skill between the two dirs, add a `RENAMED_REMOVALS` entry in
`hardlinks.py` so the stale user-level hardlink is cleaned up on every machine.

## Anthropic reference docs (installed on every machine)

The `audit-skills` skill bundles current Anthropic specs that ship with it via the same sync:

- `~/.claude/skills/audit-skills/references/anthropic-skills-docs.txt` — field specs + substitution variables
- `~/.claude/skills/audit-skills/references/anthropic-skill-creator.md` — a canonical skill example

Files in this skill

  • README.md4.3 KB
  • audit-hooks.md2.8 KB
  • audit-models.md1.1 KB
  • audit-tools.md1 KB
  • computer-use.md6.6 KB
  • cowork.md4.7 KB
  • do-debrief.md2.6 KB
  • do-design-audit.md921 B
  • do-design-system.md3.7 KB
  • do-discover-paths.md1.8 KB
  • do-docs.md10.7 KB
  • do-issue.md1.6 KB
  • do-presentation.md4.2 KB
  • do-voice-recording.md2.8 KB
  • email.md1.7 KB
  • google-workspace.md1.2 KB
  • new-skill.md4.4 KB
  • present.md2.3 KB
  • reclassify.md996 B
  • zoom-out.md1 KB

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.