cocoindex 0.1.44__tar.gz → 0.1.46__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 (251) hide show
  1. cocoindex-0.1.46/.github/workflows/CI.yml +46 -0
  2. {cocoindex-0.1.44 → cocoindex-0.1.46}/.github/workflows/_test.yml +14 -2
  3. {cocoindex-0.1.44 → cocoindex-0.1.46}/.github/workflows/docs.yml +6 -20
  4. {cocoindex-0.1.44 → cocoindex-0.1.46}/.vscode/settings.json +3 -1
  5. {cocoindex-0.1.44 → cocoindex-0.1.46}/Cargo.lock +1 -1
  6. {cocoindex-0.1.44 → cocoindex-0.1.46}/Cargo.toml +1 -1
  7. {cocoindex-0.1.44 → cocoindex-0.1.46}/PKG-INFO +3 -1
  8. {cocoindex-0.1.44 → cocoindex-0.1.46}/docs/docs/core/flow_def.mdx +1 -1
  9. {cocoindex-0.1.44 → cocoindex-0.1.46}/docs/docs/core/settings.mdx +1 -1
  10. {cocoindex-0.1.44 → cocoindex-0.1.46}/docs/docs/ops/functions.md +11 -0
  11. {cocoindex-0.1.44 → cocoindex-0.1.46}/docs/docs/ops/sources.md +1 -0
  12. {cocoindex-0.1.44 → cocoindex-0.1.46}/docs/docs/ops/storages.md +31 -3
  13. {cocoindex-0.1.44 → cocoindex-0.1.46}/docs/docusaurus.config.ts +5 -0
  14. {cocoindex-0.1.44 → cocoindex-0.1.46}/docs/package.json +4 -4
  15. {cocoindex-0.1.44 → cocoindex-0.1.46}/docs/yarn.lock +1477 -1712
  16. cocoindex-0.1.46/examples/amazon_s3_embedding/main.py +120 -0
  17. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/code_embedding/main.py +53 -26
  18. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/docs_to_knowledge_graph/main.py +82 -37
  19. cocoindex-0.1.46/examples/fastapi_server_docker/.env +5 -0
  20. cocoindex-0.1.46/examples/fastapi_server_docker/README.md +65 -0
  21. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/fastapi_server_docker/compose.yaml +3 -1
  22. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/fastapi_server_docker/dockerfile +6 -0
  23. cocoindex-0.1.46/examples/fastapi_server_docker/main.py +112 -0
  24. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/fastapi_server_docker/requirements.txt +3 -1
  25. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/gdrive_text_embedding/main.py +50 -25
  26. cocoindex-0.1.46/examples/image_search/README.md +59 -0
  27. cocoindex-0.1.46/examples/image_search/main.py +130 -0
  28. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/image_search/pyproject.toml +7 -1
  29. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/manuals_llm_extraction/main.py +30 -11
  30. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/pdf_embedding/main.py +43 -21
  31. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/product_recommendation/main.py +86 -42
  32. cocoindex-0.1.46/examples/text_embedding/Text_Embedding.ipynb +408 -0
  33. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/text_embedding/main.py +47 -24
  34. cocoindex-0.1.46/examples/text_embedding/markdown_files/1810.04805v2.md +530 -0
  35. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/text_embedding_qdrant/main.py +27 -25
  36. {cocoindex-0.1.44 → cocoindex-0.1.46}/pyproject.toml +14 -2
  37. {cocoindex-0.1.44 → cocoindex-0.1.46}/python/cocoindex/__init__.py +2 -1
  38. {cocoindex-0.1.44 → cocoindex-0.1.46}/python/cocoindex/auth_registry.py +7 -3
  39. {cocoindex-0.1.44 → cocoindex-0.1.46}/python/cocoindex/cli.py +185 -66
  40. {cocoindex-0.1.44 → cocoindex-0.1.46}/python/cocoindex/convert.py +93 -52
  41. {cocoindex-0.1.44 → cocoindex-0.1.46}/python/cocoindex/flow.py +302 -131
  42. {cocoindex-0.1.44 → cocoindex-0.1.46}/python/cocoindex/functions.py +17 -4
  43. {cocoindex-0.1.44 → cocoindex-0.1.46}/python/cocoindex/index.py +6 -0
  44. {cocoindex-0.1.44 → cocoindex-0.1.46}/python/cocoindex/lib.py +14 -9
  45. {cocoindex-0.1.44 → cocoindex-0.1.46}/python/cocoindex/llm.py +4 -0
  46. {cocoindex-0.1.44 → cocoindex-0.1.46}/python/cocoindex/op.py +126 -61
  47. {cocoindex-0.1.44 → cocoindex-0.1.46}/python/cocoindex/query.py +40 -17
  48. {cocoindex-0.1.44 → cocoindex-0.1.46}/python/cocoindex/runtime.py +9 -4
  49. {cocoindex-0.1.44 → cocoindex-0.1.46}/python/cocoindex/setting.py +35 -12
  50. {cocoindex-0.1.44 → cocoindex-0.1.46}/python/cocoindex/setup.py +7 -3
  51. {cocoindex-0.1.44 → cocoindex-0.1.46}/python/cocoindex/sources.py +3 -1
  52. {cocoindex-0.1.44 → cocoindex-0.1.46}/python/cocoindex/storages.py +50 -7
  53. {cocoindex-0.1.44 → cocoindex-0.1.46}/python/cocoindex/tests/test_convert.py +255 -63
  54. {cocoindex-0.1.44 → cocoindex-0.1.46}/python/cocoindex/typing.py +116 -70
  55. {cocoindex-0.1.44 → cocoindex-0.1.46}/python/cocoindex/utils.py +10 -2
  56. cocoindex-0.1.46/ruff.toml +5 -0
  57. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/base/schema.rs +6 -6
  58. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/base/spec.rs +10 -0
  59. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/base/value.rs +21 -0
  60. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/builder/analyzer.rs +3 -2
  61. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/builder/plan.rs +2 -1
  62. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/execution/db_tracking.rs +76 -7
  63. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/execution/row_indexer.rs +78 -49
  64. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/ops/factory_bases.rs +45 -7
  65. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/ops/functions/split_recursively.rs +320 -104
  66. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/ops/interface.rs +23 -3
  67. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/ops/registration.rs +3 -0
  68. cocoindex-0.1.46/src/ops/storages/kuzu.rs +1119 -0
  69. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/ops/storages/mod.rs +3 -1
  70. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/ops/storages/neo4j.rs +187 -438
  71. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/ops/storages/postgres.rs +139 -283
  72. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/ops/storages/qdrant.rs +4 -3
  73. cocoindex-0.1.46/src/ops/storages/shared/mod.rs +2 -0
  74. cocoindex-0.1.46/src/ops/storages/shared/property_graph.rs +562 -0
  75. cocoindex-0.1.46/src/ops/storages/shared/table_columns.rs +185 -0
  76. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/prelude.rs +2 -2
  77. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/service/error.rs +4 -0
  78. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/setup/driver.rs +26 -9
  79. cocoindex-0.1.44/.github/workflows/CI.yml +0 -51
  80. cocoindex-0.1.44/examples/amazon_s3_embedding/main.py +0 -77
  81. cocoindex-0.1.44/examples/fastapi_server_docker/.env +0 -1
  82. cocoindex-0.1.44/examples/fastapi_server_docker/README.md +0 -10
  83. cocoindex-0.1.44/examples/fastapi_server_docker/main.py +0 -27
  84. cocoindex-0.1.44/examples/fastapi_server_docker/sample_code/main.py +0 -113
  85. cocoindex-0.1.44/examples/fastapi_server_docker/src/cocoindex_funs.py +0 -45
  86. cocoindex-0.1.44/examples/image_search/README.md +0 -60
  87. cocoindex-0.1.44/examples/image_search/main.py +0 -130
  88. cocoindex-0.1.44/examples/text_embedding/Text_Embedding.ipynb +0 -392
  89. cocoindex-0.1.44/src/ops/storages/spec.rs +0 -50
  90. {cocoindex-0.1.44 → cocoindex-0.1.46}/.cargo/config.toml +0 -0
  91. {cocoindex-0.1.44 → cocoindex-0.1.46}/.env.lib_debug +0 -0
  92. {cocoindex-0.1.44 → cocoindex-0.1.46}/.github/ISSUE_TEMPLATE//360/237/220/233-bug-report.md" +0 -0
  93. {cocoindex-0.1.44 → cocoindex-0.1.46}/.github/ISSUE_TEMPLATE//360/237/222/241-feature-request.md" +0 -0
  94. {cocoindex-0.1.44 → cocoindex-0.1.46}/.github/scripts/update_version.sh +0 -0
  95. {cocoindex-0.1.44 → cocoindex-0.1.46}/.github/workflows/release.yml +0 -0
  96. {cocoindex-0.1.44 → cocoindex-0.1.46}/.gitignore +0 -0
  97. {cocoindex-0.1.44 → cocoindex-0.1.46}/CODE_OF_CONDUCT.md +0 -0
  98. {cocoindex-0.1.44 → cocoindex-0.1.46}/CONTRIBUTING.md +0 -0
  99. {cocoindex-0.1.44 → cocoindex-0.1.46}/LICENSE +0 -0
  100. {cocoindex-0.1.44 → cocoindex-0.1.46}/README.md +0 -0
  101. {cocoindex-0.1.44 → cocoindex-0.1.46}/dev/neo4j.yaml +0 -0
  102. {cocoindex-0.1.44 → cocoindex-0.1.46}/dev/postgres.yaml +0 -0
  103. {cocoindex-0.1.44 → cocoindex-0.1.46}/docs/.gitignore +0 -0
  104. {cocoindex-0.1.44 → cocoindex-0.1.46}/docs/README.md +0 -0
  105. {cocoindex-0.1.44 → cocoindex-0.1.46}/docs/docs/about/community.md +0 -0
  106. {cocoindex-0.1.44 → cocoindex-0.1.46}/docs/docs/about/contributing.md +0 -0
  107. {cocoindex-0.1.44 → cocoindex-0.1.46}/docs/docs/ai/llm.mdx +0 -0
  108. {cocoindex-0.1.44 → cocoindex-0.1.46}/docs/docs/core/basics.md +0 -0
  109. {cocoindex-0.1.44 → cocoindex-0.1.46}/docs/docs/core/cli.mdx +0 -0
  110. {cocoindex-0.1.44 → cocoindex-0.1.46}/docs/docs/core/custom_function.mdx +0 -0
  111. {cocoindex-0.1.44 → cocoindex-0.1.46}/docs/docs/core/data_example.svg +0 -0
  112. {cocoindex-0.1.44 → cocoindex-0.1.46}/docs/docs/core/data_types.mdx +0 -0
  113. {cocoindex-0.1.44 → cocoindex-0.1.46}/docs/docs/core/flow_example.svg +0 -0
  114. {cocoindex-0.1.44 → cocoindex-0.1.46}/docs/docs/core/flow_methods.mdx +0 -0
  115. {cocoindex-0.1.44 → cocoindex-0.1.46}/docs/docs/getting_started/installation.md +0 -0
  116. {cocoindex-0.1.44 → cocoindex-0.1.46}/docs/docs/getting_started/markdown_files.zip +0 -0
  117. {cocoindex-0.1.44 → cocoindex-0.1.46}/docs/docs/getting_started/overview.md +0 -0
  118. {cocoindex-0.1.44 → cocoindex-0.1.46}/docs/docs/getting_started/quickstart.md +0 -0
  119. {cocoindex-0.1.44 → cocoindex-0.1.46}/docs/docs/query.mdx +0 -0
  120. {cocoindex-0.1.44 → cocoindex-0.1.46}/docs/sidebars.ts +0 -0
  121. {cocoindex-0.1.44 → cocoindex-0.1.46}/docs/src/components/HomepageFeatures/index.tsx +0 -0
  122. {cocoindex-0.1.44 → cocoindex-0.1.46}/docs/src/components/HomepageFeatures/styles.module.css +0 -0
  123. {cocoindex-0.1.44 → cocoindex-0.1.46}/docs/src/css/custom.css +0 -0
  124. {cocoindex-0.1.44 → cocoindex-0.1.46}/docs/src/theme/Root.js +0 -0
  125. {cocoindex-0.1.44 → cocoindex-0.1.46}/docs/static/.nojekyll +0 -0
  126. {cocoindex-0.1.44 → cocoindex-0.1.46}/docs/static/img/docusaurus.png +0 -0
  127. {cocoindex-0.1.44 → cocoindex-0.1.46}/docs/static/img/favicon.ico +0 -0
  128. {cocoindex-0.1.44 → cocoindex-0.1.46}/docs/static/img/icon.svg +0 -0
  129. {cocoindex-0.1.44 → cocoindex-0.1.46}/docs/static/robots.txt +0 -0
  130. {cocoindex-0.1.44 → cocoindex-0.1.46}/docs/tsconfig.json +0 -0
  131. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/amazon_s3_embedding/.env.example +0 -0
  132. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/amazon_s3_embedding/.gitignore +0 -0
  133. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/amazon_s3_embedding/README.md +0 -0
  134. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/amazon_s3_embedding/pyproject.toml +0 -0
  135. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/code_embedding/.env +0 -0
  136. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/code_embedding/README.md +0 -0
  137. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/code_embedding/pyproject.toml +0 -0
  138. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/docs_to_knowledge_graph/.env +0 -0
  139. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/docs_to_knowledge_graph/README.md +0 -0
  140. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/docs_to_knowledge_graph/pyproject.toml +0 -0
  141. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/fastapi_server_docker/.dockerignore +0 -0
  142. {cocoindex-0.1.44/examples/text_embedding/markdown_files → cocoindex-0.1.46/examples/fastapi_server_docker/files}/1810.04805v2.md +0 -0
  143. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/gdrive_text_embedding/.env.example +0 -0
  144. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/gdrive_text_embedding/.gitignore +0 -0
  145. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/gdrive_text_embedding/README.md +0 -0
  146. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/gdrive_text_embedding/pyproject.toml +0 -0
  147. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/image_search/.env +0 -0
  148. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/image_search/frontend/.gitignore +0 -0
  149. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/image_search/frontend/index.html +0 -0
  150. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/image_search/frontend/package-lock.json +0 -0
  151. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/image_search/frontend/package.json +0 -0
  152. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/image_search/frontend/src/App.jsx +0 -0
  153. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/image_search/frontend/src/main.jsx +0 -0
  154. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/image_search/frontend/src/style.css +0 -0
  155. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/image_search/frontend/vite.config.js +0 -0
  156. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/image_search/img/cat1.jpeg +0 -0
  157. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/image_search/img/dog1.jpeg +0 -0
  158. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/image_search/img/elephant1.jpg +0 -0
  159. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/image_search/img/giraffe.jpg +0 -0
  160. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/image_search/requirements.txt +0 -0
  161. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/manuals_llm_extraction/.env +0 -0
  162. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/manuals_llm_extraction/README.md +0 -0
  163. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/manuals_llm_extraction/manuals/array.pdf +0 -0
  164. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/manuals_llm_extraction/manuals/base64.pdf +0 -0
  165. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/manuals_llm_extraction/manuals/copy.pdf +0 -0
  166. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/manuals_llm_extraction/manuals/glob.pdf +0 -0
  167. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/manuals_llm_extraction/pyproject.toml +0 -0
  168. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/pdf_embedding/.env +0 -0
  169. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/pdf_embedding/README.md +0 -0
  170. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/pdf_embedding/pdf_files/1706.03762v7.pdf +0 -0
  171. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/pdf_embedding/pdf_files/1810.04805v2.pdf +0 -0
  172. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/pdf_embedding/pdf_files/rfc8259.pdf +0 -0
  173. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/pdf_embedding/pyproject.toml +0 -0
  174. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/product_recommendation/.env +0 -0
  175. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/product_recommendation/README.md +0 -0
  176. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/product_recommendation/img/cocoinsight.png +0 -0
  177. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/product_recommendation/img/neo4j.png +0 -0
  178. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/product_recommendation/products/p1.json +0 -0
  179. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/product_recommendation/products/p2.json +0 -0
  180. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/product_recommendation/products/p3.json +0 -0
  181. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/product_recommendation/products/p4.json +0 -0
  182. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/product_recommendation/products/p5.json +0 -0
  183. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/product_recommendation/products/p6.json +0 -0
  184. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/product_recommendation/products/p7.json +0 -0
  185. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/product_recommendation/products/p8.json +0 -0
  186. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/product_recommendation/products/p9.json +0 -0
  187. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/product_recommendation/pyproject.toml +0 -0
  188. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/text_embedding/.env +0 -0
  189. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/text_embedding/README.md +0 -0
  190. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/text_embedding/markdown_files/1706.03762v7.md +0 -0
  191. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/text_embedding/markdown_files/rfc8259.md +0 -0
  192. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/text_embedding/pyproject.toml +0 -0
  193. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/text_embedding_qdrant/.env +0 -0
  194. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/text_embedding_qdrant/README.md +0 -0
  195. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/text_embedding_qdrant/markdown_files/rfc8259.md +0 -0
  196. {cocoindex-0.1.44 → cocoindex-0.1.46}/examples/text_embedding_qdrant/pyproject.toml +0 -0
  197. {cocoindex-0.1.44 → cocoindex-0.1.46}/python/cocoindex/py.typed +0 -0
  198. {cocoindex-0.1.44 → cocoindex-0.1.46}/python/cocoindex/tests/__init__.py +0 -0
  199. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/base/duration.rs +0 -0
  200. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/base/field_attrs.rs +0 -0
  201. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/base/json_schema.rs +0 -0
  202. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/base/mod.rs +0 -0
  203. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/builder/analyzed_flow.rs +0 -0
  204. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/builder/flow_builder.rs +0 -0
  205. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/builder/mod.rs +0 -0
  206. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/execution/db_tracking_setup.rs +0 -0
  207. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/execution/dumper.rs +0 -0
  208. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/execution/evaluator.rs +0 -0
  209. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/execution/indexing_status.rs +0 -0
  210. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/execution/live_updater.rs +0 -0
  211. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/execution/memoization.rs +0 -0
  212. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/execution/mod.rs +0 -0
  213. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/execution/query.rs +0 -0
  214. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/execution/source_indexer.rs +0 -0
  215. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/execution/stats.rs +0 -0
  216. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/lib.rs +0 -0
  217. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/lib_context.rs +0 -0
  218. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/llm/anthropic.rs +0 -0
  219. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/llm/gemini.rs +0 -0
  220. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/llm/mod.rs +0 -0
  221. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/llm/ollama.rs +0 -0
  222. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/llm/openai.rs +0 -0
  223. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/ops/functions/extract_by_llm.rs +0 -0
  224. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/ops/functions/mod.rs +0 -0
  225. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/ops/functions/parse_json.rs +0 -0
  226. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/ops/mod.rs +0 -0
  227. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/ops/py_factory.rs +0 -0
  228. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/ops/registry.rs +0 -0
  229. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/ops/sdk.rs +0 -0
  230. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/ops/sources/amazon_s3.rs +0 -0
  231. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/ops/sources/google_drive.rs +0 -0
  232. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/ops/sources/local_file.rs +0 -0
  233. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/ops/sources/mod.rs +0 -0
  234. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/py/convert.rs +0 -0
  235. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/py/mod.rs +0 -0
  236. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/server.rs +0 -0
  237. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/service/flows.rs +0 -0
  238. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/service/mod.rs +0 -0
  239. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/service/search.rs +0 -0
  240. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/settings.rs +0 -0
  241. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/setup/auth_registry.rs +0 -0
  242. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/setup/components.rs +0 -0
  243. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/setup/db_metadata.rs +0 -0
  244. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/setup/mod.rs +0 -0
  245. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/setup/states.rs +0 -0
  246. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/utils/db.rs +0 -0
  247. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/utils/fingerprint.rs +0 -0
  248. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/utils/immutable.rs +0 -0
  249. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/utils/mod.rs +0 -0
  250. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/utils/retryable.rs +0 -0
  251. {cocoindex-0.1.44 → cocoindex-0.1.46}/src/utils/yaml_ser.rs +0 -0
