fips-agents-cli 0.7.0__tar.gz → 0.9.1__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (65) hide show
  1. fips_agents_cli-0.9.1/.github/CODEOWNERS +2 -0
  2. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/.gitignore +4 -0
  3. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/CLAUDE.md +21 -5
  4. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/PKG-INFO +116 -38
  5. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/README.md +115 -37
  6. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/pyproject.toml +1 -1
  7. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/scripts/release.sh +27 -6
  8. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/src/fips_agents_cli/cli.py +2 -0
  9. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/src/fips_agents_cli/commands/create.py +33 -1
  10. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/src/fips_agents_cli/commands/patch.py +50 -27
  11. fips_agents_cli-0.9.1/src/fips_agents_cli/commands/vendor.py +154 -0
  12. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/src/fips_agents_cli/tools/git.py +10 -1
  13. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/src/fips_agents_cli/tools/patching.py +156 -26
  14. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/src/fips_agents_cli/tools/project.py +147 -6
  15. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/src/fips_agents_cli/tools/validation.py +41 -2
  16. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/src/fips_agents_cli/version.py +1 -1
  17. fips_agents_cli-0.9.1/tests/fixtures/middleware_template/component.py.j2 +39 -0
  18. fips_agents_cli-0.9.1/tests/fixtures/middleware_template/test.py.j2 +40 -0
  19. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/tests/test_create.py +4 -4
  20. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/tests/test_generate.py +117 -0
  21. fips_agents_cli-0.9.1/tests/test_patch.py +295 -0
  22. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/.claude/commands/create-release.md +0 -0
  23. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/.claude/docs-state.json +0 -0
  24. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/.github/agents/README.md +0 -0
  25. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/.github/agents/create-release.agent.md +0 -0
  26. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/.github/workflows/test.yml +0 -0
  27. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/.github/workflows/workflow.yaml +0 -0
  28. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/LICENSE +0 -0
  29. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/RELEASE_CHECKLIST.md +0 -0
  30. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/docs/PUBLISHING.md +0 -0
  31. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/docs/QUICK_START_PUBLISHING.md +0 -0
  32. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/docs/README.md +0 -0
  33. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/llms.txt +0 -0
  34. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/planning/AGENT_FRAMEWORK_PLAN.md +0 -0
  35. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/planning/GENERATOR_IMPLEMENTATION_PLAN.md +0 -0
  36. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/planning/IMPLEMENTATION_SUMMARY.md +0 -0
  37. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/planning/MVP-PLAN.md +0 -0
  38. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/planning/PLAN.md +0 -0
  39. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/planning/PROMPT_ISSUE.md +0 -0
  40. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/planning/agent-registry-roadmap.md +0 -0
  41. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/planning/agent-template-gaps.md +0 -0
  42. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/planning/composable-agent-capabilities.md +0 -0
  43. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/research/BAML_RESEARCH_REPORT.md +0 -0
  44. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/research/Ignite-CLI-Architecture-Analysis.md +0 -0
  45. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/retrospectives/2026-04-06_issue-triage-v0.3.0/RETRO.md +0 -0
  46. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/retrospectives/2026-04-10_full-stack-integration/RETRO.md +0 -0
  47. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/scripts/README.md +0 -0
  48. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/src/fips_agents_cli/__init__.py +0 -0
  49. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/src/fips_agents_cli/__main__.py +0 -0
  50. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/src/fips_agents_cli/commands/__init__.py +0 -0
  51. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/src/fips_agents_cli/commands/add.py +0 -0
  52. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/src/fips_agents_cli/commands/generate.py +0 -0
  53. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/src/fips_agents_cli/commands/model_car.py +0 -0
  54. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/src/fips_agents_cli/tools/__init__.py +0 -0
  55. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/src/fips_agents_cli/tools/filesystem.py +0 -0
  56. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/src/fips_agents_cli/tools/generators.py +0 -0
  57. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/src/fips_agents_cli/tools/github.py +0 -0
  58. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/tests/__init__.py +0 -0
  59. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/tests/conftest.py +0 -0
  60. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/tests/test_filesystem.py +0 -0
  61. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/tests/test_generators.py +0 -0
  62. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/tests/test_github.py +0 -0
  63. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/tests/test_model_car.py +0 -0
  64. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/tests/test_project.py +0 -0
  65. {fips_agents_cli-0.7.0 → fips_agents_cli-0.9.1}/tests/test_validation.py +0 -0
@@ -0,0 +1,2 @@
1
+ # Code Owners - all PRs require approval from @rdwj
2
+ * @rdwj
@@ -25,6 +25,7 @@ MANIFEST
25
25
 
26
26
  # Virtual environments
27
27
  venv/
28
+ .venv/
28
29
  env/
29
30
  ENV/
30
31
  env.bak/
@@ -88,3 +89,6 @@ tokens.txt
88
89
 
89
90
  # Project specific
90
91
  setup_structure.sh
92
+
93
+ # Session handoff notes (local-only — content lives in MEMORY.md)
94
+ NEXT_SESSION.md
@@ -6,7 +6,12 @@ This file provides guidance to Claude Code (claude.ai/code) when working with co
6
6
 
7
7
  **fips-agents-cli** is a Python-based CLI tool for scaffolding FIPS-compliant AI agent projects. It scaffolds MCP (Model Context Protocol) servers and AI agent projects from production-ready templates, customizes them for new projects, and prepares them for immediate development use.
8
8
 
9
- **Current Status:** `create mcp-server` and `create agent` commands implemented.
9
+ **Current Status:** Scaffolding commands implemented: `create mcp-server`, `create agent`, `create gateway`, `create ui`, `create sandbox`, `create model-car`. Post-scaffolding commands: `generate` (tool, resource, prompt, middleware), `patch` (check, all + type-specific category subcommands — see below), `add` (code-executor), `vendor`. Note: `create workflow` exists in code but is not yet working.
10
+
11
+ The `patch` command is type-aware via `template.type` in `.template-info`:
12
+ - **MCP server** projects expose `patch generators | core | docs | build`.
13
+ - **Agent / workflow** projects expose `patch chart | docs | build | claude`.
14
+ Running an MCP-only subcommand inside an agent project (or vice versa) exits with a clear "available categories" error. `patch check` and `patch all` work for any supported type.
10
15
 
11
16
  ## Development Commands
12
17
 
@@ -91,18 +96,25 @@ This command will:
91
96
 
92
97
  ```bash
93
98
  # 1. Update version in both files manually or use the script:
94
- ./scripts/release.sh <version> "<commit-message>"
99
+ ./scripts/release.sh <version> [<summary>]
95
100
 
96
- # Example:
101
+ # Examples:
102
+ ./scripts/release.sh 0.1.2
97
103
  ./scripts/release.sh 0.1.2 "Add new generator features"
98
104
 
99
105
  # The script handles:
100
106
  # - Updating version.py and pyproject.toml
107
+ # - Constructing the release commit message from the project convention
101
108
  # - Committing changes (including README.md changelog)
102
109
  # - Creating and pushing tag
103
110
  # - Triggering GitHub Actions
104
111
  ```
105
112
 
113
+ **Release commit message convention**: `chore: Release fips-agents-cli vX.Y.Z`,
114
+ optionally followed by ` — <summary>`. The script always constructs the message
115
+ from the version argument; callers only supply the summary, never the full
116
+ message. This keeps `git log --grep "Release fips-agents-cli"` reliable.
117
+
106
118
  **Note**: Always update the changelog in README.md before running the script.
107
119
 
108
120
  See `RELEASE_CHECKLIST.md` for detailed release procedures and troubleshooting.
@@ -141,7 +153,7 @@ Two cloning strategies exist:
141
153
  1. Clone monorepo, extract `templates/agent-loop/` subdirectory
142
154
  2. Update `pyproject.toml` name field via tomlkit
143
155
  3. String-replace `agent-template` → new name in Chart.yaml, values.yaml, AGENTS.md, Containerfile, Makefile
144
- 4. Source directories are NOT renamed — `base_agent` is a framework component
156
+ 4. Source directories are NOT renamed — the agent-loop template ships with `src/agent.py` directly, not a project-named module
145
157
  5. Initialize fresh git repository with initial commit
146
158
 
147
159
  **Rich Console Output**: All user-facing output uses Rich library for:
@@ -272,7 +284,7 @@ def test_something(temp_dir):
272
284
 
273
285
  **Agent Template** (`fips-agents/agent-template` — monorepo, `templates/agent-loop/`):
274
286
  - `pyproject.toml` with project name (no entry point scripts)
275
- - `src/base_agent/` framework (NOT renamed during customization)
287
+ - `src/agent.py` user agent subclass (lives at this path directly — no project-named module wrapper)
276
288
  - `chart/` Helm chart for OpenShift deployment
277
289
  - `agent.yaml` configuration (customized via `/plan-agent`, not during scaffolding)
278
290
  - `.claude/commands/` with agent development slash commands
@@ -325,6 +337,10 @@ Common causes:
325
337
  2. Dependencies not installed: `pip install -e .[dev]`
326
338
  3. Git not configured globally: `git config --global user.email "test@example.com"`
