novelscribe 0.2.0__tar.gz

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 (281) hide show
  1. novelscribe-0.2.0/MANIFEST.in +5 -0
  2. novelscribe-0.2.0/PKG-INFO +479 -0
  3. novelscribe-0.2.0/README.md +426 -0
  4. novelscribe-0.2.0/agents/__init__.py +0 -0
  5. novelscribe-0.2.0/agents/chapter_planner_agent.md +244 -0
  6. novelscribe-0.2.0/agents/character_agent.md +237 -0
  7. novelscribe-0.2.0/agents/continuity_agent.md +313 -0
  8. novelscribe-0.2.0/agents/discuss_agent.md +195 -0
  9. novelscribe-0.2.0/agents/editor_agent.md +296 -0
  10. novelscribe-0.2.0/agents/en/chapter_planner_agent.md +244 -0
  11. novelscribe-0.2.0/agents/en/character_agent.md +237 -0
  12. novelscribe-0.2.0/agents/en/continuity_agent.md +313 -0
  13. novelscribe-0.2.0/agents/en/discuss_agent.md +195 -0
  14. novelscribe-0.2.0/agents/en/editor_agent.md +296 -0
  15. novelscribe-0.2.0/agents/en/genre_agent.md +277 -0
  16. novelscribe-0.2.0/agents/en/humanizer_agent.md +436 -0
  17. novelscribe-0.2.0/agents/en/outline_agent.md +288 -0
  18. novelscribe-0.2.0/agents/en/summary_agent.md +195 -0
  19. novelscribe-0.2.0/agents/en/system.md +26 -0
  20. novelscribe-0.2.0/agents/en/template_agent.md +211 -0
  21. novelscribe-0.2.0/agents/en/test_agent.md +10 -0
  22. novelscribe-0.2.0/agents/en/world_agent.md +241 -0
  23. novelscribe-0.2.0/agents/en/writer_agent.md +362 -0
  24. novelscribe-0.2.0/agents/genre_agent.md +277 -0
  25. novelscribe-0.2.0/agents/humanizer_agent.md +436 -0
  26. novelscribe-0.2.0/agents/outline_agent.md +288 -0
  27. novelscribe-0.2.0/agents/summary_agent.md +195 -0
  28. novelscribe-0.2.0/agents/system.md +26 -0
  29. novelscribe-0.2.0/agents/template_agent.md +211 -0
  30. novelscribe-0.2.0/agents/test_agent.md +10 -0
  31. novelscribe-0.2.0/agents/world_agent.md +241 -0
  32. novelscribe-0.2.0/agents/writer_agent.md +362 -0
  33. novelscribe-0.2.0/agents/zh-CN/chapter_planner_agent.md +244 -0
  34. novelscribe-0.2.0/agents/zh-CN/character_agent.md +237 -0
  35. novelscribe-0.2.0/agents/zh-CN/continuity_agent.md +313 -0
  36. novelscribe-0.2.0/agents/zh-CN/discuss_agent.md +195 -0
  37. novelscribe-0.2.0/agents/zh-CN/editor_agent.md +280 -0
  38. novelscribe-0.2.0/agents/zh-CN/genre_agent.md +280 -0
  39. novelscribe-0.2.0/agents/zh-CN/humanizer_agent.md +436 -0
  40. novelscribe-0.2.0/agents/zh-CN/outline_agent.md +288 -0
  41. novelscribe-0.2.0/agents/zh-CN/summary_agent.md +195 -0
  42. novelscribe-0.2.0/agents/zh-CN/system.md +26 -0
  43. novelscribe-0.2.0/agents/zh-CN/template_agent.md +211 -0
  44. novelscribe-0.2.0/agents/zh-CN/test_agent.md +10 -0
  45. novelscribe-0.2.0/agents/zh-CN/world_agent.md +241 -0
  46. novelscribe-0.2.0/agents/zh-CN/writer_agent.md +362 -0
  47. novelscribe-0.2.0/api/__init__.py +1 -0
  48. novelscribe-0.2.0/api/app.py +217 -0
  49. novelscribe-0.2.0/api/models.py +302 -0
  50. novelscribe-0.2.0/api/tasks.py +344 -0
  51. novelscribe-0.2.0/api/websocket_manager.py +543 -0
  52. novelscribe-0.2.0/cli.py +420 -0
  53. novelscribe-0.2.0/cli_agents.py +161 -0
  54. novelscribe-0.2.0/cli_autonomous.py +304 -0
  55. novelscribe-0.2.0/cli_config.py +90 -0
  56. novelscribe-0.2.0/cli_drafts.py +329 -0
  57. novelscribe-0.2.0/cli_logs.py +427 -0
  58. novelscribe-0.2.0/cli_memory.py +448 -0
  59. novelscribe-0.2.0/cli_pagination.py +384 -0
  60. novelscribe-0.2.0/cli_parallel.py +177 -0
  61. novelscribe-0.2.0/cli_performance.py +424 -0
  62. novelscribe-0.2.0/cli_proactive.py +405 -0
  63. novelscribe-0.2.0/cli_qa.py +554 -0
  64. novelscribe-0.2.0/cli_run.py +250 -0
  65. novelscribe-0.2.0/cli_setup.py +260 -0
  66. novelscribe-0.2.0/cli_summary.py +405 -0
  67. novelscribe-0.2.0/cli_templates.py +319 -0
  68. novelscribe-0.2.0/cli_templates_create.py +486 -0
  69. novelscribe-0.2.0/cli_verify.py +290 -0
  70. novelscribe-0.2.0/cli_version.py +89 -0
  71. novelscribe-0.2.0/cli_workflows.py +178 -0
  72. novelscribe-0.2.0/core/__init__.py +3 -0
  73. novelscribe-0.2.0/core/_version.py +12 -0
  74. novelscribe-0.2.0/core/agent.py +52 -0
  75. novelscribe-0.2.0/core/agent_executor.py +194 -0
  76. novelscribe-0.2.0/core/agent_loader.py +191 -0
  77. novelscribe-0.2.0/core/agent_queue.py +430 -0
  78. novelscribe-0.2.0/core/agent_registry.py +201 -0
  79. novelscribe-0.2.0/core/async_executor.py +347 -0
  80. novelscribe-0.2.0/core/autonomous_executor.py +359 -0
  81. novelscribe-0.2.0/core/benchmarking.py +622 -0
  82. novelscribe-0.2.0/core/cache_manager.py +449 -0
  83. novelscribe-0.2.0/core/chapter_paginator.py +519 -0
  84. novelscribe-0.2.0/core/chapter_regenerator.py +363 -0
  85. novelscribe-0.2.0/core/checkpoint_manager.py +244 -0
  86. novelscribe-0.2.0/core/context_cache.py +511 -0
  87. novelscribe-0.2.0/core/context_manager.py +465 -0
  88. novelscribe-0.2.0/core/context_pruner.py +528 -0
  89. novelscribe-0.2.0/core/continuity_parser.py +241 -0
  90. novelscribe-0.2.0/core/cost_calculator.py +253 -0
  91. novelscribe-0.2.0/core/draft_manager.py +431 -0
  92. novelscribe-0.2.0/core/file_optimizer.py +127 -0
  93. novelscribe-0.2.0/core/fix_plan_generator.py +226 -0
  94. novelscribe-0.2.0/core/git_manager.py +294 -0
  95. novelscribe-0.2.0/core/human_checkpoint.py +251 -0
  96. novelscribe-0.2.0/core/language_config.py +269 -0
  97. novelscribe-0.2.0/core/llm_client.py +561 -0
  98. novelscribe-0.2.0/core/llm_optimizer.py +253 -0
  99. novelscribe-0.2.0/core/logger.py +664 -0
  100. novelscribe-0.2.0/core/memory_monitor.py +434 -0
  101. novelscribe-0.2.0/core/memory_profiler.py +483 -0
  102. novelscribe-0.2.0/core/multi_chapter_manager.py +520 -0
  103. novelscribe-0.2.0/core/object_pool.py +411 -0
  104. novelscribe-0.2.0/core/orchestrator.py +366 -0
  105. novelscribe-0.2.0/core/orchestrator_agent_integration.py +134 -0
  106. novelscribe-0.2.0/core/parallel_executor.py +589 -0
  107. novelscribe-0.2.0/core/parallel_orchestrator.py +383 -0
  108. novelscribe-0.2.0/core/performance_profiler.py +501 -0
  109. novelscribe-0.2.0/core/phase_parallelizer.py +436 -0
  110. novelscribe-0.2.0/core/progress_tracker.py +235 -0
  111. novelscribe-0.2.0/core/quality_gate.py +816 -0
  112. novelscribe-0.2.0/core/quality_metrics.py +590 -0
  113. novelscribe-0.2.0/core/rewrite_loop.py +66 -0
  114. novelscribe-0.2.0/core/rollback_manager.py +363 -0
  115. novelscribe-0.2.0/core/step_executor.py +404 -0
  116. novelscribe-0.2.0/core/storage.py +369 -0
  117. novelscribe-0.2.0/core/suggestions/__init__.py +37 -0
  118. novelscribe-0.2.0/core/suggestions/knowledge_base.py +325 -0
  119. novelscribe-0.2.0/core/suggestions/learning_tracker.py +541 -0
  120. novelscribe-0.2.0/core/suggestions/models.py +188 -0
  121. novelscribe-0.2.0/core/suggestions/orchestrator.py +329 -0
  122. novelscribe-0.2.0/core/summary_manager.py +468 -0
  123. novelscribe-0.2.0/core/summary_store.py +537 -0
  124. novelscribe-0.2.0/core/template_loader.py +195 -0
  125. novelscribe-0.2.0/core/token_tracker.py +536 -0
  126. novelscribe-0.2.0/core/validation_system.py +701 -0
  127. novelscribe-0.2.0/core/variable_resolver.py +227 -0
  128. novelscribe-0.2.0/core/verification_engine.py +230 -0
  129. novelscribe-0.2.0/core/version.py +271 -0
  130. novelscribe-0.2.0/core/version_comparator.py +334 -0
  131. novelscribe-0.2.0/core/workflow_executor.py +204 -0
  132. novelscribe-0.2.0/core/workflow_loader.py +215 -0
  133. novelscribe-0.2.0/novelscribe.egg-info/PKG-INFO +479 -0
  134. novelscribe-0.2.0/novelscribe.egg-info/SOURCES.txt +279 -0
  135. novelscribe-0.2.0/novelscribe.egg-info/dependency_links.txt +1 -0
  136. novelscribe-0.2.0/novelscribe.egg-info/entry_points.txt +2 -0
  137. novelscribe-0.2.0/novelscribe.egg-info/requires.txt +29 -0
  138. novelscribe-0.2.0/novelscribe.egg-info/top_level.txt +24 -0
  139. novelscribe-0.2.0/pyproject.toml +188 -0
  140. novelscribe-0.2.0/setup.cfg +4 -0
  141. novelscribe-0.2.0/tests/test_agent_loader_extended.py +388 -0
  142. novelscribe-0.2.0/tests/test_agent_queue_extended.py +530 -0
  143. novelscribe-0.2.0/tests/test_agent_registry_extended.py +514 -0
  144. novelscribe-0.2.0/tests/test_agent_system.py +323 -0
  145. novelscribe-0.2.0/tests/test_api.py +5 -0
  146. novelscribe-0.2.0/tests/test_api_coverage.py +708 -0
  147. novelscribe-0.2.0/tests/test_api_models.py +349 -0
  148. novelscribe-0.2.0/tests/test_async_executor_extended.py +477 -0
  149. novelscribe-0.2.0/tests/test_auth.py +395 -0
  150. novelscribe-0.2.0/tests/test_autonomous_executor.py +585 -0
  151. novelscribe-0.2.0/tests/test_autonomous_executor_coverage.py +845 -0
  152. novelscribe-0.2.0/tests/test_autonomous_executor_coverage_extended.py +372 -0
  153. novelscribe-0.2.0/tests/test_benchmarking.py +9 -0
  154. novelscribe-0.2.0/tests/test_benchmarking_comprehensive.py +520 -0
  155. novelscribe-0.2.0/tests/test_cache_manager_extended.py +673 -0
  156. novelscribe-0.2.0/tests/test_chapter_paginator.py +711 -0
  157. novelscribe-0.2.0/tests/test_chapter_paginator_extended.py +267 -0
  158. novelscribe-0.2.0/tests/test_chapter_regenerator.py +605 -0
  159. novelscribe-0.2.0/tests/test_checkpoint_manager.py +392 -0
  160. novelscribe-0.2.0/tests/test_checkpoint_manager_extended.py +207 -0
  161. novelscribe-0.2.0/tests/test_cli.py +195 -0
  162. novelscribe-0.2.0/tests/test_cli_agents.py +281 -0
  163. novelscribe-0.2.0/tests/test_cli_autonomous.py +642 -0
  164. novelscribe-0.2.0/tests/test_cli_config.py +173 -0
  165. novelscribe-0.2.0/tests/test_cli_drafts.py +463 -0
  166. novelscribe-0.2.0/tests/test_cli_integration.py +173 -0
  167. novelscribe-0.2.0/tests/test_cli_language.py +264 -0
  168. novelscribe-0.2.0/tests/test_cli_memory.py +400 -0
  169. novelscribe-0.2.0/tests/test_cli_pagination.py +1229 -0
  170. novelscribe-0.2.0/tests/test_cli_performance.py +967 -0
  171. novelscribe-0.2.0/tests/test_cli_run.py +342 -0
  172. novelscribe-0.2.0/tests/test_cli_setup.py +183 -0
  173. novelscribe-0.2.0/tests/test_cli_summary.py +478 -0
  174. novelscribe-0.2.0/tests/test_cli_verify.py +1031 -0
  175. novelscribe-0.2.0/tests/test_cli_version.py +56 -0
  176. novelscribe-0.2.0/tests/test_cli_workflows.py +356 -0
  177. novelscribe-0.2.0/tests/test_comprehensive_coverage.py +478 -0
  178. novelscribe-0.2.0/tests/test_context_cache_comprehensive.py +398 -0
  179. novelscribe-0.2.0/tests/test_context_cache_extended.py +358 -0
  180. novelscribe-0.2.0/tests/test_context_manager_coverage.py +51 -0
  181. novelscribe-0.2.0/tests/test_context_manager_extended.py +691 -0
  182. novelscribe-0.2.0/tests/test_context_pruner_coverage.py +792 -0
  183. novelscribe-0.2.0/tests/test_continuity_parser.py +252 -0
  184. novelscribe-0.2.0/tests/test_cost_calculator.py +183 -0
  185. novelscribe-0.2.0/tests/test_draft_manager.py +640 -0
  186. novelscribe-0.2.0/tests/test_error_handling.py +182 -0
  187. novelscribe-0.2.0/tests/test_fix_plan_generator.py +306 -0
  188. novelscribe-0.2.0/tests/test_git_manager.py +371 -0
  189. novelscribe-0.2.0/tests/test_human_checkpoint.py +391 -0
  190. novelscribe-0.2.0/tests/test_knowledge_base.py +325 -0
  191. novelscribe-0.2.0/tests/test_language_config.py +262 -0
  192. novelscribe-0.2.0/tests/test_language_integration.py +417 -0
  193. novelscribe-0.2.0/tests/test_learning_tracker.py +404 -0
  194. novelscribe-0.2.0/tests/test_llm_client.py +293 -0
  195. novelscribe-0.2.0/tests/test_llm_client_comprehensive.py +1001 -0
  196. novelscribe-0.2.0/tests/test_llm_client_coverage.py +108 -0
  197. novelscribe-0.2.0/tests/test_llm_client_extended.py +231 -0
  198. novelscribe-0.2.0/tests/test_llm_optimizer_coverage.py +275 -0
  199. novelscribe-0.2.0/tests/test_logger.py +419 -0
  200. novelscribe-0.2.0/tests/test_memory.py +475 -0
  201. novelscribe-0.2.0/tests/test_memory_monitor.py +675 -0
  202. novelscribe-0.2.0/tests/test_memory_profiler.py +704 -0
  203. novelscribe-0.2.0/tests/test_memory_profiler_comprehensive.py +815 -0
  204. novelscribe-0.2.0/tests/test_multi_chapter_manager.py +802 -0
  205. novelscribe-0.2.0/tests/test_object_pool.py +770 -0
  206. novelscribe-0.2.0/tests/test_optimization_utils.py +134 -0
  207. novelscribe-0.2.0/tests/test_orchestrator.py +453 -0
  208. novelscribe-0.2.0/tests/test_orchestrator_agent_integration.py +477 -0
  209. novelscribe-0.2.0/tests/test_orchestrator_comprehensive.py +711 -0
  210. novelscribe-0.2.0/tests/test_orchestrator_extended.py +156 -0
  211. novelscribe-0.2.0/tests/test_packaging_regression.py +550 -0
  212. novelscribe-0.2.0/tests/test_pagination.py +532 -0
  213. novelscribe-0.2.0/tests/test_parallel.py +467 -0
  214. novelscribe-0.2.0/tests/test_parallel_executor_comprehensive.py +515 -0
  215. novelscribe-0.2.0/tests/test_parallel_orchestrator.py +427 -0
  216. novelscribe-0.2.0/tests/test_performance.py +674 -0
  217. novelscribe-0.2.0/tests/test_performance_profiler_comprehensive.py +543 -0
  218. novelscribe-0.2.0/tests/test_phase_parallelizer.py +628 -0
  219. novelscribe-0.2.0/tests/test_progress_tracker.py +178 -0
  220. novelscribe-0.2.0/tests/test_quality_gate.py +651 -0
  221. novelscribe-0.2.0/tests/test_quality_gate_coverage.py +387 -0
  222. novelscribe-0.2.0/tests/test_quality_metrics.py +318 -0
  223. novelscribe-0.2.0/tests/test_rate_limit.py +317 -0
  224. novelscribe-0.2.0/tests/test_rewrite_loop_extended.py +142 -0
  225. novelscribe-0.2.0/tests/test_rollback_manager.py +449 -0
  226. novelscribe-0.2.0/tests/test_router_advanced_coverage.py +528 -0
  227. novelscribe-0.2.0/tests/test_router_coverage_extended.py +255 -0
  228. novelscribe-0.2.0/tests/test_router_final_coverage.py +373 -0
  229. novelscribe-0.2.0/tests/test_router_logs.py +561 -0
  230. novelscribe-0.2.0/tests/test_router_logs_coverage.py +657 -0
  231. novelscribe-0.2.0/tests/test_router_logs_integration.py +299 -0
  232. novelscribe-0.2.0/tests/test_router_logs_parameterized.py +404 -0
  233. novelscribe-0.2.0/tests/test_router_logs_performance.py +368 -0
  234. novelscribe-0.2.0/tests/test_router_missing_coverage.py +349 -0
  235. novelscribe-0.2.0/tests/test_router_streaming.py +673 -0
  236. novelscribe-0.2.0/tests/test_router_streaming_coverage.py +1070 -0
  237. novelscribe-0.2.0/tests/test_router_streaming_integration.py +296 -0
  238. novelscribe-0.2.0/tests/test_router_streaming_parameterized.py +639 -0
  239. novelscribe-0.2.0/tests/test_router_streaming_performance.py +567 -0
  240. novelscribe-0.2.0/tests/test_router_targeted_coverage.py +454 -0
  241. novelscribe-0.2.0/tests/test_setup_wizard.py +188 -0
  242. novelscribe-0.2.0/tests/test_step_executor.py +390 -0
  243. novelscribe-0.2.0/tests/test_step_executor_comprehensive.py +823 -0
  244. novelscribe-0.2.0/tests/test_step_executor_coverage.py +372 -0
  245. novelscribe-0.2.0/tests/test_storage.py +266 -0
  246. novelscribe-0.2.0/tests/test_storage_comprehensive.py +583 -0
  247. novelscribe-0.2.0/tests/test_storage_coverage.py +296 -0
  248. novelscribe-0.2.0/tests/test_storage_models.py +99 -0
  249. novelscribe-0.2.0/tests/test_suggestion_models.py +291 -0
  250. novelscribe-0.2.0/tests/test_summary.py +542 -0
  251. novelscribe-0.2.0/tests/test_summary_manager.py +259 -0
  252. novelscribe-0.2.0/tests/test_summary_store_comprehensive.py +854 -0
  253. novelscribe-0.2.0/tests/test_summary_store_targets.py +205 -0
  254. novelscribe-0.2.0/tests/test_tasks.py +387 -0
  255. novelscribe-0.2.0/tests/test_template_loader.py +249 -0
  256. novelscribe-0.2.0/tests/test_token_tracker.py +327 -0
  257. novelscribe-0.2.0/tests/test_validation_system.py +524 -0
  258. novelscribe-0.2.0/tests/test_variable_resolver.py +411 -0
  259. novelscribe-0.2.0/tests/test_verification_engine.py +305 -0
  260. novelscribe-0.2.0/tests/test_verification_engine_extended.py +255 -0
  261. novelscribe-0.2.0/tests/test_version.py +193 -0
  262. novelscribe-0.2.0/tests/test_version_comparator.py +149 -0
  263. novelscribe-0.2.0/tests/test_version_comparator_coverage.py +210 -0
  264. novelscribe-0.2.0/tests/test_version_comprehensive.py +307 -0
  265. novelscribe-0.2.0/tests/test_version_extended.py +347 -0
  266. novelscribe-0.2.0/tests/test_websocket.py +329 -0
  267. novelscribe-0.2.0/tests/test_websocket_manager.py +482 -0
  268. novelscribe-0.2.0/tests/test_workflow_engine.py +420 -0
  269. novelscribe-0.2.0/tests/test_workflow_executor.py +116 -0
  270. novelscribe-0.2.0/tests/test_workflow_executor_coverage.py +431 -0
  271. novelscribe-0.2.0/tests/test_workflow_loader.py +246 -0
  272. novelscribe-0.2.0/workflows/__init__.py +0 -0
  273. novelscribe-0.2.0/workflows/autonomous.yaml +152 -0
  274. novelscribe-0.2.0/workflows/chapter_plan_phase.yaml +60 -0
  275. novelscribe-0.2.0/workflows/character_phase.yaml +62 -0
  276. novelscribe-0.2.0/workflows/continuity_phase.yaml +86 -0
  277. novelscribe-0.2.0/workflows/new_novel.yaml +53 -0
  278. novelscribe-0.2.0/workflows/outline_phase.yaml +72 -0
  279. novelscribe-0.2.0/workflows/verification_phase.yaml +140 -0
  280. novelscribe-0.2.0/workflows/worldbuilding_phase.yaml +62 -0
  281. novelscribe-0.2.0/workflows/writing_phase.yaml +122 -0
