@aigne/doc-smith 0.8.12-beta.3 โ†’ 0.8.12-beta.4

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 (169) hide show
  1. package/.aigne/doc-smith/config.yaml +9 -6
  2. package/.aigne/doc-smith/output/structure-plan.json +123 -109
  3. package/.aigne/doc-smith/upload-cache.yaml +48 -0
  4. package/.github/workflows/publish-docs.yml +4 -7
  5. package/.release-please-manifest.json +1 -1
  6. package/CHANGELOG.md +13 -0
  7. package/agents/clear/choose-contents.mjs +22 -5
  8. package/agents/clear/clear-auth-tokens.mjs +2 -4
  9. package/agents/clear/clear-deployment-config.mjs +49 -0
  10. package/agents/clear/clear-document-config.mjs +2 -5
  11. package/agents/clear/clear-document-structure.mjs +2 -6
  12. package/agents/clear/clear-generated-docs.mjs +0 -1
  13. package/agents/generate/check-need-generate-structure.mjs +15 -60
  14. package/agents/generate/document-structure-tools/generate-sub-structure.mjs +131 -0
  15. package/agents/generate/generate-structure-without-tools.yaml +65 -0
  16. package/agents/generate/generate-structure.yaml +7 -1
  17. package/agents/generate/index.yaml +0 -3
  18. package/agents/generate/update-document-structure.yaml +3 -0
  19. package/agents/generate/user-review-document-structure.mjs +7 -5
  20. package/agents/init/index.mjs +15 -15
  21. package/agents/publish/publish-docs.mjs +130 -111
  22. package/agents/translate/index.yaml +1 -1
  23. package/agents/update/batch-generate-document.yaml +1 -1
  24. package/agents/update/batch-update-document.yaml +1 -1
  25. package/agents/update/check-document.mjs +3 -19
  26. package/agents/update/user-review-document.mjs +4 -3
  27. package/agents/utils/load-sources.mjs +54 -151
  28. package/agents/utils/transform-detail-datasources.mjs +14 -18
  29. package/aigne.yaml +2 -0
  30. package/biome.json +1 -1
  31. package/docs/_sidebar.md +13 -15
  32. package/docs/configuration-initial-setup.ja.md +179 -0
  33. package/docs/configuration-initial-setup.md +179 -0
  34. package/docs/configuration-initial-setup.zh-TW.md +179 -0
  35. package/docs/configuration-initial-setup.zh.md +179 -0
  36. package/docs/configuration-managing-preferences.ja.md +100 -0
  37. package/docs/configuration-managing-preferences.md +100 -0
  38. package/docs/configuration-managing-preferences.zh-TW.md +100 -0
  39. package/docs/configuration-managing-preferences.zh.md +100 -0
  40. package/docs/configuration.ja.md +68 -184
  41. package/docs/configuration.md +62 -178
  42. package/docs/configuration.zh-TW.md +70 -186
  43. package/docs/configuration.zh.md +67 -183
  44. package/docs/getting-started.ja.md +46 -78
  45. package/docs/getting-started.md +46 -78
  46. package/docs/getting-started.zh-TW.md +47 -79
  47. package/docs/getting-started.zh.md +47 -79
  48. package/docs/guides-cleaning-up.ja.md +50 -0
  49. package/docs/guides-cleaning-up.md +50 -0
  50. package/docs/guides-cleaning-up.zh-TW.md +50 -0
  51. package/docs/guides-cleaning-up.zh.md +50 -0
  52. package/docs/guides-evaluating-documents.ja.md +66 -0
  53. package/docs/guides-evaluating-documents.md +66 -0
  54. package/docs/guides-evaluating-documents.zh-TW.md +66 -0
  55. package/docs/guides-evaluating-documents.zh.md +66 -0
  56. package/docs/guides-generating-documentation.ja.md +149 -0
  57. package/docs/guides-generating-documentation.md +149 -0
  58. package/docs/guides-generating-documentation.zh-TW.md +149 -0
  59. package/docs/guides-generating-documentation.zh.md +149 -0
  60. package/docs/guides-interactive-chat.ja.md +85 -0
  61. package/docs/guides-interactive-chat.md +85 -0
  62. package/docs/guides-interactive-chat.zh-TW.md +85 -0
  63. package/docs/guides-interactive-chat.zh.md +85 -0
  64. package/docs/guides-managing-history.ja.md +51 -0
  65. package/docs/guides-managing-history.md +51 -0
  66. package/docs/guides-managing-history.zh-TW.md +51 -0
  67. package/docs/guides-managing-history.zh.md +51 -0
  68. package/docs/guides-publishing-your-docs.ja.md +78 -0
  69. package/docs/guides-publishing-your-docs.md +78 -0
  70. package/docs/guides-publishing-your-docs.zh-TW.md +78 -0
  71. package/docs/guides-publishing-your-docs.zh.md +78 -0
  72. package/docs/guides-translating-documentation.ja.md +95 -0
  73. package/docs/guides-translating-documentation.md +95 -0
  74. package/docs/guides-translating-documentation.zh-TW.md +95 -0
  75. package/docs/guides-translating-documentation.zh.md +95 -0
  76. package/docs/guides-updating-documentation.ja.md +77 -0
  77. package/docs/guides-updating-documentation.md +77 -0
  78. package/docs/guides-updating-documentation.zh-TW.md +77 -0
  79. package/docs/guides-updating-documentation.zh.md +77 -0
  80. package/docs/guides.ja.md +32 -0
  81. package/docs/guides.md +32 -0
  82. package/docs/guides.zh-TW.md +32 -0
  83. package/docs/guides.zh.md +32 -0
  84. package/docs/overview.ja.md +39 -60
  85. package/docs/overview.md +39 -60
  86. package/docs/overview.zh-TW.md +39 -60
  87. package/docs/overview.zh.md +39 -60
  88. package/docs/release-notes.ja.md +255 -0
  89. package/docs/release-notes.md +255 -0
  90. package/docs/release-notes.zh-TW.md +255 -0
  91. package/docs/release-notes.zh.md +255 -0
  92. package/package.json +4 -2
  93. package/prompts/common/document/content-rules-core.md +1 -0
  94. package/prompts/common/document-structure/document-structure-rules.md +8 -9
  95. package/prompts/common/document-structure/output-constraints.md +1 -1
  96. package/prompts/structure/document-rules.md +8 -2
  97. package/prompts/structure/generate/system-prompt.md +27 -2
  98. package/prompts/structure/generate/user-prompt.md +18 -0
  99. package/prompts/structure/update/system-prompt.md +12 -0
  100. package/prompts/structure/update/user-prompt.md +3 -0
  101. package/tests/agents/clear/choose-contents.test.mjs +8 -4
  102. package/tests/agents/generate/check-need-generate-structure.test.mjs +53 -63
  103. package/tests/agents/generate/document-structure-tools/generate-sub-structure.test.mjs +277 -0
  104. package/tests/agents/init/init.test.mjs +18 -18
  105. package/tests/agents/publish/publish-docs.test.mjs +79 -0
  106. package/tests/agents/update/check-document.test.mjs +7 -67
  107. package/tests/agents/utils/load-sources.test.mjs +90 -90
  108. package/tests/agents/utils/transform-detail-datasources.test.mjs +153 -196
  109. package/tests/utils/file-utils.test.mjs +309 -1
  110. package/utils/auth-utils.mjs +9 -3
  111. package/utils/constants/index.mjs +3 -1
  112. package/utils/file-utils.mjs +315 -0
  113. package/utils/utils.mjs +89 -50
  114. package/docs/advanced-how-it-works.ja.md +0 -101
  115. package/docs/advanced-how-it-works.md +0 -101
  116. package/docs/advanced-how-it-works.zh-TW.md +0 -101
  117. package/docs/advanced-how-it-works.zh.md +0 -101
  118. package/docs/advanced-quality-assurance.ja.md +0 -92
  119. package/docs/advanced-quality-assurance.md +0 -92
  120. package/docs/advanced-quality-assurance.zh-TW.md +0 -92
  121. package/docs/advanced-quality-assurance.zh.md +0 -92
  122. package/docs/advanced.ja.md +0 -20
  123. package/docs/advanced.md +0 -20
  124. package/docs/advanced.zh-TW.md +0 -20
  125. package/docs/advanced.zh.md +0 -20
  126. package/docs/changelog.ja.md +0 -486
  127. package/docs/changelog.md +0 -486
  128. package/docs/changelog.zh-TW.md +0 -486
  129. package/docs/changelog.zh.md +0 -486
  130. package/docs/cli-reference.ja.md +0 -311
  131. package/docs/cli-reference.md +0 -311
  132. package/docs/cli-reference.zh-TW.md +0 -311
  133. package/docs/cli-reference.zh.md +0 -311
  134. package/docs/configuration-interactive-setup.ja.md +0 -138
  135. package/docs/configuration-interactive-setup.md +0 -138
  136. package/docs/configuration-interactive-setup.zh-TW.md +0 -138
  137. package/docs/configuration-interactive-setup.zh.md +0 -138
  138. package/docs/configuration-language-support.ja.md +0 -64
  139. package/docs/configuration-language-support.md +0 -64
  140. package/docs/configuration-language-support.zh-TW.md +0 -64
  141. package/docs/configuration-language-support.zh.md +0 -64
  142. package/docs/configuration-llm-setup.ja.md +0 -56
  143. package/docs/configuration-llm-setup.md +0 -56
  144. package/docs/configuration-llm-setup.zh-TW.md +0 -56
  145. package/docs/configuration-llm-setup.zh.md +0 -56
  146. package/docs/configuration-preferences.ja.md +0 -144
  147. package/docs/configuration-preferences.md +0 -144
  148. package/docs/configuration-preferences.zh-TW.md +0 -144
  149. package/docs/configuration-preferences.zh.md +0 -144
  150. package/docs/features-generate-documentation.ja.md +0 -95
  151. package/docs/features-generate-documentation.md +0 -95
  152. package/docs/features-generate-documentation.zh-TW.md +0 -95
  153. package/docs/features-generate-documentation.zh.md +0 -95
  154. package/docs/features-publish-your-docs.ja.md +0 -130
  155. package/docs/features-publish-your-docs.md +0 -130
  156. package/docs/features-publish-your-docs.zh-TW.md +0 -130
  157. package/docs/features-publish-your-docs.zh.md +0 -130
  158. package/docs/features-translate-documentation.ja.md +0 -90
  159. package/docs/features-translate-documentation.md +0 -90
  160. package/docs/features-translate-documentation.zh-TW.md +0 -90
  161. package/docs/features-translate-documentation.zh.md +0 -90
  162. package/docs/features-update-and-refine.ja.md +0 -142
  163. package/docs/features-update-and-refine.md +0 -142
  164. package/docs/features-update-and-refine.zh-TW.md +0 -143
  165. package/docs/features-update-and-refine.zh.md +0 -142
  166. package/docs/features.ja.md +0 -62
  167. package/docs/features.md +0 -62
  168. package/docs/features.zh-TW.md +0 -62
  169. package/docs/features.zh.md +0 -62
@@ -16,8 +16,8 @@ projectLogo: https://docsmith.aigne.io/image-bin/uploads/9645caf64b4232699982c4d
16
16
  # solveProblems - Solve problems: Help users troubleshoot and fix issues
17
17
  # mixedPurpose - Mix of above: Comprehensive documentation covering multiple needs
18
18
  documentPurpose:
19
+ - getStarted
19
20
  - completeTasks
20
- - findAnswers
21
21
 
22
22
  # Target Audience: Who will be reading this most often?
23
23
  # Available options (uncomment and modify as needed):
@@ -29,7 +29,6 @@ documentPurpose:
29
29
  # mixedTechnical - Mixed technical audience: Developers, DevOps, and technical users
30
30
  targetAudienceTypes:
31
31
  - endUsers
32
- - developers
33
32
 
34
33
  # Reader Knowledge Level: What do readers typically know when they arrive?
35
34
  # Available options (uncomment and modify as needed):
@@ -52,11 +51,10 @@ documentationDepth: comprehensive
52
51
  rules: |
53
52
  Avoid using vague or empty words that don't provide measurable or specific details, such as 'intelligently', 'seamlessly', 'comprehensive', or 'high-quality'. Focus on concrete, verifiable facts and information.
54
53
  Focus on concrete, verifiable facts and information.
55
-
54
+ Must cover all subcommands of DocSmith
56
55
 
57
56
  # Target Audience: Describe your specific target audience and their characteristics
58
57
  targetAudience: |
59
-
60
58
 
61
59
  locale: en
62
60
  translateLanguages:
@@ -65,8 +63,13 @@ translateLanguages:
65
63
  - ja
66
64
  docsDir: ./docs # Directory to save generated documentation
67
65
  sourcesPath: # Source code paths to analyze
68
- - ./
69
- lastGitHead: 6fc5d715e778663896ae179975ec72d9e5ff97ed
66
+ - ./README.md
67
+ - ./CHANGELOG.md
68
+ - ./aigne.yaml
69
+ - ./agents
70
+ - ./media.md
71
+ - ./.aigne/doc-smith/config.yaml
72
+ lastGitHead: f0db74dffd0876dab4cc3ad628523abd359c9430
70
73
  # โš ๏ธ Warning: boardId is auto-generated by system, please do not edit manually
71
74
  boardId: "docsmith"
72
75
  appUrl: https://docsmith.aigne.io
@@ -1,148 +1,162 @@
1
1
  [
2
2
  {
3
3
  "title": "Overview",
4
- "description": "Get a quick introduction to AIGNE DocSmith, what it does, its main features, and how it fits into the larger AIGNE ecosystem.",
4
+ "description": "Explains what AIGNE DocSmith does, the problems it solves, and its main capabilities based on your project's code.",
5
5
  "path": "/overview",
6
- "parentId": null,
7
- "sourceIds": ["README.md", "package.json", "aigne.yaml"]
6
+ "sourceIds": ["README.md", "aigne.yaml", ".aigne/doc-smith/config.yaml"],
7
+ "parentId": ""
8
8
  },
9
9
  {
10
10
  "title": "Getting Started",
11
- "description": "Follow this simple, step-by-step guide to install the tool, configure your project, and generate your first set of documents in minutes.",
11
+ "description": "Provides a step-by-step guide to installing the tool and generating your first set of documents.",
12
12
  "path": "/getting-started",
13
- "parentId": null,
14
- "sourceIds": ["README.md", "media.md", "agents/input-generator.mjs"]
13
+ "sourceIds": ["README.md", "agents/init/index.mjs", "media.md"],
14
+ "parentId": ""
15
15
  },
16
16
  {
17
- "title": "Core Features",
18
- "description": "Explore the main commands and capabilities of DocSmith, from creating new documentation to publishing it online.",
19
- "path": "/features",
20
- "parentId": null,
21
- "sourceIds": ["README.md"]
22
- },
23
- {
24
- "title": "Generate Documentation",
25
- "description": "Learn how to use a single command to automatically create a complete set of documentation from your source code.",
26
- "path": "/features/generate-documentation",
27
- "parentId": "/features",
28
- "sourceIds": ["README.md", "media.md", "agents/docs-generator.yaml"]
29
- },
30
- {
31
- "title": "Update and Refine",
32
- "description": "Discover how to intelligently update your documents when your code changes, or make specific improvements using feedback.",
33
- "path": "/features/update-and-refine",
34
- "parentId": "/features",
35
- "sourceIds": ["README.md", "media.md", "agents/detail-regenerator.yaml"]
17
+ "title": "Guides",
18
+ "description": "Contains step-by-step instructions for performing common documentation tasks.",
19
+ "path": "/guides",
20
+ "sourceIds": [
21
+ "aigne.yaml",
22
+ "README.md",
23
+ "agents/generate/index.yaml",
24
+ "agents/update/index.yaml",
25
+ "agents/translate/index.yaml",
26
+ "agents/publish/index.yaml",
27
+ "agents/clear/index.yaml",
28
+ "agents/evaluate/index.yaml",
29
+ "agents/history/index.yaml",
30
+ "agents/chat/index.yaml"
31
+ ],
32
+ "parentId": ""
33
+ },
34
+ {
35
+ "title": "Configuration",
36
+ "description": "Details how to set up the tool and manage personal preferences for document generation.",
37
+ "path": "/configuration",
38
+ "sourceIds": [
39
+ "aigne.yaml",
40
+ "agents/init/index.mjs",
41
+ "agents/prefs/index.mjs",
42
+ ".aigne/doc-smith/config.yaml"
43
+ ],
44
+ "parentId": ""
36
45
  },
37
46
  {
38
- "title": "Translate Documentation",
39
- "description": "Learn how to automatically translate your documentation into multiple languages to reach a global audience.",
40
- "path": "/features/translate-documentation",
41
- "parentId": "/features",
42
- "sourceIds": ["README.md", "media.md", "agents/translate.yaml", "agents/retranslate.yaml"]
47
+ "title": "Release Notes",
48
+ "description": "Lists new features, improvements, and bug fixes for each version of the tool.",
49
+ "path": "/release-notes",
50
+ "sourceIds": ["CHANGELOG.md"],
51
+ "parentId": ""
43
52
  },
44
53
  {
45
- "title": "Publish Your Docs",
46
- "description": "A guide on how to easily publish your documentation to a public platform or your own private website.",
47
- "path": "/features/publish-your-docs",
48
- "parentId": "/features",
54
+ "title": "Generating Documentation",
55
+ "description": "Walks through the process of creating a new set of documents from your source files from start to finish.",
56
+ "path": "/guides/generating-documentation",
49
57
  "sourceIds": [
58
+ "agents/generate/index.yaml",
59
+ "agents/generate/generate-structure.yaml",
60
+ "agents/generate/user-review-document-structure.mjs",
61
+ "agents/update/batch-generate-document.yaml",
50
62
  "README.md",
51
- "media.md",
52
- "agents/publish-docs.mjs",
53
- "utils/auth-utils.mjs",
54
- "utils/blocklet.mjs"
55
- ]
63
+ "agents/generate/check-need-generate-structure.mjs",
64
+ "agents/generate/refine-document-structure.yaml",
65
+ "agents/generate/check-document-structure.yaml"
66
+ ],
67
+ "parentId": "/guides"
56
68
  },