@@ -0,0 +1,46 @@
1
+ # This file is autogenerated by maturin v1.8.1
2
+ # To update, run
3
+ #
4
+ # maturin generate-ci github
5
+ #
6
+ name: CI
7
+
8
+ on:
9
+ pull_request:
10
+ branches: [main]
11
+ paths:
12
+ - src/**
13
+ - python/**
14
+ - "*.toml"
15
+ - ".github/workflows/*.yml"
16
+ push:
17
+ branches: [main]
18
+ paths:
19
+ - src/**
20
+ - python/**
21
+ - "*.toml"
22
+ - ".github/workflows/*.yml"
23
+ workflow_dispatch:
24
+
25
+ permissions:
26
+ contents: read
27
+
28
+ jobs:
29
+ format-check:
30
+ name: Check Python formatting
31
+ runs-on: ubuntu-latest
32
+ steps:
33
+ - uses: actions/checkout@v4
34
+ - uses: actions/setup-python@v5
35
+ with:
36
+ python-version: 3.11
37
+ - name: Install Ruff
38
+ run: |
39
+ pip install ruff
40
+ - name: Check Python formatting
41
+ run: |
42
+ ruff format --check .
43
+
44
+ test:
45
+ name: Run test
46
+ uses: ./.github/workflows/_test.yml
@@ -36,10 +36,22 @@ jobs:
36
36
  key: ${{ runner.os }}-pythonenv-${{ matrix.python-version }}-${{ hashFiles('pyproject.toml') }}
37
37
  restore-keys: |
38
38
  ${{ runner.os }}-pythonenv-${{ matrix.python-version }}-
39
- - name: Python build & test
39
+ - name: Setup venv
40
40
  run: |
41
41
  python -m venv .venv
42
+ - name: Install Python toolchains
43
+ run: |
44
+ source .venv/bin/activate
45
+ pip install maturin pytest mypy
46
+ - name: Python build
47
+ run: |
42
48
  source .venv/bin/activate
43
- pip install maturin pytest
44
49
  maturin develop
50
+ - name: Python type check (mypy)
51
+ run: |
52
+ source .venv/bin/activate
53
+ mypy python
54
+ - name: Python tests
55
+ run: |
56
+ source .venv/bin/activate
45
57
  pytest python/cocoindex/tests
@@ -22,22 +22,15 @@ jobs:
22
22
  runs-on: ubuntu-latest
23
23
  steps:
24
24
  - uses: actions/checkout@v4
25
- with:
26
- fetch-depth: 0
27
- sparse-checkout: docs
28
- path: src-staging
29
- - name: Move docs
30
- run: |
31
- shopt -s dotglob
32
- mv src-staging/docs/* .
33
25
  - uses: actions/setup-node@v4
34
26
  with:
35
27
  node-version: 18
36
28
  cache: yarn
29
+ cache-dependency-path: docs/yarn.lock
37
30
  - name: Install dependencies
38
- run: yarn install --frozen-lockfile
31
+ run: yarn --cwd docs install --frozen-lockfile
39
32
  - name: Test build website
40
- run: yarn build
33
+ run: yarn --cwd docs build
41
34
 
42
35
  deploy-precheck:
43
36
  if: ${{ github.event_name != 'pull_request' }}
@@ -59,18 +52,11 @@ jobs:
59
52
  environment: docs-release
60
53
  steps:
61
54
  - uses: actions/checkout@v4
62
- with:
63
- fetch-depth: 0
64
- sparse-checkout: docs
65
- path: src-staging
66
- - name: Move docs
67
- run: |
68
- shopt -s dotglob
69
- mv src-staging/docs/* .
70
55
  - uses: actions/setup-node@v4
71
56
  with:
72
57
  node-version: 18
73
58
  cache: yarn
59
+ cache-dependency-path: docs/yarn.lock
74
60
  - uses: webfactory/ssh-agent@v0.5.0
75
61
  with:
76
62
  ssh-private-key: ${{ secrets.GH_PAGES_DEPLOY }}
@@ -84,5 +70,5 @@ jobs:
84
70
  export COCOINDEX_DOCS_ALGOLIA_API_KEY=${{ vars.COCOINDEX_DOCS_ALGOLIA_API_KEY }}
85
71
  git config --global user.email "${{ vars.COCOINDEX_DOCS_DEPLOY_USER_EMAIL }}"
86
72
  git config --global user.name "${{ vars.COCOINDEX_DOCS_DEPLOY_USER_NAME }}"
87
- yarn install --frozen-lockfile
88
- yarn deploy
73
+ yarn --cwd docs install --frozen-lockfile
74
+ yarn --cwd docs deploy
@@ -3,5 +3,7 @@
3
3
  "cocoindex",
4
4
  "reindexing",
5
5
  "timedelta"
6
- ]
6
+ ],
7
+ "editor.formatOnSave": true,
8
+ "python.formatting.provider": "ruff"
7
9
  }
@@ -993,7 +993,7 @@ dependencies = [
993
993
 
994
994
  [[package]]
995
995
  name = "cocoindex"
996
- version = "0.1.44"
996
+ version = "0.1.46"
997
997
  dependencies = [
998
998
  "anyhow",
999
999
  "async-openai",
@@ -2,7 +2,7 @@
2
2
  name = "cocoindex"
3
3
  # Version used for local development is always higher than others to take precedence.
4
4
  # Will be overridden for specific release versions.
5
- version = "0.1.44"
5
+ version = "0.1.46"
6
6
  edition = "2024"
7
7
 
8
8
  [profile.release]
@@ -1,12 +1,14 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: cocoindex
3
- Version: 0.1.44
3
+ Version: 0.1.46
4
4
  Requires-Dist: sentence-transformers>=3.3.1
5
5
  Requires-Dist: click>=8.1.8
6
6
  Requires-Dist: rich>=14.0.0
7
7
  Requires-Dist: python-dotenv>=1.1.0
8
8
  Requires-Dist: pytest ; extra == 'test'
9
+ Requires-Dist: ruff ; extra == 'dev'
9
10
  Provides-Extra: test
11
+ Provides-Extra: dev
10
12
  License-File: LICENSE
11
13
  Summary: With CocoIndex, users declare the transformation, CocoIndex creates & maintains an index, and keeps the derived index up to date based on source update, with minimal computation and changes.
12
14
  Author-email: CocoIndex <cocoindex.io@gmail.com>
@@ -348,7 +348,7 @@ It will use `Staging__doc_embeddings` as the collection name if the current app
348
348
  Most time a target storage is created by calling `export()` method on a collector, and this `export()` call comes with configurations needed for the target storage, e.g. options for storage indexes.
349
349
  Occasionally, you may need to specify some configurations for target storage out of the context of any specific data collector.
350
350
 
351
- For example, for graph database targets like `Neo4j`, you may have a data collector to export data to Neo4j relationships, which will create nodes referenced by various relationships in turn.
351
+ For example, for graph database targets like `Neo4j` and `Kuzu`, you may have a data collector to export data to relationships, which will create nodes referenced by various relationships in turn.
352
352
  These nodes don't directly come from any specific data collector (consider relationships from different data collectors may share the same nodes).
353
353
  To specify configurations for these nodes, you can *declare* spec for related node labels.
354
354
 
@@ -6,7 +6,7 @@ description: Provide settings for CocoIndex, e.g. database connection, app names
6
6
  import Tabs from '@theme/Tabs';
7
7
  import TabItem from '@theme/TabItem';
8
8
 
9
- # CocoIndex Settings
9
+ # CocoIndex Setting
10
10
 
11
11
  Certain settings need to be provided for CocoIndex to work, e.g. database connections, app namespace, etc.
12
12
 
@@ -26,6 +26,17 @@ Input data:
26
26
 
27
27
  * `text` (type: `str`, required): The text to split.
28
28
  * `chunk_size` (type: `int`, required): The maximum size of each chunk, in bytes.
29
+ * `min_chunk_size` (type: `int`, optional): The minimum size of each chunk, in bytes. If not provided, default to `chunk_size / 2`.
30
+
31
+ :::note
32
+
33
+ `SplitRecursively` will do its best to make the output chunks sized between `min_chunk_size` and `chunk_size`.
34
+ However, it's possible that some chunks are smaller than `min_chunk_size` or larger than `chunk_size` in rare cases, e.g. too short input text, or non-splittable large text.
35
+
36
+ Please avoid setting `min_chunk_size` to a value too close to `chunk_size`, to leave more rooms for the function to plan the optimal chunking.
37
+
38
+ :::
39
+
29
40
  * `chunk_overlap` (type: `int`, optional): The maximum overlap size between adjacent chunks, in bytes.
30
41
  * `language` (type: `str`, optional): The language of the document.
31
42
  Can be a langauge name (e.g. `Python`, `Javascript`, `Markdown`) or a file extension (e.g. `.py`, `.js`, `.md`).
@@ -95,6 +95,7 @@ This is how to setup:
95
95
  "Service": "s3.amazonaws.com"
96
96
  },
97
97
  "Resource": "${SQS_QUEUE_ARN}",
98
+ "Action": "SQS:SendMessage",
98
99
  "Condition": {
99
100
  "ArnLike": {
100
101
  "aws:SourceArn": "${S3_BUCKET_ARN}"
@@ -391,6 +391,12 @@ graph TD
391
391
  classDef node font-size:8pt,text-align:left,stroke-width:2;
392
392
  ```
393
393
 
394
+ #### Examples
395
+
396
+ You can find end-to-end examples fitting into any of supported property graphs in the following directories:
397
+ * [examples/docs_to_knowledge_graph](https://github.com/cocoindex-io/cocoindex/tree/main/examples/docs_to_knowledge_graph)
398
+ * [examples/product_recommendation](https://github.com/cocoindex-io/cocoindex/tree/main/examples/product_recommendation)
399
+
394
400
  ### Neo4j
395
401
 
396
402
  If you don't have a Neo4j database, you can start a Neo4j database using our docker compose config:
@@ -407,14 +413,14 @@ Please read and agree the license before starting the instance.
407
413
 
408
414
  :::
409
415
 
410
- The `Neo4j` storage exports each row as a relationship to Neo4j Knowledge Graph. The spec takes the following fields:
416
+ The `Neo4j` target spec takes the following fields:
411
417
 
412
418
  * `connection` (type: [auth reference](../core/flow_def#auth-registry) to `Neo4jConnectionSpec`): The connection to the Neo4j database. `Neo4jConnectionSpec` has the following fields:
413
419
  * `url` (type: `str`): The URI of the Neo4j database to use as the internal storage, e.g. `bolt://localhost:7687`.
414
420
  * `user` (type: `str`): Username for the Neo4j database.
415
421
  * `password` (type: `str`): Password for the Neo4j database.
416
422
  * `db` (type: `str`, optional): The name of the Neo4j database to use as the internal storage, e.g. `neo4j`.
417
- * `mapping` (type: `NodeMapping | RelationshipMapping`): The mapping from collected row to nodes or relationships of the graph. 2 variations are supported:
423
+ * `mapping` (type: `Nodes | Relationships`): The mapping from collected row to nodes or relationships of the graph. For either [nodes to export](#nodes-to-export) or [relationships to export](#relationships-to-export).
418
424
 
419
425
  Neo4j also provides a declaration spec `Neo4jDeclaration`, to configure indexing options for nodes only referenced by relationships. It has the following fields:
420
426
 
@@ -424,4 +430,26 @@ Neo4j also provides a declaration spec `Neo4jDeclaration`, to configure indexing
424
430
  * `primary_key_fields` (required)
425
431
  * `vector_indexes` (optional)
426
432
 
427
- You can find an end-to-end example [here](https://github.com/cocoindex-io/cocoindex/tree/main/examples/docs_to_knowledge_graph).
433
+ ### Kuzu
434
+
435
+ CocoIndex supports talking to Kuzu through its [API server](https://github.com/kuzudb/api-server).
436
+ You can bring up a Kuzu API server locally by running:
437
+
438
+ ```bash
439
+ KUZU_DB_DIR=$HOME/.kuzudb
440
+ KUZU_PORT=8123
441
+ docker run -d --name kuzu -p ${KUZU_PORT}:8000 -v ${KUZU_DB_DIR}:/database kuzudb/api-server:latest
442
+ ```
443
+
444
+ The `Kuzu` target spec takes the following fields:
445
+
446
+ * `connection` (type: [auth reference](../core/flow_def#auth-registry) to `KuzuConnectionSpec`): The connection to the Kuzu database. `KuzuConnectionSpec` has the following fields:
447
+ * `api_server_url` (type: `str`): The URL of the Kuzu API server, e.g. `http://localhost:8123`.
448
+ * `mapping` (type: `Nodes | Relationships`): The mapping from collected row to nodes or relationships of the graph. For either [nodes to export](#nodes-to-export) or [relationships to export](#relationships-to-export).
449
+
450
+ Kuzu also provides a declaration spec `KuzuDeclaration`, to configure indexing options for nodes only referenced by relationships. It has the following fields:
451
+
452
+ * `connection` (type: auth reference to `KuzuConnectionSpec`)
453
+ * Fields for [nodes to declare](#declare-extra-node-labels), including
454
+ * `nodes_label` (required)
455
+ * `primary_key_fields` (required)
@@ -86,6 +86,11 @@ const config: Config = {
86
86
  // Replace with your project's social card
87
87
  image: 'img/social-card.jpg',
88
88
  metadata: [{ name: 'description', content: 'Official documentation for CocoIndex - Learn how to use CocoIndex to build robust data indexing pipelines for AI applications. Comprehensive guides, API references, and best practices for implementing efficient data processing workflows.' }],
89
+ colorMode: {
90
+ defaultMode: 'light',
91
+ disableSwitch: false,
92
+ respectPrefersColorScheme: true,
93
+ },
89
94
  navbar: {
90
95
  title: 'CocoIndex',
91
96
  logo: {
@@ -15,10 +15,10 @@
15
15
  "typecheck": "tsc"
16
16
  },
17
17
  "dependencies": {
18
- "@docusaurus/core": "3.7.0",
19
- "@docusaurus/plugin-client-redirects": "^3.7.0",
20
- "@docusaurus/preset-classic": "3.7.0",
21
- "@docusaurus/theme-mermaid": "^3.7.0",
18
+ "@docusaurus/core": "^3.8.0",
19
+ "@docusaurus/plugin-client-redirects": "^3.8.0",
20
+ "@docusaurus/preset-classic": "^3.8.0",
21
+ "@docusaurus/theme-mermaid": "^3.8.0",
22
22
  "@mdx-js/react": "^3.0.0",
23
23
  "clsx": "^2.0.0",
24
24
  "mixpanel-browser": "^2.59.0",