TalkPipe 0.7.0a2__tar.gz → 0.7.1__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 (146) hide show
  1. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/.github/ISSUE_TEMPLATE/release-checklist.md +4 -1
  2. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/CHANGELOG.md +23 -1
  3. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/PKG-INFO +43 -2
  4. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/README.md +40 -0
  5. talkpipe-0.7.1/docs/.gitignore +3 -0
  6. talkpipe-0.7.1/docs/make_structure_diagram.sh +3 -0
  7. talkpipe-0.7.1/docs/structure.tex +59 -0
  8. talkpipe-0.7.1/docs/talkpipe_diagram.png +0 -0
  9. talkpipe-0.7.1/examples/.gitignore +2 -0
  10. talkpipe-0.7.1/examples/Tutorial_1-Document_Indexing/README.md +523 -0
  11. talkpipe-0.7.1/examples/Tutorial_1-Document_Indexing/Step_1_CreateSyntheticData.sh +28 -0
  12. talkpipe-0.7.1/examples/Tutorial_1-Document_Indexing/Step_2_IndexStories.sh +24 -0
  13. talkpipe-0.7.1/examples/Tutorial_1-Document_Indexing/Step_3_SearchStories.sh +18 -0
  14. talkpipe-0.7.1/examples/Tutorial_1-Document_Indexing/stories.json +50 -0
  15. talkpipe-0.7.1/examples/Tutorial_1-Document_Indexing/story_search_ui.yaml +11 -0
  16. talkpipe-0.7.1/examples/Tutorial_2-Search_by_Example_and_RAG/README.md +280 -0
  17. talkpipe-0.7.1/examples/Tutorial_2-Search_by_Example_and_RAG/Step_1_CreateVectorDatabase.sh +20 -0
  18. talkpipe-0.7.1/examples/Tutorial_2-Search_by_Example_and_RAG/Step_2_SearchByExample.sh +24 -0
  19. talkpipe-0.7.1/examples/Tutorial_2-Search_by_Example_and_RAG/Step_3_SpecializedRag.sh +10 -0
  20. talkpipe-0.7.1/examples/Tutorial_2-Search_by_Example_and_RAG/step_3_extras.py +29 -0
  21. talkpipe-0.7.1/examples/Tutorial_2-Search_by_Example_and_RAG/story_by_example_ui.yaml +11 -0
  22. talkpipe-0.7.1/examples/Tutorial_3_Report_Writing/README.md +354 -0
  23. talkpipe-0.7.1/examples/Tutorial_3_Report_Writing/file_structure.md +52 -0
  24. talkpipe-0.7.1/examples/Tutorial_3_Report_Writing/multi_format_ui.yml +22 -0
  25. talkpipe-0.7.1/examples/Tutorial_3_Report_Writing/report_topic_ui.yaml +11 -0
  26. talkpipe-0.7.1/examples/Tutorial_3_Report_Writing/step1.sh +22 -0
  27. talkpipe-0.7.1/examples/Tutorial_3_Report_Writing/step2.sh +23 -0
  28. talkpipe-0.7.1/examples/Tutorial_3_Report_Writing/step3.sh +20 -0
  29. talkpipe-0.7.1/examples/Tutorial_3_Report_Writing/step3_extras.py +142 -0
  30. talkpipe-0.7.1/examples/Tutorial_3_Report_Writing/step_1_extras.py +70 -0
  31. talkpipe-0.7.1/examples/Tutorial_3_Report_Writing/step_2_extras.py +153 -0
  32. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/pyproject.toml +2 -1
  33. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/__init__.py +1 -1
  34. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/app/apiendpoint.py +391 -312
  35. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/app/static/unit-docs.html +136 -49
  36. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/app/static/unit-docs.txt +105 -36
  37. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/pipe/basic.py +94 -13
  38. talkpipe-0.7.1/src/talkpipe/search/abstract.py +64 -0
  39. talkpipe-0.7.1/src/talkpipe/search/simplevectordb.py +430 -0
  40. talkpipe-0.7.1/src/talkpipe/search/whoosh.py +331 -0
  41. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/util/data_manipulation.py +27 -3
  42. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe.egg-info/PKG-INFO +43 -2
  43. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe.egg-info/SOURCES.txt +31 -4
  44. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe.egg-info/requires.txt +2 -1
  45. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/tests/talkpipe/llm/test_embedding.py +13 -0
  46. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/tests/talkpipe/pipe/test_basic.py +5 -4
  47. {talkpipe-0.7.0a2/tests/talkpipe/vectordb → talkpipe-0.7.1/tests/talkpipe/search}/test_simplevectordb.py +40 -28
  48. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/tests/talkpipe/search/test_whoosh.py +78 -15
  49. talkpipe-0.7.1/tests/talkpipe/util/test_data_manipulation.py +53 -0
  50. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/tests/talkpipe/util/test_util.py +8 -0
  51. talkpipe-0.7.0a2/src/talkpipe/search/abstract.py +0 -43
  52. talkpipe-0.7.0a2/src/talkpipe/search/whoosh.py +0 -127
  53. talkpipe-0.7.0a2/src/talkpipe/vectordb/abstract.py +0 -68
  54. talkpipe-0.7.0a2/src/talkpipe/vectordb/simplevectordb.py +0 -598
  55. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/.gitignore +0 -0
  56. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/.vscode/settings.json +0 -0
  57. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/.vscode/tasks.json +0 -0
  58. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/COPYRIGHT +0 -0
  59. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/Dockerfile +0 -0
  60. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/LICENSE +0 -0
  61. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/base-image/Dockerfile +0 -0
  62. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/bin/config-analyzer.py +0 -0
  63. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/bin/config_bash +0 -0
  64. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/docs/LLMChat.png +0 -0
  65. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/docs/LLMEvaluateWebPage.png +0 -0
  66. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/docs/TalkPipe.png +0 -0
  67. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/docs/TalkPipe.xcf +0 -0
  68. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/pytest.ini +0 -0
  69. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/setup.cfg +0 -0
  70. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/setup.py +0 -0
  71. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/app/__init__.py +0 -0
  72. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/app/chatcli.py +0 -0
  73. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/app/chatterlang_server.py +0 -0
  74. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/app/runscript.py +0 -0
  75. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/app/static/.gitignore +0 -0
  76. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/app/static/favicon.ico +0 -0
  77. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/app/unit_documentation_analyzer.py +0 -0
  78. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/chatterlang/__init__.py +0 -0
  79. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/chatterlang/compiler.py +0 -0
  80. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/chatterlang/parsers.py +0 -0
  81. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/chatterlang/registry.py +0 -0
  82. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/data/__init__.py +0 -0
  83. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/data/email.py +0 -0
  84. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/data/extraction.py +0 -0
  85. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/data/html.py +0 -0
  86. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/data/mongo.py +0 -0
  87. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/data/rss.py +0 -0
  88. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/jupyter/basic.py +0 -0
  89. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/jupyter/examples.py +0 -0
  90. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/jupyter/interactive.py +0 -0
  91. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/llm/__init__.py +0 -0
  92. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/llm/chat.py +0 -0
  93. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/llm/config.py +0 -0
  94. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/llm/embedding.py +0 -0
  95. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/llm/embedding_adapters.py +0 -0
  96. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/llm/prompt_adapters.py +0 -0
  97. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/operations/__init__.py +0 -0
  98. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/operations/filtering.py +0 -0
  99. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/operations/matrices.py +0 -0
  100. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/operations/signatures.py +0 -0
  101. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/operations/thread_ops.py +0 -0
  102. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/operations/transforms.py +0 -0
  103. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/pipe/__init__.py +0 -0
  104. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/pipe/core.py +0 -0
  105. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/pipe/fork.py +0 -0
  106. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/pipe/io.py +0 -0
  107. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/pipe/math.py +0 -0
  108. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/util/__init__.py +0 -0
  109. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/util/collections.py +0 -0
  110. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/util/config.py +0 -0
  111. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe/util/os.py +0 -0
  112. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe.egg-info/dependency_links.txt +0 -0
  113. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe.egg-info/entry_points.txt +0 -0
  114. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/src/talkpipe.egg-info/top_level.txt +0 -0
  115. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/tests/conftest.py +0 -0
  116. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/tests/talkpipe/app/test_chatcli.py +0 -0
  117. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/tests/talkpipe/app/test_runscript.py +0 -0
  118. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/tests/talkpipe/chatterlang/test_chatterlang_server.py +0 -0
  119. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/tests/talkpipe/chatterlang/test_compiler.py +0 -0
  120. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/tests/talkpipe/chatterlang/test_parsers.py +0 -0
  121. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/tests/talkpipe/data/sample_feed.pkl +0 -0
  122. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/tests/talkpipe/data/test.docx +0 -0
  123. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/tests/talkpipe/data/test_email.py +0 -0
  124. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/tests/talkpipe/data/test_extraction.py +0 -0
  125. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/tests/talkpipe/data/test_html.py +0 -0
  126. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/tests/talkpipe/data/test_html_exceptions.py +0 -0
  127. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/tests/talkpipe/data/test_mogomock.py +0 -0
  128. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/tests/talkpipe/data/test_mongo.py +0 -0
  129. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/tests/talkpipe/data/test_mongo_integration.py +0 -0
  130. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/tests/talkpipe/data/test_rss.py +0 -0
  131. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/tests/talkpipe/jupyter/test_basic_jupyter.py +0 -0
  132. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/tests/talkpipe/jupyter/test_examples.py +0 -0
  133. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/tests/talkpipe/jupyter/test_interactive.py +0 -0
  134. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/tests/talkpipe/llm/test_chat.py +0 -0
  135. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/tests/talkpipe/operations/test_filtering.py +0 -0
  136. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/tests/talkpipe/operations/test_matrices.py +0 -0
  137. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/tests/talkpipe/operations/test_signatures.py +0 -0
  138. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/tests/talkpipe/operations/test_threading.py +0 -0
  139. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/tests/talkpipe/operations/test_transforms.py +0 -0
  140. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/tests/talkpipe/pipe/test_core.py +0 -0
  141. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/tests/talkpipe/pipe/test_fork.py +0 -0
  142. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/tests/talkpipe/pipe/test_io.py +0 -0
  143. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/tests/talkpipe/pipe/test_math.py +0 -0
  144. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/tests/talkpipe/test_documentation_examples.py +0 -0
  145. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/tests/talkpipe/util/test_collections.py +0 -0
  146. {talkpipe-0.7.0a2 → talkpipe-0.7.1}/tests/testutils.py +0 -0
