trustgraph-flow 1.2.3__tar.gz → 1.2.4__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 (283) hide show
  1. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/PKG-INFO +1 -1
  2. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/agent/mcp_tool/service.py +8 -4
  3. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/agent/react/agent_manager.py +7 -8
  4. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/agent/react/service.py +18 -18
  5. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/agent/react/tools.py +9 -5
  6. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/chunking/recursive/chunker.py +8 -4
  7. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/chunking/token/chunker.py +8 -4
  8. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/config/service/config.py +6 -1
  9. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/config/service/flow.py +6 -2
  10. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/config/service/service.py +9 -4
  11. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/cores/knowledge.py +21 -17
  12. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/cores/service.py +10 -6
  13. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/decoding/mistral_ocr/processor.py +14 -10
  14. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/decoding/pdf/pdf_decoder.py +9 -5
  15. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/direct/milvus_doc_embeddings.py +7 -4
  16. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/direct/milvus_graph_embeddings.py +7 -4
  17. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/direct/milvus_object_embeddings.py +7 -4
  18. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/embeddings/document_embeddings/embeddings.py +7 -3
  19. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/embeddings/fastembed/processor.py +6 -1
  20. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/embeddings/graph_embeddings/embeddings.py +7 -3
  21. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/external/wikipedia/service.py +4 -1
  22. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/extract/kg/agent/extract.py +13 -9
  23. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/extract/kg/definitions/extract.py +10 -6
  24. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/extract/kg/relationships/extract.py +10 -6
  25. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/extract/kg/topics/extract.py +7 -3
  26. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/extract/object/row/extract.py +9 -5
  27. trustgraph_flow-1.2.4/trustgraph/flow_version.py +1 -0
  28. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/config/receiver.py +11 -8
  29. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/dispatch/core_export.py +5 -1
  30. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/dispatch/core_import.py +6 -2
  31. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/dispatch/document_embeddings_export.py +5 -1
  32. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/dispatch/document_load.py +5 -1
  33. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/dispatch/entity_contexts_export.py +5 -1
  34. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/dispatch/graph_embeddings_export.py +5 -1
  35. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/dispatch/manager.py +6 -2
  36. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/dispatch/mux.py +7 -3
  37. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/dispatch/requestor.py +1 -1
  38. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/dispatch/text_load.py +5 -1
  39. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/dispatch/triples_export.py +5 -1
  40. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/endpoint/constant_endpoint.py +1 -1
  41. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/endpoint/metrics.py +1 -1
  42. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/endpoint/socket.py +6 -6
  43. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/endpoint/stream_endpoint.py +1 -1
  44. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/endpoint/variable_endpoint.py +1 -1
  45. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/librarian/blob_store.py +9 -5
  46. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/librarian/librarian.py +22 -18
  47. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/librarian/service.py +14 -10
  48. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/metering/counter.py +9 -5
  49. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/model/text_completion/azure/llm.py +11 -7
  50. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/model/text_completion/azure_openai/llm.py +11 -7
  51. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/model/text_completion/claude/llm.py +9 -5
  52. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/model/text_completion/cohere/llm.py +9 -5
  53. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/model/text_completion/googleaistudio/llm.py +10 -7
  54. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/model/text_completion/llamafile/llm.py +9 -5
  55. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/model/text_completion/lmstudio/llm.py +11 -7
  56. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/model/text_completion/mistral/llm.py +9 -5
  57. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/model/text_completion/ollama/llm.py +7 -3
  58. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/model/text_completion/openai/llm.py +9 -5
  59. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/model/text_completion/tgi/llm.py +10 -7
  60. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/model/text_completion/vllm/llm.py +10 -7
  61. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/processing/processing.py +13 -10
  62. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/prompt/template/service.py +23 -19
  63. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/query/doc_embeddings/milvus/service.py +6 -1
  64. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/query/doc_embeddings/pinecone/service.py +8 -4
  65. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/query/doc_embeddings/qdrant/service.py +6 -1
  66. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/query/graph_embeddings/milvus/service.py +7 -4
  67. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/query/graph_embeddings/pinecone/service.py +8 -4
  68. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/query/graph_embeddings/qdrant/service.py +7 -4
  69. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/query/triples/cassandra/service.py +6 -1
  70. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/query/triples/falkordb/service.py +6 -1
  71. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/query/triples/memgraph/service.py +6 -3
  72. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/query/triples/neo4j/service.py +6 -1
  73. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/retrieval/document_rag/document_rag.py +15 -11
  74. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/retrieval/document_rag/rag.py +8 -4
  75. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/retrieval/graph_rag/graph_rag.py +19 -15
  76. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/retrieval/graph_rag/rag.py +8 -4
  77. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/rev_gateway/service.py +7 -7
  78. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/doc_embeddings/pinecone/write.py +6 -2
  79. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/doc_embeddings/qdrant/write.py +5 -1
  80. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/graph_embeddings/pinecone/write.py +6 -2
  81. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/graph_embeddings/qdrant/write.py +5 -1
  82. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/rows/cassandra/write.py +5 -1
  83. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/triples/cassandra/write.py +5 -1
  84. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/triples/falkordb/write.py +12 -8
  85. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/triples/memgraph/write.py +22 -18
  86. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/triples/neo4j/write.py +20 -16
  87. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/tables/config.py +18 -29
  88. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/tables/knowledge.py +26 -39
  89. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/tables/library.py +38 -53
  90. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/template/prompt_manager.py +7 -3
  91. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph_flow.egg-info/PKG-INFO +1 -1
  92. trustgraph_flow-1.2.3/trustgraph/flow_version.py +0 -1
  93. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/README.md +0 -0
  94. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/pyproject.toml +0 -0
  95. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/setup.cfg +0 -0
  96. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/__init__.py +0 -0
  97. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/agent/__init__.py +0 -0
  98. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/agent/mcp_tool/__init__.py +0 -0
  99. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/agent/mcp_tool/__main__.py +0 -0
  100. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/agent/react/__init__.py +0 -0
  101. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/agent/react/__main__.py +0 -0
  102. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/agent/react/types.py +0 -0
  103. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/chunking/__init__.py +0 -0
  104. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/chunking/recursive/__init__.py +0 -0
  105. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/chunking/recursive/__main__.py +0 -0
  106. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/chunking/token/__init__.py +0 -0
  107. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/chunking/token/__main__.py +0 -0
  108. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/config/service/__init__.py +0 -0
  109. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/config/service/__main__.py +0 -0
  110. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/cores/__init__.py +0 -0
  111. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/cores/__main__.py +0 -0
  112. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/decoding/__init__.py +0 -0
  113. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/decoding/mistral_ocr/__init__.py +0 -0
  114. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/decoding/mistral_ocr/__main__.py +0 -0
  115. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/decoding/pdf/__init__.py +0 -0
  116. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/decoding/pdf/__main__.py +0 -0
  117. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/direct/__init__.py +0 -0
  118. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/direct/cassandra.py +0 -0
  119. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/embeddings/__init__.py +0 -0
  120. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/embeddings/document_embeddings/__init__.py +0 -0
  121. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/embeddings/document_embeddings/__main__.py +0 -0
  122. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/embeddings/fastembed/__init__.py +0 -0
  123. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/embeddings/fastembed/__main__.py +0 -0
  124. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/embeddings/graph_embeddings/__init__.py +0 -0
  125. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/embeddings/graph_embeddings/__main__.py +0 -0
  126. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/embeddings/ollama/__init__.py +0 -0
  127. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/embeddings/ollama/__main__.py +0 -0
  128. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/embeddings/ollama/processor.py +0 -0
  129. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/external/__init__.py +0 -0
  130. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/external/wikipedia/__init__.py +0 -0
  131. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/external/wikipedia/__main__.py +0 -0
  132. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/extract/__init__.py +0 -0
  133. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/extract/kg/__init__.py +0 -0
  134. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/extract/kg/agent/__init__.py +0 -0
  135. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/extract/kg/agent/__main__.py +0 -0
  136. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/extract/kg/definitions/__init__.py +0 -0
  137. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/extract/kg/definitions/__main__.py +0 -0
  138. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/extract/kg/relationships/__init__.py +0 -0
  139. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/extract/kg/relationships/__main__.py +0 -0
  140. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/extract/kg/topics/__init__.py +0 -0
  141. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/extract/kg/topics/__main__.py +0 -0
  142. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/extract/object/__init__.py +0 -0
  143. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/extract/object/row/__init__.py +0 -0
  144. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/extract/object/row/__main__.py +0 -0
  145. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/__init__.py +0 -0
  146. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/__main__.py +0 -0
  147. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/auth.py +0 -0
  148. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/dispatch/agent.py +0 -0
  149. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/dispatch/config.py +0 -0
  150. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/dispatch/document_embeddings_import.py +0 -0
  151. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/dispatch/document_rag.py +0 -0
  152. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/dispatch/embeddings.py +0 -0
  153. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/dispatch/entity_contexts_import.py +0 -0
  154. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/dispatch/flow.py +0 -0
  155. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/dispatch/graph_embeddings_import.py +0 -0
  156. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/dispatch/graph_embeddings_query.py +0 -0
  157. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/dispatch/graph_rag.py +0 -0
  158. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/dispatch/knowledge.py +0 -0
  159. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/dispatch/librarian.py +0 -0
  160. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/dispatch/mcp_tool.py +0 -0
  161. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/dispatch/prompt.py +0 -0
  162. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/dispatch/sender.py +0 -0
  163. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/dispatch/serialize.py +0 -0
  164. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/dispatch/streamer.py +0 -0
  165. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/dispatch/text_completion.py +0 -0
  166. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/dispatch/triples_import.py +0 -0
  167. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/dispatch/triples_query.py +0 -0
  168. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/endpoint/manager.py +0 -0
  169. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/running.py +0 -0
  170. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/service.py +0 -0
  171. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/unused/dbpedia.py +0 -0
  172. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/unused/encyclopedia.py +0 -0
  173. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/gateway/unused/internet_search.py +0 -0
  174. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/librarian/__init__.py +0 -0
  175. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/librarian/__main__.py +0 -0
  176. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/metering/__init__.py +0 -0
  177. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/metering/__main__.py +0 -0
  178. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/model/__init__.py +0 -0
  179. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/model/text_completion/__init__.py +0 -0
  180. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/model/text_completion/azure/__init__.py +0 -0
  181. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/model/text_completion/azure/__main__.py +0 -0
  182. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/model/text_completion/azure_openai/__init__.py +0 -0
  183. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/model/text_completion/azure_openai/__main__.py +0 -0
  184. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/model/text_completion/claude/__init__.py +0 -0
  185. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/model/text_completion/claude/__main__.py +0 -0
  186. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/model/text_completion/cohere/__init__.py +0 -0
  187. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/model/text_completion/cohere/__main__.py +0 -0
  188. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/model/text_completion/googleaistudio/__init__.py +0 -0
  189. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/model/text_completion/googleaistudio/__main__.py +0 -0
  190. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/model/text_completion/llamafile/__init__.py +0 -0
  191. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/model/text_completion/llamafile/__main__.py +0 -0
  192. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/model/text_completion/lmstudio/__init__.py +0 -0
  193. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/model/text_completion/lmstudio/__main__.py +0 -0
  194. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/model/text_completion/mistral/__init__.py +0 -0
  195. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/model/text_completion/mistral/__main__.py +0 -0
  196. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/model/text_completion/ollama/__init__.py +0 -0
  197. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/model/text_completion/ollama/__main__.py +0 -0
  198. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/model/text_completion/openai/__init__.py +0 -0
  199. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/model/text_completion/openai/__main__.py +0 -0
  200. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/model/text_completion/tgi/__init__.py +0 -0
  201. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/model/text_completion/tgi/__main__.py +0 -0
  202. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/model/text_completion/vllm/__init__.py +0 -0
  203. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/model/text_completion/vllm/__main__.py +0 -0
  204. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/processing/__init__.py +0 -0
  205. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/processing/__main__.py +0 -0
  206. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/prompt/__init__.py +0 -0
  207. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/prompt/template/__init__.py +0 -0
  208. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/prompt/template/__main__.py +0 -0
  209. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/query/__init__.py +0 -0
  210. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/query/doc_embeddings/__init__.py +0 -0
  211. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/query/doc_embeddings/milvus/__init__.py +0 -0
  212. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/query/doc_embeddings/milvus/__main__.py +0 -0
  213. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/query/doc_embeddings/pinecone/__init__.py +0 -0
  214. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/query/doc_embeddings/pinecone/__main__.py +0 -0
  215. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/query/doc_embeddings/qdrant/__init__.py +0 -0
  216. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/query/doc_embeddings/qdrant/__main__.py +0 -0
  217. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/query/graph_embeddings/__init__.py +0 -0
  218. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/query/graph_embeddings/milvus/__init__.py +0 -0
  219. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/query/graph_embeddings/milvus/__main__.py +0 -0
  220. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/query/graph_embeddings/pinecone/__init__.py +0 -0
  221. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/query/graph_embeddings/pinecone/__main__.py +0 -0
  222. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/query/graph_embeddings/qdrant/__init__.py +0 -0
  223. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/query/graph_embeddings/qdrant/__main__.py +0 -0
  224. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/query/triples/__init__.py +0 -0
  225. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/query/triples/cassandra/__init__.py +0 -0
  226. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/query/triples/cassandra/__main__.py +0 -0
  227. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/query/triples/falkordb/__init__.py +0 -0
  228. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/query/triples/falkordb/__main__.py +0 -0
  229. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/query/triples/memgraph/__init__.py +0 -0
  230. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/query/triples/memgraph/__main__.py +0 -0
  231. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/query/triples/neo4j/__init__.py +0 -0
  232. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/query/triples/neo4j/__main__.py +0 -0
  233. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/retrieval/__init__.py +0 -0
  234. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/retrieval/document_rag/__init__.py +0 -0
  235. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/retrieval/document_rag/__main__.py +0 -0
  236. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/retrieval/graph_rag/__init__.py +0 -0
  237. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/retrieval/graph_rag/__main__.py +0 -0
  238. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/rev_gateway/__init__.py +0 -0
  239. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/rev_gateway/__main__.py +0 -0
  240. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/rev_gateway/dispatcher.py +0 -0
  241. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/__init__.py +0 -0
  242. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/doc_embeddings/__init__.py +0 -0
  243. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/doc_embeddings/milvus/__init__.py +0 -0
  244. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/doc_embeddings/milvus/__main__.py +0 -0
  245. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/doc_embeddings/milvus/write.py +0 -0
  246. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/doc_embeddings/pinecone/__init__.py +0 -0
  247. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/doc_embeddings/pinecone/__main__.py +0 -0
  248. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/doc_embeddings/qdrant/__init__.py +0 -0
  249. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/doc_embeddings/qdrant/__main__.py +0 -0
  250. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/graph_embeddings/__init__.py +0 -0
  251. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/graph_embeddings/milvus/__init__.py +0 -0
  252. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/graph_embeddings/milvus/__main__.py +0 -0
  253. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/graph_embeddings/milvus/write.py +0 -0
  254. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/graph_embeddings/pinecone/__init__.py +0 -0
  255. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/graph_embeddings/pinecone/__main__.py +0 -0
  256. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/graph_embeddings/qdrant/__init__.py +0 -0
  257. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/graph_embeddings/qdrant/__main__.py +0 -0
  258. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/knowledge/__init__.py +0 -0
  259. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/knowledge/__main__.py +0 -0
  260. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/knowledge/store.py +0 -0
  261. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/object_embeddings/__init__.py +0 -0
  262. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/object_embeddings/milvus/__init__.py +0 -0
  263. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/object_embeddings/milvus/__main__.py +0 -0
  264. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/object_embeddings/milvus/write.py +0 -0
  265. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/rows/__init__.py +0 -0
  266. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/rows/cassandra/__init__.py +0 -0
  267. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/rows/cassandra/__main__.py +0 -0
  268. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/triples/__init__.py +0 -0
  269. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/triples/cassandra/__init__.py +0 -0
  270. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/triples/cassandra/__main__.py +0 -0
  271. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/triples/falkordb/__init__.py +0 -0
  272. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/triples/falkordb/__main__.py +0 -0
  273. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/triples/memgraph/__init__.py +0 -0
  274. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/triples/memgraph/__main__.py +0 -0
  275. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/triples/neo4j/__init__.py +0 -0
  276. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/storage/triples/neo4j/__main__.py +0 -0
  277. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/tables/__init__.py +0 -0
  278. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph/template/__init__.py +0 -0
  279. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph_flow.egg-info/SOURCES.txt +0 -0
  280. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph_flow.egg-info/dependency_links.txt +0 -0
  281. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph_flow.egg-info/entry_points.txt +0 -0
  282. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph_flow.egg-info/requires.txt +0 -0
  283. {trustgraph_flow-1.2.3 → trustgraph_flow-1.2.4}/trustgraph_flow.egg-info/top_level.txt +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: trustgraph-flow