327
339
 
340
+ ## Release Process Notes
341
+
342
+ When creating a new release, always update the changelog in README.md *before* running the release script. The changelog lives in the README under the `## Changelog` heading. Each version should have its own section with the version number and date, listing new features, fixes, and breaking changes. Forgetting the changelog entry leads to patch releases (like v0.8.1) that exist solely to backfill documentation — avoid that by treating the changelog update as a required step in every release.
343
+
328
344
  ## Repository-Specific Notes
329
345
 
330
346
  - The main branch is `main` (not `master`)
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: fips-agents-cli
3
- Version: 0.7.0
3
+ Version: 0.9.1
4
4
  Summary: CLI tool for creating and managing FIPS-compliant AI agent projects
5
5
  Project-URL: Homepage, https://github.com/fips-agents/fips-agents-cli
6
6
  Project-URL: Repository, https://github.com/fips-agents/fips-agents-cli
@@ -145,6 +145,7 @@ fips-agents add --help
145
145
  fips-agents create --help
146
146
  fips-agents generate --help
147
147
  fips-agents patch --help
148
+ fips-agents vendor --help
148
149
  ```
149
150
 
150
151
  ---
@@ -216,6 +217,12 @@ Creates an AI agent project from the [agent-template](https://github.com/fips-ag
216
217
 
217
218
  **Options:** Same as `create mcp-server` (see shared options table above).
218
219
 
220
+ **Additional option:**
221
+
222
+ | Option | Description |
223
+ |--------|-------------|
224
+ | `--vendored` | Copy fipsagents source into the project instead of using PyPI dependency |
225
+
219
226
  **Examples:**
220
227
 
221
228
  ```bash
@@ -227,6 +234,9 @@ fips-agents create agent my-agent --github --org fips-agents
227
234
 
228
235
  # Non-interactive mode
229
236
  fips-agents create agent my-agent --yes --local
237
+
238
+ # Create with vendored fipsagents source
239
+ fips-agents create agent my-agent --vendored --local
230
240
  ```
231
241
 
232
242
  #### `create gateway`
@@ -547,7 +557,9 @@ When using `--params` with `generate tool` or `generate prompt`, provide a JSON
547
557
 
548
558
  ### Patch Commands
549
559
 
550
- The `patch` command group updates files in existing MCP server projects from the upstream template repository without overwriting your custom code. It shows interactive diffs for files that may contain customizations.
560
+ The `patch` command group updates files in existing projects from the upstream template repository without overwriting your custom code. It shows interactive diffs for files that may contain customizations.
561
+
562
+ Supported project types: **MCP server**, **agent**, **workflow**. The available category subcommands depend on the project type — `patch` reads `template.type` from `.template-info` and surfaces a clear error if you run a category that doesn't apply (e.g. `patch generators` inside an agent project).
551
563
 
552
564
  Run these commands from within your project directory.
553
565
 
@@ -557,47 +569,35 @@ Run these commands from within your project directory.
557
569
  fips-agents patch check
558
570
  ```
559
571
 
560
- Check for available template updates. Shows what files have changed in the template since your project was created, organized by category.
561
-
562
- #### `patch generators`
563
-
564
- ```bash
565
- fips-agents patch generators [--dry-run]
566
- ```
567
-
568
- Update code generator templates (Jinja2 templates in `.fips-agents-cli/generators/`).
569
-
570
- #### `patch core`
571
-
572
- ```bash
573
- fips-agents patch core [--dry-run]
574
- ```
575
-
576
- Update core infrastructure files (loaders, server bootstrap).
572
+ Check for available template updates. Shows what files have changed in the template since your project was created, organized by category. Works for any supported project type.
577
573
 
578
- #### `patch docs`
574
+ #### `patch all`
579
575
 
580
576
  ```bash
581
- fips-agents patch docs [--dry-run]
577
+ fips-agents patch all [--dry-run] [--skip-confirmation]
582
578
  ```
583
579
 
584
- Update documentation files and examples.
580
+ Update every category that applies to the current project type. Prompts for confirmation before starting unless `--skip-confirmation` is passed.
585
581
 
586
- #### `patch build`
582
+ #### MCP server categories
587
583
 
588
- ```bash
589
- fips-agents patch build [--dry-run]
590
- ```
584
+ | Subcommand | Patches |
585
+ |----------------------|--------------------------------------------------------------------------|
586
+ | `patch generators` | Jinja2 templates in `.fips-agents-cli/generators/` |
587
+ | `patch core` | Core infrastructure (loaders, server bootstrap) |
588
+ | `patch docs` | Documentation files and examples |
589
+ | `patch build` | Build and deployment files (Makefile, Containerfile) |
591
590
 
