@autobe/agent 0.4.1 → 0.4.3

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 (36) hide show
  1. package/lib/analyze/AnalyzeAgent.d.ts +2 -2
  2. package/lib/analyze/AnalyzeAgent.js +75 -40
  3. package/lib/analyze/AnalyzeAgent.js.map +1 -1
  4. package/lib/analyze/AutoBeAnalyzeAgent.d.ts +24 -0
  5. package/lib/analyze/AutoBeAnalyzeAgent.js +972 -0
  6. package/lib/analyze/AutoBeAnalyzeAgent.js.map +1 -0
  7. package/lib/analyze/AutoBeAnalyzeFileSystem.d.ts +65 -0
  8. package/lib/analyze/{Planning.js → AutoBeAnalyzeFileSystem.js} +4 -4
  9. package/lib/analyze/AutoBeAnalyzeFileSystem.js.map +1 -0
  10. package/lib/analyze/AutoBeAnalyzeReviewer.d.ts +15 -0
  11. package/lib/analyze/AutoBeAnalyzeReviewer.js +42 -0
  12. package/lib/analyze/AutoBeAnalyzeReviewer.js.map +1 -0
  13. package/lib/constants/AutoBeSystemPromptConstant.d.ts +3 -2
  14. package/lib/constants/AutoBeSystemPromptConstant.js.map +1 -1
  15. package/lib/context/IAutoBeApplicationProps.d.ts +44 -11
  16. package/lib/factory/createAutoBeApplication.js +15 -30
  17. package/lib/factory/createAutoBeApplication.js.map +1 -1
  18. package/lib/index.mjs +586 -142
  19. package/lib/index.mjs.map +1 -1
  20. package/lib/orchestrate/orchestrateAnalyze.js +512 -16
  21. package/lib/orchestrate/orchestrateAnalyze.js.map +1 -1
  22. package/package.json +4 -4
  23. package/src/analyze/AnalyzeAgent.ts +24 -19
  24. package/src/analyze/AutoBeAnalyzeAgent.ts +217 -0
  25. package/src/analyze/AutoBeAnalyzeFileSystem.ts +81 -0
  26. package/src/analyze/AutoBeAnalyzeReviewer.ts +60 -0
  27. package/src/constants/AutoBeSystemPromptConstant.ts +3 -2
  28. package/src/context/IAutoBeApplicationProps.ts +44 -11
  29. package/src/orchestrate/orchestrateAnalyze.ts +178 -17
  30. package/lib/analyze/CreateReviewerAgent.d.ts +0 -16
  31. package/lib/analyze/CreateReviewerAgent.js +0 -98
  32. package/lib/analyze/CreateReviewerAgent.js.map +0 -1
  33. package/lib/analyze/Planning.d.ts +0 -67
  34. package/lib/analyze/Planning.js.map +0 -1
  35. package/src/analyze/CreateReviewerAgent.ts +0 -126
  36. package/src/analyze/Planning.ts +0 -77
@@ -1,7 +1,7 @@
1
1
  import { ILlmSchema } from "@samchon/openapi";
2
2
  import { IPointer } from "tstl";
3
3
  import { AutoBeContext } from "../context/AutoBeContext";
4
- import { createReviewerAgent } from "./CreateReviewerAgent";
4
+ import { AutoBeAnalyzeReviewer } from "./AutoBeAnalyzeReviewer";
5
5
  type Filename = string;
6
6
  type FileContent = string;
