Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
35 changes: 18 additions & 17 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,31 +8,31 @@ Example webhook servers implementing the CATE (Contextual Access for Tool Execut

A comprehensive server combining all features with a browser-based dashboard for configuration.

- **[examples/advanced_server/](examples/advanced_server/)** - Access rules, PII redaction, A/B testing, and a web UI
- **[examples/contextual_access/advanced_server/](examples/contextual_access/advanced_server/)** - Access rules, PII redaction, A/B testing, and a web UI

### Focused Examples (Single-Purpose, No UI)

Minimal servers demonstrating individual hook capabilities:

| Example | Description | Hook Points Used |
| ------- | ----------- | ---------------- |
| **[user_blocking](examples/user_blocking/)** | Block specific users from tools | Access, Pre |
| **[content_filter](examples/content_filter/)** | Filter/block based on content | Access, Pre, Post |
| **[pii_redactor](examples/pii_redactor/)** | Detect and redact PII in outputs | Post |
| **[ab_testing](examples/ab_testing/)** | A/B and canary test tool versions | Pre |
| **[basic_rules](examples/basic_rules/)** | Configurable rules for all hooks | Access, Pre, Post |
| **[user_blocking](examples/contextual_access/user_blocking/)** | Block specific users from tools | Access, Pre |
| **[content_filter](examples/contextual_access/content_filter/)** | Filter/block based on content | Access, Pre, Post |
| **[pii_redactor](examples/contextual_access/pii_redactor/)** | Detect and redact PII in outputs | Post |
| **[ab_testing](examples/contextual_access/ab_testing/)** | A/B and canary test tool versions | Pre |
| **[basic_rules](examples/contextual_access/basic_rules/)** | Configurable rules for all hooks | Access, Pre, Post |

## Quick Start

```bash
# Run the advanced server with the web dashboard
go run ./examples/advanced_server -config ./examples/advanced_server/example-config.yaml
go run ./examples/contextual_access/advanced_server -config ./examples/contextual_access/advanced_server/example-config.yaml

# Or run a focused example
go run ./examples/pii_redactor -types "email,ssn,credit_card"
go run ./examples/user_blocking -block "user1,user2"
go run ./examples/content_filter -config ./examples/content_filter/example-config.yaml
go run ./examples/ab_testing -config ./examples/ab_testing/example-config.yaml
go run ./examples/contextual_access/pii_redactor -types "email,ssn,credit_card"
go run ./examples/contextual_access/user_blocking -block "user1,user2"
go run ./examples/contextual_access/content_filter -config ./examples/contextual_access/content_filter/example-config.yaml
go run ./examples/contextual_access/ab_testing -config ./examples/contextual_access/ab_testing/example-config.yaml
```

## Hook Points
Expand Down Expand Up @@ -67,12 +67,13 @@ Engine Request Flow

```
├── examples/
│ ├── advanced_server/ # Full-featured server with web UI
│ ├── basic_rules/ # Configurable rules (original example)
│ ├── user_blocking/ # Block specific users
│ ├── content_filter/ # Content-based filtering
│ ├── pii_redactor/ # PII detection and redaction
│ └── ab_testing/ # A/B and canary testing
│ └── contextual_access/
│ ├── advanced_server/ # Full-featured server with web UI
│ ├── basic_rules/ # Configurable rules (original example)
│ ├── user_blocking/ # Block specific users
│ ├── content_filter/ # Content-based filtering
│ ├── pii_redactor/ # PII detection and redaction
│ └── ab_testing/ # A/B and canary testing
├── pkg/
│ └── server/ # Generated types from OpenAPI schema
├── go.mod
Expand Down
Loading