@@ -11,10 +11,13 @@ assignees: ''
11
11
  - [ ] Commit all changes
12
12
  - [ ] Ensure unit tests pass in live environment
13
13
  - [ ] Merge into master
14
- - [ ] Build docker image
14
+ - [ ] Build docker images and make sure runnable unit tests pass
15
+ - docker build -f base-image/Dockerfile . -t talkpipe:base
16
+ - docker build . -t talkpipe:experimental
15
17
  - [ ] Tag repository
16
18
  - [ ] Build whl files
17
19
  - [ ] Install whl file in new environment and test a script in chatterlang_server
20
+ - [ ] Run examples in the tutorials
18
21
  - [ ] Push to pypi
19
22
  - [ ] Push code to repo
20
23
  - [ ] Push tags to repo
@@ -1,6 +1,21 @@
1
1
  # Changelog
2
+ ## 0.7.1
3
+ ### New Segments and Sources
4
+ - Added **formatItem** to produce a human-readable text representation of various properties of an item, and added relevant methods to data_manipulation.
5
+ - Added **copy** and **deepcopy** segments for making copies of data in a pipeline. This is important in situations where you
6
+ don't want the original input data to be modified during processing.
7
+
8
+ ### Improvements
9
+ - Added an "examples" directory with three tutorials, each of which builds on the previous one and contains multiple steps.
10
+ - Updates to **apiendpoint**:
11
+ - Changed the default port.
12
+ - Fixed a bug causing it to be unable to load a script from a file.
13
+ - Added metric and method options to vector_search in the SimpleVectorDB class and propagated those through to searchVector.
14
+ - Updated **progressTicks** so it writes to stderr rather than stdout.
15
+ - Updated **searchWhoosh** so the user can specify fields to use as the query and whether to attach results or pass them all along.
16
+
2
17
 
