Skip to content

examples: add minions-clone (AI task app on the Agent37 Agents API)#8

Open
ArchanaRangrej wants to merge 1 commit into
mainfrom
feat/minions-clone-app
Open

examples: add minions-clone (AI task app on the Agent37 Agents API)#8
ArchanaRangrej wants to merge 1 commit into
mainfrom
feat/minions-clone-app

Conversation

@ArchanaRangrej

@ArchanaRangrej ArchanaRangrej commented Jun 27, 2026

Copy link
Copy Markdown

minions-clone — Prompt Request

User:

Build a modern AI task-management platform on the Agent37 Agents API, matching a series of screenshots, as a production-shaped example in this repo: a "What do you need done?" task composer, a multi-turn chat detail page per task (user prompt plus assistant reply with a "Thought process" disclosure, editable title, a "Ready for review" status with a "Mark complete" action, and a follow-up composer), and a Tasks page as a 3-column Kanban board (In Progress / Ready for review / Complete) with counts, status icons, and drag-and-drop cards that click through to the task's history. Each card's "..." menu moves it to the other two columns or deletes it, and each column header's "..." menu deletes all cards in that column. I want clean architecture, reusable components, and a feature-based folder structure; grill me with one question at a time before building. Decisions made along the way: Next.js 15 App Router plus TypeScript over plain React; Tailwind v4 with hand-rolled UI primitives and lucide icons; one shared Agent37 instance with one session per task, provisioned lazily on the first task; no auth in v1 (schema leaves room for user_id); Medium is priority metadata while Goal steers the agent via Agent37's native goal mode; submit navigates to a streaming /tasks/[id] whose route tees the Agent37 SSE to the browser while persisting state; the detail thread is read live from the Agent37 session rather than cached; dropping a card into In Progress reopens the task without re-running the agent; Recurring and Skills are stubs and Dictate is decorative; and on persistence, we first stripped the DB to an in-memory store then reversed that because losing the board on restart contradicts the production-shaped-template goal, settling on a single-file local SQLite store (Drizzle plus libSQL, two runtime deps, no drizzle-kit or generated migrations, CREATE TABLE IF NOT EXISTS on boot), kept metadata-only with Agent37 owning threads and execution. Finally, simplify the changed code for reuse and altitude without hunting for correctness bugs, then commit, push, and open this PR.

Assistant:

Delivered minions-clone as the example's first commit: a Next.js 15 App Router app with a task composer, a live-streaming multi-turn chat detail page, and a native HTML5 drag-and-drop Kanban board with card-move and column-bulk-delete menus, all matching the screenshots. Layering is clean: route handlers to services to an Agent37 gateway that holds the sk_live_ key server-side (enforced via server-only) plus libSQL/Drizzle repositories, with column presentation and the board's optimistic move/reconcile logic each consolidated to a single source. Persistence is a thin metadata-only SQLite store that self-creates its tables, while Agent37 owns execution and the chat transcript (read live from the session); the stream route tees SSE to the browser while persisting only status and the session_id/response_id pointers. Verified live against a funded key (provisioning, the SSE tee, and live thread read-back all worked; the agent turn itself stopped on an Agent37 budget 402, a billing state rather than a code issue), then tore down the test instance; typecheck and next build pass, and the simplify pass removed dead exports and duplicated metadata behavior-neutrally.

🤖 Generated with Claude Code

A production-shaped Next.js 15 example: write a task in plain language,
Agent37 runs an agent that plans/uses tools/streams its work live, and a
3-column Kanban board tracks tasks through queued -> running ->
ready_for_review -> completed. The detail page is a multi-turn chat thread
reusing one Agent37 session per task; the thread is read live from the
session (Agent37 owns execution + transcript).

Persistence is a thin metadata layer in local SQLite (Drizzle + libSQL,
file minions.db): it holds only what Agent37 can't — board metadata plus
the session_id/response_id pointers. The schema self-creates on boot
(CREATE TABLE IF NOT EXISTS), so a fresh clone runs with no migration step;
the provisioned instance id is persisted so a restart reuses it instead of
provisioning a new billed instance. The sk_live_ key stays server-side via
server-only; the browser talks only to /api routes.

Layering: route handlers -> server/services -> server/agent37 gateway +
server/db repositories. Verified live: provision -> stream -> persist round
trip writes session/response pointers to SQLite and reads the thread back
from the Agent37 session.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant