You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/channels.md
+10Lines changed: 10 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -103,6 +103,16 @@ When the Slack adapter receives a message:
103
103
104
104
This gives users visual feedback that their message is being processed, especially for long-running research queries.
105
105
106
+
### Telegram Processing Indicators
107
+
108
+
The Telegram adapter mirrors Slack's processing feedback:
109
+
110
+
1. A typing indicator ("typing...") is sent immediately and refreshed every 4 seconds
111
+
2. If the handler takes longer than 15 seconds, an interim message is posted: _"Working on it — I'll send the result when ready."_
112
+
3. The typing indicator stops when the response is ready
113
+
114
+
**Context isolation:** Each handler goroutine runs with an independent context (10-minute timeout), detached from the polling loop. This prevents in-flight tasks from being cancelled if the polling context is interrupted during server restarts or errors.
|`no_secrets`| Outbound | Detects API keys, tokens, and private keys (OpenAI, Anthropic, AWS, GitHub, Slack, Telegram, etc.) |
15
15
16
16
## Modes
17
17
18
18
| Mode | Behavior |
19
19
|------|----------|
20
-
|`enforce`| Blocks violating messages, returns error to caller|
20
+
|`enforce`| Blocks violating inbound messages; **redacts** outbound messages (see below)|
21
21
|`warn`| Logs violation, allows message to pass |
22
22
23
+
### Outbound Redaction
24
+
25
+
Outbound messages (from the agent to the user) are always **redacted** rather than blocked, even in `enforce` mode. Blocking would discard a potentially useful agent response (e.g., code analysis) over a false positive from broad PII/secret patterns matching source code. Matched content is replaced with `[REDACTED]` and a warning is logged.
26
+
27
+
### PII Validators
28
+
29
+
To reduce false positives, PII patterns use structural validators beyond simple regex:
30
+
31
+
| Pattern | Validator | What it checks |
32
+
|---------|-----------|---------------|
33
+
| SSN |`validateSSN`| Rejects area=000/666/900+, group=00, serial=0000, all-same digits, known test SSNs |
The `github` skill provides a complete git + GitHub workflow through script-backed tools:
363
+
364
+
```bash
365
+
forge skills add github
366
+
```
367
+
368
+
This registers eight tools:
369
+
370
+
| Tool | Purpose |
371
+
|------|---------|
372
+
|`github_clone`| Clone a repository and create a feature branch |
373
+
|`github_checkout`| Switch to or create a branch |
374
+
|`github_status`| Show git status for a cloned project |
375
+
|`github_commit`| Stage and commit changes |
376
+
|`github_push`| Push a feature branch to the remote |
377
+
|`github_create_pr`| Create a pull request |
378
+
|`github_create_issue`| Create a GitHub issue |
379
+
|`github_list_issues`| List open issues for a repository |
380
+
381
+
**Workflow:** Clone → explore → edit → status → commit → push → create PR. The skill's system prompt enforces this sequence and prevents raw `git` commands via `cli_execute`.
The `code-agent` skill enables autonomous code generation and modification using [builtin code-agent tools](tools.md#code-agent-tools):
388
+
389
+
```bash
390
+
forge skills add code-agent
391
+
```
392
+
393
+
This registers eight tools:
394
+
395
+
| Tool | Purpose |
396
+
|------|---------|
397
+
|`code_agent_scaffold`| Bootstrap a new project (Vite, Express, FastAPI, Go, Spring Boot, etc.) |
398
+
|`code_agent_write`| Create or update files |
399
+
|`code_agent_edit`| Surgical text replacement in existing files |
400
+
|`code_agent_read`| Read a file or list directory contents |
401
+
|`code_agent_run`| Install dependencies, start a server, open a browser |
402
+
|`grep_search`| Search file contents by regex |
403
+
|`glob_search`| Find files by name pattern |
404
+
|`directory_tree`| Show project directory tree |
405
+
406
+
The skill uses **denied tools** (`bash_execute`, `file_write`, `file_edit`, `file_patch`, `file_read`, `schedule_*`) to ensure the LLM uses the skill's own tool wrappers instead of raw builtins. All file operations are confined to the agent's working directory via `PathValidator`.
Skills can declare domain-specific guardrails in their `SKILL.md` frontmatter to enforce security policies at runtime. These guardrails operate at four interception points in the agent loop, preventing unauthorized commands, data exfiltration, capability enumeration, and binary name disclosure.
Copy file name to clipboardExpand all lines: docs/tools.md
+45Lines changed: 45 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -36,6 +36,51 @@ Tools are capabilities that an LLM agent can invoke during execution. Forge prov
36
36
37
37
Register all builtins with `builtins.RegisterAll(registry)`.
38
38
39
+
## Code-Agent Tools
40
+
41
+
When the `code-agent` skill is active, Forge registers additional tools for autonomous code generation and modification. These tools are **not** registered by default — they are conditionally added when the skill requires them.
42
+
43
+
All code-agent tools use a `PathValidator` that confines resolved paths within the agent's working directory, preventing directory traversal attacks.
44
+
45
+
| Tool | Description |
46
+
|------|-------------|
47
+
|`bash_execute`| Execute bash commands with pipes, redirection, and shell features |
48
+
|`file_read`| Read file contents with optional line offset/limit, or list directory entries |
49
+
|`file_write`| Create or overwrite files in the project directory |
50
+
|`file_edit`| Edit files by exact string matching with unified diff output |
51
+
|`file_patch`| Batch file operations (add, update, delete, move) in a single call |
52
+
|`glob_search`| Find files by glob pattern (e.g., `**/*.go`), sorted by modification time |
53
+
|`grep_search`| Search file contents with regex; uses `rg` if available, falls back to Go |
54
+
|`directory_tree`| Display tree-formatted directory listing (default max depth: 3) |
55
+
56
+
### Registration Groups
57
+
58
+
Code-agent tools are registered in layered groups, allowing skills to request only the capabilities they need:
0 commit comments