592
- Update build and deployment files (Makefile, Containerfile).
591
+ #### Agent / workflow categories
593
592
 
594
- #### `patch all`
593
+ | Subcommand | Patches |
594
+ |----------------|-------------------------------------------------------------------------------|
595
+ | `patch chart` | Helm chart templates (`chart/templates/**`, `chart/Chart.yaml`) |
596
+ | `patch docs` | `CLAUDE.md`, `AGENTS.md`, `docs/**` |
597
+ | `patch build` | `Makefile`, `Containerfile`, `deploy.sh`, `redeploy.sh` |
598
+ | `patch claude` | Claude Code slash commands shipped with the template (`.claude/commands/**`) |
595
599
 
596
- ```bash
597
- fips-agents patch all [--dry-run] [--skip-confirmation]
598
- ```
599
-
600
- Update all patchable file categories at once. Prompts for confirmation before starting unless `--skip-confirmation` is passed.
600
+ User-customized files are never patched: for MCP this means `src/tools/`, `src/resources/`, `src/prompts/`, `src/middleware/`, `pyproject.toml`, etc. For agent/workflow it means `src/agent.py`, `agent.yaml`, `chart/values.yaml`, `src/fipsagents/**` (managed by `fips-agents vendor`), and `pyproject.toml`.
601
601
 
602
602
  All patch subcommands (except `check`) accept `--dry-run` to preview changes without modifying files.
603
603
 
@@ -635,6 +635,45 @@ cd my-research-agent
635
635
  fips-agents add code-executor
636
636
  ```
637
637
 
638
+ ---
639
+
640
+ ### Vendor Commands
641
+
642
+ The `vendor` command copies the fipsagents source into your agent project, replacing the PyPI dependency. This gives you full control over the fipsagents code.
643
+
644
+ #### `vendor`
645
+
646
+ ```bash
647
+ fips-agents vendor [OPTIONS]
648
+ ```
649
+
650
+ Copies fipsagents source into `src/fipsagents/` and rewrites `pyproject.toml` to use individual dependencies instead of the fipsagents package.
651
+
652
+ **Options:**
653
+
654
+ | Option | Description |
655
+ |--------|-------------|
656
+ | `--update` | Update an already-vendored project with the latest upstream source |
657
+ | `--version TEXT` | Vendor a specific version tag (e.g., `fipsagents-v0.7.0`). Default: latest main |
658
+
659
+ **Examples:**
660
+
661
+ ```bash
662
+ # Vendor into current project
663
+ fips-agents vendor
664
+
665
+ # Vendor a specific version
666
+ fips-agents vendor --version fipsagents-v0.7.0
667
+
668
+ # Update vendored source from upstream
669
+ fips-agents vendor --update
670
+ ```
671
+
672
+ **When to use vendored vs. PyPI:**
673
+
674
+ - **PyPI dependency** (default): Best for teams running multiple agents that share the same fipsagents version. Centralized updates.
675
+ - **Vendored source**: Best for agents that need custom BaseAgent modifications, environments with no PyPI access, or when you want to read and debug the fipsagents source locally.
676
+
638
677
  ## Project Name Requirements
639
678
 
640
679
  Project names must follow these rules:
@@ -663,10 +702,9 @@ pytest
663
702
 
664
703
  ```bash
665
704
  cd my-research-agent
666
- python -m venv venv
667
- source venv/bin/activate
668
- pip install -e .[dev]
669
- pytest
705
+ make install # Create venv, install dependencies
706
+ make run-local # Start HTTP server on port 8080
707
+ make test # Run tests
670
708
  # See AGENTS.md for the /plan-agent slash command workflow
