kash-shell 0.3.30__tar.gz → 0.3.34__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 (334) hide show
  1. {kash_shell-0.3.30 → kash_shell-0.3.34}/PKG-INFO +5 -5
  2. {kash_shell-0.3.30 → kash_shell-0.3.34}/README.md +2 -2
  3. {kash_shell-0.3.30 → kash_shell-0.3.34}/pyproject.toml +3 -2
  4. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/actions/core/chat.py +1 -0
  5. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/actions/core/markdownify_html.py +1 -1
  6. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/actions/core/readability.py +1 -4
  7. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/actions/core/render_as_html.py +1 -0
  8. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/actions/core/show_webpage.py +2 -0
  9. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/actions/core/summarize_as_bullets.py +1 -1
  10. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/config/logger.py +1 -1
  11. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/config/text_styles.py +1 -1
  12. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/docs/markdown/topics/a2_installation.md +3 -2
  13. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/exec/action_decorators.py +5 -3
  14. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/exec/action_exec.py +50 -5
  15. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/exec/fetch_url_items.py +4 -2
  16. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/exec/llm_transforms.py +14 -5
  17. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/exec/runtime_settings.py +2 -0
  18. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/file_storage/file_store.py +50 -92
  19. kash_shell-0.3.34/src/kash/file_storage/item_id_index.py +128 -0
  20. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/mcp/mcp_server_routes.py +42 -12
  21. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/model/actions_model.py +18 -7
  22. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/model/exec_model.py +3 -0
  23. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/model/items_model.py +54 -12
  24. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/api_utils/gather_limited.py +2 -0
  25. kash_shell-0.3.34/src/kash/utils/api_utils/multitask_gather.py +134 -0
  26. kash_shell-0.3.34/src/kash/utils/common/s3_utils.py +108 -0
  27. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/common/url.py +16 -4
  28. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/rich_custom/multitask_status.py +84 -10
  29. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/text_handling/markdown_footnotes.py +16 -43
  30. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/text_handling/markdown_utils.py +108 -28
  31. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/web_content/web_fetch.py +2 -1
  32. {kash_shell-0.3.30 → kash_shell-0.3.34}/uv.lock +87 -87
  33. {kash_shell-0.3.30 → kash_shell-0.3.34}/.copier-answers.yml +0 -0
  34. {kash_shell-0.3.30 → kash_shell-0.3.34}/.cursor/rules/general.mdc +0 -0
  35. {kash_shell-0.3.30 → kash_shell-0.3.34}/.cursor/rules/python.mdc +0 -0
  36. {kash_shell-0.3.30 → kash_shell-0.3.34}/.env.template +0 -0
  37. {kash_shell-0.3.30 → kash_shell-0.3.34}/.github/workflows/ci.yml +0 -0
  38. {kash_shell-0.3.30 → kash_shell-0.3.34}/.github/workflows/publish.yml +0 -0
  39. {kash_shell-0.3.30 → kash_shell-0.3.34}/.gitignore +0 -0
  40. {kash_shell-0.3.30 → kash_shell-0.3.34}/LICENSE +0 -0
  41. {kash_shell-0.3.30 → kash_shell-0.3.34}/Makefile +0 -0
  42. {kash_shell-0.3.30 → kash_shell-0.3.34}/development.md +0 -0
  43. {kash_shell-0.3.30 → kash_shell-0.3.34}/devtools/generate_readme.xsh +0 -0
  44. {kash_shell-0.3.30 → kash_shell-0.3.34}/devtools/lint.py +0 -0
  45. {kash_shell-0.3.30 → kash_shell-0.3.34}/devtools/profile_main.py +0 -0
  46. {kash_shell-0.3.30 → kash_shell-0.3.34}/installation.md +0 -0
  47. {kash_shell-0.3.30 → kash_shell-0.3.34}/publishing.md +0 -0
  48. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/__init__.py +0 -0
  49. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/__main__.py +0 -0
  50. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/actions/__init__.py +0 -0
  51. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/actions/core/assistant_chat.py +0 -0
  52. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/actions/core/combine_docs.py +0 -0
  53. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/actions/core/concat_docs.py +0 -0
  54. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/actions/core/format_markdown_template.py +0 -0
  55. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/actions/core/minify_html.py +0 -0
  56. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/actions/core/save_sidematter_meta.py +0 -0
  57. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/actions/core/strip_html.py +0 -0
  58. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/actions/core/tabbed_webpage_config.py +0 -0
  59. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/actions/core/tabbed_webpage_generate.py +0 -0
  60. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/actions/core/zip_sidematter.py +0 -0
  61. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/actions/meta/write_instructions.py +0 -0
  62. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/actions/meta/write_new_action.py +0 -0
  63. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/commands/__init__.py +0 -0
  64. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/commands/base/basic_file_commands.py +0 -0
  65. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/commands/base/browser_commands.py +0 -0
  66. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/commands/base/debug_commands.py +0 -0
  67. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/commands/base/diff_commands.py +0 -0
  68. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/commands/base/files_command.py +0 -0
  69. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/commands/base/general_commands.py +0 -0
  70. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/commands/base/logs_commands.py +0 -0
  71. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/commands/base/model_commands.py +0 -0
  72. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/commands/base/reformat_command.py +0 -0
  73. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/commands/base/search_command.py +0 -0
  74. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/commands/base/show_command.py +0 -0
  75. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/commands/extras/parse_uv_lock.py +0 -0
  76. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/commands/extras/utils_commands.py +0 -0
  77. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/commands/help/assistant_commands.py +0 -0
  78. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/commands/help/doc_commands.py +0 -0
  79. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/commands/help/help_commands.py +0 -0
  80. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/commands/help/logo.py +0 -0
  81. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/commands/help/welcome.py +0 -0
  82. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/commands/workspace/selection_commands.py +0 -0
  83. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/commands/workspace/workspace_commands.py +0 -0
  84. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/config/__init__.py +0 -0
  85. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/config/capture_output.py +0 -0
  86. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/config/colors.py +0 -0
  87. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/config/env_settings.py +0 -0
  88. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/config/init.py +0 -0
  89. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/config/lazy_imports.py +0 -0
  90. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/config/logger_basic.py +0 -0
  91. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/config/logo.txt +0 -0
  92. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/config/server_config.py +0 -0
  93. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/config/settings.py +0 -0
  94. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/config/setup.py +0 -0
  95. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/config/suppress_warnings.py +0 -0
  96. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/config/unified_live.py +0 -0
  97. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/docs/__init__.py +0 -0
  98. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/docs/all_docs.py +0 -0
  99. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/docs/load_actions_info.py +0 -0
  100. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/docs/load_api_docs.py +0 -0
  101. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/docs/load_help_topics.py +0 -0
  102. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/docs/load_source_code.py +0 -0
  103. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/docs/markdown/api_docs_template.md +0 -0
  104. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/docs/markdown/assistant_instructions_template.md +0 -0
  105. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/docs/markdown/readme_template.md +0 -0
  106. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/docs/markdown/topics/a1_what_is_kash.md +0 -0
  107. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/docs/markdown/topics/a3_getting_started.md +0 -0
  108. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/docs/markdown/topics/a4_elements.md +0 -0
  109. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/docs/markdown/topics/a5_tips_for_use_with_other_tools.md +0 -0
  110. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/docs/markdown/topics/b0_philosophy_of_kash.md +0 -0
  111. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/docs/markdown/topics/b1_kash_overview.md +0 -0
  112. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/docs/markdown/topics/b2_workspace_and_file_formats.md +0 -0
  113. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/docs/markdown/topics/b3_modern_shell_tool_recommendations.md +0 -0
  114. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/docs/markdown/topics/b4_faq.md +0 -0
  115. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/docs/markdown/warning.md +0 -0
  116. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/docs/markdown/welcome.md +0 -0
  117. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/docs_base/docs_base.py +0 -0
  118. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/docs_base/load_custom_command_info.py +0 -0
  119. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/docs_base/load_faqs.py +0 -0
  120. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/docs_base/load_recipe_snippets.py +0 -0
  121. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/docs_base/recipes/general_system_commands.sh +0 -0
  122. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/docs_base/recipes/python_dev_commands.sh +0 -0
  123. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/docs_base/recipes/tldr_standard_commands.sh +0 -0
  124. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/embeddings/cosine.py +0 -0
  125. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/embeddings/embeddings.py +0 -0
  126. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/embeddings/text_similarity.py +0 -0
  127. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/exec/__init__.py +0 -0
  128. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/exec/action_registry.py +0 -0
  129. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/exec/combiners.py +0 -0
  130. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/exec/command_exec.py +0 -0
  131. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/exec/command_registry.py +0 -0
  132. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/exec/history.py +0 -0
  133. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/exec/importing.py +0 -0
  134. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/exec/precondition_checks.py +0 -0
  135. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/exec/precondition_registry.py +0 -0
  136. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/exec/preconditions.py +0 -0
  137. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/exec/resolve_args.py +0 -0
  138. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/exec/shell_callable_action.py +0 -0
  139. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/exec_model/__init__.py +0 -0
  140. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/exec_model/args_model.py +0 -0
  141. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/exec_model/commands_model.py +0 -0
  142. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/exec_model/script_model.py +0 -0
  143. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/exec_model/shell_model.py +0 -0
  144. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/file_storage/__init__.py +0 -0
  145. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/file_storage/item_file_format.py +0 -0
  146. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/file_storage/metadata_dirs.py +0 -0
  147. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/file_storage/persisted_yaml.py +0 -0
  148. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/file_storage/store_cache_warmer.py +0 -0
  149. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/file_storage/store_filenames.py +0 -0
  150. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/help/__init__.py +0 -0
  151. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/help/assistant.py +0 -0
  152. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/help/assistant_instructions.py +0 -0
  153. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/help/assistant_output.py +0 -0
  154. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/help/function_param_info.py +0 -0
  155. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/help/help_embeddings.py +0 -0
  156. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/help/help_lookups.py +0 -0
  157. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/help/help_pages.py +0 -0
  158. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/help/help_printing.py +0 -0
  159. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/help/help_types.py +0 -0
  160. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/help/recommended_commands.py +0 -0
  161. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/help/tldr_help.py +0 -0
  162. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/llm_utils/__init__.py +0 -0
  163. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/llm_utils/clean_headings.py +0 -0
  164. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/llm_utils/custom_sliding_transforms.py +0 -0
  165. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/llm_utils/fuzzy_parsing.py +0 -0
  166. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/llm_utils/init_litellm.py +0 -0
  167. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/llm_utils/llm_api_keys.py +0 -0
  168. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/llm_utils/llm_completion.py +0 -0
  169. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/llm_utils/llm_messages.py +0 -0
  170. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/llm_utils/llm_names.py +0 -0
  171. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/llm_utils/llms.py +0 -0
  172. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/local_server/__init__.py +0 -0
  173. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/local_server/local_server.py +0 -0
  174. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/local_server/local_server_commands.py +0 -0
  175. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/local_server/local_server_routes.py +0 -0
  176. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/local_server/local_url_formatters.py +0 -0
  177. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/local_server/port_tools.py +0 -0
  178. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/local_server/rich_html_template.py +0 -0
  179. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/mcp/__init__.py +0 -0
  180. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/mcp/mcp_cli.py +0 -0
  181. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/mcp/mcp_main.py +0 -0
  182. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/mcp/mcp_server_commands.py +0 -0
  183. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/mcp/mcp_server_sse.py +0 -0
  184. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/mcp/mcp_server_stdio.py +0 -0
  185. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/media_base/__init__.py +0 -0
  186. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/media_base/audio_processing.py +0 -0
  187. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/media_base/media_cache.py +0 -0
  188. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/media_base/media_services.py +0 -0
  189. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/media_base/media_tools.py +0 -0
  190. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/media_base/services/local_file_media.py +0 -0
  191. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/media_base/timestamp_citations.py +0 -0
  192. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/media_base/transcription_deepgram.py +0 -0
  193. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/media_base/transcription_format.py +0 -0
  194. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/media_base/transcription_whisper.py +0 -0
  195. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/model/__init__.py +0 -0
  196. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/model/assistant_response_model.py +0 -0
  197. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/model/compound_actions_model.py +0 -0
  198. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/model/concept_model.py +0 -0
  199. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/model/graph_model.py +0 -0
  200. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/model/language_list.py +0 -0
  201. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/model/llm_actions_model.py +0 -0
  202. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/model/media_model.py +0 -0
  203. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/model/operations_model.py +0 -0
  204. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/model/params_model.py +0 -0
  205. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/model/paths_model.py +0 -0
  206. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/model/preconditions_model.py +0 -0
  207. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/shell/__init__.py +0 -0
  208. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/shell/completions/completion_scoring.py +0 -0
  209. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/shell/completions/completion_types.py +0 -0
  210. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/shell/completions/shell_completions.py +0 -0
  211. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/shell/file_icons/color_for_format.py +0 -0
  212. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/shell/file_icons/nerd_icons.py +0 -0
  213. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/shell/input/__init__.py +0 -0
  214. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/shell/input/input_prompts.py +0 -0
  215. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/shell/input/inquirer_settings.py +0 -0
  216. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/shell/input/param_inputs.py +0 -0
  217. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/shell/input/shell_confirm.py +0 -0
  218. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/shell/output/__init__.py +0 -0
  219. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/shell/output/kerm_code_utils.py +0 -0
  220. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/shell/output/kerm_codes.py +0 -0
  221. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/shell/output/kmarkdown.py +0 -0
  222. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/shell/output/shell_formatting.py +0 -0
  223. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/shell/output/shell_output.py +0 -0
  224. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/shell/shell_main.py +0 -0
  225. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/shell/ui/__init__.py +0 -0
  226. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/shell/ui/shell_results.py +0 -0
  227. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/shell/ui/shell_syntax.py +0 -0
  228. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/shell/utils/exception_printing.py +0 -0
  229. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/shell/utils/native_utils.py +0 -0
  230. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/shell/utils/shell_function_wrapper.py +0 -0
  231. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/shell/version.py +0 -0
  232. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/__init__.py +0 -0
  233. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/api_utils/api_retries.py +0 -0
  234. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/api_utils/cache_requests_limited.py +0 -0
  235. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/api_utils/http_utils.py +0 -0
  236. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/api_utils/progress_protocol.py +0 -0
  237. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/common/__init__.py +0 -0
  238. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/common/format_utils.py +0 -0
  239. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/common/function_inspect.py +0 -0
  240. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/common/import_utils.py +0 -0
  241. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/common/lazyobject.py +0 -0
  242. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/common/obj_replace.py +0 -0
  243. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/common/parse_docstring.py +0 -0
  244. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/common/parse_key_vals.py +0 -0
  245. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/common/parse_shell_args.py +0 -0
  246. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/common/stack_traces.py +0 -0
  247. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/common/task_stack.py +0 -0
  248. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/common/testing.py +0 -0
  249. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/common/type_utils.py +0 -0
  250. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/common/uniquifier.py +0 -0
  251. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/common/url_slice.py +0 -0
  252. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/errors.py +0 -0
  253. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/file_formats/chat_format.py +0 -0
  254. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/file_utils/__init__.py +0 -0
  255. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/file_utils/csv_utils.py +0 -0
  256. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/file_utils/dir_info.py +0 -0
  257. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/file_utils/file_ext.py +0 -0
  258. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/file_utils/file_formats.py +0 -0
  259. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/file_utils/file_formats_model.py +0 -0
  260. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/file_utils/file_sort_filter.py +0 -0
  261. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/file_utils/file_walk.py +0 -0
  262. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/file_utils/filename_parsing.py +0 -0
  263. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/file_utils/ignore_files.py +0 -0
  264. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/file_utils/mtime_cache.py +0 -0
  265. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/file_utils/path_utils.py +0 -0
  266. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/lang_utils/__init__.py +0 -0
  267. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/lang_utils/capitalization.py +0 -0
  268. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/rich_custom/__init__.py +0 -0
  269. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/rich_custom/ansi_cell_len.py +0 -0
  270. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/rich_custom/rich_char_transform.py +0 -0
  271. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/rich_custom/rich_indent.py +0 -0
  272. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/rich_custom/rich_markdown_fork.py +0 -0
  273. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/text_handling/doc_normalization.py +0 -0
  274. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/text_handling/escape_html_tags.py +0 -0
  275. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/text_handling/markdown_render.py +0 -0
  276. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/text_handling/markdownify_utils.py +0 -0
  277. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/utils/text_handling/unified_diffs.py +0 -0
  278. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/web_content/canon_url.py +0 -0
  279. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/web_content/dir_store.py +0 -0
  280. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/web_content/file_cache_utils.py +0 -0
  281. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/web_content/file_processing.py +0 -0
  282. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/web_content/local_file_cache.py +0 -0
  283. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/web_content/web_extract.py +0 -0
  284. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/web_content/web_extract_justext.py +0 -0
  285. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/web_content/web_extract_readabilipy.py +0 -0
  286. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/web_content/web_page_model.py +0 -0
  287. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/web_gen/__init__.py +0 -0
  288. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/web_gen/tabbed_webpage.py +0 -0
  289. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/web_gen/template_render.py +0 -0
  290. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/web_gen/templates/base_styles.css.jinja +0 -0
  291. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/web_gen/templates/base_webpage.html.jinja +0 -0
  292. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/web_gen/templates/components/toc_scripts.js.jinja +0 -0
  293. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/web_gen/templates/components/toc_styles.css.jinja +0 -0
  294. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/web_gen/templates/components/tooltip_scripts.js.jinja +0 -0
  295. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/web_gen/templates/components/tooltip_styles.css.jinja +0 -0
  296. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/web_gen/templates/components/youtube_popover_scripts.js.jinja +0 -0
  297. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/web_gen/templates/components/youtube_popover_styles.css.jinja +0 -0
  298. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/web_gen/templates/content_styles.css.jinja +0 -0
  299. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/web_gen/templates/explain_view.html.jinja +0 -0
  300. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/web_gen/templates/item_view.html.jinja +0 -0
  301. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/web_gen/templates/simple_webpage.html.jinja +0 -0
  302. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/web_gen/templates/tabbed_webpage.html.jinja +0 -0
  303. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/web_gen/templates/youtube_webpage.html.jinja +0 -0
  304. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/web_gen/webpage_render.py +0 -0
  305. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/workspaces/__init__.py +0 -0
  306. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/workspaces/param_state.py +0 -0
  307. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/workspaces/selections.py +0 -0
  308. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/workspaces/source_items.py +0 -0
  309. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/workspaces/workspace_dirs.py +0 -0
  310. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/workspaces/workspace_output.py +0 -0
  311. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/workspaces/workspace_registry.py +0 -0
  312. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/workspaces/workspaces.py +0 -0
  313. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/xonsh_custom/command_nl_utils.py +0 -0
  314. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/xonsh_custom/custom_shell.py +0 -0
  315. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/xonsh_custom/customize_prompt.py +0 -0
  316. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/xonsh_custom/load_into_xonsh.py +0 -0
  317. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/xonsh_custom/shell_load_commands.py +0 -0
  318. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/xonsh_custom/shell_which.py +0 -0
  319. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/xonsh_custom/xonsh_completers.py +0 -0
  320. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/xonsh_custom/xonsh_env.py +0 -0
  321. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/xonsh_custom/xonsh_keybindings.py +0 -0
  322. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/xonsh_custom/xonsh_modern_tools.py +0 -0
  323. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/xonsh_custom/xonsh_ranking_completer.py +0 -0
  324. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/xontrib/fnm.py +0 -0
  325. {kash_shell-0.3.30 → kash_shell-0.3.34}/src/kash/xontrib/kash_extension.py +0 -0
  326. {kash_shell-0.3.30 → kash_shell-0.3.34}/tests/file_storage/test_file_store.py +0 -0
  327. {kash_shell-0.3.30 → kash_shell-0.3.34}/tests/kash/utils/api_utils/test_gather_limited.py +0 -0
  328. {kash_shell-0.3.30 → kash_shell-0.3.34}/tests/kash/utils/file_utils/test_csv_utils.py +0 -0
  329. {kash_shell-0.3.30 → kash_shell-0.3.34}/tests/kash/utils/rich_custom/test_multitask_status.py +0 -0
  330. {kash_shell-0.3.30 → kash_shell-0.3.34}/tests/model/test_item_serialization.py +0 -0
  331. {kash_shell-0.3.30 → kash_shell-0.3.34}/tests/shell/input/interactive_input_test.py +0 -0
  332. {kash_shell-0.3.30 → kash_shell-0.3.34}/tests/test_shell.py +0 -0
  333. {kash_shell-0.3.30 → kash_shell-0.3.34}/tests/utils/text_handling/test_markdown_footnotes.py +0 -0
  334. {kash_shell-0.3.30 → kash_shell-0.3.34}/tests/web_gen/test_social_metadata.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: kash-shell
