DEV Community

Charles Wu for seekdb

Posted on

We Built an Agent That Analyzes Itself — Here’s What We Learned

When your Agent’s footprints become team insights, something interesting happens.

The Problem Nobody Talks About

Your team builds an AI Agent. It works great. People use it every day — in Slack, in DingTalk, in Discord.

Then what?

The conversations vanish into chat history. The queries disappear after execution. The insights stay trapped in individual sessions.

Over time, nobody can answer:

  • What questions do people ask most?

  • Where does the Agent fail repeatedly?

  • What patterns hide in thousands of interactions?

We faced this exact problem. And the answer wasn’t “add more analytics.” The answer was: build an Agent that analyzes itself.

Meet bubseek — an insight Agent that turned our scattered footprints into team intelligence.

What Is bubseek?

One-liner: A self-driven insight Agent built on bub (Agent framework) + seekdb (AI-native database).

What it does:

  • Accepts natural language requests (“Track AI trending projects this week”)

  • Connects to data sources autonomously (GitHub, Slack, internal systems)

  • Defines views, executes analysis, generates reports

  • Stores everything in seekdb — including its own execution traces

  • Analyzes its own traces to produce team insights

The twist: bubseek doesn’t just consume data. It consumes itself. Every interaction becomes fuel for understanding how the team works.

Why We Built It

The Old Way: BI Ticket Backlog

Team member: "I need a dashboard for GitHub trending"
 ↓
Product manager: "Add to backlog"
 ↓
2 weeks later: "Requirements unclear, need refinement"
 ↓
1 month later: Dashboard shipped (wrong metrics)
 ↓
Repeat.
Enter fullscreen mode Exit fullscreen mode

Small requests get deprioritized. Big requests take forever.

The bubseek Way: Conversation, Not Queue

Team member: "Track AI trending projects, update daily"
 ↓
bubseek: "Got it. Setting up GitHub → seekdb → daily report"
 ↓
Next morning: Report arrives in Slack
 ↓
Team member: "Add vLLM mention analysis"
 ↓
bubseek: "Updated. Next report will include it"
Enter fullscreen mode Exit fullscreen mode

Response time: From “weeks” to “seconds.”

The Building Blocks

bubseek combines two projects:

  • bub (Agent Framework)

    • Hook-first architecture: core stays minimal, features as plugins
    • Tape system: immutable execution trace (every thought, tool call, result)
    • Skills engine: extendable tool library
  • seekdb (AI-Native Database)

    • SQL + vector + full-text search in one database
    • Lightweight: runs on 1 core, 2GB RAM
    • Designed for AI workloads (RAG, embeddings, hybrid search)

Together: bub handles the Agent loop, seekdb stores everything (including the Agent’s own footprints).

What We Learned

Lesson 1: Channels should be zero-code

Built-in channels:

  • Feishu, DingTalk, WeChat, Discord, Telegram

  • Web interface (Marimo notebook)

Setup: Configure environment variables for each channel. No additional code required.

Note: Feishu is an enterprise collaboration platform popular in Asia, similar to Slack.

Note: Feishu is an enterprise collaboration platform popular in Asia, similar to Slack.

Lesson 2: Data consumption is a conversation, not a queue

Traditional BI: Deploy system → build reports → train users

bubseek: Tell it what you want → it figures out the rest

Example Workflows

Output formats:

  • Marimo notebooks (interactive Python dashboards)

  • GitHub repo cards (SVG/PNG for sharing)

  • Natural language reports (for chat)

Lesson 3: The Agent is its own best analyst

Traditional observability: External monitoring system → metrics → dashboards

bubseek observability: Agent naturally produces data → analyzes itself

The Tape System

Every Agent execution creates an immutable trace:

  • User request

  • Agent thoughts (step-by-step reasoning)

  • Tool calls (which APIs, which queries)

  • Results (what was found/generated)

  • Delivery (where sent, when)

This tape isn’t a log. It’s the data source for meta-analysis.

Example Insights (from early testing)

The loop closes: Agent serves team → produces data → data analyzed → team understands itself better.

Lesson 4: Your data foundation shapes everything

Why seekdb?

Configuration:

BUB_TAPESTORE_SQLALCHEMY_URL=mysql+oceanbase://user:pass@host:port/database
Enter fullscreen mode Exit fullscreen mode

Exit strategy: If seekdb hits limits, seamless upgrade to OceanBase (same protocol, distributed scale).

The Real Innovation: Self-Understanding Agent

Most Agents are stateless workers:

  • Do task → forget everything

  • Next task starts from zero

  • No institutional memory

bubseek is stateful team member:

  • Remembers all interactions

  • Learns from failures

  • Produces insights about itself

Example: bubseek Analyzes Its Own Usage

User: "What questions did people ask most this week?"

bubseek: (queries its own tape in seekdb)
         (clusters by topic)
         (generates report)
Enter fullscreen mode Exit fullscreen mode

Example output (illustrative — your actual numbers will vary):

Top 5 topics:
 1. GitHub trending (23 queries)
 2. AI paper summaries (18 queries)
 3. Team sprint metrics (12 queries)
 4. Competitor analysis (9 queries)
 5. Code review automation (7 queries)
Enter fullscreen mode Exit fullscreen mode

No separate analytics tool needed. The Agent is the analytics.

Getting Started

Prerequisites

Configure bubseek

Example values below are placeholders from the README; replace them with your own model, API key, API base URL, and database URL before running uv run bub chat.

git clone https://github.com/ob-labs/bubseek.git
cd bubseek
uv sync
uv run bub --help
export BUB_MODEL=openrouter:qwen/qwen3-coder-next
export BUB_API_KEY=sk-or-v1-your-key
export BUB_API_BASE=https://openrouter.ai/api/v1
export BUB_TAPESTORE_SQLALCHEMY_URL=mysql+oceanbase://user:pass@host:port/database
uv run bub chat
Enter fullscreen mode Exit fullscreen mode

For channel-specific variables, production URLs, and alternative model providers, use the full guides in the repo: Getting started (https://github.com/ob-labs/bubseek/blob/main/docs/getting-started.md), Configuration (https://github.com/ob-labs/bubseek/blob/main/docs/configuration.md).

What’s Next

Under discussion:

Further iterations may include multi-Agent coordination, smarter schema design, and proactive insight recommendations.

(Roadmap still evolving — join the conversation on GitHub.)

The Big Picture

bubseek isn’t a BI tool. It’s a bet on a different future:

We’re not saying bubseek is the answer. We’re saying: the question is worth asking.

What if your Agent knew as much about your team as you do

References

Top comments (0)