@@ -0,0 +1,5 @@
1
+ include agents/en/*.md
2
+ include agents/zh-CN/*.md
3
+ include agents/zh-TW/*.md
4
+ include workflows/*.yaml
5
+ include core/_version.py
@@ -0,0 +1,479 @@
1
+ Metadata-Version: 2.4
2
+ Name: novelscribe
3
+ Version: 0.2.0
4
+ Summary: AI-powered autonomous novel generation system — install with 'pip install novelscribe', run with 'scribe'
5
+ Author-email: NovelScribe Team <huangjien@gmail.com>
6
+ License-Expression: MIT
7
+ Project-URL: Homepage, https://github.com/huangjien/novelscribe
8
+ Project-URL: Documentation, https://github.com/huangjien/novelscribe#readme
9
+ Project-URL: Repository, https://github.com/huangjien/novelscribe
10
+ Project-URL: Issues, https://github.com/huangjien/novelscribe/issues
11
+ Project-URL: Changelog, https://github.com/huangjien/novelscribe/releases
12
+ Keywords: novel,writing,ai,llm,gpt,autonomous,agents,fiction,creative,scribe
13
+ Classifier: Development Status :: 4 - Beta
14
+ Classifier: Intended Audience :: End Users/Desktop
15
+ Classifier: Intended Audience :: Developers
16
+ Classifier: Operating System :: OS Independent
17
+ Classifier: Programming Language :: Python :: 3
18
+ Classifier: Programming Language :: Python :: 3.10
19
+ Classifier: Programming Language :: Python :: 3.11
20
+ Classifier: Programming Language :: Python :: 3.12
21
+ Classifier: Programming Language :: Python :: 3.13
22
+ Classifier: Topic :: Text Processing :: General
23
+ Classifier: Topic :: Software Development :: Libraries :: Python Modules
24
+ Requires-Python: <3.15,>=3.10
25
+ Description-Content-Type: text/markdown
26
+ Requires-Dist: openai>=1.0.0
27
+ Requires-Dist: anthropic>=0.18.0
28
+ Requires-Dist: google-generativeai>=0.3.0
29
+ Requires-Dist: pyyaml>=6.0
30
+ Requires-Dist: gitpython>=3.1.40
31
+ Requires-Dist: click>=8.1.0
32
+ Requires-Dist: pydantic>=2.0.0
33
+ Requires-Dist: python-dotenv>=1.0.0
34
+ Requires-Dist: toml>=0.10.2
35
+ Requires-Dist: requests>=2.31.0
36
+ Requires-Dist: packaging>=23.0
37
+ Requires-Dist: inquirer3>=0.3.0
38
+ Requires-Dist: rich>=13.0.0
39
+ Provides-Extra: dev
40
+ Requires-Dist: pytest>=8.0.0; extra == "dev"
41
+ Requires-Dist: pytest-asyncio>=0.23.0; extra == "dev"
42
+ Requires-Dist: pytest-cov>=5.0.0; extra == "dev"
43
+ Requires-Dist: pytest-xdist>=3.5.0; extra == "dev"
44
+ Requires-Dist: pytest-cache; extra == "dev"
45
+ Requires-Dist: black>=23.0.0; extra == "dev"
46
+ Requires-Dist: ruff>=0.1.0; extra == "dev"
47
+ Requires-Dist: mypy>=1.5.0; extra == "dev"
48
+ Requires-Dist: pre-commit>=3.0.0; extra == "dev"
49
+ Provides-Extra: api
50
+ Requires-Dist: fastapi>=0.104.0; extra == "api"
51
+ Requires-Dist: uvicorn[standard]>=0.24.0; extra == "api"
52
+ Requires-Dist: websockets>=12.0; extra == "api"
53
+
54
+ # Novel Writing Harness
55
+
56
+ [![CI](https://github.com/huangjien/wst/actions/workflows/ci.yml/badge.svg)](https://github.com/huangjien/wst/actions/workflows/ci.yml)
57
+ [![PyPI version](https://badge.fury.io/py/novel-harness.svg)](https://pypi.org/project/novel-harness/)
58
+ [![Python versions](https://img.shields.io/badge/python-3.10%20|%203.11%20|%203.12%20|%203.13%20|%203.14-blue.svg)](https://pypi.org/project/novel-harness/)
59
+ [![License](https://img.shields.io/badge/license-MIT-green.svg)](LICENSE)
60
+
61
+ An AI-powered autonomous novel generation system with multi-agent architecture.
62
+
63
+ > **Language / 语言 / 語言:** [English](README.md) | [简体中文](docs/getting-started/README.zh-CN.md) | [繁體中文](docs/getting-started/README.zh-TW.md)
64
+
65
+ ## Quick Start
66
+
67
+ ### Installation
68
+
69
+ ```bash
70
+ cd wst/novel_harness
71
+ uv sync --all-extras
72
+ ```
73
+
74
+ ## Usage
75
+
76
+ ### Method 1: Use the Wrapper Script (Recommended)
77
+
78
+ The project includes a `scribe` wrapper script that automatically uses the correct Python environment:
79
+
80
+ ```bash
81
+ # From the project directory
82
+ ./scribe --help
83
+
84
+ # Add to PATH for easy access
85
+ export PATH="/path/to/wst/novel_harness:$PATH"
86
+
87
+ # Then use from anywhere
88
+ scribe --help
89
+ scribe new my-novel
90
+ ```
91
+
92
+ ### Method 2: Using uv run
93
+
94
+ ```bash
95
+ cd wst/novel_harness
96
+ uv run python cli.py --help
97
+ ```
98
+
99
+ ## Quick Examples
100
+
101
+ ```bash
102
+ # Show help
103
+ ./scribe --help
104
+
105
+ # Check version
106
+ ./scribe version info
107
+
108
+ # Check for updates
109
+ ./scribe version check
110
+
111
+ # Initialize a new novel
112
+ ./scribe new my-novel --provider openai --model gpt-4
113
+
114
+ # Run autonomous generation
115
+ ./scribe autonomous start my-novel
116
+
117
+ # Explore available agents
118
+ ./scribe agents list
119
+ ./scribe agents show writer_agent
120
+
121
+ # Explore available workflows
122
+ ./scribe workflows list
123
+ ./scribe workflows show outline
124
+
125
+ # Run agents/workflows
126
+ ./scribe run agent writer_agent --project my-novel
127
+ ./scribe run workflow outline --project my-novel
128
+ ```
129
+
130
+ ## CLI Commands
131
+
132
+ ### Agent Commands
133
+
134
+ Explore and manage AI agents:
135
+
136
+ ```bash
137
+ # List all available agents
138
+ scribe agents list
139
+
140
+ # Show detailed information about an agent
141
+ scribe agents show writer_agent
142
+
143
+ # Agents are grouped by category:
144
+ # - Analytical: Analysis, planning, and validation agents
145
+ # - Creative: Content generation and creative writing agents
146
+ # - Validation: Quality checking and verification agents
147
+ ```
148
+
149
+ ### Template Commands
150
+
151
+ Explore and manage story templates:
152
+
153
+ ```bash
154
+ # List all available templates
155
+ scribe templates list
156
+
157
+ # Show template details
158
+ scribe templates show heros_journey --category plot
159
+
160
+ # Format template for prompts (optionally at position %)
161
+ scribe templates format heros_journey --position 50
162
+
163
+ # Export all templates
164
+ scribe templates export -o templates.json
165
+
166
+ # Show template system info
167
+ scribe templates info
168
+
169
+ # Show supported languages
170
+ scribe templates languages
171
+
172
+ # Create new templates
173
+ scribe template-create plot -n "My Structure" -d "Description" -b "0:Hook:Description"
174
+ scribe template-create character -n "My Archetype" -d "Description" -e "Want:Description"
175
+ scribe template-create scene -n "My Scene" -d "Description" -e "Element:Description"
176
+
177
+ # Clone and modify existing templates
178
+ scribe template-create clone heros_journey my_journey -c plot
179
+
180
+ # Validate template YAML
181
+ scribe template-create validate templates/en/plot/my_template.yaml
182
+
183
+ # Translate template to another language
184
+ scribe template-create translate heros_journey -c plot --source-language en --target-language zh-CN
185
+
186
+ # Show template creation help
187
+ scribe template-create help
188
+ ```
189
+
190
+ ### Workflow Commands
191
+
192
+ Explore and manage workflows:
193
+
194
+ ```bash
195
+ # List all available workflows
196
+ scribe workflows list
197
+
198
+ # Show detailed information about a workflow
199
+ scribe workflows show new_novel
200
+
201
+ # Workflows are multi-step processes that combine agents
202
+ # Examples: new_novel, outline, writing, editing
203
+ ```
204
+
205
+ ### Run Commands
206
+
207
+ Execute agents and workflows:
208
+
209
+ ```bash
210
+ # Run a single agent
211
+ scribe run agent writer_agent --project my-novel
212
+
213
+ # Run a workflow
214
+ scribe run workflow outline --project my-novel
215
+
216
+ # With verbose output
217
+ scribe -vv run agent character_agent --project my-novel
218
+
219
+ # Dry run (preview what would happen)
220
+ scribe run workflow writing --project my-novel --dry-run
221
+ ```
222
+
223
+ ## Multi-Language Support
224
+
225
+ The Novel Writing Harness supports multiple languages for agents, workflows, and system messages.
226
+
227
+ ### Supported Languages
228
+
229
+ | Language | Code | Script |
230
+ |----------|------|--------|
231
+ | English | `en` | Latin |
232
+ | Simplified Chinese | `zh-CN` | Han |
233
+ | Traditional Chinese | `zh-TW` | Han |
234
+
235
+ ### Setting Your Language
236
+
237
+ #### Per-Project (Recommended)
238
+
239
+ Set the language in your project's `META.yaml`:
240
+
241
+ ```yaml
242
+ project_name: my_novel
243
+ language: zh-CN
244
+ genre: fantasy
245
+ target_word_count: 80000
246
+ ```
247
+
248
+ All commands will automatically use this language:
249
+
250
+ ```bash
251
+ scribe agents list # Uses zh-CN from META.yaml
252
+ scribe workflows show outline # Uses zh-CN from META.yaml
253
+ scribe run workflow autonomous # Uses zh-CN from META.yaml
254
+ ```
255
+
256
+ #### User Default
257
+
258
+ Set your personal default language:
259
+
260
+ ```bash
261
+ scribe config set language zh-CN
262
+ ```
263
+
264
+ This applies to all new projects.
265
+
266
+ #### Override with CLI Option
267
+
268
+ Temporarily override the project or user setting:
269
+
270
+ ```bash
271
+ # View agents in Traditional Chinese
272
+ scribe --lang zh-TW agents list
273
+
274
+ # Run workflow in English
275
+ scribe --lang en run workflow outline --project my-novel
276
+ ```
277
+
278
+ #### Environment Variable
279
+
280
+ Set via environment variable (useful for CI/CD):
281
+
282
+ ```bash
283
+ export SCRIBE_LANGUAGE=zh-CN
284
+ scribe agents list # Uses zh-CN
285
+ ```
286
+
287
+ ### Language Resolution Priority
288
+
289
+ The system resolves language using this priority chain (highest to lowest):
290
+
291
+ 1. **CLI option** `--lang` (highest priority)
292
+ 2. **Project configuration** `META.yaml` field `language`
293
+ 3. **User configuration** `~/.scribe/config.yaml`
294
+ 4. **Environment variable** `SCRIBE_LANGUAGE`
295
+ 5. **System locale** (auto-detected)
296
+ 6. **English** `en` (fallback, always available)
297
+
298
+ ### Examples
299
+
300
+ ```bash
301
+ # Set default language to Simplified Chinese
302
+ scribe config set language zh-CN
303
+
304
+ # Create a new novel project
305
+ cd my-novel
306
+ echo "language: zh-TW" >> META.yaml
307
+
308
+ # List agents - shows Traditional Chinese
309
+ scribe agents list
310
+
311
+ # Temporarily view in English
312
+ scribe --lang en agents list
313
+
314
+ # Run workflow - uses Traditional Chinese from META.yaml
315
+ scribe run workflow outline
316
+
317
+ # Per-command override
318
+ scribe --lang zh-CN run agent writer_agent --project my-novel
319
+ ```
320
+
321
+ ### Fallback Behavior
322
+
323
+ If a language version is missing, the system automatically falls back to English:
324
+
325
+ ```
326
+ Request: zh-CN → Check agents/zh-CN/ → Empty → Fallback to agents/en/
327
+ Request: zh-TW → Check workflows/zh-TW/ → Missing → Fallback to workflows/en/
328
+ ```
329
+
330
+ This ensures all commands work even when translations are incomplete.
331
+
332
+ ### Viewing Current Language
333
+
334
+ All commands display the current language in their output:
335
+
336
+ ```bash
337
+ $ scribe agents list
338
+ Available Agents (12) [Language: zh-CN]:
339
+ ...
340
+ ```
341
+
342
+ ### Adding New Languages
343
+
344
+ The system is designed to easily support additional languages. To add a new language:
345
+
346
+ 1. Create language subdirectories:
347
+ ```bash
348
+ mkdir -p agents/{new-lang}
349
+ mkdir -p workflows/{new-lang}
350
+ ```
351
+
352
+ 2. Add translated agent/workflow files
353
+
354
+ 3. Update `LanguageCode` enum in `core/language_config.py`
355
+
356
+ 4. Update CLI `--lang` option choices
357
+
358
+ For detailed translation guidelines, see [TRANSLATION_GUIDE.md](TRANSLATION_GUIDE.md) (to be created).
359
+
360
+ ## IDE & Chatbot Integration
361
+
362
+ The Novel Harness now supports seamless integration with VS Code Copilot, Trae, and other AI chatbots through a dedicated skill.
363
+
364
+ ### Quick Start with Chatbot
365
+
366
+ 1. **Install the Skill**
367
+ ```bash
368
+ # The skill is packaged at: novel_harness_skill.skill
369
+ # Copy to your skills directory
370
+ cp novel_harness_skill.skill ~/.trae/skills/
371
+ ```
372
+
373
+ 2. **Use from Your Chatbot**
374
+
375
+ Simply ask your chatbot to work with novels:
376
+
377
+ - *"Create a new science fiction novel called 'The Last Algorithm'"*
378
+ - *"Start autonomous generation for my_novel project"*
379
+ - *"Check the status of the generation"*
380
+ - *"Review chapter 5 of my_novel"*
381
+ - *"Generate a progress report for my_novel"*
382
+
383
+ ### Available Chatbot Commands
384
+
385
+ **Project Management:**
386
+ - Create/list/delete novel projects
387
+ - Set genre, word count, language
388
+ - View project status and details
389
+
390
+ **Content Generation:**
391
+ - Run autonomous generation (end-to-end)
392
+ - Generate individual chapters
393
+ - Execute specific workflows (outline, writing, editing)
394
+ - Run individual agents
395
+
396
+ **Review & Edit:**
397
+ - View generated chapters
398
+ - Access hierarchical summaries
399
+ - Edit content directly
400
+ - Run quality checks
401
+
402
+ **Monitoring:**
403
+ - Real-time progress tracking
404
+ - View execution logs
405
+ - Stream status updates
406
+ - Generate progress reports
407
+
408
+ ### Integration Modes
409
+
410
+ **API Server Mode (Recommended):**
411
+ ```python
412
+ # Automatically starts FastAPI server on localhost:8000
413
+ # RESTful API with full feature support
414
+ ```
415
+
416
+ **CLI Fallback Mode:**
417
+ ```python
418
+ # Direct CLI commands when API unavailable
419
+ # Automatic fallback for maximum reliability
420
+ ```
421
+
422
+ ### Documentation
423
+
424
+ See [docs/](docs/README.md) for full documentation:
425
+
426
+ **Getting Started:**
427
+ - [Quick Start Guide](docs/getting-started/QUICK_START.md)
428
+ - [Installation Guide](docs/getting-started/INSTALLATION_GUIDE.md)
429
+ - [User Guide](docs/getting-started/USER_GUIDE.md)
430
+
431
+ **Guides:**
432
+ - [Template Creation Guide](docs/guides/TEMPLATE_CREATION.md)
433
+ - [Translation Guide](docs/guides/TRANSLATION_GUIDE.md)
434
+ - [Skill Usage Guide](docs/guides/SKILL_USAGE.md)
435
+
436
+ **Development:**
437
+ - [CI/CD Guide](docs/development/CI_CD.md)
438
+ - [Deployment Guide](docs/development/DEPLOY.md)
439
+
440
+ **Reference:**
441
+ - [UV Guide](docs/reference/UV_GUIDE.md)
442
+ - [PyPI Setup](docs/reference/PYPI_SETUP.md)
443
+
444
+ ## CI/CD
445
+
446
+ This project uses GitHub Actions for automated testing, linting, and deployment.
447
+
448
+ ### Workflows
449
+
450
+ - **CI**: Runs tests, linting, and type checking on every push/PR
451
+ - **CD**: Builds and publishes package to PyPI on release
452
+ - **Pre-commit**: Runs quality checks on all branches
453
+
454
+ ### Status Badges
455
+
456
+ Add status badges to your README:
457
+
458
+ ```markdown
459
+ [![CI](https://github.com/huangjien/wst/actions/workflows/ci.yml/badge.svg)](https://github.com/huangjien/wst/actions/workflows/ci.yml)
460
+ [![PyPI version](https://badge.fury.io/py/novel-harness.svg)](https://pypi.org/project/novel-harness/)
461
+ ```
462
+
463
+ ### Local Development
464
+
465
+ ```bash
466
+ # Install pre-commit hooks
467
+ pre-commit install
468
+
469
+ # Run all checks locally
470
+ make check
471
+
472
+ # Or individually
473
+ make format # Format code
474
+ make lint # Lint code
475
+ make type-check # Type check
476
+ make test # Run tests
477
+ ```
478
+
479
+ See [CI_CD.md](CI_CD.md) for detailed setup instructions.