Compare commits
4 Commits
integratio
...
1e65aadda9
Author | SHA1 | Date | |
---|---|---|---|
1e65aadda9 | |||
a00b6a8782 | |||
d381070c75 | |||
9cb1f5da1f |
7
AGENTS.md
Normal file
7
AGENTS.md
Normal file
@@ -0,0 +1,7 @@
|
||||
Agent Guidance (Repo Base)
|
||||
|
||||
- Use area prompt packs generated under `dist/prompts/`:
|
||||
- CTO: [dist/prompts/cto.md](dist/prompts/cto.md)
|
||||
- COO: [dist/prompts/coo.md](dist/prompts/coo.md)
|
||||
- To rebuild packs locally: `make prompts` (runs inside CI container).
|
||||
- Keep prompts modular and concise; favor COMMON modules and minimal area deltas.
|
16
BOOTSTRAP.md
Normal file
16
BOOTSTRAP.md
Normal file
@@ -0,0 +1,16 @@
|
||||
The purpose of this repository is to create a re-usable set of prompts for use in AI chat intefaces and with agentic AI.
|
||||
|
||||
This file is being created at the very start of the repository in an attempt to provide full traceability. It will be passed to codex as a prompt.
|
||||
|
||||
Codex instructions:
|
||||
|
||||
- Remain in planning mode only. Ask questions and gather data.
|
||||
- Create a propsoals directory and write out proposals to it for me to review and approve.
|
||||
- Do not undertake any work unless I ask you for a proposal and I approve the proposal.
|
||||
- Ask questions with numbers and allow them to be answered like 1:y 2:n or (for multiple choice) 1:a 2:b and so forth.
|
||||
- Keep the chat message output short. Use proposal files that I can view in my editor (vsCode).
|
||||
- The directory you are in is one level up from the git repository. This is so that git worktree can be used, to help mitigate issues with git branching. The repository is in a child directory called LLMScaffolding.
|
||||
|
||||
Your first concreate action:
|
||||
- Please help me establish a git workflow (via the proposal/approval process I have outlined). This workflow should follow best practices, it should presume the use of CI/CD via Gitea (Gitlab/Github are banned, never produce anything for those platforms).
|
||||
|
13
COMMON/README.md
Normal file
13
COMMON/README.md
Normal file
@@ -0,0 +1,13 @@
|
||||
COMMON
|
||||
|
||||
Purpose
|
||||
- Foundational, shared practices usable across projects.
|
||||
- Opinionated but adaptable; intended as a base layer.
|
||||
|
||||
Contents (initial)
|
||||
- Git workflow: [COMMON/git-workflow.md](git-workflow.md)
|
||||
- CI/bootstrap parity: [COMMON/bootstrap-cicd.md](bootstrap-cicd.md)
|
||||
- Documentation style: [COMMON/docs-style.md](docs-style.md)
|
||||
|
||||
Notes
|
||||
- Keep content generic and reusable; project-specific overrides should live in the target repo.
|
21
COMMON/bootstrap-cicd.md
Normal file
21
COMMON/bootstrap-cicd.md
Normal file
@@ -0,0 +1,21 @@
|
||||
Local CI Parity & Bootstrap
|
||||
|
||||
Purpose
|
||||
- Provide a portable CI toolchain via a Dockerized image and compose file so that format/lint/build checks run identically locally and in CI.
|
||||
|
||||
Components
|
||||
- `ci.Dockerfile` – builds the CI image with shellcheck, shfmt, hadolint, actionlint, yamllint, Node tools.
|
||||
- `docker/ci.compose.yml` – runs the CI container mounting the repo at `/workspace`.
|
||||
- `scripts/ci` – wrapper for phases: `format`, `lint`, `build`, `test`, `security`, `all`.
|
||||
- Git hooks – `.githooks/*` installed via `scripts/setup-hooks`.
|
||||
|
||||
Usage
|
||||
- Install hooks: `make hooks-setup`
|
||||
- Quick checks: `make quick` (format + lint)
|
||||
- Full pass: `make check` (all phases)
|
||||
|
||||
Notes
|
||||
- Pre-commit hook runs format/lint and commit message checks.
|
||||
- Pre-push hook runs build/test/security placeholders.
|
||||
- CI workflow runs on integration and protected branches when runners are enabled.
|
||||
|
8
COMMON/docs-style.md
Normal file
8
COMMON/docs-style.md
Normal file
@@ -0,0 +1,8 @@
|
||||
Documentation Style Guide
|
||||
|
||||
- When referencing another Markdown file in this repo, use a relative link so it is clickable in Gitea. Example: [COMMON/git-workflow.md](COMMON/git-workflow.md).
|
||||
- Keep titles concise and descriptive; use sentence case unless a proper noun.
|
||||
- Prefer short bullets (one point per line). Merge related points.
|
||||
- Use backticks for commands, file paths, env vars, and code identifiers.
|
||||
- Make documents actionable: lead with outcomes, then steps, then background.
|
||||
|
@@ -1,6 +1,6 @@
|
||||
COO Agent Pack
|
||||
|
||||
Use the generated pack for agents: [dist/prompts/coo.md](dist/prompts/coo.md).
|
||||
Use the generated pack for agents: [dist/prompts/coo.md](../../dist/prompts/coo.md).
|
||||
|
||||
Includes (via COMMON base):
|
||||
- System persona, style, safety
|
||||
|
@@ -1,6 +1,6 @@
|
||||
CTO Agent Pack
|
||||
|
||||
Use the generated pack for agents: [dist/prompts/cto.md](dist/prompts/cto.md).
|
||||
Use the generated pack for agents: [dist/prompts/cto.md](../../dist/prompts/cto.md).
|
||||
|
||||
Includes (via COMMON base):
|
||||
- System persona, style, safety
|
||||
|
@@ -7,8 +7,8 @@ Layout
|
||||
- COMMON/ CTO/ COO/ CCO/ — questions, proposals, and prompt modules only
|
||||
- scripts/ — Makefile and helper scripts
|
||||
- docker/ — CI compose and Dockerfile
|
||||
- CTO/dist/prompts/ and COO/dist/prompts/ — generated prompt packs
|
||||
- COMMON/proposals/, COMMON/questions/ — planning artifacts
|
||||
- dist/prompts/ — generated prompt packs (cto.md, coo.md)
|
||||
- proposals/, questions/ — repository planning artifacts
|
||||
|
||||
Quickstart
|
||||
- Install hooks: `make -f scripts/Makefile hooks-setup`
|
||||
|
0
dist/prompts/coo.md
vendored
Normal file
0
dist/prompts/coo.md
vendored
Normal file
0
dist/prompts/cto.md
vendored
Normal file
0
dist/prompts/cto.md
vendored
Normal file
@@ -1,42 +0,0 @@
|
||||
DISCUSSION – Areas, Structure, Ownership
|
||||
|
||||
Context
|
||||
- This repo hosts generic, foundational practices reusable across projects.
|
||||
- Areas: COMMON (shared practices), CTO (shared technical standards), COO (business ops), CCO (deferred; placeholder only).
|
||||
|
||||
Decisions Confirmed
|
||||
- Area directories are uppercase: COMMON, CTO, COO, CCO.
|
||||
- Shared practices and base guidance live under COMMON.
|
||||
- CCO is deferred for now; placeholder directory only.
|
||||
|
||||
Open Questions to Confirm
|
||||
- Naming conventions within areas
|
||||
- File naming: keep kebab-case (e.g., [COMMON/git-workflow.md](COMMON/git-workflow.md)) or use TitleCase?
|
||||
- Per-area `README.md` vs. `INDEX.md` expectations.
|
||||
- Scope boundaries
|
||||
- COMMON: include Git workflow, CI/bootstrap parity, templates (PR/issue), documentation style guide, ADR pattern, security/privacy baselines?
|
||||
- CTO: preferred tech stacks, language/runtime versions, container base image policy, local dev environment patterns (devcontainers/Make), testing strategy, quality bars?
|
||||
- COO: operating rhythm (cadences, ceremonies), roles/RACI, OKR/KPI templates, onboarding, procurement/vendor-lite guidance, documentation templates?
|
||||
- CCO: when in scope, include customer journey templates, support/SLA baselines, enablement playbooks, feedback loops? Any overlap rules with COO/CTO?
|
||||
- Consumers and audience
|
||||
- Internal only or some content public-facing? Any confidentiality/compliance constraints (esp. COO/CCO)?
|
||||
- Reuse strategy
|
||||
- Copy into new repos vs. reference centrally? Provide “adoption guides” per area? Offer minimal vs. advanced profiles?
|
||||
- Ownership & change control
|
||||
- CODEOWNERS per area? Who approves updates across COMMON/CTO/COO?
|
||||
- Labels and PR templates per area; contribution guidelines?
|
||||
- Document shape and standards
|
||||
- Prescriptive checklists vs. narrative guidance; include “10-minute quickstart” per area?
|
||||
- Standardize front‑matter, headers, and ADR structure?
|
||||
- Cross‑cutting policies
|
||||
- Where to maintain shared policies (security, privacy, accessibility) — under COMMON?
|
||||
- CI for docs
|
||||
- Keep current markdown/yaml linters repo‑wide; add link checker/spellcheck?
|
||||
- Migration of existing docs
|
||||
- Which existing files beyond Git workflow and CI bootstrap should move under COMMON now vs. later (e.g., proposals, questions, [RESUME.md](RESUME.md), [TODO.md](TODO.md))?
|
||||
|
||||
Proposed Next Steps (pending answers)
|
||||
- Seed per‑area README with scope, audiences, adoption guidance.
|
||||
- Create COMMON/templates/ for reusable checklists, PR/issue templates, ADRs.
|
||||
- Map/move additional shared docs into COMMON and update references.
|
||||
- Define CODEOWNERS and contribution norms per area.
|
@@ -48,5 +48,6 @@ Branches on remote
|
||||
- Track in [docs/TODO.md](TODO.md): Revisit enabling runners and protected checks on 2025-09-24
|
||||
|
||||
10) Next tasks
|
||||
- Answer any outstanding questions in COMMON/questions/*
|
||||
- Answer any outstanding questions in questions/*
|
||||
- On approval, implement further proposals and update instructions/*
|
||||
|
||||
|
@@ -12,7 +12,7 @@ TODO
|
||||
|
||||
- CI/CD bootstrap
|
||||
- [x] Create branch bootstrap-cicd from main
|
||||
- [x] Add questions at [COMMON/questions/bootstrap-cicd.md](../COMMON/questions/bootstrap-cicd.md)
|
||||
- [x] Add questions at [questions/bootstrap-cicd.md](../questions/bootstrap-cicd.md)
|
||||
- [x] Draft proposal based on answers
|
||||
- [x] Implement parity tooling: scripts/ci, docker/ci.Dockerfile, docker/ci.compose.yml
|
||||
- [x] Add .gitea/workflows: ci.yml, release.yml, nightly.yml
|
||||
|
@@ -1,31 +1,9 @@
|
||||
#!/usr/bin/env python3
|
||||
import os, sys
|
||||
import os, sys, yaml
|
||||
|
||||
def load_manifest(path):
|
||||
# Minimal YAML parser for our simple manifests:
|
||||
# keys: name (ignored), include: [..], modules: [..]
|
||||
data = {"include": [], "modules": []}
|
||||
key = None
|
||||
with open(path, 'r', encoding='utf-8') as f:
|
||||
for raw in f:
|
||||
line = raw.rstrip('\n')
|
||||
s = line.strip()
|
||||
if not s or s.startswith('#'):
|
||||
continue
|
||||
if s.startswith('include:'):
|
||||
key = 'include'
|
||||
continue
|
||||
if s.startswith('modules:'):
|
||||
key = 'modules'
|
||||
continue
|
||||
if s.startswith('name:'):
|
||||
key = None
|
||||
continue
|
||||
# list item under current key
|
||||
if key in ('include', 'modules') and s.startswith('- '):
|
||||
item = s[2:].strip()
|
||||
data[key].append(item)
|
||||
return data
|
||||
return yaml.safe_load(f)
|
||||
|
||||
def resolve(path, seen):
|
||||
m = load_manifest(path)
|
||||
@@ -50,8 +28,7 @@ def main():
|
||||
if not mods:
|
||||
print(f"No modules resolved from {manifest}", file=sys.stderr)
|
||||
sys.exit(1)
|
||||
if out_path != '-':
|
||||
os.makedirs(os.path.dirname(out_path), exist_ok=True)
|
||||
os.makedirs(os.path.dirname(out_path), exist_ok=True)
|
||||
def read(p):
|
||||
with open(p, 'r', encoding='utf-8') as f:
|
||||
return f.read().strip() + "\n\n"
|
||||
|
@@ -7,7 +7,7 @@ Usage: scripts/prompts <command> [args]
|
||||
|
||||
Commands:
|
||||
build <manifest> <output> Build a flattened prompt from a manifest
|
||||
pack <area> Build known area pack (cto|coo) into area dist/
|
||||
pack <area> Build known area pack (cto|coo) into dist/prompts
|
||||
all Build all known area packs
|
||||
lint Lint prompts (budgets and includes)
|
||||
USAGE
|
||||
@@ -28,15 +28,11 @@ ci_run() {
|
||||
build_manifest() {
|
||||
local manifest=$1 out=$2 root
|
||||
root="$(repo_root)"
|
||||
mkdir -p "$root/dist/prompts"
|
||||
# Write on host to avoid ownership issues; container prints to stdout.
|
||||
TMP_OUT=$(mktemp)
|
||||
trap '[[ -n "${TMP_OUT:-}" ]] && rm -f "$TMP_OUT"' EXIT
|
||||
ci_run "python3 scripts/prompt_build.py '$manifest' -" >"$TMP_OUT" || true
|
||||
# Fallback: if container produced no output, run on host
|
||||
if [[ ! -s "$TMP_OUT" ]]; then
|
||||
python3 scripts/prompt_build.py "$manifest" - >"$TMP_OUT"
|
||||
fi
|
||||
mkdir -p "$(dirname "$out")"
|
||||
ci_run "python3 scripts/prompt_build.py '$manifest' -" >"$TMP_OUT"
|
||||
mv "$TMP_OUT" "$out"
|
||||
}
|
||||
|
||||
@@ -48,12 +44,12 @@ case "$cmd" in
|
||||
pack)
|
||||
shift; area=${1:-}; root="$(repo_root)"
|
||||
case "$area" in
|
||||
cto) build_manifest "$root/COMMON/prompt/manifests/cto.yaml" "$root/CTO/dist/prompts/cto.md" ;;
|
||||
coo) build_manifest "$root/COMMON/prompt/manifests/coo.yaml" "$root/COO/dist/prompts/coo.md" ;;
|
||||
cto) build_manifest "$root/COMMON/prompt/manifests/cto.yaml" "$root/dist/prompts/cto.md" ;;
|
||||
coo) build_manifest "$root/COMMON/prompt/manifests/coo.yaml" "$root/dist/prompts/coo.md" ;;
|
||||
*) echo "Unknown area: $area" >&2; exit 2 ;;
|
||||
esac ;;
|
||||
all)
|
||||
root="$(repo_root)"
|
||||
root="$(repo_root)"; mkdir -p "$root/dist/prompts"
|
||||
"$0" pack cto
|
||||
"$0" pack coo ;;
|
||||
lint)
|
||||
|
Reference in New Issue
Block a user