Skip to content

About

Claude Beyond Prompting, Published by Packt

Resources

Stars

1 star

Watchers

0 watching

Forks

Repository files navigation

Claude Beyond Prompting - Companion Repository

This repository contains the hands-on companion code for Claude Beyond Prompting: Build reusable skills, agentic systems and workflows (Packt).

Each chapter folder holds a snapshot of the TodoMate application at the point that chapter's exercises begin. Open the folder for your current chapter, run the app, and follow along.


Application: TodoMate

A minimal task manager used throughout the book as a concrete debugging and skills target. Users can add, complete, filter, and delete tasks. The frontend persists tasks via localStorage; the Express backend provides a /api/tasks endpoint and emits structured logs to Kamori.


Tech Stack

Layer Technology
Frontend Vite React 18 + TypeScript
Backend Express (Node.js, TypeScript)
Observability Kamori — structured JSON log ingestion, queryable via MCP
Persistence localStorage (client) · in-memory store (server)
Container Docker Compose
Package manager npm

Repository Structure

Each chapter folder contains a todo-mate/ subfolder with the runnable application and a CHAPTER.md that describes what changed, which bugs are present, and what the exercise is.


Prerequisites


Installation

Install dependencies once per chapter folder before running either way:

$ cd chapter-N/todo-mate   # replace N with your chapter number
$ npm install

Running with Docker Compose

$ cd chapter-N/todo-mate
$ docker compose up --build
Service URL
Frontend http://localhost:5173
Backend API http://localhost:3000
Kamori ingress http://localhost:3110
Kamori MCP http://localhost:3111/mcp

Logs from both the frontend and backend are streamed to your terminal by the kamori-logs service and ingested into Kamori's SQLite database for later MCP queries.

To stop: Ctrl+C, then docker compose down to remove containers (add -v to also wipe the Kamori log database).


Running locally (without Docker)

If you prefer to run the app without Docker, start Kamori separately first (see kamori.io for installation), then:

$ cd chapter-N/todo-mate
$ npm install          # skip if already done
$ npm run dev
Service URL
Frontend http://localhost:5173
Backend API http://localhost:3000

You will need a running Kamori instance and must set VITE_KAMORI_URL and INGEST_TOKEN in .env to match it. Chapters that use Kamori's MCP server (Part IV) require Docker Compose or a manually started Kamori process.


Environment Variables

Copy .env.example to .env before running if you want to override defaults:

Variable Default Description
INGEST_TOKEN todomate-dev Shared secret for Kamori ingestion
VITE_API_URL http://localhost:3000 Backend URL seen by the browser
VITE_KAMORI_URL http://localhost:3110 Kamori ingress URL seen by the browser
VITE_KAMORI_TOKEN todomate-dev Token used by the frontend to ship logs

Kamori

Kamori is the structured logging and observability server used throughout the book. It accepts JSON log events via POST /v1/ingest, stores them in a local SQLite database, and exposes them over a streaming endpoint (GET /v1/stream) and an MCP server (introduced in Part IV).

The kamori-logs Docker Compose service tails the stream and pretty-prints events to your terminal so you can see log evidence while following along.


Skills

From chapter 4 onward, chapter folder contains a .claude/skills/ directory. Start Claude Code from inside the chapter fodler so it picks up the project skills:

$ cd chapter-N
$ claude
$ /skills          # lists available project skills

License

See the book's accompanying materials license. The companion code is provided for educational use alongside the book.

About

Claude Beyond Prompting, Published by Packt

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Used by

Contributors

Languages