claude-code-engineering: a course companion repo for treating Claude Code as infrastructure
This repository demonstrates how to use Claude Code to do real engineering work, not just writing code. 本项目是极客时间专栏 《Claude Code 工程化实战》 的官方配套示例仓库,目标就是: 👉 把 Claude Code 从“对话式编码工具”,变成 可设计、可复用、可治理的工程系统。
At a glance
- What is it?
- This repository is the official sample code for a paid Geektime column on engineering with Claude Code. It is a teaching artefact tied to a course and a book, not a standalone library, and the README is mostly a syllabus rather than installation instructions.
- Who is it for?
- Adopt this repository only if you already have access to the Geektime column or the companion book, because the code is organised as per-lecture project directories that assume the surrounding explanation.
- Can I use it commercially?
- Not without permission. GitHub finds no licence file in the repository, and without a licence all rights are reserved by default: you may read the code but not reuse it. Check the README, or ask the authors, before using it.
- Is it still maintained?
- Yes. The repository last received commits 55 days ago.
- What is it written in?
- Mainly JavaScript, according to GitHub's language statistics.
Answers come from the project's GitHub data, last synced on September 15, 2026, and from our analysis. They are not legal advice.
DEEP OPEN-SOURCE ANALYSIS
What problem this repository addresses, and for whom
Most material about Claude Code stops at prompt technique. This repository starts from a different premise, stated in its own description: that Claude Code should move from being a conversational coding tool into a system that can be designed, reused and governed. The README frames the whole thing as an engineering discipline with named subsystems: memory, Skills, SubAgents, Hooks, MCP, Headless mode, the SDK and Plugins. The intended reader is someone who already uses Claude Code and now needs to make its behaviour repeatable across a team.
The audience is narrow in a specific way. The repository is the official companion to a 23-lecture audio column on Geektime, and the README also points to a separate 10-chapter print book, explicitly described as complementary rather than identical content. The book is said to carry 226 code fragments under 99-书籍代码/, while the course ships one runnable directory per lecture under projects/. So the reader is expected to be consuming one or both paid products. If you arrive at the GitHub page cold, you are looking at the skeleton of a course, not a self-contained toolkit.
The syllabus as architecture: five parts and what each one installs
The README is a table of contents, and reading it as an architecture document is the most useful thing you can do with it. Part one is foundations: a tour of the Claude Code stack, then CLAUDE.md as a persistent memory layer for project conventions and coding style. Part two covers sub-agents, and the lecture titles map to concrete roles rather than abstractions: a read-only code reviewer restricted to Read, Grep and Glob; a test runner and log analyser whose purpose is to absorb several hundred lines of output and return only a conclusion to the main conversation; parallel exploration and a bug-fix pipeline; and finally Agent Teams, described as multi-session collaboration with role division and state passing.
Part three is the Skills system. Lecture 9 treats the description field in SKILL.md as a trigger rather than documentation, which is the single most consequential design claim in the outline. Lecture 10 describes team command sets such as /review, /deploy and /commit as Skills configured with disable-model-invocation: true, which is a concrete and checkable statement about how slash commands are implemented. Lecture 11 describes a three-layer progressive disclosure structure for a financial analysis Skill, with a contents page, chapters and an appendix. Part four covers Hooks for pre- and post-tool checks, MCP for external tool connections, and part five moves to production concerns: the tool system, headless mode for CI/CD, a Rules system split into instruction rules and permission rules, and the Agent SDK with its query() interface and a ClaudeCodeOptions type whose full name is cut off in the README.
What the repository layout tells you before you clone it
Two directories are named in the README. projects/ holds one subdirectory per lecture and is described as directly runnable. 99-书籍代码/ holds 226 fragments tied to the book's chapters. 91-Pictures/ holds cover images and banners. The primary language reported for the repository is JavaScript, which is worth noting because the sibling project referenced in the README, agent-design-patterns, is described as shipping minimal runnable Python. If you are a Python shop expecting the same, check the projects/ directory for the lecture you care about before assuming parity.
The absence of a releases section is the other structural signal. There is no version to pin, no changelog to diff and no tagged artefact. The last push timestamp is recent, so the repository is alive, but liveness and versioning are different properties. For a teaching repository that is fine. For anything you intend to vendor into a build, it means you are tracking a moving branch.
Running the examples: what the README does and does not specify
This is where the material runs thin, and it should be said plainly. The README gives no installation command, no dependency manifest reference, no Node version requirement and no environment variable list. It states that each lecture has a projects/ subdirectory that can be run directly, and that is the extent of the operational guidance in the supplied text. The book's code lives under 99-书籍代码/ as fragments, which by definition are not runnable on their own.
What the README does give is configuration surface, expressed through lecture descriptions rather than setup steps. The named keys and mechanisms are: CLAUDE.md for project memory, SKILL.md with a description field that acts as the trigger and a disable-model-invocation: true frontmatter key for command-style Skills, Hooks configured through frontmatter for pre- and post-tool interception, and the Agent SDK's query() function alongside ClaudeCodeOptions. If you are evaluating whether this repository matches your stack, those identifiers are the checklist. Anything beyond them, such as which package manager to use or how the projects are wired together, is not determinable from the README and would need the course itself.
The governance claim is the interesting part, and also the untested part
The strongest idea in the outline is the separation in lecture 20 between instruction rules, which tell Claude what to do, and permission rules, which tell Claude what it is allowed to do. That split is the difference between a prompt and a policy, and it is the kind of distinction that survives contact with a real team. The Hooks lectures make a similar move, placing custom checks before and after tool execution so that dangerous commands are blocked, sensitive files are protected and formatting happens automatically, with lecture 16 extending this to a Stop hook used as a quality gate and to SubAgent event acceptance.
The limitation is that none of this is verifiable from the repository description alone. A hook that blocks a dangerous command is only as good as its pattern matching, and the README does not show a single hook definition. A read-only sub-agent restricted to Read, Grep and Glob is a permission boundary only if the restriction is enforced rather than requested, and the README does not say which it is. Treat the governance framing as a set of hypotheses the course presumably demonstrates, not as properties you can confirm from the GitHub page. If your threat model requires enforced constraints, verify the enforcement mechanism in the actual lecture code before relying on it.
Where a general-purpose agent framework is the better choice
The real alternative for most teams is not another Claude Code course repository. It is a general agent framework such as the one the same author documents elsewhere: the README points to designing-ai-agents and agent-design-patterns, with a dual-axis framework of seven cognitive functions against six execution topologies, 27 agent design patterns and minimal runnable Python. The difference in approach is concrete. This repository teaches you to configure and constrain one specific product, Claude Code, using its own extension points: CLAUDE.md, SKILL.md, Hooks, MCP and the SDK. The pattern repositories teach you to build the agent loop yourself in a language you control.
Choose accordingly. If your team has standardised on Claude Code and the problem is that its behaviour is inconsistent between engineers, this repository's subject matter is exactly on target. If you need to embed agent behaviour inside a service you own, run it against a model you choose, or ship it as a product, the configuration surface here is the wrong layer of abstraction, and the Python pattern repositories are the closer fit. The two are complementary, and the README says as much about the book and the column.
Maintenance cost, licensing and the practical decision
Maintenance cost here is not a dependency problem, because there is no package to depend on. It is a drift problem. The repository tracks a fast-moving product, and the lecture outline references features such as Agent Teams and a Rules system that are specific to a moment in Claude Code's development. When the product changes, the lecture code is what needs updating, and there is no release cadence to signal when that has happened. The README does describe the column as adding projects, updates and deeper cases on top of the book, which suggests the author intends to keep pace, but intent is not a schedule.
The licence is listed as unknown in the repository metadata, and the README supplied here does not state one. That matters more than usual for a teaching repository, because the natural thing to do with example code is copy it. Without a declared licence, the default position is that no reuse rights are granted, so check with the author or the Geektime column terms before lifting a Skill definition or a hook configuration into your own repository. This is a factual gap, not a legal opinion, and it is the first thing to resolve.
Editorial conclusion
Adopt this repository only if you already have access to the Geektime column or the companion book, because the code is organised as per-lecture project directories that assume the surrounding explanation. If you want a drop-in library with an install command, a versioned release and a changelog, this is the wrong artefact: the repository has no releases and no declared licence, so verify the licence terms with the author before reusing any code commercially, and check whether the projects directory matches the lecture you are on before copying a pattern into a production agent.
Community notes