3
- ## In Progress
18
+ ## 0.7.0
4
19
  ### New Segments and Sources
5
20
  - **progressTicks** – Prints out a tick for every n items seen and a new line for every m ticks.
6
21
  Especially useful for debugging and marking progress in logs.
@@ -12,6 +27,10 @@
12
27
  ### Improvements
13
28
  - Rewrote firstN to use decorator syntax (making it shorter) and to not throw an exception
14
29
  when there are fewer than N items.
30
+ - Created a set of protocols for search engines, both full-text and vector DB-based.
31
+ These protocols can be used to write wrappers around different search engines and
32
+ vector databases, providing a common API that can then be used in different segments
33
+ and sources.
15
34
  - Integrated the Whoosh pure-Python, stand-alone search engine. This is intended for testing,
16
35
  debugging, and smaller stand-alone scenarios. It allows a programmer to work on pipelines that
17
36
  use full-text search engines without setting up a full search engine server. It can support
@@ -20,6 +39,9 @@
20
39
  - Added SimpleVectorDB, a pure Python, simple vector database. It allows a programmer to build
21
40
  and debug pipelines requiring simple vector databases. It supports smaller-scale databases
22
41
  that can later be replaced with a separate server.
42
+ - Added a default option to extract_property and propagated the option to several segments.
43
+ - Wrote a conceptual diagram for the library and wrote short descriptions to orient people to
44
+ how the library can be used.
23
45
 