671
709
  ```
672
710
 
@@ -778,7 +816,8 @@ fips-agents-cli/
778
816
  │ │ ├── create.py # create mcp-server, agent, gateway, ui
779
817
  │ │ ├── generate.py # generate tool/resource/prompt/middleware
780
818
  │ │ ├── model_car.py # create model-car
781
- │ │ └── patch.py # patch command
819
+ │ │ ├── patch.py # patch command
820
+ │ │ └── vendor.py # vendor fipsagents source
782
821
  │ └── tools/ # Utility modules
783
822
  │ ├── filesystem.py
784
823
  │ ├── git.py
@@ -897,6 +936,45 @@ MIT License - see LICENSE file for details
897
936
 
898
937
  ## Changelog
899
938
 
939
+ ### Version 0.9.1
940
+
941
+ - Chore: Realign `tests/` formatting with black 26.3.1 to match CI (v0.9.0's release pipeline failed because local black 24.x produced different output than CI's 26.x; no functional change)
942
+
943
+ ### Version 0.9.0
944
+
945
+ - Feature: `fips-agents patch` now supports agent and workflow projects in addition to MCP servers (#12)
946
+ - Feature: New `patch chart` and `patch claude` subcommands for agent/workflow projects (#15)
947
+ - Feature: `.template-info` now records `template.type` and (for monorepo templates) `template.subdir` so post-scaffolding commands can route by project type (#13)
948
+ - Feature: New `find_fips_project_root()` walks up to `.template-info`, replacing the MCP-only fastmcp-dependency probe in patch commands (#14)
949
+ - Improvement: `_clone_template_for_patch()` resolves the monorepo subdir during patching, so glob/compare runs against `templates/agent-loop/` instead of the monorepo root (#16)
950
+ - Improvement: Running an MCP-only subcommand inside an agent project (or vice versa) now exits with a clear "available categories" error
951
+ - Improvement: `patch all` enumerates the project's actual category set instead of assuming MCP layout
952
+ - Backwards compat: Projects scaffolded before `template.type` existed default to `mcp-server`; no migration required
953
+ - Tests: 20 new tests in `tests/test_patch.py` covering the type-aware patch flow end-to-end against a fake-scaffolded agent project
954
+
955
+ ### Version 0.8.2
956
+
957
+ - Test: New `TestGenerateMiddlewareRealTemplate` integration test renders the real v3.x middleware Jinja2 template against each `--hook-type` and the no-flag case, with templates committed under `tests/fixtures/middleware_template/` so the suite runs offline (#3)
958
+ - Chore: `scripts/release.sh` now constructs the release commit message from the version argument using the project convention (`chore: Release fips-agents-cli vX.Y.Z` with optional ` — <summary>`); convention documented in CLAUDE.md (#4)
959
+ - Docs: Drop broken `See Also` links from `.fips-agents-cli/README.md` in scaffolded MCP projects (#5, fixed in `fips-agents/mcp-server-template`)
960
+ - Docs: Updated CLAUDE.md release section to reflect the new release-script signature
961
+
962
+ ### Version 0.8.1
963
+
964
+ - Docs: Updated CLAUDE.md current-status line and added release-process notes
965
+ - Chore: Repository hardening — added CODEOWNERS and enabled main branch protection
966
+ - Chore: Black formatting drift cleanup; removed remaining "framework" language from docs in favor of "toolkit"
967
+ - Chore: `.venv/` and `NEXT_SESSION.md` gitignored
968
+
969
+ ### Version 0.8.0
970
+
971
+ - Feature: New `--vendored` flag on `create agent` copies fipsagents source instead of PyPI dependency
972
+ - Feature: New `fips-agents vendor` command for post-scaffold vendoring of existing projects
973
+ - Feature: `fips-agents vendor --update` refreshes vendored source from upstream
974
+ - Feature: `fips-agents vendor --version` pins to a specific fipsagents release tag
975
+ - Fix: `customize_agent_project` now removes monorepo Makefile install line (matching workflow template behavior)
976
+ - Fix: Added `redeploy.sh` to agent project customization file list
977
+
900
978
  ### Version 0.7.0
901
979
 
902
980
  - Feature: New `add` command group for composable agent capabilities
@@ -112,6 +112,7 @@ fips-agents add --help
112
112
  fips-agents create --help
113
113
  fips-agents generate --help
114
114
  fips-agents patch --help
115
+ fips-agents vendor --help
115
116
  ```
116
117
 
117
118
  ---
