fabricatio 0.4.4__tar.gz → 0.4.4.dev1__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 (192) hide show
  1. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/Makefile +3 -6
  2. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/PKG-INFO +6 -17
  3. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/README.md +5 -16
  4. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/examples/extract_and_inject/ask.py +1 -1
  5. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/examples/extract_and_inject/extract_and_inject.py +3 -3
  6. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/examples/make_a_rating/rating.py +3 -3
  7. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/examples/rules/draft_ruleset.py +2 -2
  8. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/examples/search_bibtex/search.py +4 -3
  9. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/examples/write_article/article_rag.py +6 -6
  10. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/examples/write_article/post_process.py +2 -1
  11. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/examples/write_article/write_article.py +12 -4
  12. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-actions/pyproject.toml +1 -1
  13. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-digest/pyproject.toml +1 -1
  14. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-digest/python/fabricatio_digest/capabilities/digest.py +9 -8
  15. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-digest/python/fabricatio_digest/config.py +6 -4
  16. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-digest/python/fabricatio_digest/models/tasklist.py +0 -1
  17. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-improve/pyproject.toml +1 -1
  18. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-improve/python/fabricatio_improve/capabilities/correct.py +18 -18
  19. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-improve/python/fabricatio_improve/capabilities/review.py +7 -7
  20. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-improve/python/fabricatio_improve/config.py +4 -4
  21. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-improve/python/fabricatio_improve/models/improve.py +0 -1
  22. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-improve/python/fabricatio_improve/models/kwargs_types.py +0 -1
  23. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-judge/pyproject.toml +1 -1
  24. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-judge/python/fabricatio_judge/capabilities/advanced_judge.py +3 -3
  25. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-question/pyproject.toml +1 -1
  26. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-question/python/fabricatio_question/models/questions.py +6 -5
  27. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-rule/pyproject.toml +1 -1
  28. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-rule/python/fabricatio_rule/capabilities/censor.py +3 -3
  29. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-rule/python/fabricatio_rule/capabilities/check.py +24 -24
  30. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-rule/python/fabricatio_rule/config.py +4 -5
  31. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-tagging/pyproject.toml +1 -1
  32. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-tagging/python/fabricatio_tagging/capabilities/tagging.py +24 -18
  33. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-tagging/python/fabricatio_tagging/config.py +5 -5
  34. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/pyproject.toml +1 -1
  35. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/python/fabricatio/capabilities/__init__.py +3 -14
  36. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/python/fabricatio/models/__init__.py +11 -12
  37. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/python/fabricatio/workflows/__init__.py +4 -1
  38. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/src/bin/tdown.rs +48 -110
  39. fabricatio-0.4.4/templates/built-in/generate_anki_card_template.hbs → fabricatio-0.4.4.dev1/templates/built-in/generate_anki_card_type.hbs +1 -1
  40. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/uv.lock +55 -59
  41. fabricatio-0.4.4/templates/built-in/generate_anki_card_template_generation_requirements.hbs +0 -18
  42. fabricatio-0.4.4/templates/built-in/generate_anki_deck_metadata.hbs +0 -12
  43. fabricatio-0.4.4/templates/built-in/generate_anki_model_generation_requirements.hbs +0 -17
  44. fabricatio-0.4.4/templates/built-in/generate_anki_model_name.hbs +0 -12
  45. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/.github/workflows/build-package.yaml +0 -0
  46. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/.github/workflows/ruff.yaml +0 -0
  47. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/.github/workflows/tests.yaml +0 -0
  48. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/.gitignore +0 -0
  49. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/Cargo.lock +0 -0
  50. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/Cargo.toml +0 -0
  51. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/LICENSE +0 -0
  52. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/examples/correct/correct.py +0 -0
  53. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/examples/correct/correct_loop.py +0 -0
  54. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/examples/extract_and_inject/.gitignore +0 -0
  55. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/examples/extract_and_inject/article_rag.py +0 -0
  56. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/examples/extract_and_inject/chunk_article.py +0 -0
  57. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/examples/extract_article/extract.py +0 -0
  58. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/examples/llm_usages/llm_usage.py +0 -0
  59. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/examples/make_diary/commits.json +0 -0
  60. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/examples/make_diary/diary.py +0 -0
  61. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/examples/minor/hello_fabricatio.py +0 -0
  62. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/examples/minor/write_a_poem.py +0 -0
  63. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/examples/propose_task/.gitignore +0 -0
  64. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/examples/propose_task/propose.py +0 -0
  65. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/examples/reviewer/censor.py +0 -0
  66. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/examples/reviewer/review.py +0 -0
  67. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/examples/rules/.gitignore +0 -0
  68. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/examples/search_bibtex/.gitignore +0 -0
  69. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/examples/simple_chat/chat.py +0 -0
  70. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/examples/simple_rag/simple_rag.py +0 -0
  71. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/examples/task_handle/handle_task.py +0 -0
  72. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/examples/write_article/.gitignore +0 -0
  73. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/examples/write_outline/.gitignore +0 -0
  74. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/examples/write_outline/write_outline.py +0 -0
  75. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/examples/write_outline/write_outline_corrected.py +0 -0
  76. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-actions/LICENSE +0 -0
  77. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-actions/README.md +0 -0
  78. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-actions/python/fabricatio_actions/__init__.py +0 -0
  79. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-actions/python/fabricatio_actions/actions/__init__.py +0 -0
  80. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-actions/python/fabricatio_actions/actions/fs.py +0 -0
  81. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-actions/python/fabricatio_actions/actions/output.py +0 -0
  82. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-actions/python/fabricatio_actions/models/generic.py +0 -0
  83. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-actions/python/fabricatio_actions/py.typed +0 -0
  84. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-digest/.gitignore +0 -0
  85. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-digest/LICENSE +0 -0
  86. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-digest/README.md +0 -0
  87. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-digest/python/fabricatio_digest/__init__.py +0 -0
  88. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-digest/python/fabricatio_digest/actions/__init__.py +0 -0
  89. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-digest/python/fabricatio_digest/capabilities/__init__.py +0 -0
  90. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-digest/python/fabricatio_digest/models/__init__.py +0 -0
  91. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-digest/python/fabricatio_digest/py.typed +0 -0
  92. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-digest/python/fabricatio_digest/workflows/__init__.py +0 -0
  93. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-digest/python/tests/tests.py +0 -0
  94. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-improve/LICENSE +0 -0
  95. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-improve/README.md +0 -0
  96. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-improve/python/fabricatio_improve/__init__.py +0 -0
  97. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-improve/python/fabricatio_improve/models/problem.py +0 -0
  98. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-improve/python/fabricatio_improve/py.typed +0 -0
  99. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-judge/LICENSE +0 -0
  100. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-judge/README.md +0 -0
  101. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-judge/python/fabricatio_judge/__init__.py +0 -0
  102. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-judge/python/fabricatio_judge/models/advanced_judge.py +0 -0
  103. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-judge/python/fabricatio_judge/py.typed +0 -0
  104. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-question/.gitignore +0 -0
  105. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-question/LICENSE +0 -0
  106. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-question/README.md +0 -0
  107. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-question/python/fabricatio_question/__init__.py +0 -0
  108. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-question/python/fabricatio_question/actions/__init__.py +0 -0
  109. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-question/python/fabricatio_question/capabilities/__init__.py +0 -0
  110. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-question/python/fabricatio_question/capabilities/questioning.py +0 -0
  111. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-question/python/fabricatio_question/config.py +0 -0
  112. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-question/python/fabricatio_question/models/__init__.py +0 -0
  113. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-question/python/fabricatio_question/py.typed +0 -0
  114. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-question/python/fabricatio_question/workflows/__init__.py +0 -0
  115. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-question/python/tests/tests.py +0 -0
  116. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-rule/LICENSE +0 -0
  117. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-rule/README.md +0 -0
  118. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-rule/python/fabricatio_rule/__init__.py +0 -0
  119. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-rule/python/fabricatio_rule/actions/__init__.py +0 -0
  120. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-rule/python/fabricatio_rule/actions/rules.py +0 -0
  121. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-rule/python/fabricatio_rule/capabilities/__init__.py +0 -0
  122. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-rule/python/fabricatio_rule/models/__init__.py +0 -0
  123. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-rule/python/fabricatio_rule/models/kwargs_types.py +0 -0
  124. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-rule/python/fabricatio_rule/models/patch.py +0 -0
  125. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-rule/python/fabricatio_rule/models/rule.py +0 -0
  126. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-rule/python/fabricatio_rule/py.typed +0 -0
  127. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-tagging/.gitignore +0 -0
  128. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-tagging/LICENSE +0 -0
  129. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-tagging/README.md +0 -0
  130. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-tagging/python/fabricatio_tagging/__init__.py +0 -0
  131. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-tagging/python/fabricatio_tagging/actions/__init__.py +0 -0
  132. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-tagging/python/fabricatio_tagging/capabilities/__init__.py +0 -0
  133. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-tagging/python/fabricatio_tagging/models/__init__.py +0 -0
  134. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-tagging/python/fabricatio_tagging/py.typed +0 -0
  135. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-tagging/python/fabricatio_tagging/workflows/__init__.py +0 -0
  136. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/packages/fabricatio-tagging/python/tests/tests.py +0 -0
  137. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/python/fabricatio/__init__.py +0 -0
  138. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/python/fabricatio/actions/__init__.py +0 -0
  139. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/python/fabricatio/py.typed +0 -0
  140. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/python/fabricatio/toolboxes/__init__.py +0 -0
  141. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/python/fabricatio/toolboxes/arithmetic.py +0 -0
  142. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/python/fabricatio/toolboxes/fs.py +0 -0
  143. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/python/tests/test_minor_integration.py +0 -0
  144. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/src/lib.rs +0 -0
  145. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/subpackages.py +0 -0
  146. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/as_prompt.hbs +0 -0
  147. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/binary-exploitation-ctf-solver.hbs +0 -0
  148. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/chap_summary.hbs +0 -0
  149. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/check_string.hbs +0 -0
  150. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/claude-xml.hbs +0 -0
  151. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/clean-up-code.hbs +0 -0
  152. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/co_validation.hbs +0 -0
  153. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/create_json_obj.hbs +0 -0
  154. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/cryptography-ctf-solver.hbs +0 -0
  155. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/dependencies.hbs +0 -0
  156. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/digest.hbs +0 -0
  157. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/dispatch_task.hbs +0 -0
  158. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/document-the-code.hbs +0 -0
  159. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/draft_rating_criteria.hbs +0 -0
  160. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/draft_rating_manual.hbs +0 -0
  161. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/draft_rating_weights_klee.hbs +0 -0
  162. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/draft_tool_usage_code.hbs +0 -0
  163. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/extract.hbs +0 -0
  164. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/extract_criteria_from_reasons.hbs +0 -0
  165. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/extract_reasons_from_examples.hbs +0 -0
  166. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/find-security-vulnerabilities.hbs +0 -0
  167. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/fix-bugs.hbs +0 -0
  168. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/fix_troubled_obj.hbs +0 -0
  169. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/fix_troubled_string.hbs +0 -0
  170. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/generic_string.hbs +0 -0
  171. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/improve-performance.hbs +0 -0
  172. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/liststr.hbs +0 -0
  173. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/make_choice.hbs +0 -0
  174. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/make_judgment.hbs +0 -0
  175. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/mapping.hbs +0 -0
  176. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/pathstr.hbs +0 -0
  177. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/rate_fine_grind.hbs +0 -0
  178. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/refactor.hbs +0 -0
  179. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/refined_query.hbs +0 -0
  180. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/research_content_summary.hbs +0 -0
  181. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/retrieved_display.hbs +0 -0
  182. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/reverse-engineering-ctf-solver.hbs +0 -0
  183. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/review_string.hbs +0 -0
  184. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/rule_requirement.hbs +0 -0
  185. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/ruleset_requirement_breakdown.hbs +0 -0
  186. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/selection.hbs +0 -0
  187. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/tagging.hbs +0 -0
  188. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/task_briefing.hbs +0 -0
  189. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/web-ctf-solver.hbs +0 -0
  190. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/write-git-commit.hbs +0 -0
  191. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/write-github-pull-request.hbs +0 -0
  192. {fabricatio-0.4.4 → fabricatio-0.4.4.dev1}/templates/built-in/write-github-readme.hbs +0 -0