57
69
  {
58
- "title": "CLI Command Reference",
59
- "description": "A comprehensive reference for all available `aigne doc` commands, their arguments, and options.",
60
- "path": "/cli-reference",
61
- "parentId": null,
70
+ "title": "Updating Documentation",
71
+ "description": "Explains how to modify existing documents based on code changes or new feedback.",
72
+ "path": "/guides/updating-documentation",
62
73
  "sourceIds": [
74
+ "agents/update/index.yaml",
75
+ "agents/update/update-single-document.yaml",
76
+ "agents/update/batch-update-document.yaml",
77
+ "agents/update/user-review-document.mjs",
63
78
  "README.md",
64
- "aigne.yaml",
65
- "agents/docs-generator.yaml",
66
- "agents/detail-regenerator.yaml",
67
- "agents/retranslate.yaml",
68
- "agents/team-publish-docs.yaml",
69
- "agents/prefs/index.mjs"
70
- ]
79
+ "agents/update/check-update-is-single.mjs",
80
+ "agents/update/handle-document-update.yaml",
81
+ "agents/update/generate-document.yaml"
82
+ ],
83
+ "parentId": "/guides"
71
84
  },
72
85
  {
73
- "title": "Configuration Guide",
74
- "description": "A detailed look at all the available settings to customize the style, audience, and languages of your documentation.",
75
- "path": "/configuration",
76
- "parentId": null,
77
- "sourceIds": ["README.md", "agents/input-generator.mjs", "utils/constants/index.mjs"]
86
+ "title": "Translating Documentation",
87
+ "description": "Details the steps to translate your documents into multiple supported languages.",
88
+ "path": "/guides/translating-documentation",
89
+ "sourceIds": [
90
+ "agents/translate/index.yaml",
91
+ "agents/translate/translate-multilingual.yaml",
92
+ "agents/translate/choose-language.mjs",
93
+ "README.md",
94
+ "agents/translate/translate-document.yaml",
95
+ "agents/translate/record-translation-history.mjs"
96
+ ],
97
+ "parentId": "/guides"
78
98
  },
79
99
  {
80
- "title": "LLM Setup",
81
- "description": "Learn how to set up DocSmith to use different AI models, including using AIGNE Hub without needing your own API keys.",
82
- "path": "/configuration/llm-setup",
83
- "parentId": "/configuration",
84
- "sourceIds": ["README.md", "aigne.yaml"]
100
+ "title": "Publishing Your Docs",
101
+ "description": "Shows how to make your generated documentation live and accessible online.",
102
+ "path": "/guides/publishing-your-docs",
103
+ "sourceIds": ["agents/publish/index.yaml", "agents/publish/publish-docs.mjs", "README.md"],
104
+ "parentId": "/guides"
85
105
  },