24
46
  ## 0.6.0
25
47
  ### New Segments and Sources
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: talkpipe
3
- Version: 0.7.0a2
3
+ Version: 0.7.1
4
4
  Summary: Python internal and external DSL for writing generative AI analytics
5
5
  Author-email: Travis Bauer <tlbauer@sandia.gov>
6
6
  Maintainer-email: Travis Bauer <tlbauer@sandia.gov>
@@ -24,7 +24,8 @@ Requires-Dist: python-docx
24
24
  Requires-Dist: pandas
25
25
  Requires-Dist: feedparser
26
26
  Requires-Dist: readability-lxml
27
- Requires-Dist: lxml[html_clean]
27
+ Requires-Dist: lxml
28
+ Requires-Dist: lxml_html_clean
28
29
  Requires-Dist: openai
29
30
  Requires-Dist: fastapi[standard]
30
31
  Requires-Dist: ipywidgets
@@ -56,6 +57,46 @@ TalkPipe is a Python toolkit that makes it easy to create, test, and deploy work
56
57
  - **Create AI Agents** - Build agents that can debate topics, evaluate streams of documents, or monitor RSS feeds
57
58
  - **Deploy Anywhere** - Run in Jupyter notebooks, as Docker containers, or as standalone Python applications
58
59
 
60
+ ## Structure
61
+
62
+ <center><img src="docs/talkpipe_diagram.png" width=700></center>
63
+
64
+ Talkpipe is structured in five layers: Key Functionality, Pipe, ChatterLang, Applications Components, and Docker Containers.
65
+
66
+ The Key Functionality layer offers foundational utilities and abstractions that ensure consistency across the entire system. It includes configuration management, as well as standardized wrappers for interacting with LLMs, full-text search engines, and a lightweight vector database. These components provide a unified interface for core capabilities, making it easy to integrate advanced AI and search features throughout your workflows.
67
+
68
+ The Pipe layer serves as TalkPipe's internal domain-specific language (DSL), enabling you to construct sophisticated workflows directly in Python. By instantiating modular classes and chaining them together using the `|` (pipe) operator, you can seamlessly connect sources, segments, and sinks to process data in a clear, readable, and composable manner. This approach leverages Python's native syntax and type checking, allowing for rapid development, easy debugging, and full IDE support. The Pipe layer is ideal for users who prefer programmatic control and want to integrate TalkPipe pipelines into larger Python applications or scripts.
69
+
70
+ The ChatterLang layer serves as TalkPipe's external domain-specific language (DSL), enabling you to define workflows using concise, human-readable text scripts. These scripts can be compiled directly in Python, producing callable functions that integrate seamlessly with your codebase. ChatterLang also supports specifying workflows via environment variables or command-line arguments, making it easy to configure and automate pipelines in Docker containers, shell scripts, CI/CD pipelines, and other deployment environments. This flexibility empowers both developers and non-developers to create, share, and modify AI-powered workflows without writing Python code, streamlining experimentation and operationalization.
71
+
72
+ The Application Components layer contains runnable applications that provide user interfaces and automation tools for working with TalkPipe pipelines and ChatterLang scripts. These components are designed to make it easy to interact with TalkPipe from the command line, web browser, or as part of automated workflows.
73
+
74
+ ### Key Applications
75
+
76
+ - **chatterlang_server**
77
+ Launches an interactive web interface for writing, testing, and running ChatterLang scripts. It provides real-time execution, logging, and documentation lookup.
78
+
79
+ - **chatterlang_script**
80
+ Runs ChatterLang scripts from files or directly from the command line, enabling batch processing and automation.
81
+
82
+ - **talkpipe_ref**
83
+ Generates HTML and text documentation for all available sources and segments, making it easy to discover and understand built-in functionality.
84
+
85
+ - **talkpipe_endpoint**
86
+ Exposes ChatterLang pipelines as REST APIs or web forms, allowing you to deploy workflows as web services or user-facing endpoints.
87
+
88
+ These applications are entry points for different usage scenarios, from interactive development to production deployment.
89
+
90
+ The Docker layer provides ready-to-use container images for deploying TalkPipe in different environments. It includes:
91
+
92
+ - **talkpipe-base**
93
+ A minimal container image that contains all dependencies required by TalkPipe, but does not install TalkPipe itself. Use this as a foundation for building your own images, custom workflows, or CI/CD jobs where you want to control the installation of TalkPipe or add additional components.
94
+
95
+ - **chatterlang_script**
96
+ An image that installs TalkPipe on top of the base dependencies and runs a talkpipe script.
97
+
98
+ These containers exist to simplify deployment, ensure consistent environments, and enable rapid experimentation or production use of TalkPipe and ChatterLang across platforms.
99
+
59
100
  ## Quick Start
