@duckmind/deepquark-darwin-arm64 0.9.78 → 0.9.81

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 (240) hide show
  1. package/.deepquark/skills/bundled/data-storytelling/SKILL.md +453 -0
  2. package/.deepquark/skills/bundled/docx/LICENSE.txt +30 -0
  3. package/.deepquark/skills/bundled/docx/SKILL.md +481 -0
  4. package/.deepquark/skills/bundled/docx/scripts/__init__.py +1 -0
  5. package/.deepquark/skills/bundled/docx/scripts/accept_changes.py +135 -0
  6. package/.deepquark/skills/bundled/docx/scripts/comment.py +318 -0
  7. package/.deepquark/skills/bundled/docx/scripts/office/helpers/__init__.py +0 -0
  8. package/.deepquark/skills/bundled/docx/scripts/office/helpers/merge_runs.py +199 -0
  9. package/.deepquark/skills/bundled/docx/scripts/office/helpers/simplify_redlines.py +197 -0
  10. package/.deepquark/skills/bundled/docx/scripts/office/pack.py +159 -0
  11. package/.deepquark/skills/bundled/docx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-chart.xsd +1499 -0
  12. package/.deepquark/skills/bundled/docx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-chartDrawing.xsd +146 -0
  13. package/.deepquark/skills/bundled/docx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-diagram.xsd +1085 -0
  14. package/.deepquark/skills/bundled/docx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-lockedCanvas.xsd +11 -0
  15. package/.deepquark/skills/bundled/docx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-main.xsd +3081 -0
  16. package/.deepquark/skills/bundled/docx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-picture.xsd +23 -0
  17. package/.deepquark/skills/bundled/docx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-spreadsheetDrawing.xsd +185 -0
  18. package/.deepquark/skills/bundled/docx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-wordprocessingDrawing.xsd +287 -0
  19. package/.deepquark/skills/bundled/docx/scripts/office/schemas/ISO-IEC29500-4_2016/pml.xsd +1676 -0
  20. package/.deepquark/skills/bundled/docx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-additionalCharacteristics.xsd +28 -0
  21. package/.deepquark/skills/bundled/docx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-bibliography.xsd +144 -0
  22. package/.deepquark/skills/bundled/docx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-commonSimpleTypes.xsd +174 -0
  23. package/.deepquark/skills/bundled/docx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-customXmlDataProperties.xsd +25 -0
  24. package/.deepquark/skills/bundled/docx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-customXmlSchemaProperties.xsd +18 -0
  25. package/.deepquark/skills/bundled/docx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-documentPropertiesCustom.xsd +59 -0
  26. package/.deepquark/skills/bundled/docx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-documentPropertiesExtended.xsd +56 -0
  27. package/.deepquark/skills/bundled/docx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-documentPropertiesVariantTypes.xsd +195 -0
  28. package/.deepquark/skills/bundled/docx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-math.xsd +582 -0
  29. package/.deepquark/skills/bundled/docx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-relationshipReference.xsd +25 -0
  30. package/.deepquark/skills/bundled/docx/scripts/office/schemas/ISO-IEC29500-4_2016/sml.xsd +4439 -0
  31. package/.deepquark/skills/bundled/docx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-main.xsd +570 -0
  32. package/.deepquark/skills/bundled/docx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-officeDrawing.xsd +509 -0
  33. package/.deepquark/skills/bundled/docx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-presentationDrawing.xsd +12 -0
  34. package/.deepquark/skills/bundled/docx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-spreadsheetDrawing.xsd +108 -0
  35. package/.deepquark/skills/bundled/docx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-wordprocessingDrawing.xsd +96 -0
  36. package/.deepquark/skills/bundled/docx/scripts/office/schemas/ISO-IEC29500-4_2016/wml.xsd +3646 -0
  37. package/.deepquark/skills/bundled/docx/scripts/office/schemas/ISO-IEC29500-4_2016/xml.xsd +116 -0
  38. package/.deepquark/skills/bundled/docx/scripts/office/schemas/ecma/fouth-edition/opc-contentTypes.xsd +42 -0
  39. package/.deepquark/skills/bundled/docx/scripts/office/schemas/ecma/fouth-edition/opc-coreProperties.xsd +50 -0
  40. package/.deepquark/skills/bundled/docx/scripts/office/schemas/ecma/fouth-edition/opc-digSig.xsd +49 -0
  41. package/.deepquark/skills/bundled/docx/scripts/office/schemas/ecma/fouth-edition/opc-relationships.xsd +33 -0
  42. package/.deepquark/skills/bundled/docx/scripts/office/schemas/mce/mc.xsd +75 -0
  43. package/.deepquark/skills/bundled/docx/scripts/office/schemas/microsoft/wml-2010.xsd +560 -0
  44. package/.deepquark/skills/bundled/docx/scripts/office/schemas/microsoft/wml-2012.xsd +67 -0
  45. package/.deepquark/skills/bundled/docx/scripts/office/schemas/microsoft/wml-2018.xsd +14 -0
  46. package/.deepquark/skills/bundled/docx/scripts/office/schemas/microsoft/wml-cex-2018.xsd +20 -0
  47. package/.deepquark/skills/bundled/docx/scripts/office/schemas/microsoft/wml-cid-2016.xsd +13 -0
  48. package/.deepquark/skills/bundled/docx/scripts/office/schemas/microsoft/wml-sdtdatahash-2020.xsd +4 -0
  49. package/.deepquark/skills/bundled/docx/scripts/office/schemas/microsoft/wml-symex-2015.xsd +8 -0
  50. package/.deepquark/skills/bundled/docx/scripts/office/soffice.py +183 -0
  51. package/.deepquark/skills/bundled/docx/scripts/office/unpack.py +132 -0
  52. package/.deepquark/skills/bundled/docx/scripts/office/validate.py +111 -0
  53. package/.deepquark/skills/bundled/docx/scripts/office/validators/__init__.py +15 -0
  54. package/.deepquark/skills/bundled/docx/scripts/office/validators/base.py +847 -0
  55. package/.deepquark/skills/bundled/docx/scripts/office/validators/docx.py +446 -0
  56. package/.deepquark/skills/bundled/docx/scripts/office/validators/pptx.py +275 -0
  57. package/.deepquark/skills/bundled/docx/scripts/office/validators/redlining.py +247 -0
  58. package/.deepquark/skills/bundled/docx/scripts/templates/comments.xml +3 -0
  59. package/.deepquark/skills/bundled/docx/scripts/templates/commentsExtended.xml +3 -0
  60. package/.deepquark/skills/bundled/docx/scripts/templates/commentsExtensible.xml +3 -0
  61. package/.deepquark/skills/bundled/docx/scripts/templates/commentsIds.xml +3 -0
  62. package/.deepquark/skills/bundled/docx/scripts/templates/people.xml +3 -0
  63. package/.deepquark/skills/bundled/drawio-architect/SKILL.md +300 -0
  64. package/.deepquark/skills/bundled/drawio-architect/references/architecture-patterns.md +236 -0
  65. package/.deepquark/skills/bundled/drawio-architect/references/branding.md +180 -0
  66. package/.deepquark/skills/bundled/drawio-architect/references/cloud-icons.md +493 -0
  67. package/.deepquark/skills/bundled/drawio-architect/references/style-guide.md +268 -0
  68. package/.deepquark/skills/bundled/duckmind-deep-research/ARCHITECTURE_REVIEW.md +495 -0
  69. package/.deepquark/skills/bundled/duckmind-deep-research/AUTONOMY_VERIFICATION.md +420 -0
  70. package/.deepquark/skills/bundled/duckmind-deep-research/COMPETITIVE_ANALYSIS.md +179 -0
  71. package/.deepquark/skills/bundled/duckmind-deep-research/CONTEXT_OPTIMIZATION.md +293 -0
  72. package/.deepquark/skills/bundled/duckmind-deep-research/QUICK_START.md +167 -0
  73. package/.deepquark/skills/bundled/duckmind-deep-research/README.md +259 -0
  74. package/.deepquark/skills/bundled/duckmind-deep-research/SKILL.md +754 -0
  75. package/.deepquark/skills/bundled/duckmind-deep-research/WORD_PRECISION_AUDIT.md +476 -0
  76. package/.deepquark/skills/bundled/duckmind-deep-research/reference/methodology.md +384 -0
  77. package/.deepquark/skills/bundled/duckmind-deep-research/requirements.txt +10 -0
  78. package/.deepquark/skills/bundled/duckmind-deep-research/scripts/citation_manager.py +177 -0
  79. package/.deepquark/skills/bundled/duckmind-deep-research/scripts/md_to_html.py +330 -0
  80. package/.deepquark/skills/bundled/duckmind-deep-research/scripts/research_engine.py +578 -0
  81. package/.deepquark/skills/bundled/duckmind-deep-research/scripts/source_evaluator.py +292 -0
  82. package/.deepquark/skills/bundled/duckmind-deep-research/scripts/validate_report.py +354 -0
  83. package/.deepquark/skills/bundled/duckmind-deep-research/scripts/verify_citations.py +430 -0
  84. package/.deepquark/skills/bundled/duckmind-deep-research/scripts/verify_html.py +220 -0
  85. package/.deepquark/skills/bundled/duckmind-deep-research/templates/mckinsey_report_template.html +443 -0
  86. package/.deepquark/skills/bundled/duckmind-deep-research/templates/report_template.md +414 -0
  87. package/.deepquark/skills/bundled/duckmind-deep-research/tests/fixtures/invalid_report.md +27 -0
  88. package/.deepquark/skills/bundled/duckmind-deep-research/tests/fixtures/valid_report.md +114 -0
  89. package/.deepquark/skills/bundled/duckmind-multimodal/SKILL.md +171 -0
  90. package/.deepquark/skills/bundled/duckmind-multimodal/references/image-generation.md +131 -0
  91. package/.deepquark/skills/bundled/duckmind-multimodal/references/pdf-processing.md +120 -0
  92. package/.deepquark/skills/bundled/duckmind-transcribe/SKILL.md +70 -0
  93. package/.deepquark/skills/bundled/duckmind-transcribe/scripts/transcribe.sh +134 -0
  94. package/.deepquark/skills/bundled/excel-analysis/SKILL.md +247 -0
  95. package/.deepquark/skills/bundled/ge-payroll/SKILL.md +153 -0
  96. package/.deepquark/skills/bundled/ge-payroll/evals/evals.json +23 -0
  97. package/.deepquark/skills/bundled/ge-payroll/references/pain-points-improvements.md +106 -0
  98. package/.deepquark/skills/bundled/ge-payroll/references/process-detail.md +217 -0
  99. package/.deepquark/skills/bundled/ge-payroll/references/raci-stakeholders.md +85 -0
  100. package/.deepquark/skills/bundled/ge-payroll/references/timeline-mandays.md +64 -0
  101. package/.deepquark/skills/bundled/pdf/LICENSE.txt +30 -0
  102. package/.deepquark/skills/bundled/pdf/SKILL.md +314 -0
  103. package/.deepquark/skills/bundled/pdf/forms.md +294 -0
  104. package/.deepquark/skills/bundled/pdf/reference.md +612 -0
  105. package/.deepquark/skills/bundled/pdf/scripts/check_bounding_boxes.py +65 -0
  106. package/.deepquark/skills/bundled/pdf/scripts/check_fillable_fields.py +11 -0
  107. package/.deepquark/skills/bundled/pdf/scripts/convert_pdf_to_images.py +33 -0
  108. package/.deepquark/skills/bundled/pdf/scripts/create_validation_image.py +37 -0
  109. package/.deepquark/skills/bundled/pdf/scripts/extract_form_field_info.py +122 -0
  110. package/.deepquark/skills/bundled/pdf/scripts/extract_form_structure.py +115 -0
  111. package/.deepquark/skills/bundled/pdf/scripts/fill_fillable_fields.py +98 -0
  112. package/.deepquark/skills/bundled/pdf/scripts/fill_pdf_form_with_annotations.py +107 -0
  113. package/.deepquark/skills/bundled/perplexity-search/SKILL.md +447 -0
  114. package/.deepquark/skills/bundled/perplexity-search/assets/.env.example +16 -0
  115. package/.deepquark/skills/bundled/perplexity-search/references/model_comparison.md +386 -0
  116. package/.deepquark/skills/bundled/perplexity-search/references/openrouter_setup.md +454 -0
  117. package/.deepquark/skills/bundled/perplexity-search/references/search_strategies.md +258 -0
  118. package/.deepquark/skills/bundled/perplexity-search/scripts/perplexity_search.py +277 -0
  119. package/.deepquark/skills/bundled/perplexity-search/scripts/setup_env.py +171 -0
  120. package/.deepquark/skills/bundled/pptx/LICENSE.txt +30 -0
  121. package/.deepquark/skills/bundled/pptx/SKILL.md +232 -0
  122. package/.deepquark/skills/bundled/pptx/editing.md +205 -0
  123. package/.deepquark/skills/bundled/pptx/pptxgenjs.md +420 -0
  124. package/.deepquark/skills/bundled/pptx/scripts/__init__.py +0 -0
  125. package/.deepquark/skills/bundled/pptx/scripts/add_slide.py +195 -0
  126. package/.deepquark/skills/bundled/pptx/scripts/clean.py +286 -0
  127. package/.deepquark/skills/bundled/pptx/scripts/office/helpers/__init__.py +0 -0
  128. package/.deepquark/skills/bundled/pptx/scripts/office/helpers/merge_runs.py +199 -0
  129. package/.deepquark/skills/bundled/pptx/scripts/office/helpers/simplify_redlines.py +197 -0
  130. package/.deepquark/skills/bundled/pptx/scripts/office/pack.py +159 -0
  131. package/.deepquark/skills/bundled/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-chart.xsd +1499 -0
  132. package/.deepquark/skills/bundled/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-chartDrawing.xsd +146 -0
  133. package/.deepquark/skills/bundled/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-diagram.xsd +1085 -0
  134. package/.deepquark/skills/bundled/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-lockedCanvas.xsd +11 -0
  135. package/.deepquark/skills/bundled/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-main.xsd +3081 -0
  136. package/.deepquark/skills/bundled/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-picture.xsd +23 -0
  137. package/.deepquark/skills/bundled/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-spreadsheetDrawing.xsd +185 -0
  138. package/.deepquark/skills/bundled/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-wordprocessingDrawing.xsd +287 -0
  139. package/.deepquark/skills/bundled/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/pml.xsd +1676 -0
  140. package/.deepquark/skills/bundled/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-additionalCharacteristics.xsd +28 -0
  141. package/.deepquark/skills/bundled/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-bibliography.xsd +144 -0
  142. package/.deepquark/skills/bundled/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-commonSimpleTypes.xsd +174 -0
  143. package/.deepquark/skills/bundled/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-customXmlDataProperties.xsd +25 -0
  144. package/.deepquark/skills/bundled/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-customXmlSchemaProperties.xsd +18 -0
  145. package/.deepquark/skills/bundled/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-documentPropertiesCustom.xsd +59 -0
  146. package/.deepquark/skills/bundled/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-documentPropertiesExtended.xsd +56 -0
  147. package/.deepquark/skills/bundled/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-documentPropertiesVariantTypes.xsd +195 -0
  148. package/.deepquark/skills/bundled/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-math.xsd +582 -0
  149. package/.deepquark/skills/bundled/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-relationshipReference.xsd +25 -0
  150. package/.deepquark/skills/bundled/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/sml.xsd +4439 -0
  151. package/.deepquark/skills/bundled/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-main.xsd +570 -0
  152. package/.deepquark/skills/bundled/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-officeDrawing.xsd +509 -0
  153. package/.deepquark/skills/bundled/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-presentationDrawing.xsd +12 -0
  154. package/.deepquark/skills/bundled/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-spreadsheetDrawing.xsd +108 -0
  155. package/.deepquark/skills/bundled/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-wordprocessingDrawing.xsd +96 -0
  156. package/.deepquark/skills/bundled/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/wml.xsd +3646 -0
  157. package/.deepquark/skills/bundled/pptx/scripts/office/schemas/ISO-IEC29500-4_2016/xml.xsd +116 -0
  158. package/.deepquark/skills/bundled/pptx/scripts/office/schemas/ecma/fouth-edition/opc-contentTypes.xsd +42 -0
  159. package/.deepquark/skills/bundled/pptx/scripts/office/schemas/ecma/fouth-edition/opc-coreProperties.xsd +50 -0
  160. package/.deepquark/skills/bundled/pptx/scripts/office/schemas/ecma/fouth-edition/opc-digSig.xsd +49 -0
  161. package/.deepquark/skills/bundled/pptx/scripts/office/schemas/ecma/fouth-edition/opc-relationships.xsd +33 -0
  162. package/.deepquark/skills/bundled/pptx/scripts/office/schemas/mce/mc.xsd +75 -0
  163. package/.deepquark/skills/bundled/pptx/scripts/office/schemas/microsoft/wml-2010.xsd +560 -0
  164. package/.deepquark/skills/bundled/pptx/scripts/office/schemas/microsoft/wml-2012.xsd +67 -0
  165. package/.deepquark/skills/bundled/pptx/scripts/office/schemas/microsoft/wml-2018.xsd +14 -0
  166. package/.deepquark/skills/bundled/pptx/scripts/office/schemas/microsoft/wml-cex-2018.xsd +20 -0
  167. package/.deepquark/skills/bundled/pptx/scripts/office/schemas/microsoft/wml-cid-2016.xsd +13 -0
  168. package/.deepquark/skills/bundled/pptx/scripts/office/schemas/microsoft/wml-sdtdatahash-2020.xsd +4 -0
  169. package/.deepquark/skills/bundled/pptx/scripts/office/schemas/microsoft/wml-symex-2015.xsd +8 -0
  170. package/.deepquark/skills/bundled/pptx/scripts/office/soffice.py +183 -0
  171. package/.deepquark/skills/bundled/pptx/scripts/office/unpack.py +132 -0
  172. package/.deepquark/skills/bundled/pptx/scripts/office/validate.py +111 -0
  173. package/.deepquark/skills/bundled/pptx/scripts/office/validators/__init__.py +15 -0
  174. package/.deepquark/skills/bundled/pptx/scripts/office/validators/base.py +847 -0
  175. package/.deepquark/skills/bundled/pptx/scripts/office/validators/docx.py +446 -0
  176. package/.deepquark/skills/bundled/pptx/scripts/office/validators/pptx.py +275 -0
  177. package/.deepquark/skills/bundled/pptx/scripts/office/validators/redlining.py +247 -0
  178. package/.deepquark/skills/bundled/pptx/scripts/thumbnail.py +289 -0
  179. package/.deepquark/skills/bundled/text-to-pdf-automation/SKILL.md +91 -0
  180. package/.deepquark/skills/bundled/web-fetch/SKILL.md +56 -0
  181. package/.deepquark/skills/bundled/web-fetch/scripts/fetch.sh +54 -0
  182. package/.deepquark/skills/bundled/xlsx/LICENSE.txt +30 -0
  183. package/.deepquark/skills/bundled/xlsx/SKILL.md +292 -0
  184. package/.deepquark/skills/bundled/xlsx/scripts/office/helpers/__init__.py +0 -0
  185. package/.deepquark/skills/bundled/xlsx/scripts/office/helpers/merge_runs.py +199 -0
  186. package/.deepquark/skills/bundled/xlsx/scripts/office/helpers/simplify_redlines.py +197 -0
  187. package/.deepquark/skills/bundled/xlsx/scripts/office/pack.py +159 -0
  188. package/.deepquark/skills/bundled/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-chart.xsd +1499 -0
  189. package/.deepquark/skills/bundled/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-chartDrawing.xsd +146 -0
  190. package/.deepquark/skills/bundled/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-diagram.xsd +1085 -0
  191. package/.deepquark/skills/bundled/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-lockedCanvas.xsd +11 -0
  192. package/.deepquark/skills/bundled/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-main.xsd +3081 -0
  193. package/.deepquark/skills/bundled/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-picture.xsd +23 -0
  194. package/.deepquark/skills/bundled/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-spreadsheetDrawing.xsd +185 -0
  195. package/.deepquark/skills/bundled/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/dml-wordprocessingDrawing.xsd +287 -0
  196. package/.deepquark/skills/bundled/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/pml.xsd +1676 -0
  197. package/.deepquark/skills/bundled/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-additionalCharacteristics.xsd +28 -0
  198. package/.deepquark/skills/bundled/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-bibliography.xsd +144 -0
  199. package/.deepquark/skills/bundled/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-commonSimpleTypes.xsd +174 -0
  200. package/.deepquark/skills/bundled/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-customXmlDataProperties.xsd +25 -0
  201. package/.deepquark/skills/bundled/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-customXmlSchemaProperties.xsd +18 -0
  202. package/.deepquark/skills/bundled/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-documentPropertiesCustom.xsd +59 -0
  203. package/.deepquark/skills/bundled/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-documentPropertiesExtended.xsd +56 -0
  204. package/.deepquark/skills/bundled/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-documentPropertiesVariantTypes.xsd +195 -0
  205. package/.deepquark/skills/bundled/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-math.xsd +582 -0
  206. package/.deepquark/skills/bundled/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/shared-relationshipReference.xsd +25 -0
  207. package/.deepquark/skills/bundled/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/sml.xsd +4439 -0
  208. package/.deepquark/skills/bundled/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-main.xsd +570 -0
  209. package/.deepquark/skills/bundled/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-officeDrawing.xsd +509 -0
  210. package/.deepquark/skills/bundled/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-presentationDrawing.xsd +12 -0
  211. package/.deepquark/skills/bundled/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-spreadsheetDrawing.xsd +108 -0
  212. package/.deepquark/skills/bundled/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/vml-wordprocessingDrawing.xsd +96 -0
  213. package/.deepquark/skills/bundled/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/wml.xsd +3646 -0
  214. package/.deepquark/skills/bundled/xlsx/scripts/office/schemas/ISO-IEC29500-4_2016/xml.xsd +116 -0
  215. package/.deepquark/skills/bundled/xlsx/scripts/office/schemas/ecma/fouth-edition/opc-contentTypes.xsd +42 -0
  216. package/.deepquark/skills/bundled/xlsx/scripts/office/schemas/ecma/fouth-edition/opc-coreProperties.xsd +50 -0
  217. package/.deepquark/skills/bundled/xlsx/scripts/office/schemas/ecma/fouth-edition/opc-digSig.xsd +49 -0
  218. package/.deepquark/skills/bundled/xlsx/scripts/office/schemas/ecma/fouth-edition/opc-relationships.xsd +33 -0
  219. package/.deepquark/skills/bundled/xlsx/scripts/office/schemas/mce/mc.xsd +75 -0
  220. package/.deepquark/skills/bundled/xlsx/scripts/office/schemas/microsoft/wml-2010.xsd +560 -0
  221. package/.deepquark/skills/bundled/xlsx/scripts/office/schemas/microsoft/wml-2012.xsd +67 -0
  222. package/.deepquark/skills/bundled/xlsx/scripts/office/schemas/microsoft/wml-2018.xsd +14 -0
  223. package/.deepquark/skills/bundled/xlsx/scripts/office/schemas/microsoft/wml-cex-2018.xsd +20 -0
  224. package/.deepquark/skills/bundled/xlsx/scripts/office/schemas/microsoft/wml-cid-2016.xsd +13 -0
  225. package/.deepquark/skills/bundled/xlsx/scripts/office/schemas/microsoft/wml-sdtdatahash-2020.xsd +4 -0
  226. package/.deepquark/skills/bundled/xlsx/scripts/office/schemas/microsoft/wml-symex-2015.xsd +8 -0
  227. package/.deepquark/skills/bundled/xlsx/scripts/office/soffice.py +183 -0
  228. package/.deepquark/skills/bundled/xlsx/scripts/office/unpack.py +132 -0
  229. package/.deepquark/skills/bundled/xlsx/scripts/office/validate.py +111 -0
  230. package/.deepquark/skills/bundled/xlsx/scripts/office/validators/__init__.py +15 -0
  231. package/.deepquark/skills/bundled/xlsx/scripts/office/validators/base.py +847 -0
  232. package/.deepquark/skills/bundled/xlsx/scripts/office/validators/docx.py +446 -0
  233. package/.deepquark/skills/bundled/xlsx/scripts/office/validators/pptx.py +275 -0
  234. package/.deepquark/skills/bundled/xlsx/scripts/office/validators/redlining.py +247 -0
  235. package/.deepquark/skills/bundled/xlsx/scripts/recalc.py +184 -0
  236. package/.deepquark/skills/bundled/youtube-downloader/SKILL.md +99 -0
  237. package/.deepquark/skills/bundled/youtube-downloader/scripts/download_video.py +145 -0
  238. package/.deepquark/skills/bundled/youtube-transcribe-skill/SKILL.md +116 -0
  239. package/bin/deepquark +0 -0
  240. package/package.json +4 -3