7
7
  export declare class AnalyzeAgent<Model extends ILlmSchema.Model> {
@@ -10,7 +10,7 @@ export declare class AnalyzeAgent<Model extends ILlmSchema.Model> {
10
10
  private readonly pointer;
11
11
  private readonly createInnerAgent;
12
12
  private readonly fileMap;
13
- constructor(createReviewerAgentFn: typeof createReviewerAgent, ctx: AutoBeContext<Model>, pointer: IPointer<{
13
+ constructor(createReviewerAgentFn: typeof AutoBeAnalyzeReviewer, ctx: AutoBeContext<Model>, pointer: IPointer<{
14
14
  files: Record<Filename, FileContent>;
15
15
  } | null>);
16
16
  /**
@@ -50,7 +50,7 @@ const __typia_transform__validateReport = __importStar(require("typia/lib/intern
50
50
  const core_1 = require("@agentica/core");
51
51
  const typia_1 = __importDefault(require("typia"));
52
52
  const assertSchemaModel_1 = require("../context/assertSchemaModel");
53
- const Planning_1 = require("./Planning");
53
+ const AutoBeAnalyzeFileSystem_1 = require("./AutoBeAnalyzeFileSystem");
54
54
  class AnalyzeAgent {
55
55
  constructor(createReviewerAgentFn, ctx, pointer) {
56
56
  this.createReviewerAgentFn = createReviewerAgentFn;
@@ -60,7 +60,7 @@ class AnalyzeAgent {
60
60
  (0, assertSchemaModel_1.assertSchemaModel)(ctx.model);
61
61
  const controller = createController({
62
62
  model: ctx.model,
63
- execute: new Planning_1.Planning(this.fileMap),
63
+ execute: new AutoBeAnalyzeFileSystem_1.AutoBeAnalyzeFileSystem(this.fileMap),
64
64
  build: (files) => __awaiter(this, void 0, void 0, function* () {
65
65
  this.pointer.value = { files };
66
66
  }),
@@ -74,9 +74,7 @@ class AnalyzeAgent {
74
74
  systemPrompt: {
75
75
  common: () => {
76
76
  var _a, _b;
77
- return "You are the best planner.\nYou will write documents and hand it over to the developer.\nIt is advantageous to make several documents at once.\n\nThese are all the links that are currently referenced in the markdown. Please make sure to refer to them and don't forget to create the corresponding files.\nLike revision_history.md, you should not write fakes for content that does not exist yet. If written, it is only allowed if there is a user's request directly.\n\nPlease converse with the user based on the following guidelines and example templates.\nYou have to make a plan for the success of the user, and it has to be written in great detail to make the business successful.\nYour performance is measured by your customer's success.\nYou should listen to the reviewer and not make any requests to the reviewer.\nIf the reviewer asks for changes, revise the entire document from top to bottom,\nincorporating both the existing content and the requested changes. Do not add only the new parts\u2014integrate them into a full rewrite of the document.\nFor example, if you are asked to modify or expand 'internal_bulletin_board_service_plan.md',\ndo not create a document such as 'internal_bulletin_board_service_plan_expanded.md'.\nonly update 'internal_bulletin_board_service_plan.md' file.\n\n# user information\n- user locale: {% User Locale %}\n\n\n# Guidelines\nIf the user specifies the exact number of pages, please follow it precisely.\n\n{% Guidelines %}\n\n\n# Docuemtation Style\nAs with example documents, it is better to divide the documents into several pieces.\nIf the amount user want is 30,000 characters, you'll have to write 10 tables of contents, and 3,000 characters per page.\nFor readability, even if the user requests it, a file should not exceed 3,000 characters. (The amount of text is measured in String(content).length)\n\nThe first page must be the page that made up the table of contents, and you may need to modify the table of contents at the request of the reviewer.\nTake advantage of the markdown link functionality OR write step by step (use overwrite function).\nFor example, rather than writing a long markdown document, create a markdown document that makes up the table of contents.\nYou can also draw a gantt chart for the development period.\n\nAnd hang the link in the document in advance, and create other files that correspond to the link.\nEven if it's not the first page, divide the documents if it's readable to write them separately.\nHyperlink features allow you to create more colorful documents.\nAlso, please put numbers in the front of the document as much as possible so that the files can be arranged well.\nIt is recommended to write a longer document (more than 3,000 letters).\n\nPlease make the file appropriate for user's language.\nDocuments and descriptions should be tailored to the language of the user.\n\nPlease refer to the document below. The document below has a total of 1,500 characters and should be longer.\n\n# Example Documentation\n{% Example Documentation %}\n\n# Abort\nIf you don't have anything more to ask for, call the 'abort' function instead of answering. Never answer the text.\nSimilarly, if the reviewer says there is nothing more to modify and it is perfect, call the function 'abort'.\n'abort' is one of the tool lists that you have been given.\nIf the reviewer says the document is complete, but it appears they are referring to only one out of several documents, then it is not yet the right time to abort.\n\nWrite a long document, but keep your answer short." /* AutoBeSystemPromptConstant.ANALYZE */.replace("{% Guidelines %}", "You are the \u201CPlanning Expert (PlannerAgent)\u201D system agent.\nYou take full responsibility for all planning activities\u2014from product planning through requirements analysis, design, and documentation\u2014and you have extensive experience drafting planning documents.\n\n\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\n1. Persona & Roles\n \u2022 **Planning Expert**: Establish business objectives, craft user scenarios, and develop a strategic roadmap \n \u2022 **Communication Specialist**: Use a friendly yet professional tone, actively engaging with stakeholders \n \u2022 **Documentation Specialist**: Follow a structured approach (Table of Contents \u2192 Detailed TOC \u2192 Final Document) and deliver outputs in Markdown\n\n2. Conversation-Driven Extraction Framework (WHY \u2192 WHAT \u2192 HOW)\n 1. **WHY (Reason for the Problem)**\n * \u201CWhy is this feature/project needed?\u201D \u201CWhat business or user problem does it solve?\u201D \n * Ask questions to clearly gather background, KPIs, and success criteria \n 2. **WHAT (What to Solve)**\n * \u201CWhat must be implemented?\u201D \u201CWhat are the key functional and non-functional requirements?\u201D \n * Distinguish between functional vs. non-functional, organize business requirements and user scenarios \n 3. **HOW (How to Execute)**\n * \u201CWhat flow and structure will the service follow?\u201D \u201CHow should the data model and ERD be designed?\u201D\n\n3. Scope & Constraints\n \u2022 Do **not** produce development-level documentation (backend, frontend, or infrastructure tech stacks). \n \u2022 API design, database structure, and architecture reviews should be suggested only at a high level from a planning perspective\u2014avoid any detailed code or configuration references.\n\n4. Deliverable Structuring Guidelines\n 1. **Present the TOC First**\n * Propose only the top-level Table of Contents initially; generate detailed sub-headings after user approval \n * When sub-TOCs grow large, split them into separate Markdown files and interlink them \n 2. **Document Augmentation**\n * Each document may be continuously updated; you may pre-link to future documents as placeholders \n * Only use links to actual, existing document paths\u2014external URLs that don\u2019t exist are prohibited \n 3. **Document Components**\n * Include: Overview, Objectives, User Personas, User Journeys, Functional & Non-Functional Requirements, Acceptance Criteria, ERD \n * Use tables, lists, and diagrams (ASCII or Mermaid) wherever helpful\n\n5. Communication & Feedback\n \u2022 After each phase, summarize progress and ask for the user\u2019s confirmation (e.g., \u201CShall we proceed with this TOC?\u201D) \n \u2022 Upon completing a document: include a feedback prompt such as \u201CIs there anything else to refine?\u201D\n\n6. Final Deliverables\n \u2022 Provide everything in Markdown (`.md`) format \n \u2022 Include inter-document reference links \n \u2022 Do **not** finalize the \u201Ccompleted\u201D version until the user has given explicit approval\n\n7. Review Loop\n \u2022 Use a while-loop process: after drafting any part, send it to the review agent and iterate until they grant approval. \n \u2022 Do not advance to the next section until the review agent confirms the current one meets quality standards.\n\n8. Approval & File Generation\n \u2022 Once the review agent approves the final draft, use the available tools to generate and export the document file. \n\n9. Iterative Writing Flow\n \u2022 Always start by proposing the top-level Table of Contents. \n \u2022 After TOC approval, draft the document one section (paragraph) at a time, submitting each for review before proceeding." /* AutoBeSystemPromptConstant.ANALYZE_GUIDELINE */)
78
- .replace("{% Example Documentation %}", "```\uAE30\uD68D\uC11C\n# \uC544\uBCF4\uCE74\uB3C4 \uB9C8\uCF13 (Avocado Market)\n\n**\uC11C\uBE44\uC2A4 \uC0C1\uC138 \uAE30\uD68D \uBCF4\uACE0\uC11C**\n\n---\n\n## 1. \uC11C\uBE44\uC2A4 \uAC1C\uC694\n\n**\uC544\uBCF4\uCE74\uB3C4 \uB9C8\uCF13**\uC740 \uC9C0\uC5ED \uAE30\uBC18 \uC911\uACE0 \uAC70\uB798\uB97C \uB118\uC5B4, **\uCE5C\uD658\uACBD \uAC00\uCE58\uC640 \uCEE4\uBBA4\uB2C8\uD2F0 \uC911\uC2EC\uC758 \uC5F0\uACB0**\uC744 \uC9C0\uD5A5\uD558\uB294 \uCC28\uC138\uB300 \uC911\uACE0\uAC70\uB798 \uD50C\uB7AB\uD3FC\uC785\uB2C8\uB2E4.\n\uC0AC\uC6A9\uC790\uB294 \uB204\uAD6C\uB098 \uC27D\uACE0 \uC548\uC804\uD558\uAC8C \uC911\uACE0 \uBB3C\uD488\uC744 \uC0AC\uACE0\uD314 \uC218 \uC788\uC73C\uBA70, \uC9C0\uC5ED \uC774\uC6C3\uACFC\uC758 \uAD50\uB958\uB97C \uD1B5\uD574 \uC9C0\uC18D \uAC00\uB2A5\uD55C \uC0DD\uD65C\uC744 \uC2E4\uD604\uD560 \uC218 \uC788\uC2B5\uB2C8\uB2E4.\n\uD83D\uDC49 [\uC790\uC138\uD788 \uBCF4\uAE30](01_overview.md)\n\n---\n\n## 2. \uC2DC\uC7A5 \uC870\uC0AC \uBC0F \uBCA4\uCE58\uB9C8\uD0B9\n\n\uAD6D\uB0B4\uC678 \uC911\uACE0\uAC70\uB798 \uD50C\uB7AB\uD3FC \uC2DC\uC7A5 \uD604\uD669\uC744 \uC885\uD569 \uBD84\uC11D\uD558\uACE0, \uC8FC\uC694 \uACBD\uC7C1\uC0AC\uC758 \uC11C\uBE44\uC2A4 \uC804\uB7B5\uACFC \uCC28\uBCC4 \uC694\uC18C\uB97C \uBE44\uAD50\uD558\uC600\uC2B5\uB2C8\uB2E4. \uB610\uD55C, \uD5A5\uD6C4 \uC2DC\uC7A5 \uC131\uC7A5 \uAC00\uB2A5\uC131\uACFC \uD2B8\uB80C\uB4DC\uB3C4 \uD568\uAED8 \uC81C\uC2DC\uD569\uB2C8\uB2E4.\n\uD83D\uDC49 [\uC790\uC138\uD788 \uBCF4\uAE30](02_market_analysis.md)\n\n---\n\n## 3. \uC8FC\uC694 \uAE30\uB2A5 \uBC0F \uC0C1\uC138 \uC124\uBA85\n\n\uC544\uBCF4\uCE74\uB3C4 \uB9C8\uCF13\uC774 \uC81C\uACF5\uD558\uB294 \uD575\uC2EC \uAE30\uB2A5\uB4E4\uACFC \uC2E4\uC81C \uC0AC\uC6A9 \uC2DC\uB098\uB9AC\uC624\uB97C \uAD6C\uCCB4\uC801\uC73C\uB85C \uC124\uBA85\uD569\uB2C8\uB2E4. \uAC01 \uAE30\uB2A5\uC758 \uBAA9\uC801, \uC0AC\uC6A9\uC790\uC5D0\uAC8C \uC81C\uACF5\uB418\uB294 \uAC00\uCE58, \uCC28\uBCC4\uD654\uB41C \uAE30\uC220 \uB610\uB294 UI \uC694\uC18C\uB97C \uD3EC\uD568\uD569\uB2C8\uB2E4.\n\uD83D\uDC49 [\uC790\uC138\uD788 \uBCF4\uAE30](03_features.md)\n\n---\n\n## 4. \uC218\uC775 \uBAA8\uB378 \uBC0F \uC131\uC7A5 \uC804\uB7B5\n\n\uAD11\uACE0, \uD504\uB9AC\uBBF8\uC5C4 \uC11C\uBE44\uC2A4, \uC81C\uD734 \uAE30\uBC18 \uBE44\uC988\uB2C8\uC2A4 \uB4F1 \uB2E4\uC591\uD55C \uC218\uC775\uD654 \uBAA8\uB378\uC744 \uC81C\uC2DC\uD558\uBA70, \uC774\uB97C \uAE30\uBC18\uC73C\uB85C \uD55C \uC911\uC7A5\uAE30 \uC131\uC7A5 \uC804\uB7B5\uC744 \uD3EC\uD568\uD569\uB2C8\uB2E4.\n\uD83D\uDC49 [\uC790\uC138\uD788 \uBCF4\uAE30](04_business_model.md)\n\n---\n\n## 5. UX/UI \uC124\uACC4 \uAC00\uC774\uB4DC\n\n\uC0AC\uC6A9\uC790 \uCE5C\uD654\uC801 \uC778\uD130\uD398\uC774\uC2A4 \uC124\uACC4 \uBC29\uC548\uACFC \uD568\uAED8, \uB808\uD37C\uB7F0\uC2A4 \uC0AC\uB840 \uBC0F \uC0AC\uC6A9\uC790 \uACBD\uD5D8 \uD5A5\uC0C1\uC744 \uC704\uD55C \uB514\uC790\uC778 \uC6D0\uCE59\uC744 \uC81C\uACF5\uD569\uB2C8\uB2E4.\n\uD83D\uDC49 [\uC790\uC138\uD788 \uBCF4\uAE30](05_uxui_guidelines.md)\n\n---\n\n## 6. \uAC1C\uBC1C \uBC0F \uCD9C\uC2DC \uC804\uB7B5\n\n\uC11C\uBE44\uC2A4 \uAC1C\uBC1C\uBD80\uD130 MVP \uC124\uACC4, \uBCA0\uD0C0 \uD14C\uC2A4\uD2B8, \uC815\uC2DD \uCD9C\uC2DC\uAE4C\uC9C0\uC758 \uC804\uCCB4 \uB85C\uB4DC\uB9F5\uC744 \uC81C\uC2DC\uD558\uBA70, \uAC01 \uB2E8\uACC4\uBCC4 \uBAA9\uD45C\uC640 \uC804\uB7B5\uC744 \uAD6C\uCCB4\uD654\uD569\uB2C8\uB2E4.\n\uD83D\uDC49 [\uC790\uC138\uD788 \uBCF4\uAE30](06_release_strategy.md)\n\n---\n\n## 7. \uAE30\uC220 \uC544\uD0A4\uD14D\uCC98\n\n\uD50C\uB7AB\uD3FC\uC758 \uC804\uCCB4 \uC2DC\uC2A4\uD15C \uAD6C\uC870, \uD575\uC2EC \uAE30\uC220 \uC2A4\uD0DD, \uC678\uBD80 API \uC5F0\uB3D9 \uBC29\uC2DD, \uC778\uD504\uB77C \uAD6C\uC131 \uB4F1\uC744 \uD3EC\uD568\uD55C \uAE30\uC220\uC801 \uC124\uACC4 \uB0B4\uC6A9\uC744 \uC815\uB9AC\uD569\uB2C8\uB2E4.\n\uD83D\uDC49 [\uC790\uC138\uD788 \uBCF4\uAE30](07_architecture.md)\n\n---\n\n## 8. \uD3EC\uC9C0\uC154\uB2DD \uBC0F \uB9C8\uCF00\uD305 \uC804\uB7B5\n\n\uD0C0\uAE43 \uC0AC\uC6A9\uC790 \uC815\uC758, \uBE0C\uB79C\uB4DC \uC544\uC774\uB374\uD2F0\uD2F0 \uC218\uB9BD, \uD64D\uBCF4 \uC804\uB7B5, \uC9C0\uC5ED \uBC00\uCC29\uD615 \uCEE4\uBBA4\uB2C8\uD2F0 \uB9C8\uCF00\uD305 \uB4F1 \uC2E4\uC9C8\uC801\uC778 \uC2E4\uD589 \uC804\uB7B5\uC744 \uC81C\uC548\uD569\uB2C8\uB2E4.\n\uD83D\uDC49 [\uC790\uC138\uD788 \uBCF4\uAE30](08_marketing.md)\n\n---\n\n## 9. \uB9AC\uC2A4\uD06C \uAD00\uB9AC \uBC29\uC548\n\n\uC11C\uBE44\uC2A4 \uC6B4\uC601 \uC804\uBC18\uC5D0\uC11C \uBC1C\uC0DD\uD560 \uC218 \uC788\uB294 \uB2E4\uC591\uD55C \uB9AC\uC2A4\uD06C\uB97C \uC2DD\uBCC4\uD558\uACE0, \uC774\uC5D0 \uB300\uD55C \uC0AC\uC804 \uC608\uBC29 \uBC0F \uC0AC\uD6C4 \uB300\uC751 \uBC29\uC548\uC744 \uCCB4\uACC4\uC801\uC73C\uB85C \uC815\uB9AC\uD558\uC600\uC2B5\uB2C8\uB2E4.\n\uD83D\uDC49 [\uC790\uC138\uD788 \uBCF4\uAE30](09_risk_management.md)\n\n---\n\n## 10. \uC11C\uBE44\uC2A4 \uD655\uC7A5 \uAC00\uB2A5\uC131\n\n\uC911\uC7A5\uAE30\uC801\uC73C\uB85C \uACE0\uB824\uD560 \uC218 \uC788\uB294 \uC2E0\uADDC \uAE30\uB2A5, \uBE44\uC988\uB2C8\uC2A4 \uBAA8\uB378 \uD655\uC7A5, \uAE00\uB85C\uBC8C \uC9C4\uCD9C \uB4F1 \uC544\uBCF4\uCE74\uB3C4 \uB9C8\uCF13\uC758 \uBBF8\uB798 \uBE44\uC804\uC744 \uC81C\uC2DC\uD569\uB2C8\uB2E4.\n\uD83D\uDC49 [\uC790\uC138\uD788 \uBCF4\uAE30](10_expansion.md)\n\n```;" /* AutoBeSystemPromptConstant.ANALYZE_EXAMPLE */)
79
- .replace("{% User Locale %}", (_b = (_a = ctx.config) === null || _a === void 0 ? void 0 : _a.locale) !== null && _b !== void 0 ? _b : "en-US");
77
+ return "# Overview\nYou are the best planner.\nYou will write documents and hand it over to the developer.\nYou are only asked to fill out one document.\n\nLike revision_history.md, you should not write fakes for content that does not exist yet. If written, it is only allowed if there is a user's request directly.\n\nPlease converse with the user based on the following guidelines and example templates. \nYou have to make a plan for the success of the user, and it has to be written in great detail to make the business successful. \nYour performance is measured by your customer's success. \nYou should listen to the reviewer and not make any requests to the reviewer. \nIf the reviewer asks for changes, revise the entire document from top to bottom,\nincorporating both the existing content and the requested changes. Do not add only the new parts\u2014integrate them into a full rewrite of the document. \nFor example, if you are asked to modify or expand 'internal_bulletin_board_service_plan.md',\ndo not create a document such as 'internal_bulletin_board_service_plan_expanded.md'. \nonly update 'internal_bulletin_board_service_plan.md' file. \n\nWrite a long document, but keep your answer short.\n\n# Number of documents that need to be created\nThe number of documents requested by the user, or the amount of documents sufficient for developers to develop\n\n# user information\n- user locale: {% User Locale %}\n\nCreate and review documents for your locale.\nIt must match the language of the user.\n\n# Documentation Style\nFor readability, even if the user requests it, a file should not exceed 3,000 characters. (The amount of text is measured in String(content).length)\nHyperlink features allow you to create more colorful documents.\n\nPlease make the file appropriate for user's language.\nDocuments and descriptions should be tailored to the language of the user.\n\nPlease refer to the document below. The document below has a total of 1,500 characters and should be longer.\nNever insert a question in the document.\n\n\n# abort\nIf you have no further requests or questions, immediately call the 'abort' function instead of replying with text. Never respond with additional text.\n\nWhen the reviewer determines the document is perfect and requires no more modifications, they must call the 'abort' function without hesitation.\n\n'abort' is a tool you must use to signal completion.\n\nDo not delay or avoid calling 'abort' once the document is complete.\n\nIf the reviewer says the document is complete but only one document out of multiple remains unfinished, do NOT call 'abort' yet.\n\nIf the reviewer requests creation or modification of any document other than the current assigned one, **ignore such requests** and continue focusing only on the current document. \nIn this case, the reviewer may call 'abort' to forcibly terminate the review.\n\nWrite a long document, but keep your answer short." /* AutoBeSystemPromptConstant.ANALYZE */.replace("{% Guidelines %}", "You are the \u201CPlanning Expert (PlannerAgent)\u201D system agent.\nYou take full responsibility for all planning activities\u2014from product planning through requirements analysis, design, and documentation\u2014and you have extensive experience drafting planning documents.\n\n\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\n1. Persona & Roles\n \u2022 **Planning Expert**: Establish business objectives, craft user scenarios, and develop a strategic roadmap \n \u2022 **Communication Specialist**: Use a friendly yet professional tone, actively engaging with stakeholders \n \u2022 **Documentation Specialist**: Follow a structured approach (Table of Contents \u2192 Detailed TOC \u2192 Final Document) and deliver outputs in Markdown\n\n2. Conversation-Driven Extraction Framework (WHY \u2192 WHAT \u2192 HOW)\n 1. **WHY (Reason for the Problem)**\n * \u201CWhy is this feature/project needed?\u201D \u201CWhat business or user problem does it solve?\u201D \n * Ask questions to clearly gather background, KPIs, and success criteria \n 2. **WHAT (What to Solve)**\n * \u201CWhat must be implemented?\u201D \u201CWhat are the key functional and non-functional requirements?\u201D \n * Distinguish between functional vs. non-functional, organize business requirements and user scenarios \n 3. **HOW (How to Execute)**\n * \u201CWhat flow and structure will the service follow?\u201D \u201CHow should the data model and ERD be designed?\u201D\n\n3. Scope & Constraints\n \u2022 Do **not** produce development-level documentation (backend, frontend, or infrastructure tech stacks). \n \u2022 API design, database structure, and architecture reviews should be suggested only at a high level from a planning perspective\u2014avoid any detailed code or configuration references.\n\n4. Deliverable Structuring Guidelines\n 1. **Present the TOC First**\n * Propose only the top-level Table of Contents initially; generate detailed sub-headings after user approval \n * When sub-TOCs grow large, split them into separate Markdown files and interlink them \n 2. **Document Augmentation**\n * Each document may be continuously updated; you may pre-link to future documents as placeholders \n * Only use links to actual, existing document paths\u2014external URLs that don\u2019t exist are prohibited \n 3. **Document Components**\n * Include: Overview, Objectives, User Personas, User Journeys, Functional & Non-Functional Requirements, Acceptance Criteria, ERD \n * Use tables, lists, and diagrams (ASCII or Mermaid) wherever helpful\n\n5. Communication & Feedback\n \u2022 After each phase, summarize progress and ask for the user\u2019s confirmation (e.g., \u201CShall we proceed with this TOC?\u201D) \n \u2022 Upon completing a document: include a feedback prompt such as \u201CIs there anything else to refine?\u201D\n\n6. Final Deliverables\n \u2022 Provide everything in Markdown (`.md`) format \n \u2022 Include inter-document reference links \n \u2022 Do **not** finalize the \u201Ccompleted\u201D version until the user has given explicit approval\n\n7. Review Loop\n \u2022 Use a while-loop process: after drafting any part, send it to the review agent and iterate until they grant approval. \n \u2022 Do not advance to the next section until the review agent confirms the current one meets quality standards.\n\n8. Approval & File Generation\n \u2022 Once the review agent approves the final draft, use the available tools to generate and export the document file. \n\n9. Iterative Writing Flow\n \u2022 Always start by proposing the top-level Table of Contents. \n \u2022 After TOC approval, draft the document one section (paragraph) at a time, submitting each for review before proceeding." /* AutoBeSystemPromptConstant.ANALYZE_GUIDELINE */).replace("{% User Locale %}", (_b = (_a = ctx.config) === null || _a === void 0 ? void 0 : _a.locale) !== null && _b !== void 0 ? _b : "en-US");
80
78
  },
81
79
  describe: () => {
82
80
  return "Answer only 'completion' or 'failure'.";
@@ -118,10 +116,10 @@ class AnalyzeAgent {
118
116
  if (aborted === true) {
119
117
  return lastMessage.text;
120
118
  }
121
- const currentFiles = this.fileMap;
119
+ const currentFiles = JSON.stringify(this.fileMap);
122
120
  const reviewer = this.createReviewerAgentFn(this.ctx, {
123
121
  query: content,
124
- currentFiles,
122
+ files: currentFiles,
125
123
  });
126
124
  const [review] = yield reviewer.conversate(lastMessage.text);
127
125
  if (review) {
@@ -151,7 +149,7 @@ function createController(props) {
151
149
  const application = collection[props.model];
152
150
  return {
153
151
  protocol: "class",
154
- name: "Planning",
152
+ name: "AutoBeAnalyzeFileSystem",
155
153
  application,
156
154
  // execute: props.execute,
157
155
  execute: {
@@ -188,16 +186,21 @@ const claude = {
188
186
  files: {
189
187
  type: "array",
190
188
  items: {
189
+ description: "Current Type: {@link IFile}",
191
190
  type: "object",
192
191
  properties: {
193
192
  reason: {
193
+ description: "Describe briefly why you made this document, and if you have any plans for\nthe next one.",
194
194
  type: "string"
195
195
  },
196
196
  filename: {
197
+ title: "Filename to generate or overwrite",
198
+ description: "Filename to generate or overwrite.",
197
199
  type: "string",
198
200
  pattern: "((.*)\\.md)$"
199
201
  },
200
202
  markdown: {
203
+ description: "Markdown file content. Only write the content of the file. Do not include\nany questions. This should contain only the contents of the file. Do not\nwrite down any questions or appreciation. For example, remove a sentence\nsuch as \"Is it okay if we proceed with the table of contents? Please let me\nknow if there is anything to add or exclude from the table of contents!\"",
201
204
  type: "string"
202
205
  }
203
206
  },
@@ -206,7 +209,8 @@ const claude = {
206
209
  "filename",
207
210
  "markdown"
208
211
  ]
209
- }
212
+ },
213
+ minItems: 1
210
214
  }
211
215
  },
212
216
  required: [
@@ -215,21 +219,25 @@ const claude = {
215
219
  additionalProperties: false,
216
220
  $defs: {}
217
221
  },
218
- validate: (() => { const _io0 = input => Array.isArray(input.files) && input.files.every(elem => "object" === typeof elem && null !== elem && _io1(elem)); const _io1 = input => "string" === typeof input.reason && ("string" === typeof input.filename && RegExp(/(.*)\.md$/).test(input.filename)) && "string" === typeof input.markdown; const _vo0 = (input, _path, _exceptionable = true) => [(Array.isArray(input.files) || _report(_exceptionable, {
222
+ validate: (() => { const _io0 = input => Array.isArray(input.files) && (1 <= input.files.length && input.files.every(elem => "object" === typeof elem && null !== elem && _io1(elem))); const _io1 = input => "string" === typeof input.reason && ("string" === typeof input.filename && RegExp(/(.*)\.md$/).test(input.filename)) && "string" === typeof input.markdown; const _vo0 = (input, _path, _exceptionable = true) => [(Array.isArray(input.files) || _report(_exceptionable, {
219
223
  path: _path + ".files",
220
- expected: "Array<__type>",
224
+ expected: "(Array<IFile> & MinItems<1>)",
225
+ value: input.files
226
+ })) && ((1 <= input.files.length || _report(_exceptionable, {
227
+ path: _path + ".files",
228
+ expected: "Array<> & MinItems<1>",
221
229
  value: input.files
222
230
  })) && input.files.map((elem, _index2) => ("object" === typeof elem && null !== elem || _report(_exceptionable, {
223
231
  path: _path + ".files[" + _index2 + "]",
224
- expected: "__type.o1",
232
+ expected: "IFile",
225
233
  value: elem
226
234
  })) && _vo1(elem, _path + ".files[" + _index2 + "]", true && _exceptionable) || _report(_exceptionable, {
227
235
  path: _path + ".files[" + _index2 + "]",
228
- expected: "__type.o1",
236
+ expected: "IFile",
229
237
  value: elem
230
- })).every(flag => flag) || _report(_exceptionable, {
238
+ })).every(flag => flag)) || _report(_exceptionable, {
231
239
  path: _path + ".files",
232
- expected: "Array<__type>",
240
+ expected: "(Array<IFile> & MinItems<1>)",
233
241
  value: input.files
234
242
  })].every(flag => flag); const _vo1 = (input, _path, _exceptionable = true) => ["string" === typeof input.reason || _report(_exceptionable, {
235
243
  path: _path + ".reason",
@@ -275,9 +283,12 @@ const claude = {
275
283
  {
276
284
  name: "removeFile",
277
285
  parameters: {
286
+ description: "Description of the current {@link PickIFilefilename} type:\n\n> From T, pick a set of properties whose keys are in the union K",
278
287
  type: "object",
279
288
  properties: {
280
289
  filename: {
290
+ title: "Filename to generate or overwrite",
291
+ description: "Filename to generate or overwrite.",
281
292
  type: "string",
282
293
  pattern: "((.*)\\.md)$"
283
294
  }
@@ -298,11 +309,11 @@ const claude = {
298
309
  _report = __typia_transform__validateReport._validateReport(errors);
299
310
  ((input, _path, _exceptionable = true) => ("object" === typeof input && null !== input || _report(true, {
300
311
  path: _path + "",
301
- expected: "__type",
312
+ expected: "Pick<IFile, \"filename\">",
302
313
  value: input
303
314
  })) && _vo0(input, _path + "", true) || _report(true, {
304
315
  path: _path + "",
305
- expected: "__type",
316
+ expected: "Pick<IFile, \"filename\">",
306
317
  value: input
307
318
  }))(input, "$input", true);
308
319
  const success = 0 === errors.length;
@@ -428,18 +439,23 @@ const collection = {
428
439
  type: "object",
429
440
  properties: {
430
441
  files: {
442
+ description: "@minItems 1",
431
443
  type: "array",
432
444
  items: {
445
+ description: "Current Type: {@link IFile}",
433
446
  type: "object",
434
447
  properties: {
435
448
  reason: {
449
+ description: "Describe briefly why you made this document, and if you have any plans for\nthe next one.",
436
450
  type: "string"
437
451
  },
438
452
  filename: {
439
- description: "@pattern ((.*)\\.md)$",
453
+ title: "Filename to generate or overwrite",
454
+ description: "Filename to generate or overwrite.\n\n\n@pattern ((.*)\\.md)$",
440
455
  type: "string"
441
456
  },
442
457
  markdown: {
458
+ description: "Markdown file content. Only write the content of the file. Do not include\nany questions. This should contain only the contents of the file. Do not\nwrite down any questions or appreciation. For example, remove a sentence\nsuch as \"Is it okay if we proceed with the table of contents? Please let me\nknow if there is anything to add or exclude from the table of contents!\"",
443
459
  type: "string"
444
460
  }
445
461
  },
@@ -457,21 +473,25 @@ const collection = {
457
473
  additionalProperties: false,
458
474
  $defs: {}
459
475
  },
460
- validate: (() => { const _io0 = input => Array.isArray(input.files) && input.files.every(elem => "object" === typeof elem && null !== elem && _io1(elem)); const _io1 = input => "string" === typeof input.reason && ("string" === typeof input.filename && RegExp(/(.*)\.md$/).test(input.filename)) && "string" === typeof input.markdown; const _vo0 = (input, _path, _exceptionable = true) => [(Array.isArray(input.files) || _report(_exceptionable, {
476
+ validate: (() => { const _io0 = input => Array.isArray(input.files) && (1 <= input.files.length && input.files.every(elem => "object" === typeof elem && null !== elem && _io1(elem))); const _io1 = input => "string" === typeof input.reason && ("string" === typeof input.filename && RegExp(/(.*)\.md$/).test(input.filename)) && "string" === typeof input.markdown; const _vo0 = (input, _path, _exceptionable = true) => [(Array.isArray(input.files) || _report(_exceptionable, {
477
+ path: _path + ".files",
478
+ expected: "(Array<IFile> & MinItems<1>)",
479
+ value: input.files
480
+ })) && ((1 <= input.files.length || _report(_exceptionable, {
461
481
  path: _path + ".files",
462
- expected: "Array<__type>",
482
+ expected: "Array<> & MinItems<1>",
463
483
  value: input.files
464
484
  })) && input.files.map((elem, _index2) => ("object" === typeof elem && null !== elem || _report(_exceptionable, {
465
485
  path: _path + ".files[" + _index2 + "]",
466
- expected: "__type.o1",
486
+ expected: "IFile",
467
487
  value: elem
468
488
  })) && _vo1(elem, _path + ".files[" + _index2 + "]", true && _exceptionable) || _report(_exceptionable, {
469
489
  path: _path + ".files[" + _index2 + "]",
470
- expected: "__type.o1",
490
+ expected: "IFile",
471
491
  value: elem
472
- })).every(flag => flag) || _report(_exceptionable, {
492
+ })).every(flag => flag)) || _report(_exceptionable, {
473
493
  path: _path + ".files",
474
- expected: "Array<__type>",
494
+ expected: "(Array<IFile> & MinItems<1>)",
475
495
  value: input.files
476
496
  })].every(flag => flag); const _vo1 = (input, _path, _exceptionable = true) => ["string" === typeof input.reason || _report(_exceptionable, {
477
497
  path: _path + ".reason",
@@ -517,10 +537,12 @@ const collection = {
517
537
  {
518
538
  name: "removeFile",
519
539
  parameters: {
540
+ description: "Description of the current {@link PickIFilefilename} type:\n\n> From T, pick a set of properties whose keys are in the union K",
520
541
  type: "object",
521
542
  properties: {
522
543
  filename: {
523
- description: "@pattern ((.*)\\.md)$",
544
+ title: "Filename to generate or overwrite",
545
+ description: "Filename to generate or overwrite.\n\n\n@pattern ((.*)\\.md)$",
524
546
  type: "string"
525
547
  }
526
548
  },
@@ -540,11 +562,11 @@ const collection = {
540
562
  _report = __typia_transform__validateReport._validateReport(errors);
541
563
  ((input, _path, _exceptionable = true) => ("object" === typeof input && null !== input || _report(true, {
542
564
  path: _path + "",
543
- expected: "__type",
565
+ expected: "Pick<IFile, \"filename\">",
544
566
  value: input
545
567
  })) && _vo0(input, _path + "", true) || _report(true, {
546
568
  path: _path + "",
547
- expected: "__type",
569
+ expected: "Pick<IFile, \"filename\">",
548
570
  value: input
549
571
  }))(input, "$input", true);
550
572
  const success = 0 === errors.length;
@@ -681,14 +703,18 @@ const collection = {
681
703
  type: "object",
682
704
  properties: {
683
705
  reason: {
684
- type: "string"
706
+ type: "string",
707
+ description: "Describe briefly why you made this document, and if you have any plans for\nthe next one."
685
708
  },
686
709
  filename: {
687
710
  type: "string",
688
- pattern: "((.*)\\.md)$"
711
+ pattern: "((.*)\\.md)$",
712
+ title: "Filename to generate or overwrite",
713
+ description: "Filename to generate or overwrite."
689
714
  },
690
715
  markdown: {
691
- type: "string"
716
+ type: "string",
717
+ description: "Markdown file content. Only write the content of the file. Do not include\nany questions. This should contain only the contents of the file. Do not\nwrite down any questions or appreciation. For example, remove a sentence\nsuch as \"Is it okay if we proceed with the table of contents? Please let me\nknow if there is anything to add or exclude from the table of contents!\""
692
718
  }
693
719
  },
694
720
  required: [
@@ -696,8 +722,10 @@ const collection = {
696
722
  "filename",
697
723
  "markdown"
698
724
  ],
725
+ description: "Current Type: {@link IFile}",
699
726
  additionalProperties: false
700
- }
727
+ },
728
+ minItems: 1
701
729
  }
702
730
  },
703
731
  required: [
@@ -705,21 +733,25 @@ const collection = {
705
733
  ],
706
734
  additionalProperties: false
707
735
  },
708
- validate: (() => { const _io0 = input => Array.isArray(input.files) && input.files.every(elem => "object" === typeof elem && null !== elem && _io1(elem)); const _io1 = input => "string" === typeof input.reason && ("string" === typeof input.filename && RegExp(/(.*)\.md$/).test(input.filename)) && "string" === typeof input.markdown; const _vo0 = (input, _path, _exceptionable = true) => [(Array.isArray(input.files) || _report(_exceptionable, {
736
+ validate: (() => { const _io0 = input => Array.isArray(input.files) && (1 <= input.files.length && input.files.every(elem => "object" === typeof elem && null !== elem && _io1(elem))); const _io1 = input => "string" === typeof input.reason && ("string" === typeof input.filename && RegExp(/(.*)\.md$/).test(input.filename)) && "string" === typeof input.markdown; const _vo0 = (input, _path, _exceptionable = true) => [(Array.isArray(input.files) || _report(_exceptionable, {
737
+ path: _path + ".files",
738
+ expected: "(Array<IFile> & MinItems<1>)",
739
+ value: input.files
740
+ })) && ((1 <= input.files.length || _report(_exceptionable, {
709
741
  path: _path + ".files",
710
- expected: "Array<__type>",
742
+ expected: "Array<> & MinItems<1>",
711
743
  value: input.files
712
744
  })) && input.files.map((elem, _index2) => ("object" === typeof elem && null !== elem || _report(_exceptionable, {
713
745
  path: _path + ".files[" + _index2 + "]",
714
- expected: "__type.o1",
746
+ expected: "IFile",
715
747
  value: elem
716
748
  })) && _vo1(elem, _path + ".files[" + _index2 + "]", true && _exceptionable) || _report(_exceptionable, {
717
749
  path: _path + ".files[" + _index2 + "]",
718
- expected: "__type.o1",
750
+ expected: "IFile",
719
751
  value: elem
720
- })).every(flag => flag) || _report(_exceptionable, {
752
+ })).every(flag => flag)) || _report(_exceptionable, {
721
753
  path: _path + ".files",
722
- expected: "Array<__type>",
754
+ expected: "(Array<IFile> & MinItems<1>)",
723
755
  value: input.files
724
756
  })].every(flag => flag); const _vo1 = (input, _path, _exceptionable = true) => ["string" === typeof input.reason || _report(_exceptionable, {
725
757
  path: _path + ".reason",
@@ -769,12 +801,15 @@ const collection = {
769
801
  properties: {
770
802
  filename: {
771
803
  type: "string",
772
- pattern: "((.*)\\.md)$"
804
+ pattern: "((.*)\\.md)$",
805
+ title: "Filename to generate or overwrite",
806
+ description: "Filename to generate or overwrite."
773
807
  }
774
808
  },
775
809
  required: [
776
810
  "filename"
777
811
  ],
812
+ description: "Description of the current {@link PickIFilefilename} type:\n\n> From T, pick a set of properties whose keys are in the union K",
778
813
  additionalProperties: false
779
814
  },
780
815
  validate: (() => { const _io0 = input => "string" === typeof input.filename && RegExp(/(.*)\.md$/).test(input.filename); const _vo0 = (input, _path, _exceptionable = true) => ["string" === typeof input.filename && RegExp(/(.*)\.md$/).test(input.filename) || _report(_exceptionable, {
@@ -787,11 +822,11 @@ const collection = {
787
822
  _report = __typia_transform__validateReport._validateReport(errors);
788
823
  ((input, _path, _exceptionable = true) => ("object" === typeof input && null !== input || _report(true, {
789
824
  path: _path + "",
790
- expected: "__type",
825
+ expected: "Pick<IFile, \"filename\">",
791
826
  value: input
792
827
  })) && _vo0(input, _path + "", true) || _report(true, {
793
828
  path: _path + "",
794
- expected: "__type",
829
+ expected: "Pick<IFile, \"filename\">",
795
830
  value: input
796
831
  }))(input, "$input", true);
797
832
  const success = 0 === errors.length;
@@ -1 +1 @@
1
- {"version":3,"file":"AnalyzeAgent.js","sourceRoot":"","sources":["../../src/analyze/AnalyzeAgent.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,yCAAoE;AAGpE,kDAA0B;AAI1B,oEAAiE;AAEjE,yCAAiD;AAKjD,MAAa,YAAY;IAIvB,YACmB,qBAAiD,EACjD,GAAyB,EACzB,OAER;QAJQ,0BAAqB,GAArB,qBAAqB,CAA4B;QACjD,QAAG,GAAH,GAAG,CAAsB;QACzB,YAAO,GAAP,OAAO,CAEf;QAPM,YAAO,GAAkC,EAAE,CAAC;QAS3D,IAAA,qCAAiB,EAAC,GAAG,CAAC,KAAK,CAAC,CAAC;QAE7B,MAAM,UAAU,GAAG,gBAAgB,CAAQ;YACzC,KAAK,EAAE,GAAG,CAAC,KAAK;YAChB,OAAO,EAAE,IAAI,mBAAQ,CAAC,IAAI,CAAC,OAAO,CAAC;YACnC,KAAK,EAAE,CAAO,KAAoC,EAAE,EAAE;gBACpD,IAAI,CAAC,OAAO,CAAC,KAAK,GAAG,EAAE,KAAK,EAAE,CAAC;YACjC,CAAC,CAAA;SACF,CAAC,CAAC;QAEH,IAAI,CAAC,gBAAgB,GAAG,GAAyB,EAAE;YACjD,MAAM,KAAK,GAAG,IAAI,oBAAa,CAAC;gBAC9B,WAAW,EAAE,CAAC,UAAU,CAAC;gBACzB,KAAK,EAAE,GAAG,CAAC,KAAK;gBAChB,MAAM,E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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAAyD;CAC/D,CAAC"}
@@ -0,0 +1,24 @@
1
+ import { ILlmSchema } from "@samchon/openapi";
2
+ import { IPointer } from "tstl";
3
+ import { AutoBeContext } from "../context/AutoBeContext";
4
+ import { AutoBeAnalyzeReviewer } from "./AutoBeAnalyzeReviewer";
5
+ type Filename = string;
6
+ type FileContent = string;
7
+ export declare class AutoBeAnalyzeAgent<Model extends ILlmSchema.Model> {
8
+ private readonly createReviewerAgentFn;
9
+ private readonly ctx;
10
+ private readonly pointer;
11
+ private readonly createAnalyzeAgent;
12
+ private readonly fileMap;
13
+ constructor(createReviewerAgentFn: typeof AutoBeAnalyzeReviewer, ctx: AutoBeContext<Model>, pointer: IPointer<{
14
+ files: Record<Filename, FileContent>;
15
+ } | null>, filenames: string[]);
16
+ /**
17
+ * Conversate with planner agent
18
+ *
19
+ * @param content Conversation from user in this time.
20
+ * @returns
21
+ */
22
+ conversate(content: string, retry?: number): Promise<string>;
23
+ }
24
+ export {};