agent-workflow-kit-cli 1.0.0-mvp

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.
@@ -0,0 +1,44 @@
1
+ # Repository Agent Guidelines
2
+
3
+ This repository implements the `agent-workflow-kit-cli` configuration standards for AI coding agents.
4
+
5
+ ---
6
+
7
+ ## ๐Ÿš€ AI Agent Step-by-Step Execution Workflow
8
+
9
+ AI agents MUST follow this strict 5-step workflow for any task:
10
+
11
+ ### 1. ๐Ÿ” Step 1: Research & Context Analysis
12
+ - Read existing codebase files relating to the task first.
13
+ - Understand local naming patterns, directory boundaries, and dependency versions.
14
+ - Do NOT make any code modifications or run build commands in this step.
15
+
16
+ ### 2. ๐Ÿ“ Step 2: Formulate Implementation Plan
17
+ - Document your proposed design approach.
18
+ - List all files to be created (`[NEW]`), modified (`[MODIFY]`), or deleted (`[DELETE]`).
19
+ - Identify all verification commands to run.
20
+ - Wait for user feedback or proceed intentionally based on user preferences.
21
+
22
+ ### 3. ๐Ÿ’ป Step 3: Implementation & Clean Coding
23
+ - Implement changes following strict type safety standards.
24
+ - Conform strictly to the folder structures and layers defined in the Stack Pack section below.
25
+ - Preserve existing comments, docstrings, and licensing headers.
26
+
27
+ ### 4. ๐Ÿงช Step 4: Verification & Conformance Testing
28
+ - Always run automated verification commands of the detected stack pack (e.g. compile, lint, test, build).
29
+ - If tests or builds fail, fix the errors and rerun until compile/tests are 100% clean.
30
+
31
+ ### 5. ๐Ÿ” Step 5: Self-Review & Quality Assurance
32
+ - Review your diff/changes carefully to check for syntax errors, leftover console logs, or redundant imports.
33
+ - Summarize what was changed, what was tested, and confirm that all steps are complete before marking the task as done.
34
+
35
+ ---
36
+
37
+ ## โš™๏ธ General Engineering Conventions
38
+ - Follow existing patterns in naming, architecture, and layouts.
39
+ - Read files carefully before proposing code updates.
40
+ - Ensure type safety and run clean lint/verify steps before declaring a task as done.
41
+
42
+ <!-- AWK-START: STACK_PACK -->
43
+ {{{stackContent}}}
44
+ <!-- AWK-END: STACK_PACK -->
@@ -0,0 +1,28 @@
1
+ ## ๐Ÿ Python FastAPI Guidelines
2
+
3
+ ### ๐Ÿ—๏ธ Architecture & Router-Service-Repository Conventions
4
+ Follow a clean layering architecture. Separate HTTP routing, business logic, and database operations:
5
+
6
+ ```text
7
+ app/
8
+ core/ # Config, database setup
9
+ models/ # SQLAlchemy or SQLModel entities
10
+ schemas/ # Pydantic validation models
11
+ crud/ # Database repositories/CRUD operations
12
+ services/ # Business logic layer
13
+ api/ # Route controllers
14
+ v1/
15
+ endpoints/ # API Routers
16
+ ```
17
+
18
+ ### โš™๏ธ Coding Guidelines
19
+ - **Dependency Injection:** Use FastAPI's `Depends` explicitly for injecting database sessions, security credentials, and custom services.
20
+ - **Strict Typing:** Always annotate function arguments and return types. Use Pydantic's `response_model` or type hints to enforce validation.
21
+ - **Asynchronous Handlers:** Prefer `async def` for I/O bound endpoints.
22
+
23
+ ### ๐Ÿงช Testing & Verification
24
+ Before completing a task, run the following verification pipeline locally:
25
+ ```bash
26
+ ruff check .
27
+ pytest
28
+ ```
@@ -0,0 +1,22 @@
1
+ # Python Code Style Rules
2
+
3
+ All python code in this project must conform to the following formatting and styling requirements:
4
+ - Use PEP 8 conventions.
5
+ - Format all files with Ruff.
6
+ - Imports must be sorted using Ruff or isort.
7
+ - Use explicit type annotations everywhere.
8
+
9
+ ## Naming
10
+ - Variables, functions, modules, and API helper functions must use `snake_case`.
11
+ - Classes, exceptions, and Pydantic schemas must use `PascalCase`.
12
+ - Pydantic schemas for incoming writes must use intent suffixes:
13
+ - `UserCreate` for create payloads.
14
+ - `UserUpdate` for partial or full update payloads.
15
+ - `UserRead` or `UserResponse` for response payloads, following the local convention.
16
+ - Repository and service functions should describe actions with verbs, for example `get_user`, `list_users`, `create_user`, `update_user`, and `delete_user`.
17
+
18
+ ## API Endpoint Naming
19
+ - Route path segments must be lowercase nouns, singular or plural according to the existing local convention: `/users`, `/user-profiles`, `/orders/{order_id}`.
20
+ - Do not encode actions in REST resource paths when an HTTP method already expresses the action.
21
+ - Path parameters must use `snake_case`, for example `{user_id}`.
22
+ - Router variables should be named `router`; shared dependency functions should use clear `snake_case` names.
@@ -0,0 +1,18 @@
1
+ ---
2
+ name: fastapi-feature
3
+ description: Generates or extends a Python FastAPI endpoint/module
4
+ ---
5
+
6
+ Follow this workflow to create a new API router or feature slice in the project.
7
+
8
+ Inputs:
9
+ - featureName: Name of the feature (e.g., `items`)
10
+ - endpointPath: Base path of the router (e.g., `/items`)
11
+
12
+ Steps:
13
+ 1. Create schema models under `app/schemas/` using Pydantic.
14
+ 2. Create CRUD operations under `app/crud/` using SQLAlchemy.
15
+ 3. Write business logic service under `app/services/` if needed.
16
+ 4. Implement the API router under `app/api/v1/endpoints/`.
17
+ 5. Write integration tests using pytest and AsyncClient.
18
+ 6. Verify code formatting and linting using Ruff.
@@ -0,0 +1,47 @@
1
+ ## React + TypeScript Guidelines
2
+
3
+ ### Architecture & Feature Conventions
4
+ Use a feature-first structure. Keep route wiring thin, and place feature UI, hooks, data clients, and types together:
5
+
6
+ ```text
7
+ src/
8
+ app/ # App shell, router, providers
9
+ features/
10
+ billing/
11
+ components/
12
+ BillingPanel.tsx
13
+ hooks/
14
+ useBilling.ts
15
+ services/
16
+ billingClient.ts
17
+ types.ts
18
+ index.ts
19
+ shared/
20
+ components/
21
+ hooks/
22
+ utils/
23
+ ```
24
+
25
+ ### Component, Hook, and State Rules
26
+ - Components render UI and delegate fetching, subscriptions, timers, and other side effects to custom hooks.
27
+ - Custom hooks own reusable stateful logic and must start with `use`.
28
+ - Prefer local component state for isolated interactions.
29
+ - Use Context API for low-frequency cross-tree state such as theme, auth session, or app configuration.
30
+ - Use Zustand only for shared state with frequent updates or cross-feature coordination.
31
+ - Keep feature state close to the feature before moving it to `shared/`.
32
+
33
+ ### TypeScript Standards
34
+ - Use strict TypeScript. Avoid `any`; prefer explicit domain types and discriminated unions.
35
+ - Define feature-local interfaces and types near the code that owns them.
36
+ - Export from feature `index.ts` files only when another module needs the API.
37
+ - Use absolute imports from `@/`; do not add deep relative imports like `../../`.
38
+
39
+ ### Testing & Verification
40
+ Before completing a React + TypeScript change, run the project validation pipeline:
41
+
42
+ ```bash
43
+ npm run lint
44
+ npm run typecheck
45
+ npm run test -- --run
46
+ npm run build
47
+ ```
@@ -0,0 +1,34 @@
1
+ # React + TypeScript Style Rules
2
+
3
+ All React + TypeScript code in this project must follow these rules.
4
+
5
+ ## Naming
6
+ - Components use PascalCase and live in PascalCase files: `Navbar.tsx`, `InstallSection.tsx`.
7
+ - Custom hooks use camelCase, start with `use`, and live in matching files: `useAuth.ts`, `useBillingData.ts`.
8
+ - Helper functions and variables use camelCase: `formatCurrency`, `isSubmitting`.
9
+ - Interfaces and type aliases use PascalCase: `ButtonProps`, `AuthState`.
10
+ - Constants that represent fixed configuration may use SCREAMING_SNAKE_CASE only when already established locally.
11
+
12
+ ## Imports
13
+ - Use absolute imports from the `@/` alias for source modules.
14
+ - Do not use parent-chain relative imports such as `../../components/Button`.
15
+ - Prefer `import type` for type-only imports.
16
+ - Keep feature internals private unless exported through a feature `index.ts`.
17
+
18
+ ## React and JSX
19
+ - Keep components focused on rendering and composition.
20
+ - Move data fetching, subscriptions, timers, storage access, and other side effects into custom hooks.
21
+ - Boolean JSX attributes must use shorthand: `<Input disabled />`, not `<Input disabled={true} />`.
22
+ - Pass event handlers as named functions when the body is more than a single expression.
23
+ - Render loading, error, empty, and success states for async UI.
24
+
25
+ ## State Management
26
+ - Prefer local state for component-only interactions.
27
+ - Use Context API for stable app-level concerns such as auth, theme, locale, or configuration.
28
+ - Use Zustand for shared mutable state that changes often or is consumed across distant features.
29
+ - Do not introduce global state for data that can remain feature-local.
30
+
31
+ ## Testing
32
+ - Test user-visible behavior with React Testing Library.
33
+ - Add hook tests when a custom hook owns branching logic, async behavior, or cleanup.
34
+ - Avoid snapshots unless the output is intentionally stable and small.
@@ -0,0 +1,25 @@
1
+ ---
2
+ name: react-feature
3
+ description: Generates or extends a React + TypeScript feature with component, hook, types, styles, and tests
4
+ ---
5
+
6
+ Follow this workflow to create a new React + TypeScript feature or route.
7
+
8
+ Inputs:
9
+ - featureName: Name of the feature (e.g., `billing`)
10
+ - targetPath: Feature or route folder to extend
11
+ - userFlow: Brief description of the user-visible behavior
12
+
13
+ Steps:
14
+ 1. Inspect neighboring features, routes, shared components, and import aliases before editing.
15
+ 2. Define feature-local types first, including loading, error, empty, and success state shapes.
16
+ 3. Create or update the custom hook that owns fetching, side effects, derived state, and cleanup.
17
+ 4. Create or update PascalCase components that render UI and delegate logic to hooks.
18
+ 5. Add styles using the project's existing styling approach; do not introduce a new styling system.
19
+ 6. Wire the feature into the route or parent component through the smallest public API needed.
20
+ 7. Add tests for component behavior and hook logic when branching, async work, or cleanup is present.
21
+ 8. Run validations:
22
+ - `npm run lint`
23
+ - `npm run typecheck`
24
+ - `npm run test -- --run`
25
+ - `npm run build`
@@ -0,0 +1,79 @@
1
+ ## โ˜• Java Spring Boot Guidelines
2
+
3
+ ### ๐Ÿ—๏ธ Architecture & Package Conventions
4
+ Follow a strict **feature-first** modular packaging layout. Each feature module (e.g. `customer`) must encapsulate all its layers within it:
5
+
6
+ ```text
7
+ src/main/java/com/acme/app/
8
+ customer/
9
+ dto/
10
+ CreateCustomerRequest.java
11
+ CustomerResponse.java
12
+ entity/
13
+ Customer.java
14
+ mapper/
15
+ CustomerMapper.java
16
+ repository/
17
+ CustomerRepository.java
18
+ service/
19
+ CustomerService.java
20
+ impl/CustomerServiceImpl.java
21
+ web/
22
+ CustomerController.java
23
+ ```
24
+
25
+ Corresponding test directories must match the feature layout exactly:
26
+ ```text
27
+ src/test/java/com/acme/app/
28
+ customer/
29
+ repository/
30
+ CustomerRepositoryTest.java # Custom query repository slice tests
31
+ service/
32
+ CustomerServiceTest.java # Business logic unit tests (using Mockito)
33
+ web/
34
+ CustomerControllerTest.java # Web MVC slice tests
35
+ ```
36
+
37
+ ### โš™๏ธ Coding Guidelines
38
+ - **Dependency Injection:** Prefer constructor injection. Do NOT use field-based injection (`@Autowired`).
39
+ - **DTO Validation:** Request DTOs must enforce schemas using `jakarta.validation.constraints` annotations (e.g., `@NotNull`, `@NotBlank`, `@Size`, `@Email`).
40
+ - **Layer Separation:** Keep controllers thin; delegate all business rules, transactions, and transformations to the service layer.
41
+
42
+ ### ๐Ÿ› ๏ธ Tooling & Quality Standards
43
+ The project runs Checkstyle for static analysis and Spotless for code formatting. Ensure code conforms to these rules before pushing.
44
+ ```xml
45
+ <!-- Checkstyle & Spotless Maven Configurations -->
46
+ <plugin>
47
+ <groupId>org.apache.maven.plugins</groupId>
48
+ <artifactId>maven-checkstyle-plugin</artifactId>
49
+ <configuration>
50
+ <configLocation>checkstyle.xml</configLocation>
51
+ </configuration>
52
+ </plugin>
53
+ <plugin>
54
+ <groupId>com.diffplug.spotless</groupId>
55
+ <artifactId>spotless-maven-plugin</artifactId>
56
+ <configuration>
57
+ <java>
58
+ <googleJavaFormat/>
59
+ </java>
60
+ </configuration>
61
+ </plugin>
62
+ ```
63
+
64
+ ### ๐Ÿงช Testing Guidelines
65
+ All edits must pass local verification tests before completion:
66
+
67
+ | Test Type | Requirement | Done Criteria |
68
+ | :--- | :--- | :--- |
69
+ | **Service Unit Test** | Always | Verify business rules; mock repository and external dependencies using Mockito. |
70
+ | **`@WebMvcTest`** | For new/modified controllers | Verify API routing, status codes, payload serialization, and constraint validation errors. |
71
+ | **`@DataJpaTest`** | For custom repository queries | Verify custom query logic and entity-database column mappings. |
72
+ | **`@SpringBootTest`** | Complex integrations only | Smoke test the application startup and critical cross-module integrations. |
73
+
74
+ ### ๐Ÿš€ Verification Commands
75
+ Before completing a task, run the following verification pipeline locally:
76
+ ```bash
77
+ ./mvnw clean test
78
+ ./mvnw verify
79
+ ```
@@ -0,0 +1,14 @@
1
+ # Java Spring Boot Style Constraints
2
+
3
+ Enforce strict coding style and layer definitions in this repository.
4
+
5
+ ## Coding Style
6
+ - Follow standard project style guidelines (default Google Java style).
7
+ - Organize imports cleanly: standard java libraries first, third-party libraries second, internal imports last.
8
+ - Do not use raw types. Always specify generic parameters.
9
+
10
+ ## Integration & Layers
11
+ - Follow rules defined in @AGENTS.md.
12
+ - Ensure all custom database queries are covered by repository slice tests (`@DataJpaTest`).
13
+ - Before completing work, execute:
14
+ - `./mvnw verify`
@@ -0,0 +1,26 @@
1
+ ---
2
+ name: spring-feature
3
+ description: Generates or extends a Java Spring Boot feature module
4
+ ---
5
+
6
+ Follow this workflow to create a new REST feature or API slice in the project.
7
+
8
+ Inputs:
9
+ - featureName: Name of the feature (e.g., `billing`)
10
+ - endpointPath: Base path of the controller (e.g., `/api/v1/billing`)
11
+
12
+ Steps:
13
+ 1. Examine neighboring feature packages for error handler conventions and mappings.
14
+ 2. Create the target feature package under the designated project folder.
15
+ 3. Implement layers:
16
+ - `entity/`: Database models.
17
+ - `repository/`: Spring Data JPA interface.
18
+ - `dto/`: Request/Response schemas with jakarta.validation annotations.
19
+ - `service/`: Service interfaces and implementations.
20
+ - `web/`: Controller class exposing `@RestController` with proper mappings.
21
+ 4. Create tests:
22
+ - Service Unit Tests using Mockito.
23
+ - `@WebMvcTest` for Controller routing, payloads, and validation.
24
+ - `@DataJpaTest` for custom queries.
25
+ 5. Run validations:
26
+ - `./mvnw verify`