3
- Version: 1.2.3
3
+ Version: 1.2.4
4
4
  Summary: TrustGraph provides a means to run a pipeline of flexible AI processing components in a flexible means to achieve a processing pipeline.
5
5
  Author-email: "trustgraph.ai" <security@trustgraph.ai>
6
6
  Project-URL: Homepage, https://github.com/trustgraph-ai/trustgraph
@@ -5,11 +5,15 @@ name + parameters, output is the response, either a string or an object.
5
5
  """
6
6
 
7
7
  import json
8
+ import logging
8
9
  from mcp.client.streamable_http import streamablehttp_client
9
10
  from mcp import ClientSession
10
11
 
11
12
  from ... base import ToolService
12
13
 
14
+ # Module logger
15
+ logger = logging.getLogger(__name__)
16
+
13
17
  default_ident = "mcp-tool"
14
18
 
15
19
  class Service(ToolService):
@@ -26,7 +30,7 @@ class Service(ToolService):
26
30
 
27
31
  async def on_mcp_config(self, config, version):
28
32
 
29
- print("Got config version", version)
33
+ logger.info(f"Got config version {version}")
30
34
 
31
35
  if "mcp" not in config: return
32
36
 
@@ -52,7 +56,7 @@ class Service(ToolService):
52
56
  else:
53
57
  remote_name = name
54
58
 
55
- print("Invoking", remote_name, "at", url, flush=True)
59
+ logger.info(f"Invoking {remote_name} at {url}")
56
60
 
57
61
  # Connect to a streamable HTTP server
58
62
  async with streamablehttp_client(url) as (
@@ -86,13 +90,13 @@ class Service(ToolService):
86
90
  except BaseExceptionGroup as e:
87
91
 
88
92
  for child in e.exceptions:
89
- print(child)
93
+ logger.debug(f"Child: {child}")
90
94
 
91
95
  raise e.exceptions[0]
92
96
 
93
97
  except Exception as e:
94
98
 
95
- print(e)
99
+ logger.error(f"Error invoking MCP tool: {e}", exc_info=True)
96
100
  raise e
97
101
 
98
102
  @staticmethod
@@ -164,18 +164,18 @@ class AgentManager:
164
164
 
165
165
  async def reason(self, question, history, context):
166
166
 
167
- print(f"calling reason: {question}", flush=True)
167
+ logger.debug(f"calling reason: {question}")
168
168
 
169
169
  tools = self.tools
170
170
 
171
- print(f"in reason", flush=True)
172
- print(tools, flush=True)
171
+ logger.debug("in reason")
172
+ logger.debug(f"tools: {tools}")
173
173
 
174
174
  tool_names = ",".join([
175
175
  t for t in self.tools.keys()
176
176
  ])
177
177
 
178
- print("Tool names:", tool_names, flush=True)
178
+ logger.debug(f"Tool names: {tool_names}")
179
179
 
180
180
  variables = {
181
181
  "question": question,
@@ -208,14 +208,14 @@ class AgentManager:
208
208
  ]
209
209
  }
210
210
 
211
- print(json.dumps(variables, indent=4), flush=True)
211
+ logger.debug(f"Variables: {json.dumps(variables, indent=4)}")
212
212
 
213
213
  logger.info(f"prompt: {variables}")
214
214
 
215
215
  # Get text response from prompt service
216
216
  response_text = await context("prompt-request").agent_react(variables)
217
217
 
218
- print(f"Response text:\n{response_text}", flush=True)
218
+ logger.debug(f"Response text:\n{response_text}")
219
219
 
220
220
  logger.info(f"response: {response_text}")
221
221
 
@@ -233,7 +233,6 @@ class AgentManager:
233
233
  async def react(self, question, history, think, observe, context):
234
234
 
235
235
  logger.info(f"question: {question}")
236
- print(f"question: {question}", flush=True)
237
236
 
238
237
  act = await self.reason(
239
238
  question = question,
@@ -256,7 +255,7 @@ class AgentManager:
256
255
  else:
257
256
  raise RuntimeError(f"No action for {act.name}!")
258
257
 
259
- print("TOOL>>>", act, flush=True)
258
+ logger.debug(f"TOOL>>> {act}")
260
259
 
261
260
  resp = await action.implementation(context).invoke(
262
261
  **act.arguments
@@ -8,7 +8,7 @@ import sys
8
8
  import functools
9
9
  import logging
10
10
 
11
- logging.basicConfig(level=logging.DEBUG)
11
+ # Module logger
12
12
  logger = logging.getLogger(__name__)
13
13
 
14
14
  from ... base import AgentService, TextCompletionClientSpec, PromptClientSpec
@@ -81,7 +81,7 @@ class Processor(AgentService):
81
81
 
82
82
  async def on_tools_config(self, config, version):
83
83
 
84
- print("Loading configuration version", version)
84
+ logger.info(f"Loading configuration version {version}")
85
85
 
86
86
  try:
87
87
 
@@ -151,13 +151,13 @@ class Processor(AgentService):
151
151
  additional_context=additional
152
152
  )
153
153
 
154
- print(f"Loaded {len(tools)} tools", flush=True)
155
- print("Tool configuration reloaded.", flush=True)
154
+ logger.info(f"Loaded {len(tools)} tools")
155
+ logger.info("Tool configuration reloaded.")
156
156
 
157
157
  except Exception as e:
158
158
 
159
- print("on_tools_config Exception:", e, flush=True)
160
- print("Configuration reload failed", flush=True)
159
+ logger.error(f"on_tools_config Exception: {e}", exc_info=True)
160
+ logger.error("Configuration reload failed")
161
161
 
162
162
  async def agent_request(self, request, respond, next, flow):
163
163
 
@@ -176,16 +176,16 @@ class Processor(AgentService):
176
176
  else:
177
177
  history = []
178
178
 
179
- print(f"Question: {request.question}", flush=True)
179
+ logger.info(f"Question: {request.question}")
180
180
 
181
181
  if len(history) >= self.max_iterations:
182
182
  raise RuntimeError("Too many agent iterations")
183
183
 
184
- print(f"History: {history}", flush=True)
184
+ logger.debug(f"History: {history}")
185
185
 
186
186
  async def think(x):
187
187
 
188
- print(f"Think: {x}", flush=True)
188
+ logger.debug(f"Think: {x}")
189
189
 
190
190
  r = AgentResponse(
191
191
  answer=None,
@@ -198,7 +198,7 @@ class Processor(AgentService):
198
198
 
199
199
  async def observe(x):
200
200
 
201
- print(f"Observe: {x}", flush=True)
201
+ logger.debug(f"Observe: {x}")
202
202
 
203
203
  r = AgentResponse(
204
204
  answer=None,
@@ -209,7 +209,7 @@ class Processor(AgentService):
209
209
 
210
210
  await respond(r)
211
211
 
212
- print("Call React", flush=True)
212
+ logger.debug("Call React")
213
213
 
214
214
  act = await self.agent.react(
215
215
  question = request.question,
@@ -219,11 +219,11 @@ class Processor(AgentService):
219
219
  context = flow,
220
220
  )
221
221
 
222
- print(f"Action: {act}", flush=True)
222
+ logger.debug(f"Action: {act}")
223
223
 
224
224
  if isinstance(act, Final):
225
225
 
226
- print("Send final response...", flush=True)
226
+ logger.debug("Send final response...")
227
227
 
228
228
  if isinstance(act.final, str):
229
229
  f = act.final
@@ -238,11 +238,11 @@ class Processor(AgentService):
238
238
 
239
239
  await respond(r)
240
240
 
241
- print("Done.", flush=True)
241
+ logger.debug("Done.")
242
242
 
243
243
  return
244
244
 
245
- print("Send next...", flush=True)
245
+ logger.debug("Send next...")
246
246
 
247
247
  history.append(act)
248
248
 
@@ -263,15 +263,15 @@ class Processor(AgentService):
263
263
 
264
264
  await next(r)
265
265
 
266
- print("Done.", flush=True)
266
+ logger.debug("React agent processing complete")
267
267
 
268
268
  return
269
269
 
270
270
  except Exception as e:
271
271
 
272
- print(f"agent_request Exception: {e}")
272
+ logger.error(f"agent_request Exception: {e}", exc_info=True)
273
273
 
274
- print("Send error response...", flush=True)
274
+ logger.debug("Send error response...")
275
275
 
276
276
  r = AgentResponse(
277
277
  error=Error(
@@ -1,7 +1,11 @@
1
1
 
2
2
  import json
3
+ import logging
3
4
  from .types import Argument
4
5
 
6
+ # Module logger
7
+ logger = logging.getLogger(__name__)
8
+
5
9
  # This tool implementation knows how to put a question to the graph RAG
6
10
  # service
7
11
  class KnowledgeQueryImpl:
@@ -21,7 +25,7 @@ class KnowledgeQueryImpl:
21
25
 
22
26
  async def invoke(self, **arguments):
23
27
  client = self.context("graph-rag-request")
24
- print("Graph RAG question...", flush=True)
28
+ logger.debug("Graph RAG question...")
25
29
  return await client.rag(
26
30
  arguments.get("question")
27
31
  )
@@ -44,7 +48,7 @@ class TextCompletionImpl:
44
48
 
45
49
  async def invoke(self, **arguments):
46
50
  client = self.context("prompt-request")
47
- print("Prompt question...", flush=True)
51
+ logger.debug("Prompt question...")
48
52
  return await client.question(
49
53
  arguments.get("question")
50
54
  )
@@ -67,13 +71,13 @@ class McpToolImpl:
67
71
 
68
72
  client = self.context("mcp-tool-request")
69
73
 
70
- print(f"MCP tool invocation: {self.mcp_tool_id}...", flush=True)
74
+ logger.debug(f"MCP tool invocation: {self.mcp_tool_id}...")
71
75
  output = await client.invoke(
72
76
  name = self.mcp_tool_id,
73
77
  parameters = arguments, # Pass the actual arguments
74
78
  )
75
79
 
76
- print(output)
80
+ logger.debug(f"MCP tool output: {output}")
77
81
 
78
82
  if isinstance(output, str):
79
83
  return output
@@ -94,7 +98,7 @@ class PromptImpl:
94
98
 
95
99
  async def invoke(self, **arguments):
96
100
  client = self.context("prompt-request")
97
- print(f"Prompt template invocation: {self.template_id}...", flush=True)
101
+ logger.debug(f"Prompt template invocation: {self.template_id}...")
98
102
  return await client.prompt(
99
103
  id=self.template_id,
100
104
  variables=arguments
@@ -4,12 +4,16 @@ Simple decoder, accepts text documents on input, outputs chunks from the
4
4
  as text as separate output objects.
5
5
  """
