feat: add USER.md and TOOLS.md to bootstrap framework

Introduce user profile (USER.md) and machine tool reference (TOOLS.md)
as first-class framework files. Both ship as generic defaults and are
personalized via mosaic init.

- Add USER.md/TOOLS.md defaults and parameterized templates
- Update AGENTS.md load order (6 → 8 steps)
- Update SOUL.md: default name "Assistant", add trash/mental-notes guardrails
- Update install.sh: preserve USER.md/TOOLS.md on reinstall
- Update mosaic-init: interactive USER.md + TOOLS.md generation
- Update mosaic-doctor: existence checks for new files
- Update mosaic launcher: inject USER.md/TOOLS.md into runtime prompt
- Update README: architecture diagram, generic-repo policy note

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-02-21 11:36:16 -06:00
parent e3ec3e32e5
commit 9ccd13fae7
12 changed files with 454 additions and 30 deletions

View File

@@ -35,6 +35,8 @@ If asked "who are you?", answer:
- Do not perform destructive actions without explicit instruction.
- Do not silently change intent, scope, or definitions.
- Do not create fake policy by writing canned responses for every prompt.
- Prefer `trash` over `rm` when available — recoverable beats gone forever.
- Write decisions and learnings to files — "mental notes" do not survive session restarts.
{{CUSTOM_GUARDRAILS}}
## Why This Exists

View File

@@ -0,0 +1,56 @@
# Machine-Level Tool Reference
Centralized reference for tools, credentials, and CLI patterns available across all projects.
Project-specific tooling belongs in the project's `AGENTS.md`, not here.
## Mosaic Git Wrappers (Use First)
Mosaic wrappers at `~/.config/mosaic/rails/git/*.sh` handle platform detection and edge cases. Always use these before raw CLI commands.
```bash
# Issues
~/.config/mosaic/rails/git/issue-create.sh
~/.config/mosaic/rails/git/issue-close.sh
# PRs
~/.config/mosaic/rails/git/pr-create.sh
~/.config/mosaic/rails/git/pr-merge.sh
# Milestones
~/.config/mosaic/rails/git/milestone-create.sh
# CI queue guard (required before push/merge)
~/.config/mosaic/rails/git/ci-queue-wait.sh --purpose push|merge
```
## Code Review (Codex)
```bash
# Code quality review
~/.config/mosaic/rails/codex/codex-code-review.sh --uncommitted
# Security review
~/.config/mosaic/rails/codex/codex-security-review.sh --uncommitted
```
## Git Providers
{{GIT_PROVIDERS_TABLE}}
## Credentials
**Location:** {{CREDENTIALS_LOCATION}}
**Never expose actual values. Never commit credential files.**
## CLI Gotchas
(Add platform-specific CLI gotchas as you discover them.)
{{CUSTOM_TOOLS_SECTION}}
## Safety Defaults
- Prefer `trash` over `rm` when available — recoverable beats gone forever
- Never run destructive commands without explicit instruction
- Write it down — "mental notes" don't survive session restarts; files do

View File

@@ -0,0 +1,30 @@
# User Profile
This file defines user-specific context for all agent sessions.
It is loaded globally and applies regardless of runtime or project.
## Identity
- **Name:** {{USER_NAME}}
- **Pronouns:** {{PRONOUNS}}
- **Timezone:** {{TIMEZONE}}
## Background
{{BACKGROUND}}
## Accessibility
{{ACCESSIBILITY_SECTION}}
## Communication Preferences
{{COMMUNICATION_PREFS}}
## Personal Boundaries
{{PERSONAL_BOUNDARIES}}
## Current Projects
{{PROJECTS_TABLE}}