Commit Graph

11 Commits

Author SHA1 Message Date
rob 06a1606370 Harden agent-friendly discovery and one-shot execution 2026-07-20 17:28:44 -03:00
rob 56cb34276e Harden M9: Ed25519 attestation, full SHA-256 integrity, locked-by-default, prompt improvements, registry verification 2026-07-20 16:50:49 -03:00
rob 4d22d532a3 Harden M8 trust and guidance workflows 2026-07-20 15:21:50 -03:00
rob 501e6cd589 Add evidence-based regression and schema compatibility checks 2026-07-20 14:21:42 -03:00
rob d81286e322 M8.0/M8.V1: Add contract inference engine and deterministic conformance testing 2026-07-20 13:34:13 -03:00
rob ba29e4dc4e Harden M8 preflight foundation 2026-07-20 12:08:38 -03:00
rob 6908d8ee6f Modernize provider support 2026-07-19 20:58:04 -03:00
rob 8581775002 Implement structured output for prompt steps (Phase 1)
Add schema validation and retry logic for AI responses:

- Add output_schema, max_retries, plain_text fields to PromptStep
- Add DEFAULT_OUTPUT_SCHEMA with output/reasoning fields
- Implement append_schema_instructions() for prompt augmentation
- Implement validate_schema() using jsonschema library
- Add retry logic with error feedback on validation failure
- Enhance substitute_variables() for nested field access ({var.field})
- Add jsonschema to dependencies
- Update GUI dialog with plain_text checkbox and max_retries spinner
- Add comprehensive tests for structured output and nested access

Tools using plain_text=True bypass validation (current behavior).
Tools without plain_text get structured JSON output with schema enforcement.

Migration Phase 1 complete. Next: Apply plain_text=True to all 72 tools.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-02-17 17:34:48 -04:00
rob 071ade0ffb Add system dependencies support for tools
Tools can now declare system-level package dependencies (apt, brew, pacman, dnf)
that get checked and optionally installed when the tool is installed or run.

Features:
- SystemDependency dataclass with short form (string) and long form (dict)
- New system_deps.py module with platform detection and installation
- `cmdforge system-deps <tool>` command to check/install system packages
- `cmdforge check` now shows both CmdForge and system dependencies
- `cmdforge registry install` prompts for system dep installation
- GUI: System Dependencies section in Tool Builder with add/edit dialog
- Runner warns about missing system deps before execution
- Integration with project install (manifest and lock-based)

Also includes:
- Quote paths in wrapper scripts for spaces support
- Tests for value type preservation in code steps
- Unskip invalid tool name test

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-28 16:31:37 -04:00
rob 497fe87fc5 Rename project from SmartTools to CmdForge
Major rename operation:
- Rename Python package: smarttools -> cmdforge
- Update CLI entry point: smarttools -> cmdforge
- Update all imports and module references
- Update pyproject.toml with new name, URLs, entry point
- Update all HTML templates with new branding
- Update documentation (CLAUDE.md, README.md, docs/*, wiki/*)
- Update environment variables:
  - SMARTTOOLS_ENV -> CMDFORGE_ENV
  - SMARTTOOLS_REGISTRY_DB -> CMDFORGE_REGISTRY_DB
  - SMARTTOOLS_TOKEN -> CMDFORGE_TOKEN
  - SMARTTOOLS_REGISTRY_* -> CMDFORGE_REGISTRY_*
- Update Dockerfile and docker-compose.yml
- Update tests to use new package name
- Update scripts and examples
- Update package.json and tailwind.config.js

All 158 unit tests pass. The CLI is working correctly with the
new cmdforge command.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-02 22:15:55 -04:00
rob cdb17db43a Add comprehensive test suite for core modules
New test files:
- test_tool.py: 35 tests for Tool, ToolArgument, steps, persistence
- test_runner.py: 31 tests for variable substitution, step execution
- test_providers.py: 35 tests for provider management, mocked calls
- test_cli.py: 20 tests for CLI commands
- tests/README.md: Test suite documentation

Removed placeholder test.py (triangle calculator).

Total: 158 unit tests passing, 12 integration tests (require server)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-01 03:07:16 -04:00