3
- Version: 0.3.30
3
+ Version: 0.3.34
4
4
  Summary: The knowledge agent shell (core)
5
5
  Project-URL: Repository, https://github.com/jlevy/kash-shell
6
6
  Author-email: Joshua Levy <joshua@cal.berkeley.edu>
@@ -20,7 +20,7 @@ Requires-Dist: aiolimiter>=1.2.1
20
20
  Requires-Dist: anyio>=4.8.0
21
21
  Requires-Dist: audioop-lts>=0.2.1; python_version >= '3.13'
22
22
  Requires-Dist: cachetools>=5.5.2
23
- Requires-Dist: chopdiff>=0.2.5
23
+ Requires-Dist: chopdiff>=0.2.6
24
24
  Requires-Dist: clideps>=0.1.4
25
25
  Requires-Dist: colour>=0.1.5
26
26
  Requires-Dist: cssselect>=1.2.0
@@ -41,7 +41,7 @@ Requires-Dist: litellm>=1.74.15.post1
41
41
  Requires-Dist: markdownify>=0.13.1
42
42
  Requires-Dist: mcp-proxy>=0.5.0
43
43
  Requires-Dist: mcp>=1.6.0
44
- Requires-Dist: openai>=1.66.3
44
+ Requires-Dist: openai==1.99.9
45
45
  Requires-Dist: pandas>=2.2.3
