Tasks complete → Skills crystallize automatically. Every execution makes you smarter.
GenericAgent is a self-evolving agent loop (~100 lines of stable kernel) that automatically crystallizes completed tasks into reusable skills. Every task execution leaves behind a skill — making the agent progressively more capable without manual intervention.
- Auto-Crystallization — Task done → skill generated. Zero manual effort.
- 9 Atomic Tools — code_run, file_read/write/patch, web_scan, ask_user, checkpoint, long_term_update
- L0-L4 Hierarchical Memory — Context → Working → Short → Long → Meta, with auto-promotion
- FTS5 + Semantic Search — Hybrid retrieval (0.7 semantic + 0.3 success-weight)
- GEP Gene Encoding — Each skill is a gene capsule with mutation history and evolution trace
git clone https://github.com/Youan-ai/GenericAgent-Fusion.git
cd GenericAgent-Fusionfrom generic_agent import GenericAgent
agent = GenericAgent()
# Agent automatically:
# 1. Receives task → 2. Searches existing skills → 3. Executes → 4. Crystallizes new skill
result = agent.run("Write a Python script to sort files by date")
# A new skill is now available for future tasks!
print(f"Crystallized: {result.skills_created}")┌─────────────────────────────────────────────┐
│ GenericAgent Loop │
├──────────────┬──────────────────────────────┤
│ Execution │ Crystallization │
├──────────────┼──────────────────────────────┤
│ receive task │ analyze execution path │
│ search skills│ extract SOP/pattern │
│ run tools │ encode as Gene capsule │
│ collect │ store in skill bank │
│ results │ update AGENTS.md refs │
└──────────────┴──────────────────────────────┘
| Level | Name | Capacity | Persistence |
|---|---|---|---|
| L0 | Context Window | ~session | Session |
| L1 | Working Memory | ~50 items | Task duration |
| L2 | Short-term | ~500 items | Day |
| L3 | Long-term | ~5000 items | Weeks |
| L4 | Meta-memory | Core skills | Permanent |
Open issues and PRs welcome!
Apache 2.0 — see LICENSE.