Dunn Lab Code

This repository is a resource for scientists using AI in their research. It is really three things. First, it is a manual about using AI assistance in computational research. You are reading the manual now. Second, it has an optional Claude Code plugin that implements some of the conventions described here as skills. Third, it has assorted other resources such as example configuration files. The plugin is product-specific; the manual is not.

The manual uses Claude Code and Codex as its main examples, but most of it applies to other coding agents. Agent Concepts provides a vendor-neutral conceptual template, and Coding Agents shows how the two harnesses implement it.

Our working stack, in one view

Use Visual Studio Code as the editor, but run coding agents and most tools from the terminal. Command-line workflows are the ones agents can see and drive directly. For remote or long-running sessions, use tmux so the agent keeps working when your connection closes.

Prefer text-based files that both Git and an agent can inspect: Markdown or LaTeX instead of Word documents, CSV or TSV instead of Excel workbooks, and scripts or configuration files instead of settings that exist only in a GUI. Agents work more effectively and efficiently with plain text because they can search, compare, edit, and verify it directly, without first translating a complicated file format or driving the application that owns it.

Put each project in Git and GitHub from the beginning. Let the agent make small, descriptive commits after verified steps, and install the GitHub CLI so it can work with repositories, issues, pull requests, and checks from the terminal.

The Toolkit explains these choices tool by tool, and Getting Started covers agent setup. Ask your agent to explain or help configure anything unfamiliar.

Table of contents

  • Using AI in Research — What changes and what does not: accountability, reviewing generated code, handling data, reporting AI use, and journal and funder policy. No terminal required.
  • Quick Reference — The whole thing on one page: setup, the working rhythm, permission modes, sessions, and tmux. Start here if you want the shape before the detail.
  • The Toolkit — The non-AI tools agents work through: the shell, Git, GitHub, VS Code, Python, R, Rust, Markdown, LaTeX, and Quarto, what each does, and why we use it.
  • Getting Started — How to install and verify Claude Code or Codex.
  • Agent Concepts — A vendor-neutral guide to models, harnesses, agent loops, context, tools, permissions, sessions, and the user, agent, and compute planes.
  • Coding Agents — How Claude Code and Codex map onto those concepts, where they differ, and what carries between them.
  • Managing Security — Permissions, sandboxing, and containers. What can go wrong and what actually stops it.
  • Managing Context — Giving an agent the right information: project instructions, rules, memory, skills, and plugins.
  • Working Effectively — How to frame the work: asking broadly, separating planning from building, and committing the plan.
  • Working Across Computers — The user, agent, and compute planes and how to arrange them, SSH and tmux, moving files, and running agents on shared clusters.
  • Reproducibility — What it takes for an analysis to work again: data, code, and runtime, how agents help and hurt, testing that results reproduce, and archiving.
  • Correctness — Whether a result is right: tasks that are hard to do or hard to check, with strategies and biological examples for each, plus tests, orthogonal validation, and code review.
  • Software Engineering — Building large projects with agents: architecture principles, testing and linting, idempotence and dry runs, workflow frameworks such as Snakemake, prototyping, increments and gates, issues, and release cycles.
  • Writing with AI — AI in manuscripts: where analysis and writing blur, the ways AI can contribute, discussing use openly with co-authors, and getting references right.
  • Example Workflows — A project from empty directory to working code, start to finish.
  • Computing at Yale — YCRC clusters, YCRC guidance on coding agents, and a long-running agent on Bouchet’s agent partition.
  • Dunn Lab Practices — Lab-specific practices, and the reasoning behind the conventions the plugin encodes.
  • DunnLab Plugin — The skills, commands, and assets in this repository, and how to run them.

The last three chapters are specific to our institution and lab: computing at Yale, our lab’s practices, and the plugin that encodes them.

For contributors

Corrections and additions are welcome, please file issues at https://github.com/caseywdunn/dunnlab_code/issues. dev_docs/contributing.md in the repository covers the branching model, the checks that run on every change, and the release process.

AI use

This manual, the plugin, and the scripts in this repository were written by Casey Dunn with Claude Code from the first commit in March 2026 onward, and later with OpenAI Codex as well.

Together, these agents drafted or rewrote most of the prose in these chapters, wrote the plugin skills and check scripts, and checked factual claims against vendor and YCRC documentation. I set the structure, decided every convention, edited throughout, and am responsible for all of it, including any errors.

Following this manual’s own advice on rolling your own and borrowing GAIDeT’s vocabulary, the tasks delegated under human supervision were: literature search and systematization, text generation, proofreading and editing, code generation, and process automation.

Agents: Anthropic Claude Code and OpenAI Codex.

Models: Claude Opus 4.6, 4.7, 4.8, Opus 5, and Opus 5.5; OpenAI GPT-5 via Codex.

The git history is the detailed record. Most earlier commits carry a Co-Authored-By trailer naming the Claude model that contributed to them.


This site uses Just the Docs, a documentation theme for Jekyll.