86
106
  {
87
- "title": "Language Support",
88
- "description": "See the full list of languages that DocSmith supports for automatic translation and learn how to enable them.",
89
- "path": "/configuration/language-support",
90
- "parentId": "/configuration",
91
- "sourceIds": ["README.md", "utils/constants/index.mjs"]
107
+ "title": "Initial Setup",
108
+ "description": "Guides you through the interactive setup process to create your initial configuration file.",
109
+ "path": "/configuration/initial-setup",
110
+ "sourceIds": ["agents/init/index.mjs", "README.md", ".aigne/doc-smith/config.yaml"],
111
+ "parentId": "/configuration"
92
112
  },
93
113
  {
94
114
  "title": "Managing Preferences",
95
- "description": "Understand how DocSmith learns from your feedback to create persistent rules and how to manage them via the CLI.",
96
- "path": "/configuration/preferences",
97
- "parentId": "/configuration",
98
- "sourceIds": [
99
- "utils/preferences-utils.mjs",
100
- "agents/prefs/index.mjs",
101
- "prompts/feedback-refiner.md"
102
- ]
103
- },
104
- {
105
- "title": "Interactive Setup",
106
- "description": "Learn about the guided setup wizard that helps you configure your documentation project, including intelligent conflict detection for your settings.",
107
- "path": "/configuration/interactive-setup",
108
- "parentId": "/configuration",
109
- "sourceIds": [
110
- "agents/input-generator.mjs",
111
- "utils/conflict-detector.mjs",
112
- "utils/constants/index.mjs"
113
- ]
115
+ "description": "Explains how to view, remove, and toggle your saved preferences for documentation generation.",
116
+ "path": "/configuration/managing-preferences",
117
+ "sourceIds": ["agents/prefs/index.mjs", "README.md"],
118
+ "parentId": "/configuration"
114
119
  },
115
120
  {
116
- "title": "Advanced Topics",
117
- "description": "Dive deeper into the architecture of DocSmith, learn how it works, and explore its internal mechanisms.",
118
- "path": "/advanced",
119
- "parentId": null,
120
- "sourceIds": ["README.md"]
121
+ "title": "Managing History",
122
+ "description": "Shows how to view the history of updates made to your documentation.",
123
+ "path": "/guides/managing-history",
124
+ "sourceIds": ["agents/history/view.mjs", "aigne.yaml", "agents/history/index.yaml"],
125
+ "parentId": "/guides"
121
126
  },
122
127
  {
123
- "title": "How It Works",
124
- "description": "An architectural overview of DocSmith, explaining the role of AI agents in the documentation generation pipeline.",
125
- "path": "/advanced/how-it-works",
126
- "parentId": "/advanced",
128
+ "title": "Evaluating Documents",
129
+ "description": "Details how to use the evaluation command to assess the quality and completeness of your generated documentation.",
130
+ "path": "/guides/evaluating-documents",
127
131
  "sourceIds": [
128
- "README.md",
132
+ "agents/evaluate/index.yaml",
129
133
  "aigne.yaml",
130
- "agents/structure-planning.yaml",
131
- "agents/content-detail-generator.yaml"
132
- ]
133
- },
134
- {
135
- "title": "Quality Assurance",
136
- "description": "Understand the built-in checks DocSmith performs to ensure high-quality, well-formatted, and error-free documentation, including link checking and diagram validation.",
137
- "path": "/advanced/quality-assurance",
138
- "parentId": "/advanced",
139
- "sourceIds": ["utils/markdown-checker.mjs", "utils/mermaid-validator.mjs", "utils/d2-utils.mjs"]
134
+ "agents/evaluate/document-structure.yaml",
135
+ "agents/evaluate/document.yaml",
136
+ "agents/evaluate/generate-report.mjs"
137
+ ],
138
+ "parentId": "/guides"
140
139
  },
141
140
  {
142
- "title": "Changelog",
143
- "description": "A detailed log of all notable changes, features, and bug fixes for each version of the project.",
144
- "path": "/changelog",
145
- "parentId": null,
146
- "sourceIds": ["CHANGELOG.md"]
141
+ "title": "Cleaning Up",
142
+ "description": "Provides instructions on how to use the clear command to remove generated files, configurations, and cached data.",
143
+ "path": "/guides/cleaning-up",
144
+ "sourceIds": [
145
+ "agents/clear/index.yaml",
146
+ "aigne.yaml",
147
+ "agents/clear/choose-contents.mjs",
148
+ "agents/clear/clear-generated-docs.mjs",
149
+ "agents/clear/clear-document-structure.mjs",
150
+ "agents/clear/clear-document-config.mjs",
151
+ "agents/clear/clear-auth-tokens.mjs"
152
+ ],
153
+ "parentId": "/guides"
154
+ },
155
+ {
156
+ "title": "Interactive Chat",
157
+ "description": "Explains how to use the interactive chat assistant to generate, modify, and manage your documentation.",
158
+ "path": "/guides/interactive-chat",
159
+ "sourceIds": ["agents/chat/index.yaml", "aigne.yaml"],
160
+ "parentId": "/guides"
147
161
  }
148
162
  ]