60
101
 
61
102
  Install TalkPipe:
@@ -13,6 +13,46 @@ TalkPipe is a Python toolkit that makes it easy to create, test, and deploy work
13
13
  - **Create AI Agents** - Build agents that can debate topics, evaluate streams of documents, or monitor RSS feeds
14
14
  - **Deploy Anywhere** - Run in Jupyter notebooks, as Docker containers, or as standalone Python applications
15
15
 
16
+ ## Structure
17
+
18
+ <center><img src="docs/talkpipe_diagram.png" width=700></center>
19
+
20
+ Talkpipe is structured in five layers: Key Functionality, Pipe, ChatterLang, Applications Components, and Docker Containers.
21
+
22
+ The Key Functionality layer offers foundational utilities and abstractions that ensure consistency across the entire system. It includes configuration management, as well as standardized wrappers for interacting with LLMs, full-text search engines, and a lightweight vector database. These components provide a unified interface for core capabilities, making it easy to integrate advanced AI and search features throughout your workflows.
23
+
24
+ The Pipe layer serves as TalkPipe's internal domain-specific language (DSL), enabling you to construct sophisticated workflows directly in Python. By instantiating modular classes and chaining them together using the `|` (pipe) operator, you can seamlessly connect sources, segments, and sinks to process data in a clear, readable, and composable manner. This approach leverages Python's native syntax and type checking, allowing for rapid development, easy debugging, and full IDE support. The Pipe layer is ideal for users who prefer programmatic control and want to integrate TalkPipe pipelines into larger Python applications or scripts.
25
+
26
+ The ChatterLang layer serves as TalkPipe's external domain-specific language (DSL), enabling you to define workflows using concise, human-readable text scripts. These scripts can be compiled directly in Python, producing callable functions that integrate seamlessly with your codebase. ChatterLang also supports specifying workflows via environment variables or command-line arguments, making it easy to configure and automate pipelines in Docker containers, shell scripts, CI/CD pipelines, and other deployment environments. This flexibility empowers both developers and non-developers to create, share, and modify AI-powered workflows without writing Python code, streamlining experimentation and operationalization.
27
+
28
+ The Application Components layer contains runnable applications that provide user interfaces and automation tools for working with TalkPipe pipelines and ChatterLang scripts. These components are designed to make it easy to interact with TalkPipe from the command line, web browser, or as part of automated workflows.
29
+
30
+ ### Key Applications
31
+
32
+ - **chatterlang_server**
33
+ Launches an interactive web interface for writing, testing, and running ChatterLang scripts. It provides real-time execution, logging, and documentation lookup.
34
+
35
+ - **chatterlang_script**
36
+ Runs ChatterLang scripts from files or directly from the command line, enabling batch processing and automation.
37
+
38
+ - **talkpipe_ref**
39
+ Generates HTML and text documentation for all available sources and segments, making it easy to discover and understand built-in functionality.
40
+
41
+ - **talkpipe_endpoint**
42
+ Exposes ChatterLang pipelines as REST APIs or web forms, allowing you to deploy workflows as web services or user-facing endpoints.
43
+
44
+ These applications are entry points for different usage scenarios, from interactive development to production deployment.
45
+
46
+ The Docker layer provides ready-to-use container images for deploying TalkPipe in different environments. It includes:
47
+
48
+ - **talkpipe-base**
49
+ A minimal container image that contains all dependencies required by TalkPipe, but does not install TalkPipe itself. Use this as a foundation for building your own images, custom workflows, or CI/CD jobs where you want to control the installation of TalkPipe or add additional components.
50
+
51
+ - **chatterlang_script**
52
+ An image that installs TalkPipe on top of the base dependencies and runs a talkpipe script.
53
+
54
+ These containers exist to simplify deployment, ensure consistent environments, and enable rapid experimentation or production use of TalkPipe and ChatterLang across platforms.
55
+
16
56
  ## Quick Start
