@aelinrezende/pipa-core 1.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 (259) hide show
  1. package/README.md +131 -0
  2. package/extensions/pipa/constants/backlog.d.ts +49 -0
  3. package/extensions/pipa/constants/backlog.d.ts.map +1 -0
  4. package/extensions/pipa/constants/compactor.d.ts +7 -0
  5. package/extensions/pipa/constants/compactor.d.ts.map +1 -0
  6. package/extensions/pipa/constants/docs.d.ts +46 -0
  7. package/extensions/pipa/constants/docs.d.ts.map +1 -0
  8. package/extensions/pipa/constants/file.d.ts +15 -0
  9. package/extensions/pipa/constants/file.d.ts.map +1 -0
  10. package/extensions/pipa/constants/pipa.d.ts +6 -0
  11. package/extensions/pipa/constants/pipa.d.ts.map +1 -0
  12. package/extensions/pipa/constants/store.d.ts +6 -0
  13. package/extensions/pipa/constants/store.d.ts.map +1 -0
  14. package/extensions/pipa/constants/task.d.ts +62 -0
  15. package/extensions/pipa/constants/task.d.ts.map +1 -0
  16. package/extensions/pipa/constants/teammate.d.ts +25 -0
  17. package/extensions/pipa/constants/teammate.d.ts.map +1 -0
  18. package/extensions/pipa/constants/todo.d.ts +21 -0
  19. package/extensions/pipa/constants/todo.d.ts.map +1 -0
  20. package/extensions/pipa/core/apply-features.d.ts +4 -0
  21. package/extensions/pipa/core/apply-features.d.ts.map +1 -0
  22. package/extensions/pipa/core/config.d.ts +3 -0
  23. package/extensions/pipa/core/config.d.ts.map +1 -0
  24. package/extensions/pipa/core/decorators/events.d.ts +15 -0
  25. package/extensions/pipa/core/decorators/events.d.ts.map +1 -0
  26. package/extensions/pipa/core/errors/pipa-exception.d.ts +17 -0
  27. package/extensions/pipa/core/errors/pipa-exception.d.ts.map +1 -0
  28. package/extensions/pipa/core/events.types.d.ts +72 -0
  29. package/extensions/pipa/core/events.types.d.ts.map +1 -0
  30. package/extensions/pipa/core/pipa.d.ts +19 -0
  31. package/extensions/pipa/core/pipa.d.ts.map +1 -0
  32. package/extensions/pipa/core/toast.d.ts +13 -0
  33. package/extensions/pipa/core/toast.d.ts.map +1 -0
  34. package/extensions/pipa/cross-cutting/resource-loader.d.ts +8 -0
  35. package/extensions/pipa/cross-cutting/resource-loader.d.ts.map +1 -0
  36. package/extensions/pipa/cross-cutting/store.d.ts +5 -0
  37. package/extensions/pipa/cross-cutting/store.d.ts.map +1 -0
  38. package/extensions/pipa/features/backlog/backlog.definitions.d.ts +67 -0
  39. package/extensions/pipa/features/backlog/backlog.definitions.d.ts.map +1 -0
  40. package/extensions/pipa/features/backlog/backlog.entity.d.ts +43 -0
  41. package/extensions/pipa/features/backlog/backlog.entity.d.ts.map +1 -0
  42. package/extensions/pipa/features/backlog/backlog.feature.d.ts +14 -0
  43. package/extensions/pipa/features/backlog/backlog.feature.d.ts.map +1 -0
  44. package/extensions/pipa/features/backlog/backlog.hub.d.ts +25 -0
  45. package/extensions/pipa/features/backlog/backlog.hub.d.ts.map +1 -0
  46. package/extensions/pipa/features/backlog/hooks/guard.d.ts +13 -0
  47. package/extensions/pipa/features/backlog/hooks/guard.d.ts.map +1 -0
  48. package/extensions/pipa/features/backlog/hooks/index.d.ts +2 -0
  49. package/extensions/pipa/features/backlog/hooks/index.d.ts.map +1 -0
  50. package/extensions/pipa/features/backlog/hub/core.d.ts +50 -0
  51. package/extensions/pipa/features/backlog/hub/core.d.ts.map +1 -0
  52. package/extensions/pipa/features/backlog/hub/index.d.ts +4 -0
  53. package/extensions/pipa/features/backlog/hub/index.d.ts.map +1 -0
  54. package/extensions/pipa/features/backlog/hub/state.d.ts +48 -0
  55. package/extensions/pipa/features/backlog/hub/state.d.ts.map +1 -0
  56. package/extensions/pipa/features/backlog/hub/validator.d.ts +14 -0
  57. package/extensions/pipa/features/backlog/hub/validator.d.ts.map +1 -0
  58. package/extensions/pipa/features/base-feature.d.ts +13 -0
  59. package/extensions/pipa/features/base-feature.d.ts.map +1 -0
  60. package/extensions/pipa/features/docs/docs.definitions.d.ts +73 -0
  61. package/extensions/pipa/features/docs/docs.definitions.d.ts.map +1 -0
  62. package/extensions/pipa/features/docs/docs.entity.d.ts +27 -0
  63. package/extensions/pipa/features/docs/docs.entity.d.ts.map +1 -0
  64. package/extensions/pipa/features/docs/docs.feature.d.ts +13 -0
  65. package/extensions/pipa/features/docs/docs.feature.d.ts.map +1 -0
  66. package/extensions/pipa/features/docs/docs.hub.d.ts +22 -0
  67. package/extensions/pipa/features/docs/docs.hub.d.ts.map +1 -0
  68. package/extensions/pipa/features/docs/hub/core.d.ts +38 -0
  69. package/extensions/pipa/features/docs/hub/core.d.ts.map +1 -0
  70. package/extensions/pipa/features/docs/hub/index.d.ts +4 -0
  71. package/extensions/pipa/features/docs/hub/index.d.ts.map +1 -0
  72. package/extensions/pipa/features/docs/hub/state.d.ts +34 -0
  73. package/extensions/pipa/features/docs/hub/state.d.ts.map +1 -0
  74. package/extensions/pipa/features/docs/hub/validator.d.ts +19 -0
  75. package/extensions/pipa/features/docs/hub/validator.d.ts.map +1 -0
  76. package/extensions/pipa/features/onboarding/index.d.ts +2 -0
  77. package/extensions/pipa/features/onboarding/index.d.ts.map +1 -0
  78. package/extensions/pipa/features/onboarding/onboarding.feature.d.ts +19 -0
  79. package/extensions/pipa/features/onboarding/onboarding.feature.d.ts.map +1 -0
  80. package/extensions/pipa/features/onboarding/prompts.d.ts +8 -0
  81. package/extensions/pipa/features/onboarding/prompts.d.ts.map +1 -0
  82. package/extensions/pipa/features/permission/hooks/custom-tools.d.ts +12 -0
  83. package/extensions/pipa/features/permission/hooks/custom-tools.d.ts.map +1 -0
  84. package/extensions/pipa/features/permission/hooks/index.d.ts +3 -0
  85. package/extensions/pipa/features/permission/hooks/index.d.ts.map +1 -0
  86. package/extensions/pipa/features/permission/hooks/terminal.d.ts +12 -0
  87. package/extensions/pipa/features/permission/hooks/terminal.d.ts.map +1 -0
  88. package/extensions/pipa/features/permission/permission.definitions.d.ts +16 -0
  89. package/extensions/pipa/features/permission/permission.definitions.d.ts.map +1 -0
  90. package/extensions/pipa/features/permission/permission.feature.d.ts +13 -0
  91. package/extensions/pipa/features/permission/permission.feature.d.ts.map +1 -0
  92. package/extensions/pipa/features/provider/custom.feature.d.ts +8 -0
  93. package/extensions/pipa/features/provider/custom.feature.d.ts.map +1 -0
  94. package/extensions/pipa/features/reminder-cleaner/hooks/cleaner.d.ts +14 -0
  95. package/extensions/pipa/features/reminder-cleaner/hooks/cleaner.d.ts.map +1 -0
  96. package/extensions/pipa/features/reminder-cleaner/reminder-cleaner.feature.d.ts +12 -0
  97. package/extensions/pipa/features/reminder-cleaner/reminder-cleaner.feature.d.ts.map +1 -0
  98. package/extensions/pipa/features/task/hooks/guard.d.ts +14 -0
  99. package/extensions/pipa/features/task/hooks/guard.d.ts.map +1 -0
  100. package/extensions/pipa/features/task/hooks/index.d.ts +4 -0
  101. package/extensions/pipa/features/task/hooks/index.d.ts.map +1 -0
  102. package/extensions/pipa/features/task/hooks/reminders.d.ts +15 -0
  103. package/extensions/pipa/features/task/hooks/reminders.d.ts.map +1 -0
  104. package/extensions/pipa/features/task/hooks/tui-register.d.ts +8 -0
  105. package/extensions/pipa/features/task/hooks/tui-register.d.ts.map +1 -0
  106. package/extensions/pipa/features/task/hub/core.d.ts +60 -0
  107. package/extensions/pipa/features/task/hub/core.d.ts.map +1 -0
  108. package/extensions/pipa/features/task/hub/index.d.ts +5 -0
  109. package/extensions/pipa/features/task/hub/index.d.ts.map +1 -0
  110. package/extensions/pipa/features/task/hub/squad.d.ts +37 -0
  111. package/extensions/pipa/features/task/hub/squad.d.ts.map +1 -0
  112. package/extensions/pipa/features/task/hub/state.d.ts +104 -0
  113. package/extensions/pipa/features/task/hub/state.d.ts.map +1 -0
  114. package/extensions/pipa/features/task/hub/validator.d.ts +50 -0
  115. package/extensions/pipa/features/task/hub/validator.d.ts.map +1 -0
  116. package/extensions/pipa/features/task/task.definitions.d.ts +86 -0
  117. package/extensions/pipa/features/task/task.definitions.d.ts.map +1 -0
  118. package/extensions/pipa/features/task/task.entity.d.ts +61 -0
  119. package/extensions/pipa/features/task/task.entity.d.ts.map +1 -0
  120. package/extensions/pipa/features/task/task.feature.d.ts +10 -0
  121. package/extensions/pipa/features/task/task.feature.d.ts.map +1 -0
  122. package/extensions/pipa/features/task/task.hub.d.ts +24 -0
  123. package/extensions/pipa/features/task/task.hub.d.ts.map +1 -0
  124. package/extensions/pipa/features/task/tui/index.d.ts +2 -0
  125. package/extensions/pipa/features/task/tui/index.d.ts.map +1 -0
  126. package/extensions/pipa/features/task/tui/task-tree.widget.d.ts +19 -0
  127. package/extensions/pipa/features/task/tui/task-tree.widget.d.ts.map +1 -0
  128. package/extensions/pipa/features/teammate/hooks/execution-context.d.ts +12 -0
  129. package/extensions/pipa/features/teammate/hooks/execution-context.d.ts.map +1 -0
  130. package/extensions/pipa/features/teammate/hooks/index.d.ts +8 -0
  131. package/extensions/pipa/features/teammate/hooks/index.d.ts.map +1 -0
  132. package/extensions/pipa/features/teammate/hooks/lifecycle.d.ts +17 -0
  133. package/extensions/pipa/features/teammate/hooks/lifecycle.d.ts.map +1 -0
  134. package/extensions/pipa/features/teammate/hooks/observability.d.ts +17 -0
  135. package/extensions/pipa/features/teammate/hooks/observability.d.ts.map +1 -0
  136. package/extensions/pipa/features/teammate/hooks/reminders.d.ts +19 -0
  137. package/extensions/pipa/features/teammate/hooks/reminders.d.ts.map +1 -0
  138. package/extensions/pipa/features/teammate/hooks/session-interval.d.ts +56 -0
  139. package/extensions/pipa/features/teammate/hooks/session-interval.d.ts.map +1 -0
  140. package/extensions/pipa/features/teammate/hooks/shutdown-context.d.ts +10 -0
  141. package/extensions/pipa/features/teammate/hooks/shutdown-context.d.ts.map +1 -0
  142. package/extensions/pipa/features/teammate/hooks/tui-register.d.ts +8 -0
  143. package/extensions/pipa/features/teammate/hooks/tui-register.d.ts.map +1 -0
  144. package/extensions/pipa/features/teammate/hub/core.d.ts +36 -0
  145. package/extensions/pipa/features/teammate/hub/core.d.ts.map +1 -0
  146. package/extensions/pipa/features/teammate/hub/exchange.d.ts +35 -0
  147. package/extensions/pipa/features/teammate/hub/exchange.d.ts.map +1 -0
  148. package/extensions/pipa/features/teammate/hub/frontmatter.d.ts +19 -0
  149. package/extensions/pipa/features/teammate/hub/frontmatter.d.ts.map +1 -0
  150. package/extensions/pipa/features/teammate/hub/index.d.ts +6 -0
  151. package/extensions/pipa/features/teammate/hub/index.d.ts.map +1 -0
  152. package/extensions/pipa/features/teammate/hub/state.d.ts +39 -0
  153. package/extensions/pipa/features/teammate/hub/state.d.ts.map +1 -0
  154. package/extensions/pipa/features/teammate/hub/validator.d.ts +21 -0
  155. package/extensions/pipa/features/teammate/hub/validator.d.ts.map +1 -0
  156. package/extensions/pipa/features/teammate/prompts.d.ts +13 -0
  157. package/extensions/pipa/features/teammate/prompts.d.ts.map +1 -0
  158. package/extensions/pipa/features/teammate/teammate.definitions.d.ts +42 -0
  159. package/extensions/pipa/features/teammate/teammate.definitions.d.ts.map +1 -0
  160. package/extensions/pipa/features/teammate/teammate.entity.d.ts +68 -0
  161. package/extensions/pipa/features/teammate/teammate.entity.d.ts.map +1 -0
  162. package/extensions/pipa/features/teammate/teammate.feature.d.ts +12 -0
  163. package/extensions/pipa/features/teammate/teammate.feature.d.ts.map +1 -0
  164. package/extensions/pipa/features/teammate/teammate.hub.d.ts +24 -0
  165. package/extensions/pipa/features/teammate/teammate.hub.d.ts.map +1 -0
  166. package/extensions/pipa/features/teammate/tui/index.d.ts +3 -0
  167. package/extensions/pipa/features/teammate/tui/index.d.ts.map +1 -0
  168. package/extensions/pipa/features/teammate/tui/teammate-tree.widget.d.ts +23 -0
  169. package/extensions/pipa/features/teammate/tui/teammate-tree.widget.d.ts.map +1 -0
  170. package/extensions/pipa/features/teammate/tui/tui-animator.mixin.d.ts +16 -0
  171. package/extensions/pipa/features/teammate/tui/tui-animator.mixin.d.ts.map +1 -0
  172. package/extensions/pipa/features/todo/hooks/index.d.ts +2 -0
  173. package/extensions/pipa/features/todo/hooks/index.d.ts.map +1 -0
  174. package/extensions/pipa/features/todo/hooks/reminders.d.ts +16 -0
  175. package/extensions/pipa/features/todo/hooks/reminders.d.ts.map +1 -0
  176. package/extensions/pipa/features/todo/hub/core.d.ts +35 -0
  177. package/extensions/pipa/features/todo/hub/core.d.ts.map +1 -0
  178. package/extensions/pipa/features/todo/hub/index.d.ts +4 -0
  179. package/extensions/pipa/features/todo/hub/index.d.ts.map +1 -0
  180. package/extensions/pipa/features/todo/hub/state.d.ts +40 -0
  181. package/extensions/pipa/features/todo/hub/state.d.ts.map +1 -0
  182. package/extensions/pipa/features/todo/hub/validator.d.ts +24 -0
  183. package/extensions/pipa/features/todo/hub/validator.d.ts.map +1 -0
  184. package/extensions/pipa/features/todo/todo.definitions.d.ts +31 -0
  185. package/extensions/pipa/features/todo/todo.definitions.d.ts.map +1 -0
  186. package/extensions/pipa/features/todo/todo.entity.d.ts +44 -0
  187. package/extensions/pipa/features/todo/todo.entity.d.ts.map +1 -0
  188. package/extensions/pipa/features/todo/todo.feature.d.ts +18 -0
  189. package/extensions/pipa/features/todo/todo.feature.d.ts.map +1 -0
  190. package/extensions/pipa/features/todo/todo.hub.d.ts +24 -0
  191. package/extensions/pipa/features/todo/todo.hub.d.ts.map +1 -0
  192. package/extensions/pipa/features/tool-result-compactor/hooks/compactor.d.ts +22 -0
  193. package/extensions/pipa/features/tool-result-compactor/hooks/compactor.d.ts.map +1 -0
  194. package/extensions/pipa/features/tool-result-compactor/tool-result-compactor.feature.d.ts +12 -0
  195. package/extensions/pipa/features/tool-result-compactor/tool-result-compactor.feature.d.ts.map +1 -0
  196. package/extensions/pipa/index.d.ts +5 -0
  197. package/extensions/pipa/index.d.ts.map +1 -0
  198. package/extensions/pipa/interfaces/common.d.ts +80 -0
  199. package/extensions/pipa/interfaces/common.d.ts.map +1 -0
  200. package/extensions/pipa/interfaces/config.d.ts +37 -0
  201. package/extensions/pipa/interfaces/config.d.ts.map +1 -0
  202. package/extensions/pipa/interfaces/index.d.ts +7 -0
  203. package/extensions/pipa/interfaces/index.d.ts.map +1 -0
  204. package/extensions/pipa/interfaces/intercom.d.ts +10 -0
  205. package/extensions/pipa/interfaces/intercom.d.ts.map +1 -0
  206. package/extensions/pipa/interfaces/permission.d.ts +10 -0
  207. package/extensions/pipa/interfaces/permission.d.ts.map +1 -0
  208. package/extensions/pipa/interfaces/pipa.d.ts +28 -0
  209. package/extensions/pipa/interfaces/pipa.d.ts.map +1 -0
  210. package/extensions/pipa/interfaces/reminder.d.ts +15 -0
  211. package/extensions/pipa/interfaces/reminder.d.ts.map +1 -0
  212. package/extensions/pipa/interfaces/string.d.ts +15 -0
  213. package/extensions/pipa/interfaces/string.d.ts.map +1 -0
  214. package/extensions/pipa/lib/array.d.ts +17 -0
  215. package/extensions/pipa/lib/array.d.ts.map +1 -0
  216. package/extensions/pipa/lib/doc.d.ts +30 -0
  217. package/extensions/pipa/lib/doc.d.ts.map +1 -0
  218. package/extensions/pipa/lib/file.d.ts +7 -0
  219. package/extensions/pipa/lib/file.d.ts.map +1 -0
  220. package/extensions/pipa/lib/format-tokens.d.ts +6 -0
  221. package/extensions/pipa/lib/format-tokens.d.ts.map +1 -0
  222. package/extensions/pipa/lib/graph.d.ts +16 -0
  223. package/extensions/pipa/lib/graph.d.ts.map +1 -0
  224. package/extensions/pipa/lib/index.d.ts +20 -0
  225. package/extensions/pipa/lib/index.d.ts.map +1 -0
  226. package/extensions/pipa/lib/llm.d.ts +33 -0
  227. package/extensions/pipa/lib/llm.d.ts.map +1 -0
  228. package/extensions/pipa/lib/markdown.d.ts +13 -0
  229. package/extensions/pipa/lib/markdown.d.ts.map +1 -0
  230. package/extensions/pipa/lib/onboarding.d.ts +17 -0
  231. package/extensions/pipa/lib/onboarding.d.ts.map +1 -0
  232. package/extensions/pipa/lib/paths.d.ts +22 -0
  233. package/extensions/pipa/lib/paths.d.ts.map +1 -0
  234. package/extensions/pipa/lib/permission.d.ts +22 -0
  235. package/extensions/pipa/lib/permission.d.ts.map +1 -0
  236. package/extensions/pipa/lib/pi.d.ts +38 -0
  237. package/extensions/pipa/lib/pi.d.ts.map +1 -0
  238. package/extensions/pipa/lib/reminder-cleaner.d.ts +7 -0
  239. package/extensions/pipa/lib/reminder-cleaner.d.ts.map +1 -0
  240. package/extensions/pipa/lib/string.d.ts +32 -0
  241. package/extensions/pipa/lib/string.d.ts.map +1 -0
  242. package/extensions/pipa/lib/teammate.d.ts +7 -0
  243. package/extensions/pipa/lib/teammate.d.ts.map +1 -0
  244. package/extensions/pipa/lib/tool-result-compactor.d.ts +12 -0
  245. package/extensions/pipa/lib/tool-result-compactor.d.ts.map +1 -0
  246. package/extensions/pipa/lib/tool.d.ts +9 -0
  247. package/extensions/pipa/lib/tool.d.ts.map +1 -0
  248. package/extensions/pipa/lib/tui-animation.d.ts +35 -0
  249. package/extensions/pipa/lib/tui-animation.d.ts.map +1 -0
  250. package/extensions/pipa/lib/tui.d.ts +73 -0
  251. package/extensions/pipa/lib/tui.d.ts.map +1 -0
  252. package/extensions/pipa/lib/typebox.d.ts +5 -0
  253. package/extensions/pipa/lib/typebox.d.ts.map +1 -0
  254. package/index.d.ts +36 -0
  255. package/index.d.ts.map +1 -0
  256. package/index.js +164 -0
  257. package/package.json +69 -0
  258. package/pipa.config.d.ts +4 -0
  259. package/pipa.config.d.ts.map +1 -0
