altk-evolve icon indicating copy to clipboard operation
altk-evolve copied to clipboard

Initial Kaizen architecture

Open vinodmut opened this issue 11 months ago • 5 comments

Here's a proposal for an initial architecture for this project.

The goal is to improve the effectiveness and efficiency of an agent's reasoning process based on the agent's experience.

Here are some design decisions in this setup.

  • Agent agnostic: We assume the agent is a black box. It can be implemented by any framework or custom built. The following design decisions are a consequence of this one.
  • Standard trajectory format: The agent trajectories are available in a standard format, such as OpenTelemetry.
  • Insight retrieval as a tool: The agent uses a tool to retrieve relevant insights for a given task.

(Note that these decisions will evolve. This is just a proposal for the initial version.)

A central concept are ~katas~ entities, which are the learned or provided artifacts. These can be short tips, guidelines, standard operating procedures, or reusable code to help an agent reason and perform its task. ~(Katas are patterns or routines to accomplish a task.)~

Image

The elements in this diagram:

  • Agent: Can be any agent, such as Claude Code, or something built on LangGraph.
  • Logs: Contains agent execution trajectories (including user utterances, agent reasoning, and tool calls).
  • Entities DB: A place to store katas.
  • Entities MCP tool: The interface for the agent to retrieve relevant insights.

vinodmut avatar Dec 15 '25 18:12 vinodmut

What would help is to have an e2e example

visahak avatar Dec 15 '25 18:12 visahak

A first commit contains an implementation that borrows heavily from the previous project https://github.com/AgentToolkit/kaizen/commit/46acae53a409d6e27687cff143e798eaceacb678 To run an e2e example, set up an .env file with OPENAI_API_KEY after setting up the uv venv, and then run

pytest

you can also run pytest -m e2e to only run the e2e test.

illeatmyhat avatar Dec 16 '25 00:12 illeatmyhat

Should we also look to enable the processing layer with API endpoints (particularly when it comes to retrieval). This way a we can leave it up to the agent builder to decide whether they want to connect with the agent through MCP or through deeper integration

visahak avatar Dec 16 '25 19:12 visahak

we could have an http api. the python API is also already available as a core frontend

illeatmyhat avatar Dec 20 '25 21:12 illeatmyhat

Can we close this issue?

visahak avatar Apr 09 '26 12:04 visahak