-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Labels
Description
Problem: Registry is used differently in Manifold (automatic) vs Automata (manual), but this isn't documented.
Required Changes:
- Add section to README.md comparing registry usage
- Add code example showing Automata with registry
- Update
registry.gogodoc with usage examples - Add comment in
agent/manifold.goexplaining automatic handling - Add comment in
agent/automata.goexplaining decoder responsibility
Content to Add (README.md):
### Registry Integration Patterns
The Registry interface is integrated differently depending on the agent type:
**Manifold** - Automatic tool handling:
```go
registry := command.NewRegistry()
registry.Attach("calc", calculatorServer)
agent := agent.NewManifold(llm, encoder, decoder, registry)
// Registry is automatically called when LLM requests toolsAutomata - Manual decoder handling:
func (a *MyAgent) Decode(reply *chatter.Reply) (float64, Result, error) {
// Decoder must check for tool invocations
if reply.Stage == chatter.LLM_INVOKE {
// Handle tool calls manually
phase, msg, err := a.registry.Invoke(reply)
// ... process results
}
// ... decode normal responses
}See examples/03_context (Manifold) and create new example for Automata pattern.
Estimated Effort: 1.5 hours
Skills Required: Technical writing, understanding of both agent types