mirror of
https://github.com/harivansh-afk/clanker-agent.git
synced 2026-04-21 04:00:10 +00:00
chore: rebrand companion-os to clanker-agent
- Rename all package names from companion-* to clanker-* - Update npm scopes from @mariozechner to @harivansh-afk - Rename config directories .companion -> .clanker - Rename environment variables COMPANION_* -> CLANKER_* - Update all documentation, README files, and install scripts - Rename package directories (companion-channels, companion-grind, companion-teams) - Update GitHub URLs to harivansh-afk/clanker-agent - Preserve full git history from companion-cloud monorepo
This commit is contained in:
parent
f93fe7d1a0
commit
67168d8289
356 changed files with 2249 additions and 10223 deletions
70
packages/coding-agent/clanker-out/docs/prompt-templates.md
Normal file
70
packages/coding-agent/clanker-out/docs/prompt-templates.md
Normal file
|
|
@ -0,0 +1,70 @@
|
|||
> clanker can create prompt templates. Ask it to build one for your workflow.
|
||||
|
||||
# Prompt Templates
|
||||
|
||||
Prompt templates are Markdown snippets that expand into full prompts. Type `/name` in the editor to invoke a template, where `name` is the filename without `.md`.
|
||||
|
||||
## Locations
|
||||
|
||||
Clanker loads prompt templates from:
|
||||
|
||||
- Global: `~/.clanker/agent/prompts/*.md`
|
||||
- Project: `.clanker/prompts/*.md`
|
||||
- Packages: `prompts/` directories or `clanker.prompts` entries in `package.json`
|
||||
- Settings: `prompts` array with files or directories
|
||||
- CLI: `--prompt-template <path>` (repeatable)
|
||||
|
||||
Disable discovery with `--no-prompt-templates`.
|
||||
|
||||
## Format
|
||||
|
||||
```markdown
|
||||
---
|
||||
description: Review staged git changes
|
||||
---
|
||||
|
||||
Review the staged changes (`git diff --cached`). Focus on:
|
||||
|
||||
- Bugs and logic errors
|
||||
- Security issues
|
||||
- Error handling gaps
|
||||
```
|
||||
|
||||
- The filename becomes the command name. `review.md` becomes `/review`.
|
||||
- `description` is optional. If missing, the first non-empty line is used.
|
||||
|
||||
## Usage
|
||||
|
||||
Type `/` followed by the template name in the editor. Autocomplete shows available templates with descriptions.
|
||||
|
||||
```
|
||||
/review # Expands review.md
|
||||
/component Button # Expands with argument
|
||||
/component Button "click handler" # Multiple arguments
|
||||
```
|
||||
|
||||
## Arguments
|
||||
|
||||
Templates support positional arguments and simple slicing:
|
||||
|
||||
- `$1`, `$2`, ... positional args
|
||||
- `$@` or `$ARGUMENTS` for all args joined
|
||||
- `${@:N}` for args from the Nth position (1-indexed)
|
||||
- `${@:N:L}` for `L` args starting at N
|
||||
|
||||
Example:
|
||||
|
||||
```markdown
|
||||
---
|
||||
description: Create a component
|
||||
---
|
||||
|
||||
Create a React component named $1 with features: $@
|
||||
```
|
||||
|
||||
Usage: `/component Button "onClick handler" "disabled support"`
|
||||
|
||||
## Loading Rules
|
||||
|
||||
- Template discovery in `prompts/` is non-recursive.
|
||||
- If you want templates in subdirectories, add them explicitly via `prompts` settings or a package manifest.
|
||||
Loading…
Add table
Add a link
Reference in a new issue