@@ -1813,3 +1813,51 @@ cf8ceb314728f377f2d87d920e41b9fba87659e4b312805ae9e348871a6241aa:
1813
1813
  https://docsmith.aigne.io:
1814
1814
  url: https://docsmith.aigne.io/image-bin/uploads/44cb2fc222a3dd15.png
1815
1815
  upload_time: 2025-10-03T13:04:00.403Z
1816
+ da70db1ce27d40dc18c793f37d3e08b8b7826e096434b90a98fde6cd7411ea30:
1817
+ local_path: .aigne/doc-smith/.tmp/assets/d2/78b8e8153c6fb98784d2efcc1d56b1ed9726a07aba6fbcc9e6a751a312444d9d.svg
1818
+ sites:
1819
+ https://docsmith.aigne.io:
1820
+ url: https://docsmith.aigne.io/image-bin/uploads/da70db1ce27d40dc.svg
1821
+ upload_time: 2025-10-10T07:40:16.274Z
1822
+ 5f1096a6b7d2fc044d4b322f111ea4cfe2c5e7b75fe462c4ffb4661777176e47:
1823
+ local_path: .aigne/doc-smith/.tmp/assets/d2/4d36e9d7f2ab21ca6ce28faa613c09d19117e1c85a0652e05857c9fede449edd.svg
1824
+ sites:
1825
+ https://docsmith.aigne.io:
1826
+ url: https://docsmith.aigne.io/image-bin/uploads/5f1096a6b7d2fc04.svg
1827
+ upload_time: 2025-10-10T07:40:17.648Z
1828
+ 9754353921ef1661023cbdac23905ff918883755c8c7b70fc08e35fd5766039f:
1829
+ local_path: .aigne/doc-smith/.tmp/assets/d2/fd8d9cc57a8adccb46b65506f80f1034921b7745f9258bef2ab2d23e68c01c74.svg
1830
+ sites:
1831
+ https://docsmith.aigne.io:
1832
+ url: https://docsmith.aigne.io/image-bin/uploads/9754353921ef1661.svg
1833
+ upload_time: 2025-10-10T07:40:18.307Z
1834
+ 6adb3cd3c2afb37bb58a8176a7bd5f3fe44becf3a5ff7eb5d4b191e593df4a7f:
1835
+ local_path: .aigne/doc-smith/.tmp/assets/d2/4f6fc8759f5273a3af89b83c3d8b28f78ccc21de3a0763076bc7ba96c98de7a7.svg
1836
+ sites:
1837
+ https://docsmith.aigne.io:
1838
+ url: https://docsmith.aigne.io/image-bin/uploads/6adb3cd3c2afb37b.svg
1839
+ upload_time: 2025-10-10T07:40:18.891Z
1840
+ 5994caf6eadad709c08b1f77751db6498ee575c194226cce1f366e3bfef10748:
1841
+ local_path: .aigne/doc-smith/.tmp/assets/d2/133ad4c2b1c4a820cd9214b4647dec84041fcf1a1cac313c0cb18be9105734bb.svg
1842
+ sites:
1843
+ https://docsmith.aigne.io:
1844
+ url: https://docsmith.aigne.io/image-bin/uploads/5994caf6eadad709.svg
1845
+ upload_time: 2025-10-10T07:40:20.141Z
1846
+ e87fcba2227e472141f99b92eb0247965db132079459ce8c83454dde7fc9a6ae:
1847
+ local_path: .aigne/doc-smith/.tmp/assets/d2/f693373b7427d1eca678dc30eaaf04379baf34a1788398465e04a08fec51c5f4.svg
1848
+ sites:
1849
+ https://docsmith.aigne.io:
1850
+ url: https://docsmith.aigne.io/image-bin/uploads/e87fcba2227e4721.svg
1851
+ upload_time: 2025-10-10T07:40:20.164Z
1852
+ 5948cfe4d2c9816e0b81ef93bd215d42eca8bad0cf763ba23067ba6d7618ba38:
1853
+ local_path: .aigne/doc-smith/.tmp/assets/d2/a76bd1e831a3ec5bb069ae090e3f0a562a2fbe34af65a578a72098c33adfb312.svg
1854
+ sites:
1855
+ https://docsmith.aigne.io:
1856
+ url: https://docsmith.aigne.io/image-bin/uploads/5948cfe4d2c9816e.svg
1857
+ upload_time: 2025-10-10T07:40:21.401Z
1858
+ 3b189fa893cc2120abd34e977063fd7ca631df529106542f9ef16579877ec86a:
1859
+ local_path: .aigne/doc-smith/.tmp/assets/d2/a167a6cd2dcac3d0bcc105d6e0ac6a344b634c089d38547bf91ad831ebffd187.svg
1860
+ sites:
1861
+ https://docsmith.aigne.io:
1862
+ url: https://docsmith.aigne.io/image-bin/uploads/3b189fa893cc2120.svg
1863
+ upload_time: 2025-10-10T07:40:22.634Z
@@ -1,8 +1,7 @@
1
1
  name: publish docs
2
2
 
3
3
  env:
4
- GEMINI_API_KEY: ${{ secrets.GEMINI_API_KEY }}
5
- OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }}
4
+ AIGNE_HUB_API_KEY: ${{ secrets.AIGNE_HUB_API_KEY }}
6
5
 
7
6
  permissions:
8
7
  contents: write
@@ -10,7 +9,6 @@ permissions:
10
9
  on:
