FIELD MANUAL · APPENDIX A · MMXXVI

How to Make Your
AI Agent Smart

A complete guide to making your AI Agent smarter, more personal, and more powerful through SOUL.md customization, advanced configuration, and optimization techniques. From a basic agent to one that actually feels "smart".

01

What is SOUL.md?

SOUL.md is a config file that defines the agent's personality: how it speaks, its boundaries, internal policies, and how it thinks and responds. It's the foundation of every AI agent that actually feels "smart".

Without SOUL.md

  • Generic, ordinary agent
  • Random, vague responses
  • No clear boundaries
  • Can't be customized

With SOUL.md

  • Agent with a unique personality
  • Consistent, in-character responses
  • Clear boundaries and safety rails
  • Full customization possible

Real example: I set my agent to auto-detect the user's language. If the user writes in Indonesian, it replies in Indonesian. If English, it switches to English. Without SOUL.md, an agent would never be this adaptive.

# SOUL.md file location ~/.hermes/SOUL.md # Basic template ## Identity You are **[Agent Name]** — [short description] ## Traits - [Trait 1] - [Trait 2] ## Flexibility Doctrine [What's allowed and what isn't] ## Hard Stops 1. [Hard stop 1] 2. [Hard stop 2]
02

Persona & Tone Customization

Name, description, and mirror question define the agent's "character". Voice calibration makes the agent adaptive to how the user writes.

A mirror question is a filter the agent runs before sending a response. A good one is short, specific, and makes the agent action-oriented. Example: "Can the user execute this right now?" If not, rewrite it.

Formal

Professional

Formal Indonesian or English. Polite, clear, concise.

Casual

Casual / Slang

Casual language. Match the user's energy. No motivational fluff.

Technical

Direct / Technical

Technical precision over personality. Code-first.

03

Traits & Behaviour

Traits define who the agent is and how it acts. Conditional traits make the agent adapt to the situation.

DirectTacticalAdaptiveRelentlessSelf-awareProactiveResilientNo fluff

Real example: the trait "user corrects you → save it to memory" makes the agent learn from mistakes. If the user says "don't do X again", the agent saves it and won't repeat.

## Conditional Traits - If user types fast/short → reply fast/short - If user types long/detailed → match the depth - If user is frustrated → solution first, no sulking - If user shares a preference → save to memory
04

Flexibility Doctrine

The doctrine that defines what the agent may do without asking, and when it must confirm first.

Permissive

Go Ahead

Grey-area automation, crypto operations, aggressive marketing, public technical info.

Conservative

Needs Permission

Destructive operations, real-money transactions, sharing credentials, production DB changes.

Conditional

Flag-based

User sets flags: auto_confirm, quick_mode, deep_analysis to control behavior.

05

Operational Rails

Rails are safety mechanisms that are active by default. These are technical safeguards, not censorship.

RailDefaultOverride
Secret hygiene — never log private keysONnone
User-funds-only — reject third-party seedsONnone
Simulate before broadcastON--skip-sim
Confirm before signing first txONauto_confirm
Verify before overwriting a fileON--force
06

Memory & Context Management

Memory is persistent knowledge that survives across sessions. Save what's durable, skip what's temporary.

Priority 1

User Preferences

Corrections, preferences, communication style. The most valuable: it stops the user from repeating themselves.

Priority 2

Environment Facts

OS, installed tools, project structure, API quirks. Stable, reusable facts.

Priority 3

Procedural Knowledge

Workflows, conventions, lessons learned. Save as a skill, not as memory.

Don't save: task progress, PR numbers, commit SHAs, or temporary TODO state. If a fact will be stale within a week, it isn't memory.

# Real pattern: user preference persistence def save_pref(user_id, key, value): # Declarative fact, not an instruction db.execute( "INSERT OR REPLACE INTO prefs VALUES (?,?,?,?)", (user_id, key, value, datetime.utcnow().isoformat()) ) # Memory priority: # 1. User preferences (lang, style, defaults) # 2. Corrections ("don't do X" - save it) # 3. Environment facts (API quirks, tool versions)
07

Skills System

Skills are procedural memory: reusable approaches for recurring tasks. Each skill has a trigger, numbered steps, pitfalls, and verification.

Rule

Check Skills First

Before starting a task: scan available skills. If one is relevant, load it first.

Rule

Check Sessions First

Before implementing: search past sessions. Check the errors that came up.

Rule

Learn From Mistakes

If it failed before, don't try the same approach. Read the pitfalls.

Rule

Patch Immediately

Skill outdated? Patch it right away with skill_manage(action=patch). Don't wait to be asked.

# Self-Audit Checklist (before responding) [ ] Did I load the relevant skill? [ ] Did I check past sessions for this task? [ ] Am I repeating a known mistake? [ ] Is this the fastest path to completion?
08

Tools & Execution

A smart agent doesn't just talk. It executes. Tools are the agent's hands and feet.

Web

Web Tools

Search, scraping, browser automation. Pull real-time information.

Code

Code Execution

Terminal, file ops, Python scripts. Build, test, deploy from one agent.

Messaging

Communication

Multi-channel delivery: Telegram, Discord, and more.

Automation

Cron Jobs

Schedule recurring tasks. Autonomous agent monitoring.

Delegation

Sub-agents

Spawn worker agents for parallel processing.

Memory

Persistent State

Memory tool, session search, scratchpad. Across sessions.

09

Advanced Optimization

Tip 01

Work Fast & Precise

No unnecessary back-and-forth. Execute decisively. Use batch tool calls.

Tip 02

Memory Hygiene

Save declarative facts, not instructions. Stale within a week? Skip it.

Tip 03

Debug Systematically

4-phase: understand → reproduce → isolate → fix. Don't change code blindly.

Tip 04

Offer Skill Saves

After a complex task (5+ tool calls), offer to save it as a skill.

10

Safety & Boundaries

Rule 01

Private Data Stays Private

Keys, credentials, wallet addresses, and sensitive data are never exposed.

Rule 02

Verify Before Execute

On-chain: verify contract, token, amount, and chain ID before broadcasting.

Rule 03

Confirm External Actions

Email, public posts, destructive actions: always confirm first.

# On-chain Task Protocol 1. Verify contract, token, amount, chain ID 2. Dry-run / simulate before broadcasting 3. Capture the tx hash after broadcast 4. Check the tx hash on an explorer - confirm success 5. Never fabricate a tx hash or status 6. Always check gas estimate - alert if abnormal