@@ -183,6 +184,12 @@ Creates an AI agent project from the [agent-template](https://github.com/fips-ag
183
184
 
184
185
  **Options:** Same as `create mcp-server` (see shared options table above).
185
186
 
187
+ **Additional option:**
188
+
189
+ | Option | Description |
190
+ |--------|-------------|
191
+ | `--vendored` | Copy fipsagents source into the project instead of using PyPI dependency |
192
+
186
193
  **Examples:**
187
194
 
188
195
  ```bash
@@ -194,6 +201,9 @@ fips-agents create agent my-agent --github --org fips-agents
194
201
 
195
202
  # Non-interactive mode
196
203
  fips-agents create agent my-agent --yes --local
204
+
205
+ # Create with vendored fipsagents source
206
+ fips-agents create agent my-agent --vendored --local
197
207
  ```
198
208
 
199
209
  #### `create gateway`
@@ -514,7 +524,9 @@ When using `--params` with `generate tool` or `generate prompt`, provide a JSON
514
524
 
515
525
  ### Patch Commands
516
526
 
517
- The `patch` command group updates files in existing MCP server projects from the upstream template repository without overwriting your custom code. It shows interactive diffs for files that may contain customizations.
527
+ The `patch` command group updates files in existing projects from the upstream template repository without overwriting your custom code. It shows interactive diffs for files that may contain customizations.
528
+
529
+ Supported project types: **MCP server**, **agent**, **workflow**. The available category subcommands depend on the project type — `patch` reads `template.type` from `.template-info` and surfaces a clear error if you run a category that doesn't apply (e.g. `patch generators` inside an agent project).
518
530
 
519
531
  Run these commands from within your project directory.
520
532
 
@@ -524,47 +536,35 @@ Run these commands from within your project directory.
524
536
  fips-agents patch check
525
537
  ```
526
538
 
527
- Check for available template updates. Shows what files have changed in the template since your project was created, organized by category.
528
-
529
- #### `patch generators`
530
-
531
- ```bash
532
- fips-agents patch generators [--dry-run]
533
- ```
534
-
535
- Update code generator templates (Jinja2 templates in `.fips-agents-cli/generators/`).
536
-
537
- #### `patch core`
538
-
539
- ```bash
540
- fips-agents patch core [--dry-run]
541
- ```
542
-
543
- Update core infrastructure files (loaders, server bootstrap).
539
+ Check for available template updates. Shows what files have changed in the template since your project was created, organized by category. Works for any supported project type.
544
540
 
545
- #### `patch docs`
541
+ #### `patch all`
546
542
 
547
543
  ```bash
548
- fips-agents patch docs [--dry-run]
544
+ fips-agents patch all [--dry-run] [--skip-confirmation]
549
545
  ```
550
546
 
551
- Update documentation files and examples.
547
+ Update every category that applies to the current project type. Prompts for confirmation before starting unless `--skip-confirmation` is passed.
552
548
 
553
- #### `patch build`
549
+ #### MCP server categories
554
550
 
555
- ```bash
556
- fips-agents patch build [--dry-run]
557
- ```
551
+ | Subcommand | Patches |
552
+ |----------------------|--------------------------------------------------------------------------|
553
+ | `patch generators` | Jinja2 templates in `.fips-agents-cli/generators/` |
554
+ | `patch core` | Core infrastructure (loaders, server bootstrap) |
555
+ | `patch docs` | Documentation files and examples |
556
+ | `patch build` | Build and deployment files (Makefile, Containerfile) |
558
557
 
559
- Update build and deployment files (Makefile, Containerfile).
558
+ #### Agent / workflow categories
560
559
 
561
- #### `patch all`
560
+ | Subcommand | Patches |
561
+ |----------------|-------------------------------------------------------------------------------|
562
+ | `patch chart` | Helm chart templates (`chart/templates/**`, `chart/Chart.yaml`) |
563
+ | `patch docs` | `CLAUDE.md`, `AGENTS.md`, `docs/**` |
564
+ | `patch build` | `Makefile`, `Containerfile`, `deploy.sh`, `redeploy.sh` |
565
+ | `patch claude` | Claude Code slash commands shipped with the template (`.claude/commands/**`) |
562
566
 
563
- ```bash
564
- fips-agents patch all [--dry-run] [--skip-confirmation]
565
- ```
566
-
567
- Update all patchable file categories at once. Prompts for confirmation before starting unless `--skip-confirmation` is passed.
567
+ User-customized files are never patched: for MCP this means `src/tools/`, `src/resources/`, `src/prompts/`, `src/middleware/`, `pyproject.toml`, etc. For agent/workflow it means `src/agent.py`, `agent.yaml`, `chart/values.yaml`, `src/fipsagents/**` (managed by `fips-agents vendor`), and `pyproject.toml`.
568
568
 
569
569
  All patch subcommands (except `check`) accept `--dry-run` to preview changes without modifying files.
570
570
 
@@ -602,6 +602,45 @@ cd my-research-agent
602
602
  fips-agents add code-executor
603
603
  ```
604
604
 
605
+ ---
606
+
607
+ ### Vendor Commands
608
+
609
+ The `vendor` command copies the fipsagents source into your agent project, replacing the PyPI dependency. This gives you full control over the fipsagents code.
610
+
611
+ #### `vendor`
612
+
613
+ ```bash
614
+ fips-agents vendor [OPTIONS]
615
+ ```
616
+
617
+ Copies fipsagents source into `src/fipsagents/` and rewrites `pyproject.toml` to use individual dependencies instead of the fipsagents package.
618
+
619
+ **Options:**
620
+
621
+ | Option | Description |
622
+ |--------|-------------|
623
+ | `--update` | Update an already-vendored project with the latest upstream source |
624
+ | `--version TEXT` | Vendor a specific version tag (e.g., `fipsagents-v0.7.0`). Default: latest main |
625
+
626
+ **Examples:**
627
+
628
+ ```bash
629
+ # Vendor into current project
630
+ fips-agents vendor
631
+
632
+ # Vendor a specific version
633
+ fips-agents vendor --version fipsagents-v0.7.0
634
+
635
+ # Update vendored source from upstream
636
+ fips-agents vendor --update
637
+ ```
638
+
639
+ **When to use vendored vs. PyPI:**
640
+
641
+ - **PyPI dependency** (default): Best for teams running multiple agents that share the same fipsagents version. Centralized updates.
642
+ - **Vendored source**: Best for agents that need custom BaseAgent modifications, environments with no PyPI access, or when you want to read and debug the fipsagents source locally.
643
+
605
644
  ## Project Name Requirements
606
645
 
607
646
  Project names must follow these rules:
@@ -630,10 +669,9 @@ pytest
630
669
 
631
670
  ```bash
632
671
  cd my-research-agent
633
- python -m venv venv
634
- source venv/bin/activate
635
- pip install -e .[dev]
636
- pytest
672
+ make install # Create venv, install dependencies
673
+ make run-local # Start HTTP server on port 8080
674
+ make test # Run tests
637
675
  # See AGENTS.md for the /plan-agent slash command workflow
638
676
  ```
639
677
 
@@ -745,7 +783,8 @@ fips-agents-cli/
745
783
  │ │ ├── create.py # create mcp-server, agent, gateway, ui
746
784
  │ │ ├── generate.py # generate tool/resource/prompt/middleware
747
785
  │ │ ├── model_car.py # create model-car
748
- │ │ └── patch.py # patch command
786
+ │ │ ├── patch.py # patch command
787
+ │ │ └── vendor.py # vendor fipsagents source
749
788
  │ └── tools/ # Utility modules
750
789
  │ ├── filesystem.py
751
790
  │ ├── git.py
@@ -864,6 +903,45 @@ MIT License - see LICENSE file for details
864
903
 
865
904
  ## Changelog
866
905
 
906
+ ### Version 0.9.1
907
+
908
+ - Chore: Realign `tests/` formatting with black 26.3.1 to match CI (v0.9.0's release pipeline failed because local black 24.x produced different output than CI's 26.x; no functional change)
909
+
910
+ ### Version 0.9.0
911
+
912
+ - Feature: `fips-agents patch` now supports agent and workflow projects in addition to MCP servers (#12)
913
+ - Feature: New `patch chart` and `patch claude` subcommands for agent/workflow projects (#15)
914
+ - Feature: `.template-info` now records `template.type` and (for monorepo templates) `template.subdir` so post-scaffolding commands can route by project type (#13)
915
+ - Feature: New `find_fips_project_root()` walks up to `.template-info`, replacing the MCP-only fastmcp-dependency probe in patch commands (#14)
916
+ - Improvement: `_clone_template_for_patch()` resolves the monorepo subdir during patching, so glob/compare runs against `templates/agent-loop/` instead of the monorepo root (#16)
917
+ - Improvement: Running an MCP-only subcommand inside an agent project (or vice versa) now exits with a clear "available categories" error
918
+ - Improvement: `patch all` enumerates the project's actual category set instead of assuming MCP layout
919
+ - Backwards compat: Projects scaffolded before `template.type` existed default to `mcp-server`; no migration required
920
+ - Tests: 20 new tests in `tests/test_patch.py` covering the type-aware patch flow end-to-end against a fake-scaffolded agent project
921
+
922
+ ### Version 0.8.2
923
+
924
+ - Test: New `TestGenerateMiddlewareRealTemplate` integration test renders the real v3.x middleware Jinja2 template against each `--hook-type` and the no-flag case, with templates committed under `tests/fixtures/middleware_template/` so the suite runs offline (#3)
925
+ - Chore: `scripts/release.sh` now constructs the release commit message from the version argument using the project convention (`chore: Release fips-agents-cli vX.Y.Z` with optional ` — <summary>`); convention documented in CLAUDE.md (#4)
926
+ - Docs: Drop broken `See Also` links from `.fips-agents-cli/README.md` in scaffolded MCP projects (#5, fixed in `fips-agents/mcp-server-template`)
927
+ - Docs: Updated CLAUDE.md release section to reflect the new release-script signature
928
+
929
+ ### Version 0.8.1
930
+
931
+ - Docs: Updated CLAUDE.md current-status line and added release-process notes
932
+ - Chore: Repository hardening — added CODEOWNERS and enabled main branch protection
933
+ - Chore: Black formatting drift cleanup; removed remaining "framework" language from docs in favor of "toolkit"
934
+ - Chore: `.venv/` and `NEXT_SESSION.md` gitignored
935
+
936
+ ### Version 0.8.0
937
+
938
+ - Feature: New `--vendored` flag on `create agent` copies fipsagents source instead of PyPI dependency
939
+ - Feature: New `fips-agents vendor` command for post-scaffold vendoring of existing projects
940
+ - Feature: `fips-agents vendor --update` refreshes vendored source from upstream
941
+ - Feature: `fips-agents vendor --version` pins to a specific fipsagents release tag
942
+ - Fix: `customize_agent_project` now removes monorepo Makefile install line (matching workflow template behavior)
943
+ - Fix: Added `redeploy.sh` to agent project customization file list
944
+
867
945
  ### Version 0.7.0
868
946
 
869
947
  - Feature: New `add` command group for composable agent capabilities
@@ -4,7 +4,7 @@ build-backend = "hatchling.build"
4
4
 
5
5
  [project]
6
6
  name = "fips-agents-cli"
7
- version = "0.7.0"
7
+ version = "0.9.1"
8
8
  description = "CLI tool for creating and managing FIPS-compliant AI agent projects"
9
9
  readme = "README.md"
10
10
  requires-python = ">=3.10"
@@ -2,9 +2,20 @@
2
2
  #
3
3
  # release.sh - Automated release script for fips-agents-cli
4
4
  #
5
- # Usage: ./scripts/release.sh <version> <commit-message>
5
+ # Usage: ./scripts/release.sh <version> [<summary>]
6
6
  #
7
- # Example: ./scripts/release.sh 0.1.2 "Add new feature for X"
7
+ # The release commit message is always constructed from the version using
8
+ # the project convention:
9
+ #
10
+ # chore: Release fips-agents-cli vX.Y.Z
11
+ #
12
+ # If a summary is provided, it is appended after an em-dash:
13
+ #
14
+ # chore: Release fips-agents-cli vX.Y.Z — <summary>
15
+ #
16
+ # Examples:
17
+ # ./scripts/release.sh 0.1.2
18
+ # ./scripts/release.sh 0.1.2 "Add new generator features"
8
19
  #
9
20
 
10
21
  set -e # Exit on error
@@ -29,14 +40,16 @@ print_info() {
29
40
  }
30
41
 
31
42
  # Check arguments
32
- if [ $# -ne 2 ]; then
33
- print_error "Usage: $0 <version> <commit-message>"
34
- echo "Example: $0 0.1.2 \"Add new feature for X\""
43
+ if [ $# -lt 1 ] || [ $# -gt 2 ]; then
44
+ print_error "Usage: $0 <version> [<summary>]"
45
+ echo "Examples:"
46
+ echo " $0 0.1.2"
47
+ echo " $0 0.1.2 \"Add new generator features\""
35
48
  exit 1
36
49
  fi
37
50
 
38
51
  VERSION=$1
39
- COMMIT_MSG=$2
52
+ SUMMARY=${2:-}
40
53
 
41
54
  # Validate version format (x.y.z)
42
55
  if ! [[ $VERSION =~ ^[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
@@ -45,6 +58,14 @@ if ! [[ $VERSION =~ ^[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
45
58
  exit 1
46
59
  fi
47
60
 
61
+ # Construct the conventional release commit message.
62
+ # Convention: "chore: Release fips-agents-cli vX.Y.Z" with optional " — <summary>".
63
+ if [ -n "$SUMMARY" ]; then
64
+ COMMIT_MSG="chore: Release fips-agents-cli v${VERSION} — ${SUMMARY}"
65
+ else
66
+ COMMIT_MSG="chore: Release fips-agents-cli v${VERSION}"
67
+ fi
68
+
48
69
  print_info "Preparing release v$VERSION"
49
70
  echo
50
71
 
@@ -7,6 +7,7 @@ from fips_agents_cli.commands.add import add
7
7
  from fips_agents_cli.commands.create import create
8
8
  from fips_agents_cli.commands.generate import generate
9
9
  from fips_agents_cli.commands.patch import patch
10
+ from fips_agents_cli.commands.vendor import vendor
10
11
  from fips_agents_cli.version import __version__
11
12
 
12
13
  console = Console()
@@ -29,6 +30,7 @@ cli.add_command(add)
29
30
  cli.add_command(create)
30
31
  cli.add_command(generate)
31
32
  cli.add_command(patch)
33
+ cli.add_command(vendor)
32
34
 
33
35
 
34
36
  def main():