46
46
  Requires-Dist: patch-ng>=1.18.1
47
47
  Requires-Dist: pathspec>=0.12.1
@@ -280,8 +280,8 @@ These are for `kash-media` but you can use a `kash-shell` for a more basic setup
280
280
 
281
281
  ```shell
282
282
  sudo apt-get update
283
- sudo apt-get install -y libgl1 ffmpeg libmagic-dev
284
- # For the additional command-line tools, pixi is better on Ubuntu:
283
+ sudo apt-get install -y libgl1 ffmpeg libmagic-dev imagemagick bat ripgrep hexyl
284
+ # Or for more additional command-line tools, pixi is better on Ubuntu:
285
285
  curl -fsSL https://pixi.sh/install.sh | sh
286
286
  . ~/.bashrc
287
287
  pixi global install ripgrep bat eza hexyl imagemagick zoxide
@@ -201,8 +201,8 @@ These are for `kash-media` but you can use a `kash-shell` for a more basic setup
201
201
 
202
202
  ```shell
203
203
  sudo apt-get update
204
- sudo apt-get install -y libgl1 ffmpeg libmagic-dev
205
- # For the additional command-line tools, pixi is better on Ubuntu:
204
+ sudo apt-get install -y libgl1 ffmpeg libmagic-dev imagemagick bat ripgrep hexyl
205
+ # Or for more additional command-line tools, pixi is better on Ubuntu:
206
206
  curl -fsSL https://pixi.sh/install.sh | sh
