๋ณธ๋ฌธ์œผ๋กœ ๊ฑด๋„ˆ๋›ฐ๊ธฐ

๐Ÿš€ Getting Started

Welcome to The Human Pattern Lab

The Human Pattern Lab is a living system for exploring human behavior, AI collaboration, and emergent patterns โ€” built with care, curiosity, and the occasional raccoon in a lab coat.

Whether youโ€™re:

  • exploring the ideas,
  • contributing content,
  • building features,
  • or integrating with the Labโ€™s data systems,

this guide will orient you quickly and safely.


Most visitors should begin with:

  • ๐Ÿงญ Departments โ€” understand how the Lab is organized
  • ๐Ÿงช API Reference โ€” see the real data shape behind the systems
  • ๐Ÿ“ Lab Notes โ€” read published work and in-progress drafts

If youโ€™re here to build or run the Lab locally, continue below.


๐Ÿงช Working With Lab Data (Quick Overview)โ€‹

The Lab exposes a read-only API for inspecting notes, drafts, and published material.

  • Base URL: https://api.thehumanpatternlab.com
  • Primary resource: Lab Notes

You can explore:

  • published vs draft notes
  • departmental ownership
  • summaries and rendered content

Full contracts live here:
โ†’ API Reference โ†’ Lab Notes API

(If you can โ€œshow me the data,โ€ youโ€™re already doing it right.)


๐Ÿงฐ Prerequisites (Local Development)โ€‹

To run the Lab locally, your machine needs:

โœ” Node.jsโ€‹

Recommended version: 20.19+

Check your version:

node -v

If you need to update, install nvm:

nvm install 20
nvm use 20

If you donโ€™t have nvm installed:
https://github.com/nvm-sh/nvm


โœ” npmโ€‹

Bundled with Node.

Check with:

npm -v

๐Ÿ“ฆ Clone the Repositoryโ€‹

git clone https://github.com/<your-repo>/human-pattern-lab.git
cd human-pattern-lab

๐Ÿ“ Install Dependenciesโ€‹

npm install

This installs:

  • React
  • Vite
  • React Router
  • Tailwind CSS v4
  • TypeScript
  • Vitest
  • Lab mascot and data systems
  • Shared UI components

๐Ÿงช Run the Development Serverโ€‹

Start Vite:

npm run dev

Local dev URL:

http://localhost:5173

Open that in your browser to launch the Lab UI.


๐Ÿงฌ Project Structure (Quick Map)โ€‹

src/
components/ โ†’ UI building blocks
pages/ โ†’ Route-driven screens
data/ โ†’ Lab members, departments, notes
router/ โ†’ Routing configuration
styles/ โ†’ Global Tailwind v4 styles
types/ โ†’ Shared TypeScript models
assets/ โ†’ Images, icons, mascots

Mascot lore lives in:

src/data/labteam.ts

(marked @status lore-critical)


๐Ÿ›  Build for Productionโ€‹

To create an optimized build:

npm run build

Output is written to:

/dist

Preview the production build:

npm run preview

๐Ÿงช Running Testsโ€‹

The Lab uses Vitest with a JSDOM test environment.

Run tests:

npm run test

Watch mode:

npm run test:watch

๐ŸŒŒ Metadata & File Headersโ€‹

Most major files include:

  • A cosmic metadata banner
  • JSDoc authorship
  • @lab-unit ownership
  • @status maturity indicators

Additional docs:

  • docs/code-status.md
  • docs/lab-units.md (coming soon)

๐Ÿ’ก Troubleshootingโ€‹

Tailwind styles not loadingโ€‹

Ensure this import exists at the top of src/main.tsx:

import '@/index.css';

Node version mismatchโ€‹

Use Node 20.19+

Routes misbehavingโ€‹

Check all paths in:

src/router/routes.tsx

React Router is strict about nesting and relative paths.


๐ŸŽ‰ Youโ€™re Orientedโ€‹

You now know:

  • how the Lab is structured
  • where the data lives
  • how to run it locally
  • where to explore next

Welcome to The Human Pattern Lab.
May your systems stay legible and your raccoons remain caffeinated.