11
10
  push:
12
11
  branches:
13
- - master
14
12
  - main
15
13
 
16
14
  jobs:
@@ -33,11 +31,10 @@ jobs:
33
31
  - uses: oven-sh/setup-bun@v2
34
32
  with:
35
33
  bun-version: latest
36
- cache: true
37
34
 
38
35
  - name: Install @aigne/cli
39
36
  run: |
40
- bun install -g @aigne/cli
37
+ bun install -g @aigne/cli@beta
41
38
 
42
39
  - name: Publish docs to arcblock.io
43
40
  env:
@@ -46,7 +43,7 @@ jobs:
46
43
  set -e
47
44
  aigne doc publish --appUrl https://www.arcblock.io
48
45
 
49
- - name: Publish docs to prod docsmith
46
+ - name: Publish docs to docsmith
50
47
  env:
51
48
  DOC_DISCUSS_KIT_ACCESS_TOKEN: ${{ secrets.DOC_PUBLISH_API_KEY_DOCSMITH }}
52
49
  run: |
@@ -60,7 +57,7 @@ jobs:
60
57
  if [ -n "$(git status --porcelain)" ]; then
61
58
  echo "Changes detected. Committing and pushing..."
62
59
  git add -A
63
- git commit -m "chore(docs): push doc smith cache [skip ci]"
60
+ git commit -m "chore(docs): push doc publish cache [skip ci]"
64
61
  BRANCH="${{ github.head_ref || github.ref_name }}"
65
62
  git push origin HEAD:refs/heads/"${BRANCH}"
66
63
  else
@@ -1,3 +1,3 @@
1
1
  {
2
- ".": "0.8.12-beta.3"
2
+ ".": "0.8.12-beta.4"
3
3
  }
package/CHANGELOG.md CHANGED
@@ -1,5 +1,18 @@
1
1
  # Changelog
2
2
 