207
207
  . ~/.bashrc
208
208
  pixi global install ripgrep bat eza hexyl imagemagick zoxide
@@ -48,7 +48,7 @@ dependencies = [
48
48
  "flowmark>=0.5.3",
49
49
  "frontmatter-format>=0.2.3",
50
50
  "sidematter-format>=0.0.5",
51
- "chopdiff>=0.2.5",
51
+ "chopdiff>=0.2.6",
52
52
  "clideps>=0.1.4",
53
53
  "tminify>=0.1.6",
54
54
  # Shell and file essentials:
@@ -84,7 +84,7 @@ dependencies = [
84
84
  "curl-cffi>=0.11.4",
85
85
  # LLM and API essentials:
86
86
  "tiktoken>=0.9.0",
87
- "openai>=1.66.3",
87
+ "openai==1.99.9", # FIXME: Pinning for now due to import errors (ImportError: cannot import name 'ResponseTextConfig' from 'openai.types.responses.response')
88
88
  "litellm>=1.74.15.post1",
89
89
  "pyrate-limiter>=3.7.0",
90
90
  "aiolimiter>=1.2.1",
@@ -130,6 +130,7 @@ kash-mcp = "kash.mcp.mcp_cli:main"
130
130
 
131
131
  [tool.uv.sources]
132
132
  # For local development:
133
+ # flowmark = { path = "../flowmark", editable = true }
133
134
  # clideps = { path = "../clideps", editable = true }
134
135
  # tminify = { path = "../tminify", editable = true }
135
136
  # chopdiff = { path = "../chopdiff", editable = true }
@@ -28,6 +28,7 @@ log = get_logger(__name__)
28
28
  @kash_action(
29
29
  expected_args=ONE_OR_NO_ARGS,
30
30
  precondition=is_chat,
31
+ output_format=Format.yaml,
31
32
  uses_selection=False,
32
33
  interactive_input=True,
33
34
  cacheable=False,
@@ -13,7 +13,7 @@ from kash.web_content.web_extract_readabilipy import extract_text_readabilipy
13
13
  log = get_logger(__name__)
14
14
 
15
15
 
16
- @kash_action(precondition=is_url_resource | has_html_body, mcp_tool=True)
16
+ @kash_action(precondition=is_url_resource | has_html_body, output_format=Format.markdown)
17
17
  def markdownify_html(item: Item) -> Item:
18
18
  """
19
19
  Converts raw HTML or the URL of an HTML page to Markdown, fetching with the content
@@ -9,10 +9,7 @@ from kash.web_content.web_extract_readabilipy import extract_text_readabilipy
9
9
  log = get_logger(__name__)
10
10
 
11
11
 
12
- @kash_action(
13
- precondition=is_url_resource | has_html_body,
14
- mcp_tool=True,
15
- )
12
+ @kash_action(precondition=is_url_resource | has_html_body, output_format=Format.html)
16
13
  def readability(item: Item) -> Item:
17
14
  """
18
15
  Extracts clean HTML from a raw HTML item.
@@ -15,6 +15,7 @@ log = get_logger(__name__)
15
15
  @kash_action(
16
16
  expected_args=ONE_OR_MORE_ARGS,
17
17
  precondition=(has_html_body | has_simple_text_body) & ~has_fullpage_html_body,
18
+ output_format=Format.html,
18
19
  params=(Param("no_title", "Don't add a title to the page body.", type=bool),),
19
20
  )
20
21
  def render_as_html(input: ActionInput, no_title: bool = False) -> ActionResult:
@@ -6,11 +6,13 @@ from kash.exec_model.args_model import ONE_OR_MORE_ARGS
6
6
  from kash.exec_model.commands_model import Command
7
7
  from kash.exec_model.shell_model import ShellResult
8
8
  from kash.model import ActionInput, ActionResult
9
+ from kash.utils.file_utils.file_formats_model import Format
9
10
 
10
11
 
11
12
  @kash_action(
12
13
  expected_args=ONE_OR_MORE_ARGS,
13
14
  precondition=(has_html_body | has_simple_text_body) & ~has_fullpage_html_body,
15
+ output_format=Format.html,
14
16
  )
15
17
  def show_webpage(input: ActionInput) -> ActionResult:
16
18
  """
@@ -47,7 +47,7 @@ llm_options = LLMOptions(
47
47
  )
48
48
 
49
49
 
50
- @kash_action(llm_options=llm_options, params=common_params("model"), mcp_tool=True)
50
+ @kash_action(llm_options=llm_options, params=common_params("model"))
51
51
  def summarize_as_bullets(item: Item, model: LLMName = LLM.default_standard) -> Item:
52
52
  """
53
53
  Summarize text as bullet points.
@@ -281,7 +281,7 @@ def _do_logging_setup(log_settings: LogSettings):
281
281
  def prefix(line: str, emoji: str = "", warn_emoji: str = "") -> str:
282
282
  prefix = task_stack_prefix_str()
283
283
  emojis = f"{warn_emoji}{emoji}".strip()
284
- return " ".join(filter(None, [prefix, emojis, line]))
284
+ return "".join(filter(None, [prefix, emojis, line]))
285
285
 
286
286
 
287
287
  def prefix_args(
@@ -262,7 +262,7 @@ PROMPT_ASSIST = "(assistant) ❯"
262
262
 
263
263
  EMOJI_HINT = "👉"
264
264
 
265
- EMOJI_MSG_INDENT = "⋮"
265
+ EMOJI_MSG_INDENT = "⋮ "
266
266
 
267
267
  EMOJI_START = "[➤]"
268
268
 
@@ -60,8 +60,9 @@ These are for `kash-media` but you can use a `kash-shell` for a more basic setup
60
60
 
61
61
  ```shell
62
62
  sudo apt-get update
63
- sudo apt-get install -y libgl1 ffmpeg libmagic-dev
64
- # For the additional command-line tools, pixi is better on Ubuntu:
63
+ sudo apt-get install -y libgl1 ffmpeg libmagic-dev imagemagick bat ripgrep hexyl
64
+
65
+ # Or for additional command-line tools, pixi is better on Ubuntu:
65
66
  curl -fsSL https://pixi.sh/install.sh | sh
66
67
  . ~/.bashrc
67
68
  pixi global install ripgrep bat eza hexyl imagemagick zoxide
@@ -37,6 +37,7 @@ from kash.model.params_model import Param, ParamDeclarations, TypedParamValues
37
37
  from kash.model.preconditions_model import Precondition
38
38
  from kash.utils.common.function_inspect import FuncParam, inspect_function_params
39
39
  from kash.utils.errors import InvalidDefinition
40
+ from kash.utils.file_utils.file_formats_model import Format
40
41
 
41
42
  log = get_logger(__name__)
42
43
 
@@ -204,6 +205,7 @@ def kash_action(
204
205
  arg_type: ArgType = ArgType.Locator,
205
206
  expected_args: ArgCount = ONE_ARG,
206
207
  output_type: ItemType = ItemType.doc,
208
+ output_format: Format | None = None,
207
209
  expected_outputs: ArgCount = ONE_ARG,
208
210
  params: ParamDeclarations = (),
209
211
  run_per_item: bool | None = None,
@@ -318,6 +320,7 @@ def kash_action(
318
320
  self.arg_type = arg_type
319
321
  self.uses_selection = uses_selection
320
322
  self.output_type = output_type
323
+ self.output_format = output_format
321
324
  self.interactive_input = interactive_input
322
325
  self.live_output = live_output
323
326
  self.mcp_tool = mcp_tool
@@ -397,9 +400,8 @@ def kash_action(
397
400
  context = ExecContext(action, current_runtime_settings())
398
401
 
399
402
  # Run the action.
400
- result, _, _ = run_action_with_caching(context, action_input)
401
-
402
- return result
403
+ result_with_paths = run_action_with_caching(context, action_input)
404
+ return result_with_paths.result
403
405
 
404
406
  if is_simple_func:
405
407
  # Need to convert back to a SimpleActionFunction.
@@ -1,5 +1,5 @@
1
1
  import time
2
- from dataclasses import replace
2
+ from dataclasses import dataclass, replace
3
3
  from pathlib import Path
4
4
 
5
5
  from prettyfmt import fmt_lines, fmt_path, plural
@@ -29,8 +29,10 @@ from kash.model.operations_model import Input, Operation, Source
29
29
  from kash.model.params_model import ALL_COMMON_PARAMS, GLOBAL_PARAMS, RawParamValues
30
30
  from kash.model.paths_model import StorePath
31
31
  from kash.shell.output.shell_output import PrintHooks
32
+ from kash.utils.common.s3_utils import get_s3_parent_folder, s3_sync_to_folder
32
33
  from kash.utils.common.task_stack import task_stack
33
34
  from kash.utils.common.type_utils import not_none
35
+ from kash.utils.common.url import Url, is_s3_url
34
36
  from kash.utils.errors import ContentError, InvalidOutput, get_nonfatal_exceptions
35
37
  from kash.workspaces import Selection, current_ws
36
38
 
@@ -182,7 +184,7 @@ def run_action_operation(
182
184
  this_op = replace(operation, arguments=[operation.arguments[i]])
183
185
  else:
184
186
  this_op = operation
185
- item.update_history(Source(operation=this_op, output_num=i, cacheable=action.cacheable))
187
+ item.update_source(Source(operation=this_op, output_num=i, cacheable=action.cacheable))
186
188
 
187
189
  # Override the state if appropriate (this handles marking items as transient).
188
190
  if settings.override_state:
@@ -339,20 +341,41 @@ def save_action_result(
339
341
  return result_store_paths, archived_store_paths
340
342
 
341
343
 
344
+ @dataclass(frozen=True)
345
+ class ResultWithPaths:
346
+ """
347
+ Result of an action, including the store paths of any S3 items created.
348
+ """
349
+
350
+ result: ActionResult
351
+ result_paths: list[StorePath]
352
+ archived_paths: list[StorePath]
353
+ s3_paths: list[Url]
354
+
355
+
342
356
  def run_action_with_caching(
343
357
  exec_context: ExecContext, action_input: ActionInput
344
- ) -> tuple[ActionResult, list[StorePath], list[StorePath]]:
358
+ ) -> ResultWithPaths:
345
359
  """
346
360
  Run an action, including validation, only rerunning if `rerun` requested or
347
361
  result is not already present. Returns the result, the store paths of the
348
362
  result items, and the store paths of any archived items.
349
363
 
364
+ Also handles optional S3 syncing if the input was from S3.
365
+
350
366
  Note: Mutates the input but only to add `context` to each item.
351
367
  """
352
368
  action = exec_context.action
353
369
  settings = exec_context.settings
354
370
  ws = settings.workspace
355
371
 
372
+ # If the input is from S3, we note the parent folder to copy the output back to.
373
+ s3_parent_folder = None
374
+ if exec_context.settings.sync_to_s3 and action_input.items and action_input.items[0].url:
375
+ url = action_input.items[0].url
376
+ if url and is_s3_url(url):
377
+ s3_parent_folder = get_s3_parent_folder(url)
378
+
356
379
  # Assemble the operation and validate the action input.
357
380
  operation = validate_action_input(exec_context, ws, action, action_input)
358
381
 
@@ -408,7 +431,26 @@ def run_action_with_caching(
408
431
  finally:
409
432
  action_input.clear_context()
410
433
 
411
- return result, result_store_paths, archived_store_paths
434
+ # If the action created an S3 item, we copy it back to the same S3 parent folder.
435
+ # Only do this for the first result, for simplicity.
436
+ s3_urls: list[Url] = []
437
+ if s3_parent_folder and len(result_store_paths) > 0:
438
+ log.warning(
439
+ "Source was an S3 path so syncing result S3: %s -> %s",
440
+ result_store_paths[0],
441
+ s3_parent_folder,
442
+ )
443
+ s3_urls = s3_sync_to_folder(
444
+ result_store_paths[0], s3_parent_folder, include_sidematter=True
445
+ )
446
+ log.message("Synced result to S3:\n%s", fmt_lines(s3_urls))
447
+
448
+ return ResultWithPaths(
449
+ result=result,
450
+ result_paths=result_store_paths,
451
+ archived_paths=archived_store_paths,
452
+ s3_paths=s3_urls,
453
+ )
412
454
 
413
455
 
414
456
  def run_action_with_shell_context(
@@ -486,7 +528,10 @@ def run_action_with_shell_context(
486
528
  input = prepare_action_input(*args, refetch=refetch)
487
529
 
488
530
  # Finally, run the action.
489
- result, result_store_paths, archived_store_paths = run_action_with_caching(context, input)
531
+ result_with_paths = run_action_with_caching(context, input)
532
+ result = result_with_paths.result
533
+ result_store_paths = result_with_paths.result_paths
534
+ archived_store_paths = result_with_paths.archived_paths
490
535
 
491
536
  # Implement any path operations from the output and/or select the final output
492
537
  if not internal_call:
@@ -98,9 +98,11 @@ def fetch_url_item_content(
98
98
  from kash.workspaces import current_ws
99
99
 
100
100
  ws = current_ws()
101
- if not refetch and item.title and item.description and item.body:
101
+ # We could check for description too, but many pages don't have one.
102
+ has_key_content = item.title and (not item.has_body or item.body)
103
+ if not refetch and has_key_content:
102
104
  log.info(
103
- "Already have title, description, and body, will not fetch: %s",
105
+ "Already have title so assuming metadata is up to date, will not fetch: %s",
104
106
  item.fmt_loc(),
105
107
  )
106
108
  return FetchItemResult(item, was_cached=True)
@@ -1,4 +1,5 @@
1
1
  from dataclasses import replace
2
+ from typing import Unpack
2
3
 
3
4
  from chopdiff.docs import DiffFilter, TextDoc
4
5
  from chopdiff.transforms import WindowSettings, filtered_transform
@@ -12,7 +13,7 @@ from kash.llm_utils.fuzzy_parsing import strip_markdown_fence
12
13
  from kash.llm_utils.llm_completion import llm_template_completion
13
14
  from kash.llm_utils.llm_messages import Message, MessageTemplate
14
15
  from kash.model.actions_model import LLMOptions
15
- from kash.model.items_model import Item
16
+ from kash.model.items_model import Item, ItemType, ItemUpdateOptions
16
17
  from kash.utils.errors import InvalidInput
17
18
  from kash.utils.file_utils.file_formats_model import Format
18
19
  from kash.utils.text_handling.doc_normalization import normalize_formatting
@@ -88,10 +89,11 @@ def llm_transform_str(options: LLMOptions, input_str: str, check_no_results: boo
88
89
  def llm_transform_item(
89
90
  item: Item,
90
91
  model: LLMName | None = None,
92
+ *,
91
93
  normalize: bool = True,
92
94
  strip_fence: bool = True,
93
95
  check_no_results: bool = True,
94
- format: Format | None = None,
96
+ **updates: Unpack[ItemUpdateOptions],
95
97
  ) -> Item:
96
98
  """
97
99
  Main function for running an LLM action on an item.
@@ -99,6 +101,14 @@ def llm_transform_item(
99
101
  Model may be overridden by an explicit model parameter.
100
102
  Also by default cleans up and normalizes output as Markdown.
101
103
  """
104
+ # Default to Markdown docs.
105
+ if "format" not in updates:
106
+ updates["format"] = Format.markdown
107
+ if "type" not in updates:
108
+ updates["type"] = ItemType.doc
109
+ if "body" not in updates:
110
+ updates["body"] = None
111
+
102
112
  if not item.context:
103
113
  raise InvalidInput(f"LLM actions expect a context on input item: {item}")
104
114
  action = item.context.action
@@ -112,13 +122,12 @@ def llm_transform_item(
112
122
  log.message("LLM transform from action `%s` on item: %s", action.name, item)
113
123
  log.message("LLM options: %s", action.llm_options)
114
124
 
115
- format = format or item.format or Format.markdown
116
- result_item = item.derived_copy(body=None, format=format)
125
+ result_item = item.derived_copy(**updates)
117
126
  result_str = llm_transform_str(llm_options, item.body, check_no_results=check_no_results)
118
127
  if strip_fence:
119
128
  result_str = strip_markdown_fence(result_str)
120
129
  if normalize:
121
- result_str = normalize_formatting(result_str, format=format)
130
+ result_str = normalize_formatting(result_str, format=updates["format"])
122
131
 
123
132
  result_item.body = result_str
124
133
  return result_item
@@ -102,6 +102,7 @@ def kash_runtime(
102
102
  override_state: State | None = None,
103
103
  tmp_output: bool = False,
104
104
  no_format: bool = False,
105
+ sync_to_s3: bool = False,
105
106
  ) -> RuntimeSettingsManager:
106
107
  """
107
108
  Set a specific kash execution context for a with block.
@@ -131,5 +132,6 @@ def kash_runtime(
131
132
  override_state=override_state,
132
133
  tmp_output=tmp_output,
133
134
  no_format=no_format,
135
+ sync_to_s3=sync_to_s3,
134
136
  )
135
137
  return RuntimeSettingsManager(settings=settings)