@@ -9,17 +9,15 @@ dirs:
9
9
  mkdir -p $(DIST) $(DATA)
10
10
 
11
11
 
12
- bins: dirs
12
+ dev:dirs
13
13
  cargo build -p fabricatio --bins -r -Z unstable-options --artifact-dir $(DATA)/scripts
14
14
  rm $(DATA)/scripts/*.pdb -f
15
15
  rm $(DATA)/scripts/*.dwarf -f
16
-
17
- dev: dirs bins
18
16
  uvx -p $(PY) --project . maturin develop --uv -r
19
17
  uv run subpackages.py --no-publish --pyversion $(PY) --dev
20
18
 
21
19
 
22
- bdist: dirs bins
20
+ bdist: dirs
23
21
 
24
22
  uvx -p $(PY) --project . maturin build --sdist -r -o $(DIST)
25
23
  uv run subpackages.py --no-publish --pyversion $(PY)
@@ -34,7 +32,6 @@ test:dev
34
32
 
35
33
  publish: bdist
36
34
  uv run subpackages.py --pyversion $(PY)
37
- uvx -p $(PY) --project . maturin publish
38
35
 
39
36
 
40
- .PHONY: dev bdist clean publish tests bins dirs all
37
+ .PHONY: dev bdist clean publish tests
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: fabricatio
3
- Version: 0.4.4
3
+ Version: 0.4.4.dev1
4
4
  Classifier: License :: OSI Approved :: MIT License
5
5
  Classifier: Programming Language :: Rust
6
6
  Classifier: Programming Language :: Python :: 3.12
@@ -50,22 +50,7 @@ Project-URL: Issues, https://github.com/Whth/fabricatio/issues
50
50
 
51
51
  # Fabricatio
52
52
 
53
- [![MIT License](https://img.shields.io/badge/license-MIT-blue.svg)](LICENSE)
54
- [![Python Versions](https://img.shields.io/pypi/pyversions/fabricatio)](https://pypi.org/project/fabricatio/)
55
- [![PyPI Version](https://img.shields.io/pypi/v/fabricatio)](https://pypi.org/project/fabricatio/)
56
- [![Ask DeepWiki](https://deepwiki.com/badge.svg)](https://deepwiki.com/Whth/fabricatio)
57
- [![PyPI Downloads](https://static.pepy.tech/badge/fabricatio/week)](https://pepy.tech/projects/fabricatio)
58
- [![PyPI Downloads](https://static.pepy.tech/badge/fabricatio)](https://pepy.tech/projects/fabricatio)
59
- [![Bindings: PyO3](https://img.shields.io/badge/bindings-pyo3-green)](https://github.com/PyO3/pyo3)
60
- [![Powered by LiteLLM](https://img.shields.io/badge/Powered%20by-LiteLLM-blue)](https://github.com/BerriAI/litellm)
61
- [![Build Tool: uv + maturin](https://img.shields.io/badge/built%20with-uv%20%2B%20maturin-orange)](https://github.com/astral-sh/uv)
62
- [![Build Package](https://github.com/Whth/fabricatio/actions/workflows/build-package.yaml/badge.svg)](https://github.com/Whth/fabricatio/actions/workflows/build-package.yaml)
63
- [![Ruff Lint](https://github.com/Whth/fabricatio/actions/workflows/ruff.yaml/badge.svg)](https://github.com/Whth/fabricatio/actions/workflows/ruff.yaml)
64
- [![Tests](https://github.com/Whth/fabricatio/actions/workflows/tests.yaml/badge.svg)](https://github.com/Whth/fabricatio/actions/workflows/tests.yaml)
65
- ![GitHub Issues](https://img.shields.io/github/issues/Whth/fabricatio)
66
- ![GitHub Pull Requests](https://img.shields.io/github/issues-pr/Whth/fabricatio)
67
- ![GitHub Stars](https://img.shields.io/github/stars/Whth/fabricatio)
68
- ---
53
+ ![MIT License](https://img.shields.io/badge/license-MIT-blue.svg)
69
54
 
70
55
  ## Overview
71
56
 
@@ -188,6 +173,10 @@ max_tokens = 8192
188
173
  make test
189
174
  ```
190
175
 
176
+ ## TODO
177
+
178
+ - Add an element based format strategy
179
+
191
180
  ## Contributing
192
181
 
193
182
  Contributions are welcome! Follow these steps:
@@ -1,21 +1,6 @@
1
1
  # Fabricatio
2
2
 
3
- [![MIT License](https://img.shields.io/badge/license-MIT-blue.svg)](LICENSE)
4
- [![Python Versions](https://img.shields.io/pypi/pyversions/fabricatio)](https://pypi.org/project/fabricatio/)
5
- [![PyPI Version](https://img.shields.io/pypi/v/fabricatio)](https://pypi.org/project/fabricatio/)
6
- [![Ask DeepWiki](https://deepwiki.com/badge.svg)](https://deepwiki.com/Whth/fabricatio)
7
- [![PyPI Downloads](https://static.pepy.tech/badge/fabricatio/week)](https://pepy.tech/projects/fabricatio)
8
- [![PyPI Downloads](https://static.pepy.tech/badge/fabricatio)](https://pepy.tech/projects/fabricatio)
9
- [![Bindings: PyO3](https://img.shields.io/badge/bindings-pyo3-green)](https://github.com/PyO3/pyo3)
10
- [![Powered by LiteLLM](https://img.shields.io/badge/Powered%20by-LiteLLM-blue)](https://github.com/BerriAI/litellm)
11
- [![Build Tool: uv + maturin](https://img.shields.io/badge/built%20with-uv%20%2B%20maturin-orange)](https://github.com/astral-sh/uv)
12
- [![Build Package](https://github.com/Whth/fabricatio/actions/workflows/build-package.yaml/badge.svg)](https://github.com/Whth/fabricatio/actions/workflows/build-package.yaml)
13
- [![Ruff Lint](https://github.com/Whth/fabricatio/actions/workflows/ruff.yaml/badge.svg)](https://github.com/Whth/fabricatio/actions/workflows/ruff.yaml)
14
- [![Tests](https://github.com/Whth/fabricatio/actions/workflows/tests.yaml/badge.svg)](https://github.com/Whth/fabricatio/actions/workflows/tests.yaml)
15
- ![GitHub Issues](https://img.shields.io/github/issues/Whth/fabricatio)
16
- ![GitHub Pull Requests](https://img.shields.io/github/issues-pr/Whth/fabricatio)
17
- ![GitHub Stars](https://img.shields.io/github/stars/Whth/fabricatio)
18
- ---
3
+ ![MIT License](https://img.shields.io/badge/license-MIT-blue.svg)
19
4
 
20
5
  ## Overview
21
6
 
@@ -138,6 +123,10 @@ max_tokens = 8192
138
123
  make test
139
124
  ```
140
125
 
126
+ ## TODO
127
+
128
+ - Add an element based format strategy
129
+
141
130
  ## Contributing
142
131
 
143
132
  Contributions are welcome! Follow these steps:
@@ -25,7 +25,7 @@ class Talk(Action, RAG):
25
25
  if user_say is None:
26
26
  break
27
27
  ref_q = ok(await self.arefined_query(user_say))
28
- logger.info(f"refined query: \n{ref_q}")
28
+ logger.info(f'refined query: \n{ref_q}')
29
29
  ret = await self.aretrieve(ref_q, document_model=ArticleChunk)
30
30
 
31
31
  sys_msg = "\n".join(r.as_prompt() for r in ret)
@@ -18,9 +18,9 @@ def _reader(path: str) -> Optional[str]:
18
18
  string = string.split("References\n")[0]
19
19
  string = string.split("参考文献\n")[0]
20
20
  if (leng := token_counter(text=string)) > MAX_TOKEN:
21
- logger.warning(f"{path} is too long, got {leng} tokens, skip.")
21
+ logger.warning(f'{path} is too long, got {leng} tokens, skip.')
22
22
  return None
23
- logger.info(f"Read {path} get {leng} tokens.")
23
+ logger.info(f'Read {path} get {leng} tokens.')
24
24
  return string
25
25
 
26
26
 
@@ -44,7 +44,7 @@ async def main() -> None:
44
44
  collection_name="article_essence_0324",
45
45
  persist_dir="output_0324",
46
46
  bib_mgr=BibManager("ref.bib"),
47
- reader=_reader,
47
+ reader=_reader
48
48
  )
49
49
  },
50
50
  )
@@ -32,9 +32,9 @@ class WhatToRate(Action):
32
32
  async def _execute(self, task_input: Task, rate_topic: str, **cxt: Unpack) -> List[str]:
33
33
  def _validate(resp: str) -> List[str] | None:
34
34
  if (
35
- (cap := JsonCapture.convert_with(resp, ujson.loads)) is not None
36
- and isinstance(cap, list)
37
- and all(isinstance(i, str) for i in cap)
35
+ (cap := JsonCapture.convert_with(resp, ujson.loads)) is not None
36
+ and isinstance(cap, list)
37
+ and all(isinstance(i, str) for i in cap)
38
38
  ):
39
39
  return cap
40
40
  return None
@@ -33,7 +33,7 @@ async def main() -> None:
33
33
  "4.to cover more references, we usually cite more than one articles that have similar opinions in a single sentence if possible.\n"
34
34
  "5.when using `#cite()` notation, you must be aware of the cite key should be wrapped by `<` and `>`, compiler wont let it pass compilation otherwise.",
35
35
  rule_count=5,
36
- output_key="en_ruleset",
36
+ output_key="en_ruleset"
37
37
  ),
38
38
  DraftRuleSet(
39
39
  ruleset_requirement="1. 当在文章中引用其他文章作为参考文献时, 应遵循`(作者1, 作者2等, 年份)#cite(<bibtex_cite_key>)`的格式进行标注。\n"
@@ -42,7 +42,7 @@ async def main() -> None:
42
42
  "4. 为增加参考文献的覆盖率, 我们通常建议在可能的情况下, 将多个观点相似的文献合并引用于同一句子中。"
43
43
  "5. 使用`#cite()`时需注意:BibTeX键必须用尖括号`<`和`>`包裹, 否则编译器将拒绝通过编译。",
44
44
  rule_count=5,
45
- output_key="zh_ruleset",
45
+ output_key="zh_ruleset"
46
46
  ),
47
47
  PersistentAll(persist_dir="persistent"),
48
48
  ),
@@ -1,12 +1,13 @@
1
1
  """Example of using BibManager."""
2
-
3
2
  from fabricatio import logger
4
3
  from fabricatio_typst.rust import BibManager
5
4
 
6
5
  b = BibManager("Exported Items.bib")
7
6
  logger.success(
8
7
  b.get_cite_key_by_title(
9
- "A Negative Selection Immune System Inspired Methodology for Fault Diagnosis of Wind Turbines"
8
+ "A Negative Selection Immune System Inspired Methodology for Fault Diagnosis of Wind Turbines"))
9
+ logger.success(
10
+ b.get_cite_key_fuzzy(
11
+ "System Inspired Methodology for Fault"
10
12
  )
11
13
  )
12
- logger.success(b.get_cite_key_fuzzy("System Inspired Methodology for Fault"))
@@ -12,12 +12,12 @@ class Connect(Action):
12
12
  """Connect the article to the outline."""
13
13
 
14
14
  async def _execute(
15
- self,
16
- article_briefing: str,
17
- article_proposal: ArticleProposal,
18
- article_outline: ArticleOutline,
19
- article: Article,
20
- **cxt,
15
+ self,
16
+ article_briefing: str,
17
+ article_proposal: ArticleProposal,
18
+ article_outline: ArticleOutline,
19
+ article: Article,
20
+ **cxt,
21
21
  ) -> None:
22
22
  article.update_ref(article_outline.update_ref(article_proposal.update_ref(article_briefing)))
23
23
 
@@ -2,7 +2,8 @@
2
2
 
3
3
  from fabricatio.models import Article
4
4
 
5
- a = Article.from_persistent(r"persistent\to_dump\Article_20250408_103051_51d822.json")
5
+ a = Article.from_persistent(
6
+ r"persistent\to_dump\Article_20250408_103051_51d822.json")
6
7
  a.convert_tex()
7
8
 
8
9
  from fabricatio_core.fs.curd import dump_text
@@ -123,7 +123,9 @@ def consult(
123
123
 
124
124
  @app.command()
125
125
  def finish(
126
- article_outline_path: Path = typer.Argument(help="Path to the article outline raw file."),
126
+ article_outline_path: Path = typer.Argument(
127
+ help="Path to the article outline raw file."
128
+ ),
127
129
  dump_path: Path = typer.Option(Path("out.typ"), "-d", "--dump-path", help="Path to dump the final output."),
128
130
  persist_dir: Path = typer.Option(
129
131
  Path("persistent"), "-p", "--persist-dir", help="Directory to persist the output."
@@ -215,8 +217,12 @@ def write(
215
217
 
216
218
  @app.command()
217
219
  def suma(
218
- article_path: Path = typer.Option(Path("article.typ"), "-a", "--article-path", help="Path to the article file."),
219
- skip_chapters: List[str] = typer.Option([], "-s", "--skip-chapters", help="Chapters to skip."),
220
+ article_path: Path = typer.Option(
221
+ Path("article.typ"), "-a", "--article-path", help="Path to the article file."
222
+ ),
223
+ skip_chapters: List[str] = typer.Option(
224
+ [], "-s", "--skip-chapters", help="Chapters to skip."
225
+ ),
220
226
  suma_title: str = typer.Option("Chapter Summary", "-t", "--suma-title", help="Title of the chapter summary."),
221
227
  summary_word_count: int = typer.Option(220, "-w", "--word-count", help="Word count for the summary."),
222
228
  ) -> None:
@@ -239,7 +245,9 @@ def suma(
239
245
 
240
246
  @app.command()
241
247
  def rcsuma(
242
- article_path: Path = typer.Option(Path("article.typ"), "-a", "--article-path", help="Path to the article file."),
248
+ article_path: Path = typer.Option(
249
+ Path("article.typ"), "-a", "--article-path", help="Path to the article file."
250
+ ),
243
251
  suma_title: str = typer.Option("Research Content", "-t", "--suma-title", help="Title of the summary."),
244
252
  summary_word_count: int = typer.Option(220, "-w", "--word-count", help="Word count for the summary."),
245
253
  paragraph_count: int = typer.Option(1, "-p", "--paragraph-count", help="Number of paragraphs for the summary."),
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "fabricatio-actions"
3
- version = "0.1.3"
3
+ version = "0.1.3-dev0"
4
4
  description = "A Python library providing foundational actions for file system operations and output management in LLM applications."
5
5
  readme = "README.md"
6
6
  license = { file = "LICENSE" }
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "fabricatio-digest"
3
- version = "0.1.2"
3
+ version = "0.1.2-dev0"
4
4
  description = "A extension for fabricatio, providing capabilities to handle raw requirment, digesting it into a task list"
5
5
  readme = "README.md"
6
6
  license = { file = "LICENSE" }
@@ -1,5 +1,4 @@
1
1
  """Module for the Digest class, which generates task lists based on requirements."""
2
-
3
2
  from abc import ABC
4
3
  from typing import List, Optional, Unpack
5
4
 
@@ -14,12 +13,9 @@ from fabricatio_digest.models.tasklist import TaskList
14
13
  class Digest(Propose, ABC):
15
14
  """A class that generates a task list based on a requirement."""
16
15
 
17
- async def digest[T: Role](
18
- self,
19
- requirement: str,
20
- receptions: List[T],
21
- **kwargs: Unpack[ValidateKwargs[Optional[TaskList]]],
22
- ) -> Optional[TaskList]:
16
+ async def digest[T:Role](self, requirement: str, receptions: List[T],
17
+ **kwargs: Unpack[ValidateKwargs[Optional[TaskList]]],
18
+ ) -> Optional[TaskList]:
23
19
  """Generate a task list based on the given requirement and receptions.
24
20
 
25
21
  This method utilizes a template to construct instructions for creating
@@ -39,7 +35,12 @@ class Digest(Propose, ABC):
39
35
  """
40
36
  # get the instruction to build the raw_task sequence
41
37
  instruct = TEMPLATE_MANAGER.render_template(
42
- digest_config.digest_template, {"requirement": requirement, "receptions": [r.briefing for r in receptions]}
38
+ digest_config.digest_template,
39
+
40
+ {"requirement": requirement,
41
+ "receptions": [r.briefing for r in receptions]
42
+ }
43
+
43
44
  )
44
45
 
45
46
  return await self.propose(TaskList, instruct, **kwargs)
@@ -1,5 +1,4 @@
1
1
  """Module containing configuration classes for fabricatio-digest."""
2
-
3
2
  from dataclasses import dataclass
4
3
 
5
4
  from fabricatio_core import CONFIG
@@ -9,9 +8,12 @@ from fabricatio_core import CONFIG
9
8
  class DigestConfig:
10
9
  """Configuration for fabricatio-digest."""
11
10
 
12
- digest_template: str = "digest"
11
+
12
+ digest_template:str="digest"
13
13
  """Template name for digest"""
14
14
 
15
15
 
16
- digest_config = CONFIG.load("digest", DigestConfig)
17
- __all__ = ["digest_config"]
16
+ digest_config = CONFIG.load("digest", DigestConfig)
17
+ __all__ = [
18
+ "digest_config"
19
+ ]
@@ -4,7 +4,6 @@ This module contains the definition of the TaskList class, which is used to mode
4
4
  of tasks aimed at achieving a specific ultimate target. It inherits from the ProposedAble
5
5
  interface and provides implementations for task sequence generation.
6
6
  """
7
-
8
7
  from typing import List
9
8
 
10
9
  from fabricatio_core import Task
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "fabricatio-improve"
3
- version = "0.1.3"
3
+ version = "0.1.3-dev1"
4
4
  description = "A Python library for content review, correction, and improvement in LLM applications."
5
5
  readme = "README.md"
6
6
  license = { file = "LICENSE" }
@@ -25,7 +25,7 @@ class Correct(Rating, Propose, ABC):
25
25
  """A class that provides the capability to correct objects."""
26
26
 
27
27
  async def decide_solution(
28
- self, problem_solutions: ProblemSolutions, **kwargs: Unpack[BestKwargs]
28
+ self, problem_solutions: ProblemSolutions, **kwargs: Unpack[BestKwargs]
29
29
  ) -> ProblemSolutions:
30
30
  """Decide the best solution from a list of problem solutions.
31
31
 
@@ -75,11 +75,11 @@ class Correct(Rating, Propose, ABC):
75
75
  return improvement
76
76
 
77
77
  async def fix_troubled_obj[M: SketchedAble](
78
- self,
79
- obj: M,
80
- problem_solutions: ProblemSolutions,
81
- reference: str = "",
82
- **kwargs: Unpack[ValidateKwargs[M]],
78
+ self,
79
+ obj: M,
80
+ problem_solutions: ProblemSolutions,
81
+ reference: str = "",
82
+ **kwargs: Unpack[ValidateKwargs[M]],
83
83
  ) -> Optional[M]:
84
84
  """Fix a troubled object based on problem solutions.
85
85
 
@@ -109,11 +109,11 @@ class Correct(Rating, Propose, ABC):
109
109
  )
110
110
 
111
111
  async def fix_troubled_string(
112
- self,
113
- input_text: str,
114
- problem_solutions: ProblemSolutions,
115
- reference: str = "",
116
- **kwargs: Unpack[ValidateKwargs[str]],
112
+ self,
113
+ input_text: str,
114
+ problem_solutions: ProblemSolutions,
115
+ reference: str = "",
116
+ **kwargs: Unpack[ValidateKwargs[str]],
117
117
  ) -> Optional[str]:
118
118
  """Fix a troubled string based on problem solutions.
119
119
 
@@ -143,11 +143,11 @@ class Correct(Rating, Propose, ABC):
143
143
  )
144
144
 
145
145
  async def correct_obj[M: SketchedAble](
146
- self,
147
- obj: M,
148
- improvement: Improvement,
149
- reference: str = "",
150
- **kwargs: Unpack[ValidateKwargs[M]],
146
+ self,
147
+ obj: M,
148
+ improvement: Improvement,
149
+ reference: str = "",
150
+ **kwargs: Unpack[ValidateKwargs[M]],
151
151
  ) -> Optional[M]:
152
152
  """Review and correct an object based on defined criteria and templates.
153
153
 
@@ -181,7 +181,7 @@ class Correct(Rating, Propose, ABC):
181
181
  return obj
182
182
 
183
183
  async def correct_string(
184
- self, input_text: str, improvement: Improvement, reference: str = "", **kwargs: Unpack[ValidateKwargs[str]]
184
+ self, input_text: str, improvement: Improvement, reference: str = "", **kwargs: Unpack[ValidateKwargs[str]]
185
185
  ) -> Optional[str]:
186
186
  """Review and correct a string based on defined criteria and templates.
187
187
 
@@ -213,7 +213,7 @@ class Correct(Rating, Propose, ABC):
213
213
  return input_text
214
214
 
215
215
  async def correct_obj_inplace[M: ProposedUpdateAble](
216
- self, obj: M, **kwargs: Unpack[CorrectKwargs[M]]
216
+ self, obj: M, **kwargs: Unpack[CorrectKwargs[M]]
217
217
  ) -> Optional[M]:
218
218
  """Correct an object in place based on defined criteria and templates.
219
219
 
@@ -42,12 +42,12 @@ class Review(Rating, Propose, ABC):
42
42
  return await self.review_obj(task, **kwargs)
43
43
 
44
44
  async def review_string(
45
- self,
46
- input_text: str,
47
- topic: str,
48
- criteria: Optional[Set[str]] = None,
49
- rating_manual: Optional[Dict[str, str]] = None,
50
- **kwargs: Unpack[ValidateKwargs[Improvement]],
45
+ self,
46
+ input_text: str,
47
+ topic: str,
48
+ criteria: Optional[Set[str]] = None,
49
+ rating_manual: Optional[Dict[str, str]] = None,
50
+ **kwargs: Unpack[ValidateKwargs[Improvement]],
51
51
  ) -> Optional[Improvement]:
52
52
  """Review a string based on specified topic and criteria.
53
53
 
@@ -86,7 +86,7 @@ class Review(Rating, Propose, ABC):
86
86
  )
87
87
 
88
88
  async def review_obj[M: (Display, WithBriefing)](
89
- self, obj: M, **kwargs: Unpack[ReviewKwargs[Improvement]]
89
+ self, obj: M, **kwargs: Unpack[ReviewKwargs[Improvement]]
90
90
  ) -> Optional[Improvement]:
91
91
  """Review an object that implements Display or WithBriefing interface.
92
92
 
@@ -1,5 +1,4 @@
1
1
  """Module containing configuration classes for fabricatio-improve."""
2
-
3
2
  from dataclasses import dataclass
4
3
 
5
4
  from fabricatio_core import CONFIG
@@ -8,7 +7,6 @@ from fabricatio_core import CONFIG
8
7
  @dataclass
9
8
  class ImproveConfig:
10
9
  """Configuration for fabricatio-improve."""
11
-
12
10
  review_string_template: str = "review_string"
13
11
  """The name of the review string template which will be used to review a string."""
14
12
 
@@ -19,5 +17,7 @@ class ImproveConfig:
19
17
  """The name of the fix troubled object template which will be used to fix a troubled object."""
20
18
 
21
19
 
22
- improve_config = CONFIG.load("improve", ImproveConfig)
23
- __all__ = ["improve_config"]
20
+ improve_config = CONFIG.load("improve", ImproveConfig)
21
+ __all__ = [
22
+ "improve_config"
23
+ ]
@@ -1,5 +1,4 @@
1
1
  """A module containing kwargs types for content correction and checking operations."""
2
-
3
2
  from itertools import chain
4
3
  from typing import List, Self, Tuple, Unpack
5
4
 
@@ -1,5 +1,4 @@
1
1
  """This module contains the types for the keyword arguments of the methods in the models module."""
2
-
3
2
  from typing import Dict, Required
4
3
 
5
4
  from fabricatio_capabilities.models.kwargs_types import ReferencedKwargs
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "fabricatio-judge"
3
- version = "0.1.3"
3
+ version = "0.1.3-dev1"
4
4
  description = "fabricatio-judge extends the Fabricatio ecosystem to provide advanced judgment capabilities for LLM-driven applications."
5
5
  readme = "README.md"
6
6
  license = { file = "LICENSE" }
@@ -12,9 +12,9 @@ class AdvancedJudge(Propose, ABC):
12
12
  """A class that judges the evidence and makes a final decision."""
13
13
 
14
14
  async def evidently_judge(
15
- self,
16
- prompt: str,
17
- **kwargs: Unpack[ValidateKwargs[JudgeMent]],
15
+ self,
16
+ prompt: str,
17
+ **kwargs: Unpack[ValidateKwargs[JudgeMent]],
18
18
  ) -> Optional[JudgeMent]:
19
19
  """Judge the evidence and make a final decision."""
20
20
  return await self.propose(JudgeMent, prompt, **kwargs)
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "fabricatio-question"
3
- version = "0.1.0"
3
+ version = "0.1.0-dev0"
4
4
  description = "An extension of fabricatio, which provide the capability to question user to make better planning and etc."
5
5
  readme = "README.md"
6
6
  license = { file = "LICENSE" }
@@ -21,7 +21,6 @@ class SelectionQuestion(SketchedAble):
21
21
  The selected option as a string.
22
22
  """
23
23
  return await questionary.select(self.q, choices=self.option).ask_async()
24
-
25
24
  async def multiple(self, k: int = 0) -> List[str]:
26
25
  """Present a multiple-choice selection question to the user.
27
26
 
@@ -33,11 +32,13 @@ class SelectionQuestion(SketchedAble):
33
32
  """
34
33
  # Use 'questionary.checkbox' with validation based on k value
35
34
  if k == 0:
36
- selected_options = await questionary.checkbox(self.q, choices=self.option).ask_async()
35
+ selected_options = await questionary.checkbox(
36
+ self.q, choices=self.option
37
+ ).ask_async()
37
38
  else:
38
39
  selected_options = await questionary.checkbox(
39
- self.q,
40
- choices=self.option,
41
- validate=lambda selections: True if len(selections) == k else f"Please select exactly {k} options.",
40
+ self.q, choices=self.option,
41
+ validate=lambda selections: True if len(selections) == k
42
+ else f"Please select exactly {k} options."
42
43
  ).ask_async()
43
44
  return selected_options
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "fabricatio-rule"
3
- version = "0.1.4"
3
+ version = "0.1.4-dev1"
4
4
  description = "A Python module for rule-based content validation, correction, and enforcement in LLM applications."
5
5
  license = { file = "LICENSE" }
6
6
  authors = [
@@ -28,7 +28,7 @@ class Censor(Correct, Check, ABC):
28
28
  """
29
29
 
30
30
  async def censor_obj[M: SketchedAble](
31
- self, obj: M, ruleset: RuleSet, **kwargs: Unpack[ReferencedKwargs[M]]
31
+ self, obj: M, ruleset: RuleSet, **kwargs: Unpack[ReferencedKwargs[M]]
32
32
  ) -> Optional[M]:
33
33
  """Censors an object based on the provided ruleset.
34
34
 
@@ -53,7 +53,7 @@ class Censor(Correct, Check, ABC):
53
53
  return await self.correct_obj(obj, Improvement.gather(*imp), **kwargs)
54
54
 
55
55
  async def censor_string(
56
- self, input_text: str, ruleset: RuleSet, **kwargs: Unpack[ReferencedKwargs[str]]
56
+ self, input_text: str, ruleset: RuleSet, **kwargs: Unpack[ReferencedKwargs[str]]
57
57
  ) -> Optional[str]:
58
58
  """Censors a string based on the provided ruleset.
59
59
 
@@ -79,7 +79,7 @@ class Censor(Correct, Check, ABC):
79
79
  return await self.correct_string(input_text, Improvement.gather(*imp), **kwargs)
80
80
 
81
81
  async def censor_obj_inplace[M: ProposedUpdateAble](
82
- self, obj: M, ruleset: RuleSet, **kwargs: Unpack[ReferencedKwargs[M]]
82
+ self, obj: M, ruleset: RuleSet, **kwargs: Unpack[ReferencedKwargs[M]]
83
83
  ) -> Optional[M]:
84
84
  """Censors an object in-place based on the provided ruleset.
85
85