@@ -0,0 +1,13 @@
1
+ import { Task } from '../task/task.entity';
2
+ /**
3
+ * Gera o prompt de squad para o spawned.
4
+ * @param squad O squad herdado pela tarefa atual (se houver).
5
+ * @param epics A lista de tarefas que possuem squad.
6
+ */
7
+ export declare function getSquadPrompt(squad?: string, epics?: Task[]): string;
8
+ export declare const PIPA_AGENTS_PROMPT: {
9
+ main: string;
10
+ subagent: string;
11
+ };
12
+ export declare const TEAMMATE_SPAWN_PROMPT: string;
13
+ //# sourceMappingURL=prompts.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"prompts.d.ts","sourceRoot":"","sources":["../../../../../extensions/pipa/features/teammate/prompts.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,IAAI,EAAE,MAAM,qBAAqB,CAAC;AAE3C;;;;GAIG;AACH,wBAAgB,cAAc,CAAC,KAAK,CAAC,EAAE,MAAM,EAAE,KAAK,CAAC,EAAE,IAAI,EAAE,GAAG,MAAM,CA2BrE;AAED,eAAO,MAAM,kBAAkB;IAC7B,IAAI;IAQJ,QAAQ;CAMT,CAAC;AAEF,eAAO,MAAM,qBAAqB,QAQjC,CAAC"}
@@ -0,0 +1,42 @@
1
+ import Type from 'typebox';
2
+ export declare const TEAMMATE_TOOL_SCHEMA: {
3
+ instantiate: Type.TObject<{
4
+ action: Type.TLiteral<"instantiate">;
5
+ name: Type.TString;
6
+ goal: Type.TString;
7
+ }>;
8
+ list: Type.TObject<{
9
+ action: Type.TLiteral<"list">;
10
+ }>;
11
+ online: Type.TObject<{
12
+ action: Type.TLiteral<"online">;
13
+ }>;
14
+ 'send-inbox': Type.TObject<{
15
+ action: Type.TLiteral<"send-inbox">;
16
+ teammateId: Type.TString;
17
+ message: Type.TString;
18
+ }>;
19
+ chat: Type.TObject<{
20
+ action: Type.TLiteral<"chat">;
21
+ teammateId: Type.TString;
22
+ message: Type.TString;
23
+ }>;
24
+ 'read-inbox': Type.TObject<{
25
+ action: Type.TLiteral<"read-inbox">;
26
+ }>;
27
+ dismiss: Type.TObject<{
28
+ action: Type.TLiteral<"dismiss">;
29
+ teammateId: Type.TString;
30
+ reason: Type.TString;
31
+ }>;
32
+ };
33
+ export declare const TEAMMATE_TOOL_ACTIONS_MESSAGE: {
34
+ instantiate: string;
35
+ list: string;
36
+ online: string;
37
+ chat: string;
38
+ 'send-inbox': string;
39
+ 'read-inbox': string;
40
+ dismiss: string;
41
+ };
42
+ //# sourceMappingURL=teammate.definitions.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"teammate.definitions.d.ts","sourceRoot":"","sources":["../../../../../extensions/pipa/features/teammate/teammate.definitions.ts"],"names":[],"mappings":"AAAA,OAAO,IAAI,MAAM,SAAS,CAAC;AAG3B,eAAO,MAAM,oBAAoB;IAE/B,WAAW;;;;;IAgBX,IAAI;;;IAUJ,MAAM;;;IAWN,YAAY;;;;;IAgBZ,IAAI;;;;;IAmBJ,YAAY;;;IAUZ,OAAO;;;;;CAWR,CAAC;AAEF,eAAO,MAAM,6BAA6B;IACxC,WAAW;IACX,IAAI;IACJ,MAAM;IACN,IAAI;IACJ,YAAY;IACZ,YAAY;IACZ,OAAO;CACR,CAAC"}
@@ -0,0 +1,68 @@
1
+ import { AgentSession } from '@earendil-works/pi-coding-agent';
2
+ import { PiEvent } from '../../constants/pipa';
3
+ import { PipaApi } from '../../interfaces/pipa';
4
+ import { OmitGetters, ToolActionPayload, ToolParams } from '../../interfaces/common';
5
+ import { TEAMMATE_TOOL_SCHEMA } from './teammate.definitions';
6
+ export type TeammateToolParams = ToolParams<typeof TEAMMATE_TOOL_SCHEMA>;
7
+ /** Payload de cada ação da tool teammates */
8
+ export type TeammateToolSchema<K extends keyof typeof TEAMMATE_TOOL_SCHEMA> = ToolActionPayload<typeof TEAMMATE_TOOL_SCHEMA, K>;
9
+ export declare class Teammate {
10
+ constructor(data: OmitGetters<Teammate>);
11
+ /** Nome do agente */
12
+ name: string;
13
+ /** Identificador da sessão do agente */
14
+ sessionId: string;
15
+ /** ID da sessão (agente) pai */
16
+ parentSessionId?: string;
17
+ /** Status atual do agente */
18
+ status: TeammateStatus;
19
+ /** Último evento do agente */
20
+ lastEvent?: PiEvent;
21
+ /** Profundidade do agente na hierarquia (0 para o agente principal) */
22
+ depth: number;
23
+ /** Papel do agente (ex: "main", "subagent") */
24
+ role: 'main' | 'subagent';
25
+ /** Objetivo principal do agente */
26
+ goal: string;
27
+ /** Definição do agente (obrigatório para subagentes) */
28
+ body?: string;
29
+ /** Descrição do agente (obrigatória para subagentes) */
30
+ description?: string;
31
+ /** Metadados opcionais do agente */
32
+ frontmatter?: TeammateFrontmatter;
33
+ /** Instancia `PipaApi` do teammate */
34
+ pipa?: PipaApi;
35
+ /** Instancia `AgentSession` do teammate */
36
+ session?: AgentSession;
37
+ /** Diretório de arquivos (logs, inbox, resultados) do agente */
38
+ workspaceDir: string;
39
+ /** Diretório da sessão */
40
+ sessionDir?: string;
41
+ /** Timestamp de quando o agente começou */
42
+ startedAt: number;
43
+ /** Timestamp de quando o agente foi ativado pela última vez */
44
+ lastActiveAt: number;
45
+ /** Nome da última ferramenta utilizada */
46
+ lastTool?: string;
47
+ /** Indica se o agente foi montado */
48
+ eventsMountMap?: Record<string, boolean>;
49
+ /** Indica se o agente está rodando */
50
+ get isRunning(): boolean;
51
+ /** Indica se o agente está sendo encerrado */
52
+ get isStopping(): boolean;
53
+ }
54
+ export type TeammateStatus = 'running' | 'idle' | 'failed' | 'stopping';
55
+ export interface TeammateFrontmatter {
56
+ name: string;
57
+ description: string;
58
+ body: string;
59
+ spawnableTeammates?: Record<string, string>;
60
+ }
61
+ export type TeammatesStore = Map<string, Teammate>;
62
+ export interface TeammateInboxMessage {
63
+ from: string;
64
+ content: string;
65
+ timestamp: number;
66
+ }
67
+ export declare const TeammateStatusEmojis: Record<TeammateStatus, string>;
68
+ //# sourceMappingURL=teammate.entity.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"teammate.entity.d.ts","sourceRoot":"","sources":["../../../../../extensions/pipa/features/teammate/teammate.entity.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,iCAAiC,CAAC;AAC/D,OAAO,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAC;AAC/C,OAAO,EAAE,OAAO,EAAE,MAAM,uBAAuB,CAAC;AAChD,OAAO,EAAE,WAAW,EAAE,iBAAiB,EAAE,UAAU,EAAE,MAAM,yBAAyB,CAAC;AACrF,OAAO,EAAE,oBAAoB,EAAE,MAAM,wBAAwB,CAAC;AAE9D,MAAM,MAAM,kBAAkB,GAAG,UAAU,CAAC,OAAO,oBAAoB,CAAC,CAAC;AAEzE,6CAA6C;AAC7C,MAAM,MAAM,kBAAkB,CAAC,CAAC,SAAS,MAAM,OAAO,oBAAoB,IAAI,iBAAiB,CAC7F,OAAO,oBAAoB,EAC3B,CAAC,CACF,CAAC;AAEF,qBAAa,QAAQ;IACnB,YAAY,IAAI,EAAE,WAAW,CAAC,QAAQ,CAAC,EAEtC;IAED,qBAAqB;IACrB,IAAI,EAAE,MAAM,CAAC;IAEb,wCAAwC;IACxC,SAAS,EAAE,MAAM,CAAC;IAElB,gCAAgC;IAChC,eAAe,CAAC,EAAE,MAAM,CAAC;IAEzB,6BAA6B;IAC7B,MAAM,EAAE,cAAc,CAAC;IAEvB,8BAA8B;IAC9B,SAAS,CAAC,EAAE,OAAO,CAAC;IAEpB,uEAAuE;IACvE,KAAK,EAAE,MAAM,CAAC;IAEd,+CAA+C;IAC/C,IAAI,EAAE,MAAM,GAAG,UAAU,CAAC;IAE1B,mCAAmC;IACnC,IAAI,EAAE,MAAM,CAAC;IAEb,wDAAwD;IACxD,IAAI,CAAC,EAAE,MAAM,CAAC;IAEd,wDAAwD;IACxD,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB,oCAAoC;IACpC,WAAW,CAAC,EAAE,mBAAmB,CAAC;IAElC,sCAAsC;IACtC,IAAI,CAAC,EAAE,OAAO,CAAC;IAEf,2CAA2C;IAC3C,OAAO,CAAC,EAAE,YAAY,CAAC;IAEvB,gEAAgE;IAChE,YAAY,EAAE,MAAM,CAAC;IAErB,0BAA0B;IAC1B,UAAU,CAAC,EAAE,MAAM,CAAC;IAEpB,2CAA2C;IAC3C,SAAS,EAAE,MAAM,CAAC;IAElB,+DAA+D;IAC/D,YAAY,EAAE,MAAM,CAAC;IAErB,0CAA0C;IAC1C,QAAQ,CAAC,EAAE,MAAM,CAAC;IAElB,qCAAqC;IACrC,cAAc,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAM;IAE9C,sCAAsC;IACtC,IAAI,SAAS,YAEZ;IAED,8CAA8C;IAC9C,IAAI,UAAU,YAEb;CACF;AAED,MAAM,MAAM,cAAc,GAAG,SAAS,GAAG,MAAM,GAAG,QAAQ,GAAG,UAAU,CAAC;AAExE,MAAM,WAAW,mBAAmB;IAClC,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,MAAM,CAAC;IACpB,IAAI,EAAE,MAAM,CAAC;IACb,kBAAkB,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;CAC7C;AAED,MAAM,MAAM,cAAc,GAAG,GAAG,CAAC,MAAM,EAAE,QAAQ,CAAC,CAAC;AAEnD,MAAM,WAAW,oBAAoB;IACnC,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,CAAC;IAChB,SAAS,EAAE,MAAM,CAAC;CACnB;AAED,eAAO,MAAM,oBAAoB,EAAE,MAAM,CAAC,cAAc,EAAE,MAAM,CAK/D,CAAC"}
@@ -0,0 +1,12 @@
1
+ import type { ExtensionAPI } from '@earendil-works/pi-coding-agent';
2
+ import { PipaBaseFeature } from '../base-feature';
3
+ import { TeammateExecutionContext, TeammateLifecycle, TeammateObservability, TeammateReminders, TeammateShutdownContext, TeammateTuiRegister } from './hooks';
4
+ declare const TeammateFeature_base: import("ts-mixer/dist/types/types").Class<any[], PipaBaseFeature & TeammateExecutionContext & TeammateLifecycle & TeammateReminders & TeammateShutdownContext & TeammateObservability & TeammateTuiRegister, typeof PipaBaseFeature & typeof TeammateExecutionContext & typeof TeammateLifecycle & typeof TeammateReminders & typeof TeammateShutdownContext & typeof TeammateObservability & typeof TeammateTuiRegister>;
5
+ /**
6
+ * Feature para gerenciamento de subagentes.
7
+ */
8
+ export declare class TeammateFeature extends TeammateFeature_base {
9
+ initialize(pi: ExtensionAPI): Promise<void> | void;
10
+ }
11
+ export {};
12
+ //# sourceMappingURL=teammate.feature.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"teammate.feature.d.ts","sourceRoot":"","sources":["../../../../../extensions/pipa/features/teammate/teammate.feature.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,iCAAiC,CAAC;AAGpE,OAAO,EAAE,eAAe,EAAE,MAAM,iBAAiB,CAAC;AAClD,OAAO,EACL,wBAAwB,EACxB,iBAAiB,EACjB,qBAAqB,EACrB,iBAAiB,EACjB,uBAAuB,EACvB,mBAAmB,EACpB,MAAM,SAAS,CAAC;;AAOjB;;GAEG;AACH,qBAAa,eAAgB,SAAQ,oBAQpC;IACC,UAAU,CAAC,EAAE,EAAE,YAAY,GAAG,OAAO,CAAC,IAAI,CAAC,GAAG,IAAI,CAgCjD;CACF"}
@@ -0,0 +1,24 @@
1
+ import { PipaApi } from '../../interfaces/pipa';
2
+ import { Teammate, TeammateToolSchema } from './teammate.entity';
3
+ import { TeammateCore, TeammateExchange, TeammateFrontmatter, TeammateState, TeammateValidator } from './hub';
4
+ declare const TeammateHub_base: import("ts-mixer/dist/types/types").Class<any[], TeammateFrontmatter & TeammateState & TeammateExchange & TeammateValidator & TeammateCore, typeof TeammateFrontmatter & typeof TeammateState & typeof TeammateExchange & typeof TeammateValidator & typeof TeammateCore>;
5
+ /**
6
+ * Gerencia os teammates (subagentes) do agente principal, incluindo criação,
7
+ * armazenamento e comunicação.
8
+ *
9
+ * Os métodos seguem a convenção do padrão backlog: nome camelCase da action
10
+ * (instantiate/list/online/sendInbox/readInbox/chat/dismiss) recebendo payload único tipado.
11
+ */
12
+ export declare class TeammateHub extends TeammateHub_base {
13
+ readonly pipa: PipaApi;
14
+ constructor(pipa: PipaApi);
15
+ private get teammatesFileManager();
16
+ /**
17
+ * Aciona um teammate e inicia uma nova sessão para ele.
18
+ * @param data Payload único da action 'instantiate'.
19
+ * @returns O teammate criado (sem session/pipa, não serializáveis).
20
+ */
21
+ instantiate(data: TeammateToolSchema<'instantiate'>): Promise<Teammate>;
22
+ }
23
+ export {};
24
+ //# sourceMappingURL=teammate.hub.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"teammate.hub.d.ts","sourceRoot":"","sources":["../../../../../extensions/pipa/features/teammate/teammate.hub.ts"],"names":[],"mappings":"AAUA,OAAO,EAAE,OAAO,EAAE,MAAM,uBAAuB,CAAC;AAMhD,OAAO,EAAE,QAAQ,EAAE,kBAAkB,EAAE,MAAM,mBAAmB,CAAC;AACjE,OAAO,EAAE,YAAY,EAAE,gBAAgB,EAAE,mBAAmB,EAAE,aAAa,EAAE,iBAAiB,EAAE,MAAM,OAAO,CAAC;;AAG9G;;;;;;GAMG;AACH,qBAAa,WAAY,SAAQ,gBAMhC;IACa,QAAQ,CAAC,IAAI,EAAE,OAAO;IAAlC,YAAqB,IAAI,EAAE,OAAO,EAEjC;IAED,OAAO,KAAK,oBAAoB,GAE/B;IAED;;;;OAIG;IACG,WAAW,CAAC,IAAI,EAAE,kBAAkB,CAAC,aAAa,CAAC,GAAG,OAAO,CAAC,QAAQ,CAAC,CAiG5E;CACF"}
@@ -0,0 +1,3 @@
1
+ export * from './teammate-tree.widget';
2
+ export * from './tui-animator.mixin';
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../extensions/pipa/features/teammate/tui/index.ts"],"names":[],"mappings":"AAAA,cAAc,wBAAwB,CAAC;AACvC,cAAc,sBAAsB,CAAC"}
@@ -0,0 +1,23 @@
1
+ import type { Theme } from '@earendil-works/pi-coding-agent';
2
+ import type { TUI } from '@earendil-works/pi-tui';
3
+ import { AbstractTreeWidget, type TreeNode } from '../../../lib';
4
+ import type { Teammate } from '../teammate.entity';
5
+ import { TuiAnimatorMixin } from './tui-animator.mixin';
6
+ type TeammateNode = TreeNode<Teammate>;
7
+ declare const TeammateTreeWidget_base: import("ts-mixer/dist/types/types").Class<any[], AbstractTreeWidget<Teammate> & TuiAnimatorMixin, (abstract new () => AbstractTreeWidget<Teammate>) & typeof TuiAnimatorMixin>;
8
+ export declare class TeammateTreeWidget extends TeammateTreeWidget_base {
9
+ private readonly tui;
10
+ private readonly getTeammates;
11
+ private readonly theme;
12
+ constructor(tui: TUI, getTeammates: () => Teammate[], theme: Theme);
13
+ start(): void;
14
+ stop(): void;
15
+ render(width: number): string[];
16
+ invalidate(): void;
17
+ protected renderLabel(node: TeammateNode): string;
18
+ private statusIcon;
19
+ private colorStatus;
20
+ private elapsedLabel;
21
+ }
22
+ export {};
23
+ //# sourceMappingURL=teammate-tree.widget.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"teammate-tree.widget.d.ts","sourceRoot":"","sources":["../../../../../../extensions/pipa/features/teammate/tui/teammate-tree.widget.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,iCAAiC,CAAC;AAC7D,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,wBAAwB,CAAC;AAMlD,OAAO,EACL,kBAAkB,EAKlB,KAAK,QAAQ,EACd,MAAM,cAAc,CAAC;AAEtB,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,oBAAoB,CAAC;AACnD,OAAO,EAAE,gBAAgB,EAAE,MAAM,sBAAsB,CAAC;AAExD,KAAK,YAAY,GAAG,QAAQ,CAAC,QAAQ,CAAC,CAAC;;AAEvC,qBAAa,kBAAmB,SAAQ,uBAAqD;IAEzF,OAAO,CAAC,QAAQ,CAAC,GAAG;IACpB,OAAO,CAAC,QAAQ,CAAC,YAAY;IAC7B,OAAO,CAAC,QAAQ,CAAC,KAAK;IAHxB,YACmB,GAAG,EAAE,GAAG,EACR,YAAY,EAAE,MAAM,QAAQ,EAAE,EAC9B,KAAK,EAAE,KAAK,EAG9B;IAED,KAAK,IAAI,IAAI,CAEZ;IAED,IAAI,IAAI,IAAI,CAEX;IAED,MAAM,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,EAAE,CAmB9B;IAED,UAAU,IAAI,IAAI,CAEjB;IAED,SAAS,CAAC,WAAW,CAAC,IAAI,EAAE,YAAY,GAAG,MAAM,CAoDhD;IAED,OAAO,CAAC,UAAU;IAWlB,OAAO,CAAC,WAAW;IAsBnB,OAAO,CAAC,YAAY;CA4BrB"}
@@ -0,0 +1,16 @@
1
+ import type { TUI } from '@earendil-works/pi-tui';
2
+ export declare class TuiAnimatorMixin {
3
+ step: number;
4
+ private animationInterval?;
5
+ /**
6
+ * Inicia o intervalo da animação.
7
+ * @param tui A instância do TUI para solicitar repintura
8
+ * @param intervalMs Duração do intervalo em milissegundos
9
+ */
10
+ startAnimation(tui: TUI, intervalMs?: number): void;
11
+ /**
12
+ * Interrompe o intervalo da animação e limpa a referência.
13
+ */
14
+ stopAnimation(): void;
15
+ }
16
+ //# sourceMappingURL=tui-animator.mixin.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"tui-animator.mixin.d.ts","sourceRoot":"","sources":["../../../../../../extensions/pipa/features/teammate/tui/tui-animator.mixin.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,wBAAwB,CAAC;AAElD,qBAAa,gBAAgB;IACpB,IAAI,SAAK;IAChB,OAAO,CAAC,iBAAiB,CAAC,CAAiB;IAE3C;;;;OAIG;IACH,cAAc,CAAC,GAAG,EAAE,GAAG,EAAE,UAAU,GAAE,MAAW,GAAG,IAAI,CAStD;IAED;;OAEG;IACH,aAAa,IAAI,IAAI,CAKpB;CACF"}
@@ -0,0 +1,2 @@
1
+ export * from './reminders';
2
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../extensions/pipa/features/todo/hooks/index.ts"],"names":[],"mappings":"AAAA,cAAc,aAAa,CAAC"}
@@ -0,0 +1,16 @@
1
+ import { type PipaApi } from '../../../interfaces';
2
+ /**
3
+ * Hook responsável por gerenciar lembretes e notificações
4
+ * relacionados aos afazeres (todos) pendentes.
5
+ */
6
+ export declare class TodoReminders {
7
+ /**
8
+ * Orienta o colega a criar uma lista de afazeres caso não tenha nenhuma no início da iteração.
9
+ */
10
+ promptTodoCreation(_: unknown, pipa: PipaApi): void;
11
+ /**
12
+ * Notifica o usuário/agente sobre tarefas pendentes ao final de uma interação.
13
+ */
14
+ notifyPendingTodos(_: unknown, pipa: PipaApi): void;
15
+ }
16
+ //# sourceMappingURL=reminders.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"reminders.d.ts","sourceRoot":"","sources":["../../../../../../extensions/pipa/features/todo/hooks/reminders.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,KAAK,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAKnD;;;GAGG;AACH,qBAAa,aAAa;IACxB;;OAEG;IAEH,kBAAkB,CAAC,CAAC,EAAE,OAAO,EAAE,IAAI,EAAE,OAAO,QAiB3C;IAED;;OAEG;IAEH,kBAAkB,CAAC,CAAC,EAAE,OAAO,EAAE,IAAI,EAAE,OAAO,QAqB3C;CACF"}
@@ -0,0 +1,35 @@
1
+ import { TodoValidator } from './validator';
2
+ import { PipaApi } from '../../../interfaces';
3
+ import { FileManager } from '../../../lib';
4
+ import { TodoItem, TodoToolSchema } from '../todo.entity';
5
+ /**
6
+ * Mixin central responsável pela manipulação persistente da lista de afazeres no TodoHub.
7
+ */
8
+ export declare class TodoCore extends TodoValidator {
9
+ readonly pipa: PipaApi;
10
+ readonly fileManager: FileManager<TodoItem[]>;
11
+ constructor(pipa: PipaApi);
12
+ get sessionId(): string;
13
+ persist(): void;
14
+ /**
15
+ * Atualiza um item de afazer existente e persiste as mudanças.
16
+ * @param data Payload único da action 'update'.
17
+ * @returns O item atualizado.
18
+ */
19
+ update({ id, action, ...updates }: TodoToolSchema<'update'>): TodoItem;
20
+ /**
21
+ * Remove uma etapa da lista e persiste o novo estado.
22
+ * @param data Payload único da action 'remove'.
23
+ */
24
+ remove({ id }: TodoToolSchema<'remove'>): void;
25
+ /**
26
+ * Limpa inteiramente o histórico e os afazeres da lista.
27
+ */
28
+ clear(): void;
29
+ /**
30
+ * Recupera todos os passos atuais da lista de afazeres.
31
+ * @returns Os itens da lista de afazeres.
32
+ */
33
+ list(): TodoItem[];
34
+ }
35
+ //# sourceMappingURL=core.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"core.d.ts","sourceRoot":"","sources":["../../../../../../extensions/pipa/features/todo/hub/core.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAC5C,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAC9C,OAAO,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAC3C,OAAO,EAAE,QAAQ,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAI1D;;GAEG;AACH,qBAAa,QAAS,SAAQ,aAAa;IAG7B,QAAQ,CAAC,IAAI,EAAE,OAAO;IAFlC,SAAgB,WAAW,EAAE,WAAW,CAAC,QAAQ,EAAE,CAAC,CAAC;IAErD,YAAqB,IAAI,EAAE,OAAO,EAIjC;IAED,IAAW,SAAS,IAAI,MAAM,CAE7B;IAEM,OAAO,IAAI,IAAI,CAErB;IAED;;;;OAIG;IACH,MAAM,CAAC,EAAE,EAAE,EAAE,MAAM,EAAE,GAAG,OAAO,EAAE,EAAE,cAAc,CAAC,QAAQ,CAAC,GAAG,QAAQ,CAOrE;IAED;;;OAGG;IACH,MAAM,CAAC,EAAE,EAAE,EAAE,EAAE,cAAc,CAAC,QAAQ,CAAC,GAAG,IAAI,CAK7C;IAED;;OAEG;IACH,KAAK,IAAI,IAAI,CAIZ;IAED;;;OAGG;IACH,IAAI,IAAI,QAAQ,EAAE,CAEjB;CACF"}
@@ -0,0 +1,4 @@
1
+ export * from './state';
2
+ export * from './validator';
3
+ export * from './core';
4
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../extensions/pipa/features/todo/hub/index.ts"],"names":[],"mappings":"AAAA,cAAc,SAAS,CAAC;AACxB,cAAc,aAAa,CAAC;AAC5B,cAAc,QAAQ,CAAC"}
@@ -0,0 +1,40 @@
1
+ import { TodoItem } from '../todo.entity';
2
+ /**
3
+ * Mantém e gerencia o estado em memória da lista de afazeres dos agentes.
4
+ */
5
+ export declare class TodoState {
6
+ /**
7
+ * Recupera a store global de todos.
8
+ */
9
+ static get store(): Map<string, TodoItem>;
10
+ /**
11
+ * Carrega os afazeres persistidos em disco (todo.json do workspace do agente)
12
+ * para a store em memória, substituindo os itens atuais da sessão.
13
+ */
14
+ static load(workspaceDir: string, sessionId: string): void;
15
+ /**
16
+ * Adiciona um novo item ao estado.
17
+ */
18
+ static add(item: TodoItem): TodoItem;
19
+ /**
20
+ * Atualiza parcialmente um item existente no estado.
21
+ */
22
+ static update(id: string, data: Partial<TodoItem>): TodoItem | undefined;
23
+ /**
24
+ * Remove permanentemente um item do estado através de seu ID.
25
+ */
26
+ static delete(id: string): void;
27
+ /**
28
+ * Limpa integralmente a lista de afazeres de um agente específico.
29
+ */
30
+ static clear(sessionId: string): void;
31
+ /**
32
+ * Recupera a lista contendo todos os itens atuais da lista de afazeres de um agente.
33
+ */
34
+ static list(sessionId: string): TodoItem[];
35
+ /**
36
+ * Obtém um item específico da lista de afazeres por seu ID.
37
+ */
38
+ static get(id: string): TodoItem | undefined;
39
+ }
40
+ //# sourceMappingURL=state.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"state.d.ts","sourceRoot":"","sources":["../../../../../../extensions/pipa/features/todo/hub/state.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AAE1C;;GAEG;AACH,qBAAa,SAAS;IACpB;;OAEG;IACH,WAAkB,KAAK,IAAI,GAAG,CAAC,MAAM,EAAE,QAAQ,CAAC,CAQ/C;IAED;;;OAGG;IACH,OAAc,IAAI,CAAC,YAAY,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,GAAG,IAAI,CAMhE;IAED;;OAEG;IACH,OAAc,GAAG,CAAC,IAAI,EAAE,QAAQ,GAAG,QAAQ,CAI1C;IAED;;OAEG;IACH,OAAc,MAAM,CAAC,EAAE,EAAE,MAAM,EAAE,IAAI,EAAE,OAAO,CAAC,QAAQ,CAAC,GAAG,QAAQ,GAAG,SAAS,CAW9E;IAED;;OAEG;IACH,OAAc,MAAM,CAAC,EAAE,EAAE,MAAM,GAAG,IAAI,CAErC;IAED;;OAEG;IACH,OAAc,KAAK,CAAC,SAAS,EAAE,MAAM,GAAG,IAAI,CAM3C;IAED;;OAEG;IACH,OAAc,IAAI,CAAC,SAAS,EAAE,MAAM,GAAG,QAAQ,EAAE,CAEhD;IAED;;OAEG;IACH,OAAc,GAAG,CAAC,EAAE,EAAE,MAAM,GAAG,QAAQ,GAAG,SAAS,CAElD;CACF"}
@@ -0,0 +1,24 @@
1
+ import { TodoItem } from '../todo.entity';
2
+ /**
3
+ * Classe responsável por validar as ações executadas na lista de afazeres,
4
+ * retornando falhas seguras para notificação em caso de operações inválidas.
5
+ */
6
+ export declare class TodoValidator {
7
+ /**
8
+ * Valida se um item é passível de ser atualizado.
9
+ *
10
+ * @param sessionId O ID da sessão do agente.
11
+ * @param id O ID do item que está sendo buscado.
12
+ * @returns Um objeto ValidationResult atestando se a ação pode prosseguir, com erro no caso negativo.
13
+ */
14
+ canUpdate(sessionId: string, id: string): TodoItem;
15
+ /**
16
+ * Valida se um item é passível de ser removido.
17
+ *
18
+ * @param sessionId O ID da sessão do agente.
19
+ * @param id O ID do item que está sendo buscado.
20
+ * @returns Um objeto ValidationResult atestando se a ação pode prosseguir, com erro no caso negativo.
21
+ */
22
+ canRemove(sessionId: string, id: string): TodoItem;
23
+ }
24
+ //# sourceMappingURL=validator.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"validator.d.ts","sourceRoot":"","sources":["../../../../../../extensions/pipa/features/todo/hub/validator.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AAG1C;;;GAGG;AACH,qBAAa,aAAa;IACxB;;;;;;OAMG;IACH,SAAS,CAAC,SAAS,EAAE,MAAM,EAAE,EAAE,EAAE,MAAM,GAAG,QAAQ,CAWjD;IAED;;;;;;OAMG;IACH,SAAS,CAAC,SAAS,EAAE,MAAM,EAAE,EAAE,EAAE,MAAM,GAAG,QAAQ,CAWjD;CACF"}
@@ -0,0 +1,31 @@
1
+ import Type from 'typebox';
2
+ export declare const TODO_TOOL_SCHEMA: {
3
+ instantiate: Type.TObject<{
4
+ action: Type.TLiteral<"instantiate">;
5
+ item: Type.TString;
6
+ }>;
7
+ update: Type.TObject<{
8
+ action: Type.TLiteral<"update">;
9
+ id: Type.TString;
10
+ status: Type.TOptional<Type.TUnion<boolean[]>>;
11
+ text: Type.TOptional<Type.TString>;
12
+ }>;
13
+ remove: Type.TObject<{
14
+ action: Type.TLiteral<"remove">;
15
+ id: Type.TString;
16
+ }>;
17
+ list: Type.TObject<{
18
+ action: Type.TLiteral<"list">;
19
+ }>;
20
+ clear: Type.TObject<{
21
+ action: Type.TLiteral<"clear">;
22
+ }>;
23
+ };
24
+ export declare const TODO_TOOL_ACTIONS_MESSAGE: {
25
+ instantiate: string;
26
+ update: string;
27
+ remove: string;
28
+ list: string;
29
+ clear: string;
30
+ };
31
+ //# sourceMappingURL=todo.definitions.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"todo.definitions.d.ts","sourceRoot":"","sources":["../../../../../extensions/pipa/features/todo/todo.definitions.ts"],"names":[],"mappings":"AAAA,OAAO,IAAI,MAAM,SAAS,CAAC;AAO3B,eAAO,MAAM,gBAAgB;IAC3B,WAAW;;;;IAMX,MAAM;;;;;;IAgBN,MAAM;;;;IAMN,IAAI;;;IAKJ,KAAK;;;CAGN,CAAC;AAEF,eAAO,MAAM,yBAAyB;IACpC,WAAW;IACX,MAAM;IACN,MAAM;IACN,IAAI;IACJ,KAAK;CACN,CAAC"}
@@ -0,0 +1,44 @@
1
+ import { BaseClass, ToolActionPayload, ToolParams } from '../../interfaces/common';
2
+ import { TODO_TOOL_SCHEMA } from './todo.definitions';
3
+ /**
4
+ * Status possíveis para um item na lista de afazeres.
5
+ */
6
+ export type TodoStatus = 'pending' | 'in_progress' | 'completed';
7
+ export type TodoToolParams = ToolParams<typeof TODO_TOOL_SCHEMA>;
8
+ /** Payload de cada ação da tool todo */
9
+ export type TodoToolSchema<K extends keyof typeof TODO_TOOL_SCHEMA> = ToolActionPayload<typeof TODO_TOOL_SCHEMA, K>;
10
+ /**
11
+ * Representa um único passo na lista de afazeres do agente.
12
+ */
13
+ export declare class TodoItem {
14
+ constructor(data: BaseClass<TodoItem>);
15
+ /**
16
+ * Identificador único do item.
17
+ */
18
+ id: string;
19
+ /**
20
+ * Identificador da sessão do agente que é dono deste item.
21
+ */
22
+ sessionId: string;
23
+ /**
24
+ * Texto descrevendo a etapa ou tarefa a ser realizada.
25
+ */
26
+ text: string;
27
+ /**
28
+ * Status atual do item.
29
+ */
30
+ status: TodoStatus;
31
+ /**
32
+ * Indica se o item está pendente.
33
+ */
34
+ get isPending(): boolean;
35
+ /**
36
+ * Indica se o item está em andamento.
37
+ */
38
+ get isInProgress(): boolean;
39
+ /**
40
+ * Indica se o item está concluído.
41
+ */
42
+ get isCompleted(): boolean;
43
+ }
44
+ //# sourceMappingURL=todo.entity.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"todo.entity.d.ts","sourceRoot":"","sources":["../../../../../extensions/pipa/features/todo/todo.entity.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,iBAAiB,EAAE,UAAU,EAAE,MAAM,yBAAyB,CAAC;AACnF,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AAEtD;;GAEG;AACH,MAAM,MAAM,UAAU,GAAG,SAAS,GAAG,aAAa,GAAG,WAAW,CAAC;AAEjE,MAAM,MAAM,cAAc,GAAG,UAAU,CAAC,OAAO,gBAAgB,CAAC,CAAC;AAEjE,wCAAwC;AACxC,MAAM,MAAM,cAAc,CAAC,CAAC,SAAS,MAAM,OAAO,gBAAgB,IAAI,iBAAiB,CAAC,OAAO,gBAAgB,EAAE,CAAC,CAAC,CAAC;AAEpH;;GAEG;AACH,qBAAa,QAAQ;IACnB,YAAY,IAAI,EAAE,SAAS,CAAC,QAAQ,CAAC,EAEpC;IAED;;OAEG;IACH,EAAE,EAAE,MAAM,CAAC;IAEX;;OAEG;IACH,SAAS,EAAE,MAAM,CAAC;IAElB;;OAEG;IACH,IAAI,EAAE,MAAM,CAAC;IAEb;;OAEG;IACH,MAAM,EAAE,UAAU,CAAC;IAEnB;;OAEG;IACH,IAAI,SAAS,IAAI,OAAO,CAEvB;IAED;;OAEG;IACH,IAAI,YAAY,IAAI,OAAO,CAE1B;IAED;;OAEG;IACH,IAAI,WAAW,IAAI,OAAO,CAEzB;CACF"}
@@ -0,0 +1,18 @@
1
+ import type { ExtensionAPI } from '@earendil-works/pi-coding-agent';
2
+ import { PipaBaseFeature } from '../base-feature';
3
+ import { TodoReminders } from './hooks';
4
+ declare const TodoFeature_base: import("ts-mixer/dist/types/types").Class<any[], PipaBaseFeature & TodoReminders, typeof PipaBaseFeature & typeof TodoReminders>;
5
+ /**
6
+ * Feature principal do sistema "todo", responsável por acoplar a ferramenta (tool)
7
+ * correspondente ao agente e gerenciar seu fluxo.
8
+ */
9
+ export declare class TodoFeature extends TodoFeature_base {
10
+ private mountPipa;
11
+ /**
12
+ * Inicializa o suporte à ferramenta 'todo' no ecossistema do Pi.
13
+ * Registra a tool e delega o dispatch das actions ao setToolActions (padrão backlog).
14
+ */
15
+ initialize(pi: ExtensionAPI): void;
16
+ }
17
+ export {};
18
+ //# sourceMappingURL=todo.feature.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"todo.feature.d.ts","sourceRoot":"","sources":["../../../../../extensions/pipa/features/todo/todo.feature.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,iCAAiC,CAAC;AACpE,OAAO,EAAE,eAAe,EAAE,MAAM,iBAAiB,CAAC;AAQlD,OAAO,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;;AAGxC;;;GAGG;AACH,qBAAa,WAAY,SAAQ,gBAAqC;IAIpE,OAAO,CAAC,SAAS;IAIjB;;;OAGG;IACH,UAAU,CAAC,EAAE,EAAE,YAAY,GAAG,IAAI,CAgCjC;CACF"}
@@ -0,0 +1,24 @@
1
+ import { PipaApi } from '../../interfaces';
2
+ import { TodoItem, TodoToolSchema } from './todo.entity';
3
+ import { TodoValidator, TodoCore } from './hub';
4
+ declare const TodoHub_base: import("ts-mixer/dist/types/types").Class<any[], TodoValidator & TodoCore, typeof TodoValidator & typeof TodoCore>;
5
+ /**
6
+ * Gerencia a ferramenta local de TODO do agente (Subagente).
7
+ * Responsável pela persistência em disco do passo-a-passo.
8
+ *
9
+ * Os métodos seguem a convenção do padrão backlog: nome camelCase da action
10
+ * (instantiate/update/remove/list/clear) recebendo payload único tipado.
11
+ */
12
+ export declare class TodoHub extends TodoHub_base {
13
+ readonly pipa: PipaApi;
14
+ constructor(pipa: PipaApi);
15
+ /**
16
+ * Adiciona um novo item à lista de afazeres, persistindo-o no arquivo local.
17
+ *
18
+ * @param data Payload único da action 'instantiate' contendo o texto descritivo do passo.
19
+ * @returns O item criado.
20
+ */
21
+ instantiate(data: TodoToolSchema<'instantiate'>): TodoItem;
22
+ }
23
+ export {};
24
+ //# sourceMappingURL=todo.hub.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"todo.hub.d.ts","sourceRoot":"","sources":["../../../../../extensions/pipa/features/todo/todo.hub.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC;AAC3C,OAAO,EAAE,QAAQ,EAAE,cAAc,EAAE,MAAM,eAAe,CAAC;AACzD,OAAO,EAAa,aAAa,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;;AAE3D;;;;;;GAMG;AACH,qBAAa,OAAQ,SAAQ,YAA8B;IAC7C,QAAQ,CAAC,IAAI,EAAE,OAAO;IAAlC,YAAqB,IAAI,EAAE,OAAO,EAEjC;IAED;;;;;OAKG;IACH,WAAW,CAAC,IAAI,EAAE,cAAc,CAAC,aAAa,CAAC,GAAG,QAAQ,CAMzD;CACF"}
@@ -0,0 +1,22 @@
1
+ import type { ContextEvent, TurnEndEvent } from '@earendil-works/pi-coding-agent';
2
+ import type { ContextEventResult } from '@earendil-works/pi-coding-agent/extensions';
3
+ import type { PipaApi } from '../../../interfaces';
4
+ /**
5
+ * Substitui o conteúdo de tool results antigos e volumosos por um stub com caminho de arquivo,
6
+ * reduzindo o contexto enviado ao LLM a cada turn (micro-compact periódico).
7
+ *
8
+ * Regras de elegibilidade (todas devem ser satisfeitas):
9
+ * 1. O tool result não é de erro (`isError === false`).
10
+ * 2. O turn em que foi produzido é anterior à janela de turns recentes (`COMPACTOR_RECENT_TURNS`).
11
+ * 3. O conteúdo textual total supera `COMPACTOR_MIN_CHARS` caracteres.
12
+ *
13
+ * Idempotente: resultados já compactados (conteúdo curto) não serão reprocessados.
14
+ * Sem estado persistido: o Map é reconstruído a cada sessão via eventos `turn_end`.
15
+ */
16
+ export declare class ToolResultCompactor {
17
+ private readonly toolResultTurns;
18
+ private currentTurn;
19
+ trackTurn(event: TurnEndEvent, _pipa: PipaApi): void;
20
+ compact(event: ContextEvent, pipa: PipaApi): ContextEventResult | void;
21
+ }
22
+ //# sourceMappingURL=compactor.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"compactor.d.ts","sourceRoot":"","sources":["../../../../../../extensions/pipa/features/tool-result-compactor/hooks/compactor.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,YAAY,EAAE,YAAY,EAAE,MAAM,iCAAiC,CAAC;AAClF,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,4CAA4C,CAAC;AAGrF,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAGnD;;;;;;;;;;;GAWG;AACH,qBAAa,mBAAmB;IAC9B,OAAO,CAAC,QAAQ,CAAC,eAAe,CAA6B;IAC7D,OAAO,CAAC,WAAW,CAAK;IAGxB,SAAS,CAAC,KAAK,EAAE,YAAY,EAAE,KAAK,EAAE,OAAO,GAAG,IAAI,CAMnD;IAGD,OAAO,CAAC,KAAK,EAAE,YAAY,EAAE,IAAI,EAAE,OAAO,GAAG,kBAAkB,GAAG,IAAI,CA0DrE;CACF"}
@@ -0,0 +1,12 @@
1
+ import { PipaBaseFeature } from '../base-feature';
2
+ import { ToolResultCompactor } from './hooks/compactor';
3
+ declare const ToolResultCompactorFeature_base: import("ts-mixer/dist/types/types").Class<any[], PipaBaseFeature & ToolResultCompactor, typeof PipaBaseFeature & typeof ToolResultCompactor>;
4
+ /**
5
+ * Feature de higiene de contexto: substitui o conteúdo de tool results antigos e volumosos
6
+ * por um stub com caminho de arquivo, realizando micro-compactações periódicas sem intervenção
7
+ * do usuário.
8
+ */
9
+ export declare class ToolResultCompactorFeature extends ToolResultCompactorFeature_base {
10
+ }
11
+ export {};
12
+ //# sourceMappingURL=tool-result-compactor.feature.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"tool-result-compactor.feature.d.ts","sourceRoot":"","sources":["../../../../../extensions/pipa/features/tool-result-compactor/tool-result-compactor.feature.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,eAAe,EAAE,MAAM,iBAAiB,CAAC;AAClD,OAAO,EAAE,mBAAmB,EAAE,MAAM,mBAAmB,CAAC;;AAExD;;;;GAIG;AACH,qBAAa,0BAA2B,SAAQ,+BAA2C;CAAG"}
@@ -0,0 +1,5 @@
1
+ import './core/config';
2
+ import type { ExtensionAPI } from '@earendil-works/pi-coding-agent';
3
+ import './cross-cutting/store';
4
+ export default function main(pi: ExtensionAPI): Promise<void>;
5
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../extensions/pipa/index.ts"],"names":[],"mappings":"AAAA,OAAO,eAAe,CAAC;AACvB,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,iCAAiC,CAAC;AAEpE,OAAO,uBAAuB,CAAC;AAa/B,wBAA8B,IAAI,CAAC,EAAE,EAAE,YAAY,iBAelD"}