@@ -0,0 +1,292 @@
1
+ #!/usr/bin/env python3
2
+ """
3
+ Source Credibility Evaluator
4
+ Assesses source quality, credibility, and potential biases
5
+ """
6
+
7
+ from dataclasses import dataclass
8
+ from typing import List, Dict, Optional
9
+ from urllib.parse import urlparse
10
+ from datetime import datetime, timedelta
11
+ import re
12
+
13
+
14
+ @dataclass
15
+ class CredibilityScore:
16
+ """Represents source credibility assessment"""
17
+ overall_score: float # 0-100
18
+ domain_authority: float # 0-100
19
+ recency: float # 0-100
20
+ expertise: float # 0-100
21
+ bias_score: float # 0-100 (higher = more neutral)
22
+ factors: Dict[str, str]
23
+ recommendation: str # "high_trust", "moderate_trust", "low_trust", "verify"
24
+
25
+
26
+ class SourceEvaluator:
27
+ """Evaluates source credibility and quality"""
28
+
29
+ # Domain reputation tiers
30
+ HIGH_AUTHORITY_DOMAINS = {
31
+ # Academic & Research
32
+ 'arxiv.org', 'nature.com', 'science.org', 'cell.com', 'nejm.org',
33
+ 'thelancet.com', 'springer.com', 'sciencedirect.com', 'plos.org',
34
+ 'ieee.org', 'acm.org', 'pubmed.ncbi.nlm.nih.gov',
35
+
36
+ # Government & International Organizations
37
+ 'nih.gov', 'cdc.gov', 'who.int', 'fda.gov', 'nasa.gov',
38
+ 'gov.uk', 'europa.eu', 'un.org',
39
+
40
+ # Established Tech Documentation
41
+ 'docs.python.org', 'developer.mozilla.org', 'docs.microsoft.com',
42
+ 'cloud.google.com', 'aws.amazon.com', 'kubernetes.io',
43
+
44
+ # Reputable News (Fact-check verified)
45
+ 'reuters.com', 'apnews.com', 'bbc.com', 'economist.com',
46
+ 'nature.com/news', 'scientificamerican.com'
47
+ }
48
+
49
+ MODERATE_AUTHORITY_DOMAINS = {
50
+ # Tech News & Analysis
51
+ 'techcrunch.com', 'theverge.com', 'arstechnica.com', 'wired.com',
52
+ 'zdnet.com', 'cnet.com',
53
+
54
+ # Industry Publications
55
+ 'forbes.com', 'bloomberg.com', 'wsj.com', 'ft.com',
56
+
57
+ # Educational
58
+ 'wikipedia.org', 'britannica.com', 'khanacademy.org',
59
+
60
+ # Tech Blogs (established)
61
+ 'medium.com', 'dev.to', 'stackoverflow.com', 'github.com'
62
+ }
63
+
64
+ LOW_AUTHORITY_INDICATORS = [
65
+ 'blogspot.com', 'wordpress.com', 'wix.com', 'substack.com'
66
+ ]
67
+
68
+ def __init__(self):
69
+ pass
70
+
71
+ def evaluate_source(
72
+ self,
73
+ url: str,
74
+ title: str,
75
+ content: Optional[str] = None,
76
+ publication_date: Optional[str] = None,
77
+ author: Optional[str] = None
78
+ ) -> CredibilityScore:
79
+ """Evaluate source credibility"""
80
+
81
+ domain = self._extract_domain(url)
82
+
83
+ # Calculate component scores
84
+ domain_score = self._evaluate_domain_authority(domain)
85
+ recency_score = self._evaluate_recency(publication_date)
86
+ expertise_score = self._evaluate_expertise(domain, title, author)
87
+ bias_score = self._evaluate_bias(domain, title, content)
88
+
89
+ # Calculate overall score (weighted average)
90
+ overall = (
91
+ domain_score * 0.35 +
92
+ recency_score * 0.20 +
93
+ expertise_score * 0.25 +
94
+ bias_score * 0.20
95
+ )
96
+
97
+ # Determine factors
98
+ factors = self._identify_factors(
99
+ domain, domain_score, recency_score, expertise_score, bias_score
100
+ )
101
+
102
+ # Generate recommendation
103
+ recommendation = self._generate_recommendation(overall)
104
+
105
+ return CredibilityScore(
106
+ overall_score=round(overall, 2),
107
+ domain_authority=round(domain_score, 2),
108
+ recency=round(recency_score, 2),
109
+ expertise=round(expertise_score, 2),
110
+ bias_score=round(bias_score, 2),
111
+ factors=factors,
112
+ recommendation=recommendation
113
+ )
114
+
115
+ def _extract_domain(self, url: str) -> str:
116
+ """Extract domain from URL"""
117
+ parsed = urlparse(url)
118
+ domain = parsed.netloc.lower()
119
+ # Remove www prefix
120
+ domain = domain.replace('www.', '')
121
+ return domain
122
+
123
+ def _evaluate_domain_authority(self, domain: str) -> float:
124
+ """Evaluate domain authority (0-100)"""
125
+ if domain in self.HIGH_AUTHORITY_DOMAINS:
126
+ return 90.0
127
+ elif domain in self.MODERATE_AUTHORITY_DOMAINS:
128
+ return 70.0
129
+ elif any(indicator in domain for indicator in self.LOW_AUTHORITY_INDICATORS):
130
+ return 40.0
131
+ else:
132
+ # Unknown domain - moderate skepticism
133
+ return 55.0
134
+
135
+ def _evaluate_recency(self, publication_date: Optional[str]) -> float:
136
+ """Evaluate information recency (0-100)"""
137
+ if not publication_date:
138
+ return 50.0 # Unknown date
139
+
140
+ try:
141
+ pub_date = datetime.fromisoformat(publication_date.replace('Z', '+00:00'))
142
+ age = datetime.now() - pub_date
143
+
144
+ # Recency scoring
145
+ if age < timedelta(days=90): # < 3 months
146
+ return 100.0
147
+ elif age < timedelta(days=365): # < 1 year
148
+ return 85.0
149
+ elif age < timedelta(days=730): # < 2 years
150
+ return 70.0
151
+ elif age < timedelta(days=1825): # < 5 years
152
+ return 50.0
153
+ else:
154
+ return 30.0
155
+
156
+ except Exception:
157
+ return 50.0
158
+
159
+ def _evaluate_expertise(
160
+ self,
161
+ domain: str,
162
+ title: str,
163
+ author: Optional[str]
164
+ ) -> float:
165
+ """Evaluate source expertise (0-100)"""
166
+ score = 50.0
167
+
168
+ # Academic/research domains get high expertise
169
+ if any(d in domain for d in ['arxiv', 'nature', 'science', 'ieee', 'acm']):
170
+ score += 30
171
+
172
+ # Government/official sources
173
+ if '.gov' in domain or 'who.int' in domain:
174
+ score += 25
175
+
176
+ # Technical documentation
177
+ if 'docs.' in domain or 'documentation' in title.lower():
178
+ score += 20
179
+
180
+ # Author credentials (if available)
181
+ if author:
182
+ if any(title in author.lower() for title in ['dr.', 'phd', 'professor']):
183
+ score += 15
184
+
185
+ return min(score, 100.0)
186
+
187
+ def _evaluate_bias(
188
+ self,
189
+ domain: str,
190
+ title: str,
191
+ content: Optional[str]
192
+ ) -> float:
193
+ """Evaluate potential bias (0-100, higher = more neutral)"""
194
+ score = 70.0 # Start neutral
195
+
196
+ # Check for sensationalism in title
197
+ sensational_indicators = [
198
+ '!', 'shocking', 'unbelievable', 'you won\'t believe',
199
+ 'secret', 'they don\'t want you to know'
200
+ ]
201
+ title_lower = title.lower()
202
+ if any(indicator in title_lower for indicator in sensational_indicators):
203
+ score -= 20
204
+
205
+ # Academic sources are typically less biased
206
+ if any(d in domain for d in ['arxiv', 'nature', 'science', 'ieee']):
207
+ score += 20
208
+
209
+ # Check for balance in content (if available)
210
+ if content:
211
+ # Look for balanced language
212
+ balanced_indicators = ['however', 'although', 'on the other hand', 'critics argue']
213
+ if any(indicator in content.lower() for indicator in balanced_indicators):
214
+ score += 10
215
+
216
+ return min(max(score, 0), 100.0)
217
+
218
+ def _identify_factors(
219
+ self,
220
+ domain: str,
221
+ domain_score: float,
222
+ recency_score: float,
223
+ expertise_score: float,
224
+ bias_score: float
225
+ ) -> Dict[str, str]:
226
+ """Identify key credibility factors"""
227
+ factors = {}
228
+
229
+ if domain_score >= 85:
230
+ factors['domain'] = "High authority domain"
231
+ elif domain_score <= 45:
232
+ factors['domain'] = "Low authority domain - verify claims"
233
+
234
+ if recency_score >= 85:
235
+ factors['recency'] = "Recent information"
236
+ elif recency_score <= 40:
237
+ factors['recency'] = "Outdated information - verify currency"
238
+
239
+ if expertise_score >= 80:
240
+ factors['expertise'] = "Expert source"
241
+ elif expertise_score <= 45:
242
+ factors['expertise'] = "Limited expertise indicators"
243
+
244
+ if bias_score >= 80:
245
+ factors['bias'] = "Balanced perspective"
246
+ elif bias_score <= 50:
247
+ factors['bias'] = "Potential bias detected"
248
+
249
+ return factors
250
+
251
+ def _generate_recommendation(self, overall_score: float) -> str:
252
+ """Generate trust recommendation"""
253
+ if overall_score >= 80:
254
+ return "high_trust"
255
+ elif overall_score >= 60:
256
+ return "moderate_trust"
257
+ elif overall_score >= 40:
258
+ return "low_trust"
259
+ else:
260
+ return "verify"
261
+
262
+
263
+ # Example usage
264
+ if __name__ == '__main__':
265
+ evaluator = SourceEvaluator()
266
+
267
+ # Test sources
268
+ test_sources = [
269
+ {
270
+ 'url': 'https://www.nature.com/articles/s41586-2025-12345',
271
+ 'title': 'Breakthrough in Quantum Computing',
272
+ 'publication_date': '2025-10-15'
273
+ },
274
+ {
275
+ 'url': 'https://someblog.wordpress.com/shocking-discovery',
276
+ 'title': 'SHOCKING! You Won\'t Believe This Discovery!',
277
+ 'publication_date': '2020-01-01'
278
+ },
279
+ {
280
+ 'url': 'https://docs.python.org/3/library/asyncio.html',
281
+ 'title': 'asyncio — Asynchronous I/O',
282
+ 'publication_date': '2025-11-01'
283
+ }
284
+ ]
285
+
286
+ for source in test_sources:
287
+ score = evaluator.evaluate_source(**source)
288
+ print(f"\nSource: {source['title']}")
289
+ print(f"URL: {source['url']}")
290
+ print(f"Overall Score: {score.overall_score}/100")
291
+ print(f"Recommendation: {score.recommendation}")
292
+ print(f"Factors: {score.factors}")
@@ -0,0 +1,354 @@
1
+ #!/usr/bin/env python3
2
+ """
3
+ Report Validation Script
4
+ Ensures research reports meet quality standards before delivery
5
+ """
6
+
7
+ import argparse
8
+ import re
9
+ import sys
10
+ from pathlib import Path
11
+ from typing import List, Tuple, Dict
12
+
13
+
14
+ class ReportValidator:
15
+ """Validates research report quality"""
16
+
17
+ def __init__(self, report_path: Path):
18
+ self.report_path = report_path
19
+ self.content = self._read_report()
20
+ self.errors: List[str] = []
21
+ self.warnings: List[str] = []
22
+
23
+ def _read_report(self) -> str:
24
+ """Read report file"""
25
+ try:
26
+ with open(self.report_path, 'r', encoding='utf-8') as f:
27
+ return f.read()
28
+ except Exception as e:
29
+ print(f"❌ ERROR: Cannot read report: {e}")
30
+ sys.exit(1)
31
+
32
+ def validate(self) -> bool:
33
+ """Run all validation checks"""
34
+ print(f"\n{'='*60}")
35
+ print(f"VALIDATING REPORT: {self.report_path.name}")
36
+ print(f"{'='*60}\n")
37
+
38
+ checks = [
39
+ ("Executive Summary", self._check_executive_summary),
40
+ ("Required Sections", self._check_required_sections),
41
+ ("Citations", self._check_citations),
42
+ ("Bibliography", self._check_bibliography),
43
+ ("Placeholder Text", self._check_placeholders),
44
+ ("Content Truncation", self._check_content_truncation),
45
+ ("Word Count", self._check_word_count),
46
+ ("Source Count", self._check_source_count),
47
+ ("Broken Links", self._check_broken_references),
48
+ ]
49
+
50
+ for check_name, check_func in checks:
51
+ print(f"⏳ Checking: {check_name}...", end=" ")
52
+ passed = check_func()
53
+ if passed:
54
+ print("✅ PASS")
55
+ else:
56
+ print("❌ FAIL")
57
+
58
+ self._print_summary()
59
+
60
+ return len(self.errors) == 0
61
+
62
+ def _check_executive_summary(self) -> bool:
63
+ """Check executive summary exists and is under 250 words"""
64
+ pattern = r'## Executive Summary(.*?)(?=##|\Z)'
65
+ match = re.search(pattern, self.content, re.DOTALL | re.IGNORECASE)
66
+
67
+ if not match:
68
+ self.errors.append("Missing 'Executive Summary' section")
69
+ return False
70
+
71
+ summary = match.group(1).strip()
72
+ word_count = len(summary.split())
73
+
74
+ if word_count > 250:
75
+ self.warnings.append(f"Executive summary too long: {word_count} words (should be ≤250)")
76
+
77
+ if word_count < 50:
78
+ self.warnings.append(f"Executive summary too short: {word_count} words (should be ≥50)")
79
+
80
+ return True
81
+
82
+ def _check_required_sections(self) -> bool:
83
+ """Check all required sections are present"""
84
+ required = [
85
+ "Executive Summary",
86
+ "Introduction",
87
+ "Main Analysis",
88
+ "Synthesis",
89
+ "Limitations",
90
+ "Recommendations",
91
+ "Bibliography",
92
+ "Methodology"
93
+ ]
94
+
95
+ # Recommended sections (warnings if missing, not errors)
96
+ recommended = [
97
+ "Counterevidence Register",
98
+ "Claims-Evidence Table"
99
+ ]
100
+
101
+ missing = []
102
+ for section in required:
103
+ if not re.search(rf'##.*{section}', self.content, re.IGNORECASE):
104
+ missing.append(section)
105
+
106
+ if missing:
107
+ self.errors.append(f"Missing sections: {', '.join(missing)}")
108
+ return False
109
+
110
+ # Check recommended sections (warnings only)
111
+ missing_recommended = []
112
+ for section in recommended:
113
+ if not re.search(rf'##.*{section}', self.content, re.IGNORECASE):
114
+ missing_recommended.append(section)
115
+
116
+ if missing_recommended:
117
+ self.warnings.append(f"Missing recommended sections (for academic rigor): {', '.join(missing_recommended)}")
118
+
119
+ return True
120
+
121
+ def _check_citations(self) -> bool:
122
+ """Check citation format and presence"""
123
+ # Find all citation references [1], [2], etc.
124
+ citations = re.findall(r'\[(\d+)\]', self.content)
125
+
126
+ if not citations:
127
+ self.errors.append("No citations found in report")
128
+ return False
129
+
130
+ unique_citations = set(citations)
131
+
132
+ if len(unique_citations) < 10:
133
+ self.warnings.append(f"Only {len(unique_citations)} unique sources cited (recommended: ≥10)")
134
+
135
+ # Check for consecutive citation numbers
136
+ citation_nums = sorted([int(c) for c in unique_citations])
137
+ if citation_nums:
138
+ max_citation = max(citation_nums)
139
+ expected = set(range(1, max_citation + 1))
140
+ missing = expected - set(citation_nums)
141
+
142
+ if missing:
143
+ self.warnings.append(f"Non-consecutive citation numbers, missing: {sorted(missing)}")
144
+
145
+ return True
146
+
147
+ def _check_bibliography(self) -> bool:
148
+ """Check bibliography exists, matches citations, and has no truncation placeholders"""
149
+ pattern = r'## Bibliography(.*?)(?=##|\Z)'
150
+ match = re.search(pattern, self.content, re.DOTALL | re.IGNORECASE)
151
+
152
+ if not match:
153
+ self.errors.append("Missing 'Bibliography' section")
154
+ return False
155
+
156
+ bib_section = match.group(1)
157
+
158
+ # CRITICAL: Check for truncation placeholders (2025 CiteGuard enhancement)
159
+ truncation_patterns = [
160
+ (r'\[\d+-\d+\]', 'Citation range (e.g., [8-75])'),
161
+ (r'Additional.*citations', 'Phrase "Additional citations"'),
162
+ (r'would be included', 'Phrase "would be included"'),
163
+ (r'\[\.\.\.continue', 'Pattern "[...continue"'),
164
+ (r'\[Continue with', 'Pattern "[Continue with"'),
165
+ (r'etc\.(?!\w)', 'Standalone "etc."'),
166
+ (r'and so on', 'Phrase "and so on"'),
167
+ ]
168
+
169
+ for pattern_re, description in truncation_patterns:
170
+ if re.search(pattern_re, bib_section, re.IGNORECASE):
171
+ self.errors.append(f"⚠️ CRITICAL: Bibliography contains truncation placeholder: {description}")
172
+ self.errors.append(f" This makes the report UNUSABLE - complete bibliography required")
173
+ return False
174
+
175
+ # Count bibliography entries [1], [2], etc.
176
+ bib_entries = re.findall(r'^\[(\d+)\]', bib_section, re.MULTILINE)
177
+
178
+ if not bib_entries:
179
+ self.errors.append("Bibliography has no entries")
180
+ return False
181
+
182
+ # Check citation number continuity (no gaps)
183
+ bib_nums = sorted([int(n) for n in bib_entries])
184
+ if bib_nums:
185
+ expected = list(range(1, bib_nums[-1] + 1))
186
+ actual = bib_nums
187
+ missing = [n for n in expected if n not in actual]
188
+ if missing:
189
+ self.errors.append(f"Bibliography has gaps in numbering: missing {missing}")
190
+ return False
191
+
192
+ # Find citations in text
193
+ text_citations = set(re.findall(r'\[(\d+)\]', self.content))
194
+ bib_citations = set(bib_entries)
195
+
196
+ # Check all citations have bibliography entries
197
+ missing_in_bib = text_citations - bib_citations
198
+ if missing_in_bib:
199
+ self.errors.append(f"Citations missing from bibliography: {sorted(missing_in_bib)}")
200
+ return False
201
+
202
+ # Check for unused bibliography entries
203
+ unused = bib_citations - text_citations
204
+ if unused:
205
+ self.warnings.append(f"Unused bibliography entries: {sorted(unused)}")
206
+
207
+ return True
208
+
209
+ def _check_placeholders(self) -> bool:
210
+ """Check for placeholder text that shouldn't be in final report"""
211
+ placeholders = [
212
+ 'TBD', 'TODO', 'FIXME', 'XXX',
213
+ '[citation needed]', '[needs citation]',
214
+ '[placeholder]', '[TODO]', '[TBD]'
215
+ ]
216
+
217
+ found_placeholders = []
218
+ for placeholder in placeholders:
219
+ if placeholder in self.content:
220
+ found_placeholders.append(placeholder)
221
+
222
+ if found_placeholders:
223
+ self.errors.append(f"Found placeholder text: {', '.join(found_placeholders)}")
224
+ return False
225
+
226
+ return True
227
+
228
+ def _check_content_truncation(self) -> bool:
229
+ """Check for content truncation patterns (2025 Progressive Assembly enhancement)"""
230
+ truncation_patterns = [
231
+ (r'Content continues', 'Phrase "Content continues"'),
232
+ (r'Due to length', 'Phrase "Due to length"'),
233
+ (r'would continue', 'Phrase "would continue"'),
234
+ (r'\[Sections \d+-\d+', 'Pattern "[Sections X-Y"'),
235
+ (r'Additional sections', 'Phrase "Additional sections"'),
236
+ (r'comprehensive.*word document that continues', 'Pattern "comprehensive...document that continues"'),
237
+ ]
238
+
239
+ for pattern_re, description in truncation_patterns:
240
+ if re.search(pattern_re, self.content, re.IGNORECASE):
241
+ self.errors.append(f"⚠️ CRITICAL: Content truncation detected: {description}")
242
+ self.errors.append(f" Report is INCOMPLETE and UNUSABLE - regenerate with progressive assembly")
243
+ return False
244
+
245
+ return True
246
+
247
+ def _check_word_count(self) -> bool:
248
+ """Check overall report length"""
249
+ word_count = len(self.content.split())
250
+
251
+ if word_count < 500:
252
+ self.warnings.append(f"Report is very short: {word_count} words (consider expanding)")
253
+ # No upper limit warning - progressive assembly supports unlimited lengths
254
+
255
+ return True
256
+
257
+ def _check_source_count(self) -> bool:
258
+ """Check minimum source count"""
259
+ pattern = r'## Bibliography(.*?)(?=##|\Z)'
260
+ match = re.search(pattern, self.content, re.DOTALL | re.IGNORECASE)
261
+
262
+ if not match:
263
+ return True # Already caught in bibliography check
264
+
265
+ bib_section = match.group(1)
266
+ bib_entries = re.findall(r'^\[(\d+)\]', bib_section, re.MULTILINE)
267
+
268
+ source_count = len(set(bib_entries))
269
+
270
+ if source_count < 10:
271
+ self.warnings.append(f"Only {source_count} sources (recommended: ≥10)")
272
+
273
+ return True
274
+
275
+ def _check_broken_references(self) -> bool:
276
+ """Check for broken internal references"""
277
+ # Find all markdown links [text](./path)
278
+ internal_links = re.findall(r'\[.*?\]\((\.\/.*?)\)', self.content)
279
+
280
+ broken = []
281
+ for link in internal_links:
282
+ # Remove anchor if present
283
+ link_path = link.split('#')[0]
284
+ full_path = self.report_path.parent / link_path
285
+
286
+ if not full_path.exists():
287
+ broken.append(link)
288
+
289
+ if broken:
290
+ self.errors.append(f"Broken internal links: {', '.join(broken)}")
291
+ return False
292
+
293
+ return True
294
+
295
+ def _print_summary(self):
296
+ """Print validation summary"""
297
+ print(f"\n{'='*60}")
298
+ print(f"VALIDATION SUMMARY")
299
+ print(f"{'='*60}\n")
300
+
301
+ if self.errors:
302
+ print(f"❌ ERRORS ({len(self.errors)}):")
303
+ for error in self.errors:
304
+ print(f" • {error}")
305
+ print()
306
+
307
+ if self.warnings:
308
+ print(f"⚠️ WARNINGS ({len(self.warnings)}):")
309
+ for warning in self.warnings:
310
+ print(f" • {warning}")
311
+ print()
312
+
313
+ if not self.errors and not self.warnings:
314
+ print("✅ ALL CHECKS PASSED - Report meets quality standards!\n")
315
+ elif not self.errors:
316
+ print("✅ VALIDATION PASSED (with warnings)\n")
317
+ else:
318
+ print("❌ VALIDATION FAILED - Please fix errors before delivery\n")
319
+
320
+
321
+ def main():
322
+ parser = argparse.ArgumentParser(
323
+ description="Validate research report quality",
324
+ formatter_class=argparse.RawDescriptionHelpFormatter,
325
+ epilog="""
326
+ Examples:
327
+ python validate_report.py --report report.md
328
+ python validate_report.py -r ~/.claude/research_output/research_report_20251104_153045.md
329
+ """
330
+ )
331
+
332
+ parser.add_argument(
333
+ '--report', '-r',
334
+ type=str,
335
+ required=True,
336
+ help='Path to research report markdown file'
337
+ )
338
+
339
+ args = parser.parse_args()
340
+
341
+ report_path = Path(args.report)
342
+
343
+ if not report_path.exists():
344
+ print(f"❌ ERROR: Report file not found: {report_path}")
345
+ sys.exit(1)
346
+
347
+ validator = ReportValidator(report_path)
348
+ passed = validator.validate()
349
+
350
+ sys.exit(0 if passed else 1)
351
+
352
+
353
+ if __name__ == '__main__':
354
+ main()