{"id":47870084,"url":"https://github.com/libar-dev/architect","last_synced_at":"2026-04-04T00:47:34.930Z","repository":{"id":334701214,"uuid":"1142377808","full_name":"libar-dev/architect","owner":"libar-dev","description":null,"archived":false,"fork":false,"pushed_at":"2026-04-03T05:44:36.000Z","size":8832,"stargazers_count":0,"open_issues_count":10,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-04-04T00:47:34.689Z","etag":null,"topics":["astro","documentation","starlight","typescript"],"latest_commit_sha":null,"homepage":"https://libar.dev/","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/libar-dev.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":"MAINTAINERS.md","copyright":null,"agents":"AGENTS.md","dco":null,"cla":null}},"created_at":"2026-01-26T10:29:56.000Z","updated_at":"2026-04-03T04:51:43.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/libar-dev/architect","commit_stats":null,"previous_names":["libar-dev/delivery-process"],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/libar-dev/architect","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/libar-dev%2Farchitect","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/libar-dev%2Farchitect/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/libar-dev%2Farchitect/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/libar-dev%2Farchitect/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/libar-dev","download_url":"https://codeload.github.com/libar-dev/architect/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/libar-dev%2Farchitect/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31383635,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-03T23:20:52.058Z","status":"ssl_error","status_checked_at":"2026-04-03T23:20:51.675Z","response_time":107,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["astro","documentation","starlight","typescript"],"created_at":"2026-04-04T00:47:33.958Z","updated_at":"2026-04-04T00:47:34.910Z","avatar_url":"https://github.com/libar-dev.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# @libar-dev/architect\n\n**Context engineering for AI-assisted codebases.**\n\nTurn TypeScript annotations and Gherkin specs into a **structured, queryable delivery state** — living documentation, architecture graphs, and FSM-enforced workflows that AI agents consume without hallucinating.\n\n[![npm version](https://img.shields.io/npm/v/@libar-dev/architect.svg)](https://www.npmjs.com/package/@libar-dev/architect)\n[![Build Status](https://github.com/libar-dev/delivery-process/workflows/CI/badge.svg)](https://github.com/libar-dev/delivery-process/actions)\n[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)\n[![Node.js Version](https://img.shields.io/node/v/@libar-dev/architect.svg)](https://nodejs.org/)\n\n---\n\n## Why This Exists\n\nAI coding agents need architectural context to generate correct code. This package makes **code the single source of truth** for both humans and machines — annotations in code and Gherkin specs replace manually maintained docs that drift out of date.\n\n---\n\n## Quick Start\n\n### 1. Install\n\n```bash\n# npm\nnpm install @libar-dev/architect@pre\n\n# pnpm (recommended)\npnpm add @libar-dev/architect@pre\n```\n\n**Requirements:** Node.js \u003e= 18.0.0, ESM project (`\"type\": \"module\"` in package.json)\n\n### 2. Annotate Your Code\n\n```typescript\n/** @architect */\n\n/**\n * @architect-pattern UserAuthentication\n * @architect-status roadmap\n * @architect-uses SessionManager, TokenValidator\n *\n * ## User Authentication\n *\n * Handles user login, logout, and session management.\n */\nexport class UserAuthentication {\n  // ...\n}\n```\n\n\u003e Tag prefix is configurable. The default `libar-generic` preset uses `@architect-*` (shown above). See [docs/CONFIGURATION.md](docs/CONFIGURATION.md).\n\n### 3. Generate Documentation\n\n```bash\nnpx architect-generate -g patterns -i \"src/**/*.ts\" -o docs -f\n```\n\n### 4. Enforce Workflow (Pre-commit Hook)\n\n```bash\nnpx architect-guard --staged\n```\n\nThis validates FSM transitions and blocks invalid status changes.\n\n---\n\n## How It Works\n\n**TypeScript annotations** define pattern metadata and relationships:\n\n```typescript\n/**\n * @architect\n * @architect-pattern TransformDataset\n * @architect-status completed\n * @architect-uses PatternGraph, ExtractedPattern, TagRegistry\n */\nexport function transformToPatternGraph(input: TransformInput): PatternGraph {\n  // ...\n}\n```\n\n**Gherkin feature files** own planning metadata (status, phase, deliverables). The generator merges both sources into a unified PatternGraph.\n\n**Pipeline:** `Config → Scanner → Extractor → Transformer → Codec` — files become patterns, patterns become a PatternGraph, the PatternGraph renders to Markdown and JSON.\n\n---\n\n## What Gets Generated\n\nAll output goes to [`docs-live/`](docs-live/INDEX.md) — 57+ auto-generated files from annotated source code:\n\n| Output                            | Files | Source                                                    |\n| --------------------------------- | ----: | --------------------------------------------------------- |\n| **Product area docs**             |     7 | `@architect-uses`, `@architect-status`, relationship tags |\n| **Business rules**                |     7 | Gherkin `Rule:` Invariant/Rationale blocks                |\n| **Architecture decisions (ADRs)** |     7 | Decision feature files                                    |\n| **Reference guides**              |     8 | CLI schema, codec patterns, annotations                   |\n| **Live Mermaid diagrams**         |     — | `@architect-uses`, `@architect-depends-on` relationships  |\n| **API type shapes**               |     — | `@architect-shape` on TypeScript declarations             |\n| **Validation rules**              |     3 | Process Guard FSM specs                                   |\n| **Taxonomy reference**            |     3 | Tag registry                                              |\n| **AI context modules**            |    13 | `@architect-claude-module` tagged specs                   |\n| **Changelog**                     |     1 | Release specs                                             |\n\n**Browse it:** [`docs-live/INDEX.md`](docs-live/INDEX.md) is the navigation hub with reading order, document roles, and product area statistics.\n\n---\n\n## CLI Commands\n\n| Command                   | Purpose                                                | Docs                                                                      |\n| ------------------------- | ------------------------------------------------------ | ------------------------------------------------------------------------- |\n| `architect-generate`      | Generate documentation from annotated sources          | `architect-generate --help`                                               |\n| `architect`               | Query delivery state for AI coding sessions            | [CLI Reference](docs-live/reference/CLI-REFERENCE.md)                     |\n| `architect-lint-patterns` | Validate annotation quality (missing tags, etc.)       | [Validation Rules](docs-live/VALIDATION-RULES.md)                         |\n| `architect-guard`         | Validate delivery workflow FSM transitions             | [Process Guard Reference](docs-live/reference/PROCESS-GUARD-REFERENCE.md) |\n| `architect-lint-steps`    | Validate vitest-cucumber feature/step compatibility    | [Validation Rules](docs-live/VALIDATION-RULES.md)                         |\n| `architect-validate`      | Cross-source validation with Definition of Done checks | [Validation Rules](docs-live/VALIDATION-RULES.md)                         |\n\n---\n\n## Documentation\n\n### Generated Docs (auto-maintained)\n\n**[`docs-live/INDEX.md`](docs-live/INDEX.md)** is the navigation hub — 57+ files generated from annotated source code, organized into product areas, reference guides, business rules, ADRs, taxonomy, and validation rules.\n\n### Editorial Docs (hand-maintained)\n\n| Document                                        | Focus                          |\n| ----------------------------------------------- | ------------------------------ |\n| [CONFIGURATION.md](docs/CONFIGURATION.md)       | Presets, tags, config files    |\n| [METHODOLOGY.md](docs/METHODOLOGY.md)           | Core thesis, dual-source \"why\" |\n| [GHERKIN-PATTERNS.md](docs/GHERKIN-PATTERNS.md) | Writing effective specs        |\n| [SESSION-GUIDES.md](docs/SESSION-GUIDES.md)     | Day-to-day AI/dev workflows    |\n| [VALIDATION.md](docs/VALIDATION.md)             | Automated quality checks       |\n\n---\n\n## License\n\nMIT © Libar AI\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flibar-dev%2Farchitect","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flibar-dev%2Farchitect","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flibar-dev%2Farchitect/lists"}