17
57
 
18
58
  Install TalkPipe:
@@ -0,0 +1,3 @@
1
+ *.swp
2
+ *.aux
3
+ *~
@@ -0,0 +1,3 @@
1
+ pdflatex structure.tex
2
+ convert -density 300 structure.pdf -quality 100 talkpipe_diagram.png
3
+ rm structure.pdf
@@ -0,0 +1,59 @@
1
+ \documentclass[tikz]{standalone}
2
+ \usepackage{tikz}
3
+ \usetikzlibrary{positioning, shapes, fit, backgrounds, calc, arrows.meta}
4
+
5
+ % Declare the layers
6
+ \pgfdeclarelayer{background}
7
+ \pgfdeclarelayer{docker}
8
+ \pgfsetlayers{background,docker,main}
9
+
10
+ \begin{document}
11
+ \begin{tikzpicture}[
12
+ box/.style={rectangle, draw, rounded corners, minimum width=6cm, minimum height=1cm, align=center, fill=white},
13
+ keylayer/.style={draw=blue!60, fill=blue!10, thick, rounded corners, inner sep=10pt},
14
+ dockerlayer/.style={draw=gray!80, fill=gray!20, thick, rounded corners, inner sep=15pt},
15
+ arrow/.style={->, thick, blue!60, >=stealth},
16
+ font=\sffamily
17
+ ]
18
+ % Key Functionality nodes
19
+ \node[box] (flow) {FLOW CONTROL\\\scriptsize (e.g. filtering, expressions, conversions)};
20
+ \node[box, below=0cm of flow] (data) {DATA MANIPULATION\\\scriptsize (e.g. download, html cleaning)};
21
+ \node[box, below=0cm of data] (llm) {LLM PRIMITIVES\\\scriptsize (e.g. chat, scoring, embedding)};
22
+ \node[box, below=0cm of llm] (store) {DATA STORAGE\\\scriptsize (e.g. full text indexing, vector database)};
23
+ \node[box, below=0cm of store] (utils) {UTILS\\\scriptsize (e.g. configuration)};
24
+
25
+ % Pipe - increased spacing to accommodate label
26
+ \node[box, above=1.2cm of flow] (pipe) {PIPE\\\scriptsize Internal DSL for composing AI workflows};
27
+
28
+ % ChatterLang
29
+ \node[box, above=0.5cm of pipe] (chatter) {CHATTERLANG\\\scriptsize External DSL for composing AI workflows};
30
+
31
+ % Application Layer
32
+ \node[box, above=0.5cm of chatter] (app) {
33
+ \textbf{APPLICATION COMPONENTS}\\
34
+ \scriptsize Command-line Apps \quad API Endpoints \quad Exploratory Web UIs \quad Prototypes
35
+ };
36
+
37
+ % Docker container background around all (bottom layer)
38
+ \begin{pgfonlayer}{background}
39
+ \node[dockerlayer, fit=(app)(utils)] (docker-bg) {};
40
+ \end{pgfonlayer}
41
+
42
+ % Key Functionality background box (middle layer)
43
+ \begin{pgfonlayer}{docker}
44
+ \node[keylayer, fit=(flow)(data)(llm)(store)(utils)] (key-bg) {};
45
+ \end{pgfonlayer}
46
+
47
+ % Key Functionality label (main layer - centered at top)
48
+ \node[at=(key-bg.north), anchor=south, yshift=-2pt, fill=blue!10, inner sep=3pt, draw=blue!60, rounded corners=3pt] (kfbox) {\textbf{KEY FUNCTIONALITY}};
49
+
50
+ % Docker label (main layer - centered at top)
51
+ \node[at=(docker-bg.north), anchor=south, yshift=-2pt, fill=gray!20, inner sep=3pt, draw=gray!80, rounded corners=3pt] {\textbf{DOCKER CONTAINER}};
52
+
53
+ % Arrows connecting the components
54
+ \draw[arrow] (kfbox.north) -- (pipe.south);
55
+ \draw[arrow] (pipe.north) -- (chatter.south);
56
+ \draw[arrow] (chatter.north) -- (app.south);
57
+
58
+ \end{tikzpicture}
59
+ \end{document}
Binary file
@@ -0,0 +1,2 @@
1
+ full_text_index
2
+ vector_index