60 lines
2.1 KiB
Markdown
60 lines
2.1 KiB
Markdown
# Agent Prompts
|
|||
|
|
|
||
|
|
LLM agent prompts for Poimen RoutingWorkflow.
|
||
|
|
|
||
|
|
## Agents
|
||
|
|
|
||
|
|
| Agent | Model | Purpose | Prompt File |
|
||
|
|
|-------|-------|---------|-------------|
|
||
|
|
| **Router** | `reasoning` | Natural language → WorkflowSpec | [router/AGENTS.md](router/AGENTS.md) |
|
||
|
|
|
||
|
|
---
|
||
|
|
|
||
|
|
## Architecture
|
||
|
|
|
||
|
|
```
|
||
|
|
User Request: "Scan repo X for security issues"
|
||
|
|
│
|
||
|
|
▼
|
||
|
|
┌─────────────────────────────────────────────────┐
|
||
|
|
│ RetrieveMemoryActivity │
|
||
|
|
│ Query poimen-memory for relevant skills/lessons│
|
||
|
|
└─────────────────────────────────────────────────┘
|
||
|
|
│
|
||
|
|
▼
|
||
|
|
┌─────────────────────────────────────────────────┐
|
||
|
|
│ Router Agent (LLM) │
|
||
|
|
│ Input: message + memory context + activities │
|
||
|
|
│ Output: WorkflowSpec JSON │
|
||
|
|
└─────────────────────────────────────────────────┘
|
||
|
|
│
|
||
|
|
▼
|
||
|
|
┌─────────────────────────────────────────────────┐
|
||
|
|
│ RoutingWorkflow │
|
||
|
|
│ Executes WorkflowSpec as state machine │
|
||
|
|
│ Clone → Scan → Report → Notify │
|
||
|
|
└─────────────────────────────────────────────────┘
|
||
|
|
```
|
||
|
|
|
||
|
|
---
|
||
|
|
|
||
|
|
## Memory Integration
|
||
|
|
|
||
|
|
Router receives context from `RetrieveMemoryActivity`:
|
||
|
|
|
||
|
|
```
|
||
|
|
1. User: "scan repo for security"
|
||
|
|
2. RetrieveMemoryActivity queries poimen-memory
|
||
|
|
3. Returns: skills, lessons, references
|
||
|
|
4. Injected into Router prompt
|
||
|
|
5. Router generates smarter WorkflowSpec
|
||
|
|
```
|
||
|
|
|
||
|
|
---
|
||
|
|
|
||
|
|
## LLM Endpoint
|
||
|
|
|
||
|
|
Default: `https://api.riotpiao.com/v1/chat/completions`
|
||
|
|
|
||
|
|
Override: `LOCAL_LLM_BASE_URL=http://localhost:11434`
|