@dezycro-ai/agent-plugin 2.0.0

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 (55) hide show
  1. package/.claude-plugin/plugin.json +7 -0
  2. package/LICENSE +18 -0
  3. package/PERSONAS.md +309 -0
  4. package/README.md +125 -0
  5. package/bin/resolve-auth.js +112 -0
  6. package/dist/hooks/lib/authoring.d.ts +118 -0
  7. package/dist/hooks/lib/authoring.js +277 -0
  8. package/dist/hooks/lib/config.d.ts +28 -0
  9. package/dist/hooks/lib/config.js +175 -0
  10. package/dist/hooks/lib/controller-match.d.ts +16 -0
  11. package/dist/hooks/lib/controller-match.js +96 -0
  12. package/dist/hooks/lib/coverage.d.ts +17 -0
  13. package/dist/hooks/lib/coverage.js +66 -0
  14. package/dist/hooks/lib/hashing.d.ts +8 -0
  15. package/dist/hooks/lib/hashing.js +49 -0
  16. package/dist/hooks/lib/logging.d.ts +13 -0
  17. package/dist/hooks/lib/logging.js +72 -0
  18. package/dist/hooks/lib/publish-spec.d.ts +17 -0
  19. package/dist/hooks/lib/publish-spec.js +64 -0
  20. package/dist/hooks/lib/quality-gate.d.ts +67 -0
  21. package/dist/hooks/lib/quality-gate.js +187 -0
  22. package/dist/hooks/lib/router.d.ts +32 -0
  23. package/dist/hooks/lib/router.js +717 -0
  24. package/dist/hooks/lib/state.d.ts +34 -0
  25. package/dist/hooks/lib/state.js +238 -0
  26. package/dist/hooks/lib/undo.d.ts +11 -0
  27. package/dist/hooks/lib/undo.js +71 -0
  28. package/dist/hooks/lib/verify.d.ts +28 -0
  29. package/dist/hooks/lib/verify.js +94 -0
  30. package/dist/hooks/lib/workbook.d.ts +21 -0
  31. package/dist/hooks/lib/workbook.js +77 -0
  32. package/dist/hooks/types.d.ts +249 -0
  33. package/dist/hooks/types.js +14 -0
  34. package/hooks/companion-runner +108 -0
  35. package/hooks/hooks.json +74 -0
  36. package/install.js +84 -0
  37. package/package.json +50 -0
  38. package/prompts/existing-work-ranker.md +47 -0
  39. package/prompts/prd-drafter.md +53 -0
  40. package/prompts/prd-question.md +66 -0
  41. package/prompts/trd-context-gate.md +57 -0
  42. package/prompts/trd-discovery.md +71 -0
  43. package/prompts/trd-drafter.md +63 -0
  44. package/prompts/trd-question.md +61 -0
  45. package/prompts/trd-reviewer.md +74 -0
  46. package/prompts/workbook-sweep.md +89 -0
  47. package/setup.js +35 -0
  48. package/skills/author/SKILL.md +285 -0
  49. package/skills/import-features/SKILL.md +428 -0
  50. package/skills/init/SKILL.md +133 -0
  51. package/skills/publish-spec/SKILL.md +101 -0
  52. package/skills/status/SKILL.md +76 -0
  53. package/skills/sync/SKILL.md +76 -0
  54. package/skills/verify/SKILL.md +248 -0
  55. package/skills/work/SKILL.md +201 -0
@@ -0,0 +1,32 @@
1
+ /**
2
+ * router.ts — dispatches hook invocations to the right handler.
3
+ *
4
+ * The companion-runner shim parses argv and stdin payloads into a
5
+ * RouterInvocation and calls dispatch(). Per-handler boundaries try/catch
6
+ * via the runner entry point: any exception inside this module is logged
7
+ * by the runner and converts to silent exit so a hook never breaks a
8
+ * user session.
9
+ */
10
+ import type { PostToolUsePayload, PreToolUsePayload, RouterInvocation, StopPayload, UserPromptSubmitPayload, SessionStartPayload } from '../types';
11
+ export declare const QUALITY_GATE_REASON_PREFIX = "TRD quality gate (deterministic layer) blocked APPROVED transition: ";
12
+ export declare function dispatch(invocation: RouterInvocation): Promise<number>;
13
+ declare function handleUpdateTaskGate(payload: PreToolUsePayload): number;
14
+ declare function handlePostEdit(payload: PostToolUsePayload): number;
15
+ declare function extractEditedPaths(toolInput: Record<string, unknown> | null | undefined): string[];
16
+ declare function handleSessionStart(_payload: SessionStartPayload): number;
17
+ declare function handleUserPromptSubmit(payload: UserPromptSubmitPayload): number;
18
+ declare function handleStop(payload: StopPayload): number;
19
+ declare function transcriptCharsSinceLastStop(payload: StopPayload): number | null;
20
+ declare function readActiveFeatureId(repoRoot: string): string | null;
21
+ declare function handleWorkbookMutation(payload: PostToolUsePayload): number;
22
+ export declare const _extractEditedPaths: typeof extractEditedPaths;
23
+ export declare const _handlePostEdit: typeof handlePostEdit;
24
+ export declare const _handleUpdateTaskGate: typeof handleUpdateTaskGate;
25
+ export declare const _handleStop: typeof handleStop;
26
+ export declare const _handleUserPromptSubmit: typeof handleUserPromptSubmit;
27
+ export declare const _handleWorkbookMutation: typeof handleWorkbookMutation;
28
+ export declare const _handleSessionStart: typeof handleSessionStart;
29
+ export declare const _readActiveFeatureId: typeof readActiveFeatureId;
30
+ export declare const _transcriptCharsSinceLastStop: typeof transcriptCharsSinceLastStop;
31
+ export declare const TRIVIAL_TURN_CHAR_DEFAULT_EXPORT = 600;
32
+ export {};