3
+ ## [0.8.12-beta.4](https://github.com/AIGNE-io/aigne-doc-smith/compare/v0.8.12-beta.3...v0.8.12-beta.4) (2025-10-11)
4
+
5
+
6
+ ### Features
7
+
8
+ * implement large context handling and optimize document generation ([#172](https://github.com/AIGNE-io/aigne-doc-smith/issues/172)) ([de09f7c](https://github.com/AIGNE-io/aigne-doc-smith/commit/de09f7c7f9d1ecbf620a6a4684be84f13f4fb644))
9
+
10
+
11
+ ### Bug Fixes
12
+
13
+ * add heading level constraint for doc generating ([#170](https://github.com/AIGNE-io/aigne-doc-smith/issues/170)) ([f4c7163](https://github.com/AIGNE-io/aigne-doc-smith/commit/f4c71631cc89524abf945ae5f829f8111317a5bf))
14
+ * tune update tips and support clear deployment config ([#174](https://github.com/AIGNE-io/aigne-doc-smith/issues/174)) ([71c19e0](https://github.com/AIGNE-io/aigne-doc-smith/commit/71c19e06730111f8b757e523abebaed57bbaea95))
15
+
3
16
  ## [0.8.12-beta.3](https://github.com/AIGNE-io/aigne-doc-smith/compare/v0.8.12-beta.2...v0.8.12-beta.3) (2025-10-09)
4
17
 
5
18
 
@@ -1,24 +1,41 @@
1
+ import { getDocSmithEnvFilePath } from "../../utils/auth-utils.mjs";
2
+ import { getConfigFilePath, getStructurePlanPath, toDisplayPath } from "../../utils/file-utils.mjs";
3
+
1
4
  const TARGET_METADATA = {
2
5
  generatedDocs: {
3
6
  label: "generated documents",
4
- description: "Delete all generated documents.",
7
+ description: ({ docsDir }) =>
8
+ `Delete all generated documents in './${toDisplayPath(docsDir)}' (documentation structure stays).`,
5
9
  agent: "clearGeneratedDocs",
6
10
  },
7
11
  documentStructure: {
8
12
  label: "documentation structure",
9
- description: "Delete the documentation structure and all generated documents.",
13
+ description: ({ docsDir, workDir }) =>
14
+ `Delete all generated documents in './${toDisplayPath(docsDir)}' and the documentation structure './${toDisplayPath(
15
+ getStructurePlanPath(workDir),
16
+ )}' .`,
10
17
  agent: "clearDocumentStructure",
11
18
  },
12
19
  documentConfig: {
13
20
  label: "document configuration",
14
- description: "Delete the document configuration.",
21
+ description: ({ workDir }) =>
22
+ `Delete the configuration file './${toDisplayPath(
23
+ getConfigFilePath(workDir),
24
+ )}' (requires 'aigne doc init' to regenerate).`,
15
25
  agent: "clearDocumentConfig",
16
26
  },
17
27
  authTokens: {
18
28
  label: "authorizations",
19
- description: "Clear published site authorizations.",
29
+ description: () =>
30
+ `Delete authorization information in '${getDocSmithEnvFilePath()}' (requires re-authorization after clearing).`,
20
31
  agent: "clearAuthTokens",
21
32
  },
33
+ deploymentConfig: {
34
+ label: "deployment config",
35
+ description: ({ workDir }) =>
36
+ `Delete appUrl from './${toDisplayPath(getConfigFilePath(workDir))}'.`,
37
+ agent: "clearDeploymentConfig",
38
+ },
22
39
  };
23
40
 
24
41
  const TARGET_KEYS = Object.keys(TARGET_METADATA);
@@ -46,7 +63,7 @@ export default async function chooseContents(input = {}, options = {}) {
46
63
  const choices = Object.entries(TARGET_METADATA).map(([value, def]) => ({
47
64
  name: def.label,
48
65
  value,
49
- description: def.description,
66
+ description: def.description({ docsDir: input.docsDir, workDir: input.workDir }),
50
67
  }));
51
68
 
52
69
  selectedTargets = await options.prompts.checkbox({
@@ -1,13 +1,11 @@
1
1
  import { existsSync } from "node:fs";
2
2
  import { readFile, writeFile } from "node:fs/promises";
3
- import { homedir } from "node:os";
4
- import { join } from "node:path";
5
3
  import chalk from "chalk";
6
4
  import { parse, stringify } from "yaml";
5
+ import { getDocSmithEnvFilePath } from "../../utils/auth-utils.mjs";
7
6
 
8
7
  export default async function clearAuthTokens(_input = {}, options = {}) {
9
- const DOC_SMITH_ENV_FILE = join(homedir(), ".aigne", "doc-smith-connected.yaml");
10
-
8
+ const DOC_SMITH_ENV_FILE = getDocSmithEnvFilePath();
11
9
  // Check if the file exists
12
10
  if (!existsSync(DOC_SMITH_ENV_FILE)) {
13
11
  return {
@@ -0,0 +1,49 @@
1
+ import { readFile, writeFile } from "node:fs/promises";
2
+ import yaml from "yaml";
3
+ import { pathExists, toDisplayPath, getConfigFilePath } from "../../utils/file-utils.mjs";
4
+
5
+ export default async function clearDeploymentConfig(input = {}) {
6
+ const { workDir } = input;
7
+
8
+ const configFilePath = getConfigFilePath(workDir);
9
+ const displayPath = toDisplayPath(configFilePath);
10
+
11
+ try {
12
+ // Check if config file exists
13
+ const exists = await pathExists(configFilePath);
14
+ if (!exists) {
15
+ return {
16
+ message: `๐Ÿ“ฆ Config file not found (${displayPath}). No need to clear appUrl.`,
17
+ };
18
+ }
19
+
20
+ // Remove appUrl field while preserving comments
21
+ const configContent = await readFile(configFilePath, "utf-8");
22
+ const doc = yaml.parseDocument(configContent);
23
+
24
+ if (doc.has("appUrl")) {
25
+ doc.delete("appUrl");
26
+ await writeFile(
27
+ configFilePath,
28
+ doc.toString({
29
+ keepSourceTokens: true,
30
+ indent: 2,
31
+ lineWidth: 0,
32
+ minContentWidth: 0,
33
+ }),
34
+ "utf-8",
35
+ );
36
+ }
37
+
38
+ return {
39
+ message: `๐Ÿงน Cleared appUrl from config file (${displayPath})`,
40
+ };
41
+ } catch (error) {
42
+ return {
43
+ error: true,
44
+ message: `โŒ Failed to clear deployment config: ${error.message}`,
45
+ };
46
+ }
47
+ }
48
+
49
+ clearDeploymentConfig.taskTitle = "Clear deployment configuration";
@@ -1,11 +1,8 @@
1
1
  import { rm } from "node:fs/promises";
2
- import { join } from "node:path";
3
- import { pathExists, toDisplayPath } from "../../utils/file-utils.mjs";
2
+ import { pathExists, toDisplayPath, getConfigFilePath } from "../../utils/file-utils.mjs";
4
3
 
5
4
  export default async function clearDocumentConfig({ workDir }) {
6
- // Fixed path where config.yaml is saved by init command
7
- const cwd = workDir || process.cwd();
8
- const documentConfigPath = join(cwd, ".aigne", "doc-smith", "config.yaml");
5
+ const documentConfigPath = getConfigFilePath(workDir);
9
6
  const displayPath = toDisplayPath(documentConfigPath);
10
7
 
11
8
  try {
@@ -1,14 +1,10 @@
1
1
  import { rm } from "node:fs/promises";
2
- import { join } from "node:path";
3
- import { pathExists, toDisplayPath } from "../../utils/file-utils.mjs";
2
+ import { pathExists, toDisplayPath, getStructurePlanPath } from "../../utils/file-utils.mjs";
4
3
 
5
4
  export default async function clearDocumentStructure(input = {}, _options = {}) {
6
5
  const { docsDir, workDir } = input;
7
- const cwd = workDir || process.cwd();
8
6
 
9
- // Fixed path where structure-plan.json is saved
10
- const outputDir = join(cwd, ".aigne", "doc-smith", "output");
11
- const structurePlanPath = join(outputDir, "structure-plan.json");
7
+ const structurePlanPath = getStructurePlanPath(workDir);
12
8
 
13
9
  const results = [];
14
10
  let hasError = false;
@@ -11,7 +11,6 @@ export default async function clearGeneratedDocs(input = {}, _options = {}) {
11
11
  }
12
12
 
13
13
  const generatedDocsPath = resolveToAbsolute(docsDir);
14
-
15
14
  const displayPath = toDisplayPath(generatedDocsPath);
16
15
 
17
16
  try {