The current Wizard architecture works well because of strict separation:
- LLM decides WHAT (intent, semantics)
- System handles HOW (execution, layout, deduplication)
- Single-writer guarantee prevents chaos
This pattern scales. An executive agent doesn't need to do everything - it delegates to specialized minions, each with their own well-defined scope.
┌─────────────────┐
│ THE WIZARD │ ← Executive: interprets user intent
│ (You talk to) │ routes to appropriate minion
└────────┬────────┘
│
┌─────────────────┼─────────────────┐
│ │ │
┌──────▼──────┐ ┌──────▼──────┐ ┌──────▼──────┐
│ Graph │ │ Knowledge │ │ Analysis │
│ Builder │ │ Enricher │ │ Engine │
└──────┬──────┘ └──────┬──────┘ └──────┬──────┘
│ │ │
┌──────▼──────┐ ┌──────▼──────┐ ┌──────▼──────┐
│ Layout │ │ Wikipedia │ │ Pattern │
│ Engine │ │ Fetcher │ │ Matcher │
└─────────────┘ └─────────────┘ └─────────────┘
Each layer:
- Has a specific, bounded purpose
- Only talks to its parent/children
- Cannot modify things outside its scope
- Reports results up, receives tasks down
What if agents are defined inside Redstring itself?
- A node represents an agent component
- The node's description/bio contains its prompt/instructions
- Edges represent control flow and data dependencies
- Definition graphs decompose agent capabilities
┌─────────────────────────────────────────────────────────────┐
│ Graph: "The Wizard Agent Definition" │
│ │
│ ┌─────────────┐ ┌─────────────┐ │
│ │ Intent │───────▶│ Router │ │
│ │ Detector │ │ │ │
│ │ │ │ Bio: "Route │ │
│ │ Bio: "Parse │ │ to correct │ │
│ │ user intent │ │ handler..." │ │
│ │ from..." │ └──────┬──────┘ │
│ └─────────────┘ │ │
│ ┌───────────┼───────────┐ │
│ │ │ │ │
│ ┌─────▼─────┐ ┌───▼───┐ ┌─────▼─────┐ │
│ │ Create │ │ Edit │ │ Query │ │
│ │ Handler │ │Handler│ │ Handler │ │
│ └───────────┘ └───────┘ └───────────┘ │
└─────────────────────────────────────────────────────────────┘
Each agent node's description field becomes its system prompt:
{
"name": "Intent Detector",
"color": "#8B0000",
"description": "You are the Intent Detector. Your job is to analyze user messages and classify them into one of these intents: create_graph, create_node, analyze, update_node, delete_node, enrich_node. Return JSON with 'intent' and 'confidence' fields. Do not execute anything - only classify."
}Connection definitions describe how agents interact:
| Edge Type | Meaning |
|---|---|
Delegates To |
Parent assigns task to child |
Reports To |
Child returns results to parent |
Depends On |
Must wait for this agent to complete |
Validates |
Checks output of another agent |
Fallback To |
If primary fails, try this one |
The Druid is an agent whose entire cognitive state is a Redstring graph.
- Working memory = Active graph's nodes
- Long-term memory = Saved/closed graphs
- Reasoning = Creating/connecting nodes
- Learning = Modifying definition graphs
- Goals = Root nodes with "Goal" type
- Beliefs = Nodes with confidence scores
┌─────────────────────────────────────────────────────────────┐
│ The Druid's Mind (Internal Redstring Instance) │
│ │
│ ┌─────────────┐ │
│ │ Current │──────────────────────┐ │
│ │ Goal │ │ │
│ └─────────────┘ ▼ │
│ ┌─────────────────┐ │
│ ┌─────────────┐ │ Working Memory │ │
│ │ Observation │───────────▶│ (Active Graph) │ │
│ │ from User │ └────────┬────────┘ │
│ └─────────────┘ │ │
│ ▼ │
│ ┌─────────────────┐ │
│ │ Reasoning Path │ │
│ │ (Edge Chains) │ │
│ └────────┬────────┘ │
│ │ │
│ ┌────────▼────────┐ │
│ │ Action Decision │ │
│ │ (Output Node) │ │
│ └─────────────────┘ │
└─────────────────────────────────────────────────────────────┘
| Aspect | The Wizard | The Druid |
|---|---|---|
| Role | Graph editor | Agent brain |
| State | Stateless | Graph IS state |
| Memory | Conversation only | Persistent graphs |
| Purpose | Help user build | Autonomous reasoning |
| Control | User-directed | Self-directed |
- Add
agentPromptfield to node prototypes - Add
agentTypeenum:executor,validator,router,transformer - Create "Agent" abstraction chain for typing
- Allow nodes to have
agentPromptin their bio - Parse agent definitions from graph structure
- Execute agent chains based on edge traversal
- "New Agent" workflow in Wizard
- Visual prompt editor in node panel
- Test agent button (run with sample input)
- Agent template library
- Internal Redstring instance for agent state
- Goal → Observation → Reasoning → Action loop
- Memory persistence across sessions
- Introspection API (see the Druid's "thoughts")
- Export agent as
.redstring-agentformat - Import community agents
- Agent versioning and updates
- Performance benchmarks
class AgentExecutor {
constructor(agentGraph) {
this.graph = agentGraph;
this.entryPoint = this.findNodeByType('entry');
}
async execute(input) {
let currentNode = this.entryPoint;
let context = { input, results: {} };
while (currentNode) {
// Get agent prompt from node description
const prompt = currentNode.description;
// Execute this agent step
const result = await this.runAgentStep(prompt, context);
context.results[currentNode.name] = result;
// Follow edges to next node
currentNode = this.getNextNode(currentNode, result);
}
return context.results;
}
getNextNode(current, result) {
const edges = this.getOutgoingEdges(current);
// Router pattern: edge labels are conditions
for (const edge of edges) {
if (this.matchesCondition(edge.name, result)) {
return this.getNode(edge.targetId);
}
}
return null; // End of chain
}
}{
"agentMeta": {
"name": "Research Assistant",
"version": "1.0.0",
"entryPoint": "node-intent-classifier",
"author": "The Wizard"
},
"nodes": [
{
"id": "node-intent-classifier",
"name": "Intent Classifier",
"agentConfig": {
"type": "router",
"prompt": "Classify the user's research request...",
"outputFormat": "json",
"routes": {
"search": "node-search-executor",
"summarize": "node-summarizer",
"compare": "node-comparator"
}
}
}
],
"edges": [
{
"source": "node-intent-classifier",
"target": "node-search-executor",
"condition": "intent === 'search'"
}
]
}- Composability: Small, focused agents combine into complex behaviors
- Debuggability: You can literally see the agent's structure as a graph
- Modifiability: Change one node's prompt, update one edge
- Testability: Run individual nodes with mock inputs
- Shareability: Export agent as graph, import elsewhere
- Self-improvement: Agent can modify its own definition graph
Grant, you mentioned Eubanks from "yew banks" - sacred to Celtic druids.
The Druid agent name isn't just whimsy. Druids were:
- Knowledge keepers → Graph as memory
- Advisors to chiefs → Agent advises Wizard
- Nature interpreters → Pattern recognition in data
- Ritual specialists → Structured, repeatable processes
The Wizard conjures; the Druid remembers and reasons.
- Validate: Does this architecture feel right?
- Prototype: Add
agentPromptfield to nodes - Test: Build a simple 3-node agent manually
- Iterate: What's missing? What's overcomplicated?
The goal: Anyone can build an AI agent by drawing a graph.