6
6
 
7
+ import logging
7
8
  from langchain_text_splitters import RecursiveCharacterTextSplitter
8
9
  from prometheus_client import Histogram
9
10
 
10
11
  from ... schema import TextDocument, Chunk
11
12
  from ... base import FlowProcessor, ConsumerSpec, ProducerSpec
12
13
 
14
+ # Module logger
15
+ logger = logging.getLogger(__name__)
16
+
13
17
  default_ident = "chunker"
14
18
 
15
19
  class Processor(FlowProcessor):
@@ -54,12 +58,12 @@ class Processor(FlowProcessor):
54
58
  )
55
59
  )
56
60
 
57
- print("Chunker initialised", flush=True)
61
+ logger.info("Recursive chunker initialized")
58
62
 
59
63
  async def on_message(self, msg, consumer, flow):
60
64
 
61
65
  v = msg.value()
62
- print(f"Chunking {v.metadata.id}...", flush=True)
66
+ logger.info(f"Chunking document {v.metadata.id}...")
63
67
 
64
68
  texts = self.text_splitter.create_documents(
65
69
  [v.text.decode("utf-8")]
@@ -67,7 +71,7 @@ class Processor(FlowProcessor):
67
71
 
68
72
  for ix, chunk in enumerate(texts):
69
73
 
70
- print("Chunk", len(chunk.page_content), flush=True)
74
+ logger.debug(f"Created chunk of size {len(chunk.page_content)}")
71
75
 
72
76
  r = Chunk(
73
77
  metadata=v.metadata,
@@ -80,7 +84,7 @@ class Processor(FlowProcessor):
80
84
 
81
85
  await flow("output").send(r)
82
86
 
83
- print("Done.", flush=True)
87
+ logger.debug("Document chunking complete")
84
88
 
85
89
  @staticmethod
86
90
  def add_args(parser):
@@ -4,12 +4,16 @@ Simple decoder, accepts text documents on input, outputs chunks from the
4
4
  as text as separate output objects.
5
5
  """
6
6
 
7
+ import logging
7
8
  from langchain_text_splitters import TokenTextSplitter
8
9
  from prometheus_client import Histogram
9
10
 
10
11
  from ... schema import TextDocument, Chunk
11
12
  from ... base import FlowProcessor
12
13
 
14
+ # Module logger
15
+ logger = logging.getLogger(__name__)
16
+
13
17
  default_ident = "chunker"
14
18
 
15
19
  class Processor(FlowProcessor):
@@ -53,12 +57,12 @@ class Processor(FlowProcessor):
53
57
  )
54
58
  )
55
59
 
56
- print("Chunker initialised", flush=True)
60
+ logger.info("Token chunker initialized")
57
61
 
58
62
  async def on_message(self, msg, consumer, flow):
59
63
 
60
64
  v = msg.value()
61
- print(f"Chunking {v.metadata.id}...", flush=True)
65
+ logger.info(f"Chunking document {v.metadata.id}...")
62
66
 
63
67
  texts = self.text_splitter.create_documents(
64
68
  [v.text.decode("utf-8")]
@@ -66,7 +70,7 @@ class Processor(FlowProcessor):
66
70
 
67
71
  for ix, chunk in enumerate(texts):
68
72
 
69
- print("Chunk", len(chunk.page_content), flush=True)
73
+ logger.debug(f"Created chunk of size {len(chunk.page_content)}")
70
74
 
71
75
  r = Chunk(
72
76
  metadata=v.metadata,
@@ -79,7 +83,7 @@ class Processor(FlowProcessor):
79
83
 
80
84
  await flow("output").send(r)
81
85
 
82
- print("Done.", flush=True)
86
+ logger.debug("Document chunking complete")
83
87
 
84
88
  @staticmethod
85
89
  def add_args(parser):
@@ -1,9 +1,14 @@
1
1
 
2
+ import logging
3
+
2
4
  from trustgraph.schema import ConfigResponse
3
5
  from trustgraph.schema import ConfigValue, Error
4
6
 
5
7
  from ... tables.config import ConfigTableStore
6
8
 
9
+ # Module logger
10
+ logger = logging.getLogger(__name__)
11
+
7
12
  class ConfigurationClass:
8
13
 
9
14
  async def keys(self):
@@ -228,7 +233,7 @@ class Configuration:
228
233
 
229
234
  async def handle(self, msg):
230
235
 
231
- print("Handle message ", msg.operation)
236
+ logger.debug(f"Handling config message: {msg.operation}")
232
237
 
233
238
  if msg.operation == "get":
234
239
 
@@ -1,6 +1,10 @@
1
1
 
2
2
  from trustgraph.schema import FlowResponse, Error
3
3
  import json
4
+ import logging
5
+
6
+ # Module logger
7
+ logger = logging.getLogger(__name__)
4
8
 
5
9
  class FlowConfig:
6
10
  def __init__(self, config):
@@ -41,7 +45,7 @@ class FlowConfig:
41
45
 
42
46
  async def handle_delete_class(self, msg):
43
47
 
44
- print(msg)
48
+ logger.debug(f"Flow config message: {msg}")
45
49
 
46
50
  await self.config.get("flow-classes").delete(msg.class_name)
47
51
 
@@ -218,7 +222,7 @@ class FlowConfig:
218
222
 
219
223
  async def handle(self, msg):
220
224
 
221
- print("Handle message ", msg.operation)
225
+ logger.debug(f"Handling flow message: {msg.operation}")
222
226
 
223
227
  if msg.operation == "list-classes":
224
228
  resp = await self.handle_list_classes(msg)
@@ -3,6 +3,8 @@
3
3
  Config service. Manages system global configuration state
4
4
  """
5
5
 
6
+ import logging
7
+
6
8
  from trustgraph.schema import Error
7
9
 
8
10
  from trustgraph.schema import ConfigRequest, ConfigResponse, ConfigPush
@@ -20,6 +22,9 @@ from . flow import FlowConfig
20
22
  from ... base import ProcessorMetrics, ConsumerMetrics, ProducerMetrics
21
23
  from ... base import Consumer, Producer
22
24
 
25
+ # Module logger
26
+ logger = logging.getLogger(__name__)
27
+
23
28
  # FIXME: How to ensure this doesn't conflict with other usage?
24
29
  keyspace = "config"
25
30
 
@@ -146,7 +151,7 @@ class Processor(AsyncProcessor):
146
151
 
147
152
  self.flow = FlowConfig(self.config)
148
153
 
149
- print("Service initialised.")
154
+ logger.info("Config service initialized")
150
155
 
151
156
  async def start(self):
152
157
 
@@ -172,7 +177,7 @@ class Processor(AsyncProcessor):
172
177
 
173
178
  # Race condition, should make sure version & config sync
174
179
 
175
- print("Pushed version ", await self.config.get_version())
180
+ logger.info(f"Pushed configuration version {await self.config.get_version()}")
176
181
 
177
182
  async def on_config_request(self, msg, consumer, flow):
178
183
 
@@ -183,7 +188,7 @@ class Processor(AsyncProcessor):
183
188
  # Sender-produced ID
184
189
  id = msg.properties()["id"]
185
190
 
186
- print(f"Handling {id}...", flush=True)
191
+ logger.info(f"Handling config request {id}...")
187
192
 
188
193
  resp = await self.config.handle(v)
189
194
 
@@ -214,7 +219,7 @@ class Processor(AsyncProcessor):
214
219
  # Sender-produced ID
215
220
  id = msg.properties()["id"]
216
221
 
217
- print(f"Handling {id}...", flush=True)
222
+ logger.info(f"Handling flow request {id}...")
218
223
 
219
224
  resp = await self.flow.handle(v)
220
225
 
@@ -8,6 +8,10 @@ from .. base import Publisher
8
8
  import base64
9
9
  import asyncio
10
10
  import uuid
11
+ import logging
12
+
13
+ # Module logger
14
+ logger = logging.getLogger(__name__)
11
15
 
12
16
  class KnowledgeManager:
13
17
 
@@ -26,7 +30,7 @@ class KnowledgeManager:
26
30
 
27
31
  async def delete_kg_core(self, request, respond):
28
32
 
29
- print("Deleting core...", flush=True)
33
+ logger.info("Deleting knowledge core...")
30
34
 
31
35
  await self.table_store.delete_kg_core(
32
36
  request.user, request.id
@@ -44,7 +48,7 @@ class KnowledgeManager:
44
48
 
45
49
  async def get_kg_core(self, request, respond):
46
50
 
47
- print("Get core...", flush=True)
51
+ logger.info("Getting knowledge core...")
48
52
 
49
53
  async def publish_triples(t):
50
54
  await respond(
@@ -82,7 +86,7 @@ class KnowledgeManager:
82
86
  publish_ge,
83
87
  )
84
88
 
85
- print("Get complete", flush=True)
89
+ logger.debug("Knowledge core retrieval complete")
86
90
 
87
91
  await respond(
88
92
  KnowledgeResponse(
@@ -158,13 +162,13 @@ class KnowledgeManager:
158
162
 
159
163
  async def core_loader(self):
160
164
 
161
- print("Running...", flush=True)
165
+ logger.info("Knowledge background processor running...")
162
166
  while True:
163
167
 
164
- print("Wait for next load...", flush=True)
168
+ logger.debug("Waiting for next load...")
165
169
  request, respond = await self.loader_queue.get()
166
170
 
167
- print("Loading...", request.id, flush=True)
171
+ logger.info(f"Loading knowledge: {request.id}")
168
172
 
169
173
  try:
170
174
 
@@ -204,7 +208,7 @@ class KnowledgeManager:
204
208
 
205
209
  except Exception as e:
206
210
 
207
- print("Exception:", e, flush=True)
211
+ logger.error(f"Knowledge exception: {e}", exc_info=True)
208
212
  await respond(
209
213
  KnowledgeResponse(
210
214
  error = Error(
@@ -219,15 +223,15 @@ class KnowledgeManager:
219
223
  )
220
224
 
221
225
 
222
- print("Going to start loading...", flush=True)
226
+ logger.debug("Starting knowledge loading process...")
223
227
 
224
228
  try:
225
229
 
226
230
  t_pub = None
227
231
  ge_pub = None
228
232
 
229
- print(t_q, flush=True)
230
- print(ge_q, flush=True)
233
+ logger.debug(f"Triples queue: {t_q}")
234
+ logger.debug(f"Graph embeddings queue: {ge_q}")
231
235
 
232
236
  t_pub = Publisher(
233
237
  self.flow_config.pulsar_client, t_q,
@@ -238,7 +242,7 @@ class KnowledgeManager:
238
242
  schema=GraphEmbeddings
239
243
  )
240
244
 
241
- print("Start publishers...", flush=True)
245
+ logger.debug("Starting publishers...")
242
246
 
243
247
  await t_pub.start()
244
248
  await ge_pub.start()
@@ -246,7 +250,7 @@ class KnowledgeManager:
246
250
  async def publish_triples(t):
247
251
  await t_pub.send(None, t)
248
252
 
249
- print("Publish triples...", flush=True)
253
+ logger.debug("Publishing triples...")
250
254
 
251
255
  # Remove doc table row
252
256
  await self.table_store.get_triples(
@@ -258,7 +262,7 @@ class KnowledgeManager:
258
262
  async def publish_ge(g):
259
263
  await ge_pub.send(None, g)
260
264
 
261
- print("Publish GEs...", flush=True)
265
+ logger.debug("Publishing graph embeddings...")
262
266
 
263
267
  # Remove doc table row
264
268
  await self.table_store.get_graph_embeddings(
@@ -267,19 +271,19 @@ class KnowledgeManager:
267
271
  publish_ge,
268
272
  )
269
273
 
270
- print("Completed that.", flush=True)
274
+ logger.debug("Knowledge loading completed")
271
275
 
272
276
  except Exception as e:
273
277
 
274
- print("Exception:", e, flush=True)
278
+ logger.error(f"Knowledge exception: {e}", exc_info=True)
275
279
 
276
280
  finally:
277
281
 
278
- print("Stopping publishers...", flush=True)
282
+ logger.debug("Stopping publishers...")
279
283
 
280
284
  if t_pub: await t_pub.stop()
281
285
  if ge_pub: await ge_pub.stop()
282
286
 
283
- print("Done", flush=True)
287
+ logger.debug("Knowledge processing done")
284
288
 
285
289
  continue