Repository navigation
docs: add curated AI context and maintenance guidance #18
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,20 @@ | ||
| # Architecture | ||
|
|
||
| The durable configuration is `workspace.yaml`: schema version, workspace name, | ||
| and repository entries with URL, default branch, and required/optional status. | ||
| `base_manifest.yaml` independently identifies this repository as a Base-managed | ||
| project and declares its validation command. | ||
|
|
||
| Base implements parsing, clone/update operations, status, checks, and diagnostics. | ||
| This repository supplies their input. No runtime service or package import is | ||
| needed to read the inventory. Standard contributor, issue, and CI files provide | ||
| repository governance rather than another workspace engine. | ||
|
|
||
| `tests/validate.sh` checks the repository baseline and the exact seven-repository | ||
| contract, including canonical URLs, main branches, required flags, and exclusions. | ||
| A deliberate inventory change therefore needs a matching test change and review; | ||
| adding a documentation pack does not change workspace membership. | ||
|
|
||
| Sources: [workspace.yaml](../workspace.yaml), [project manifest](../base_manifest.yaml), | ||
| [validation driver](../tests/validate.sh), and | ||
| [contribution guide](../CONTRIBUTING.md). |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,11 @@ | ||
| # base-workspace AI context index | ||
|
|
||
| Read in this order: | ||
|
|
||
| 1. [Project](PROJECT.md): purpose, audience, scope, and boundaries. | ||
| 2. [Architecture](ARCHITECTURE.md): components, contracts, and source map. | ||
| 3. [Workflows](WORKFLOWS.md): setup, validation, and contribution practices. | ||
| 4. [Maintenance](README.md): sources, update rules, and export behavior. | ||
|
|
||
| The pack is curated orientation. Canonical repository sources linked from each | ||
| page take precedence when exact implementation or policy details matter. | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,19 @@ | ||
| # Base workspace inventory | ||
|
|
||
| `base-workspace` maintains the version-controlled inventory for a canonical Base | ||
| workspace. It is a small manifest repository, not a runtime, application, or | ||
| replacement for the Base CLI. | ||
|
|
||
| `workspace.yaml` declares four required repositories: base, base-bash-libs, | ||
| base-cli, and base-workspace. It also declares three optional reference consumers: | ||
| base-demo, base-cli-demo, and base-bash-libs-demo. Optional demos support validation | ||
| and development without becoming prerequisites for a normal Base checkout. | ||
|
|
||
| Other repositories can coexist under the same local workspace root while | ||
| remaining outside this inventory. Directory discovery by `basectl projects list` | ||
| and manifest-selected workspace operations answer different questions. Use a | ||
| separate manifest to manage a different group; do not silently expand this | ||
| canonical inventory to every checkout on one person's machine. | ||
|
|
||
| Sources: [README](../README.md), [workspace manifest](../workspace.yaml), and | ||
| [manifest validation](../tests/validate.sh). |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,27 @@ | ||
| # AI context for base-workspace | ||
|
|
||
| This directory is the repository's curated orientation for AI-assisted work and | ||
| portable export. It summarizes verified repository behavior; it is not generated | ||
| runtime evidence or an authoritative release/status registry. Start with | ||
| [INDEX.md](INDEX.md). | ||
|
|
||
| Keep purpose, architecture, commands, and workflows aligned with code and | ||
| canonical documentation. Update the affected pages in the same meaningful PR; | ||
| for typo-only or internal changes with no contract impact, record no context | ||
| impact in the PR. Resolve disagreements by correcting this pack from its sources. | ||
| Do not copy credentials, local databases, private machine paths, personal records, | ||
| or transient logs into it. Link to evidence rather than copying runtime data. | ||
|
|
||
| From this checkout, with Base available: | ||
|
|
||
| ```bash | ||
| basectl export-context --list-files | ||
| basectl export-context --print | ||
| ``` | ||
|
|
||
| Markdown exports combine Markdown files in INDEX order, then append unlisted | ||
| files deterministically. Links outside this directory are source references; | ||
| the exporter does not inline their targets. Keep core explanations self-contained. | ||
| Use real regular files, not symlinks. Store generated bundles outside the project | ||
| and keep generation timestamps out of source pages so unchanged exports remain | ||
| byte-identical. This pack is picked up automatically by workspace export jobs. | ||
|
Collaborator
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Unverified claim: no "workspace export job" exists anywhere in this org. I searched this repo's CI ( |
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,27 @@ | ||
| # Workflows | ||
|
|
||
| With Base available, run the manifest-oriented read/plan commands from this | ||
| repository. Specify the intended workspace root when it differs from Base's | ||
|
Collaborator
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Instruction conflates |
||
| configured workspace: | ||
|
|
||
| ```bash | ||
| basectl workspace status --manifest workspace.yaml | ||
| basectl workspace check --manifest workspace.yaml | ||
| basectl workspace doctor --manifest workspace.yaml | ||
| basectl workspace clone --manifest workspace.yaml --dry-run | ||
| ./tests/validate.sh | ||
| git diff --check | ||
| ``` | ||
|
|
||
| A real clone creates local repositories. Optional demos require | ||
| `--include-optional`; their presence is not required for the normal workspace. | ||
| Review a plan before changing repositories, and preserve existing local work. | ||
| Use a separate inventory for unrelated personal or integration repositories. | ||
|
|
||
| Make inventory or documentation changes through an issue-backed canonical | ||
| branch and a dedicated worktree. Link the PR, record validation, and update | ||
| README/tests together when membership changes. Context-only updates do not | ||
| change VERSION, the workspace's repository set, or any sibling checkout. | ||
|
|
||
| Sources: [README commands](../README.md), [contribution guide](../CONTRIBUTING.md), | ||
| [workspace contract](../workspace.yaml), and [validation](../tests/validate.sh). | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -43,3 +43,17 @@ basectl check base-workspace | |
| basectl doctor base-workspace | ||
| basectl test base-workspace | ||
| ``` | ||
|
|
||
| ## AI Context Maintenance | ||
|
|
||
| Start AI-assisted orientation with [.ai-context/INDEX.md](.ai-context/INDEX.md). | ||
| Maintain these curated summaries alongside meaningful changes to product scope, | ||
|
Collaborator
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. New .ai-context maintenance obligation has no CI enforcement. |
||
| architecture, commands, or contributor workflows. Canonical docs and code remain | ||
| the source of truth; update the pack when they disagree. State context impact in | ||
|
Collaborator
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. PR template checklist wasn't updated to match this new rule. This line asks contributors to "state context impact in the PR," the same way the repo already requires for docs and CHANGELOG — but |
||
| the PR, including a reason when no update is needed. Typo-only and internal changes | ||
| without behavioral or architectural impact usually need no context update. | ||
|
|
||
| Validate changes with `basectl export-context --list-files` and | ||
| `basectl export-context --print` from the checkout, plus `git diff --check`. | ||
| Keep the pack self-contained enough for offline reading, free of secrets and | ||
| private runtime data, and independent of generated timestamps or export bundles. | ||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
INDEX.md doesn't self-reference, so it exports LAST despite being the stated entry point.
.ai-context/README.md(line 5-6) says "Start with INDEX.md," and the exporter (base_export_context/engine.py: ordered_context_files/index_references) builds Markdown-export order by parsing the markdown links/code-spans found insideINDEX.md, in order of appearance, then appends any unreferenced files alphabetically. Since thisINDEX.mdnever links to itself, it isn't in that reference list, so it gets appended at the end.\n\nI confirmed this by actually runningbasectl export-context --list-filesagainst this PR's worktree:\n\n.ai-context/PROJECT.md\n.ai-context/ARCHITECTURE.md\n.ai-context/WORKFLOWS.md\n.ai-context/README.md\n.ai-context/INDEX.md\n\nINDEX.md — the page meant to be read first — is last in the actual exported/printed bundle a reader or AI tool consumes viabasectl export-context --print. (Note: this same pattern already exists inbase-bash-libs/.ai-context/INDEX.md, so it's not unique to this PR, but it's being newly copied here too.)