flock-core 0.1.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.

Potentially problematic release.


This version of flock-core might be problematic. Click here for more details.

Files changed (117) hide show
  1. flock_core-0.1.1/.gitignore +173 -0
  2. flock_core-0.1.1/.python-version +1 -0
  3. flock_core-0.1.1/.vscode/launch.json +12 -0
  4. flock_core-0.1.1/.vscode/settings.json +30 -0
  5. flock_core-0.1.1/.vscode/tasks.json +113 -0
  6. flock_core-0.1.1/LICENSE +21 -0
  7. flock_core-0.1.1/PKG-INFO +449 -0
  8. flock_core-0.1.1/README.md +422 -0
  9. flock_core-0.1.1/bloggy.json +1 -0
  10. flock_core-0.1.1/data/history.json +63 -0
  11. flock_core-0.1.1/data/mock.json +182 -0
  12. flock_core-0.1.1/docs/all.txt +212 -0
  13. flock_core-0.1.1/docs/charts/README.md +53 -0
  14. flock_core-0.1.1/docs/charts/agent-workflow.md +44 -0
  15. flock_core-0.1.1/docs/charts/architecture.drawio +13 -0
  16. flock_core-0.1.1/docs/charts/charts.drawio.png +0 -0
  17. flock_core-0.1.1/docs/charts/core-architecture.md +45 -0
  18. flock_core-0.1.1/docs/charts/temporal-workflow.md +44 -0
  19. flock_core-0.1.1/docs/charts/tool-system.md +42 -0
  20. flock_core-0.1.1/docs/charts/type-system.md +40 -0
  21. flock_core-0.1.1/docs/collect.py +37 -0
  22. flock_core-0.1.1/docs/collect_python_files.py +24 -0
  23. flock_core-0.1.1/docs/hive1.png +0 -0
  24. flock_core-0.1.1/docs/hive2.png +0 -0
  25. flock_core-0.1.1/docs/hive_out.png +0 -0
  26. flock_core-0.1.1/docs/ideas/final_review.md +338 -0
  27. flock_core-0.1.1/docs/ideas/integration.md +269 -0
  28. flock_core-0.1.1/docs/ideas/interpreter.md +316 -0
  29. flock_core-0.1.1/docs/ideas/optimizers.md +309 -0
  30. flock_core-0.1.1/docs/ideas/potential_improvements.md +331 -0
  31. flock_core-0.1.1/docs/ideas/predict.md +276 -0
  32. flock_core-0.1.1/docs/ideas/react.md +304 -0
  33. flock_core-0.1.1/docs/ideas/reimplementation.md +310 -0
  34. flock_core-0.1.1/docs/ideas/week0.md +181 -0
  35. flock_core-0.1.1/docs/ideas/week1.md +276 -0
  36. flock_core-0.1.1/docs/ideas/week2.md +307 -0
  37. flock_core-0.1.1/docs/ideas/week3.md +364 -0
  38. flock_core-0.1.1/docs/ideas/week4.md +359 -0
  39. flock_core-0.1.1/docs/ideas/week5.md +361 -0
  40. flock_core-0.1.1/docs/img/app.png +0 -0
  41. flock_core-0.1.1/docs/img/charts/agent_workflow.png +0 -0
  42. flock_core-0.1.1/docs/img/charts/agent_workflow_inv.png +0 -0
  43. flock_core-0.1.1/docs/img/charts/core_architecture.png +0 -0
  44. flock_core-0.1.1/docs/img/charts/core_architecture_inv.png +0 -0
  45. flock_core-0.1.1/docs/img/charts/tool_system.png +0 -0
  46. flock_core-0.1.1/docs/img/charts/tool_system_inv.png +0 -0
  47. flock_core-0.1.1/docs/old_schwarm_readme.md +246 -0
  48. flock_core-0.1.1/docs/old_schwarm_readme2.md +308 -0
  49. flock_core-0.1.1/docs/scratchpad.md +82 -0
  50. flock_core-0.1.1/docs/todo.md +177 -0
  51. flock_core-0.1.1/examples/jupyter_notebooks/Untitled-1.ipynb +151 -0
  52. flock_core-0.1.1/examples/jupyter_notebooks/my_agent.json +1 -0
  53. flock_core-0.1.1/examples/misc/01_simple_example.py +35 -0
  54. flock_core-0.1.1/examples/misc/02_typed_output.py +111 -0
  55. flock_core-0.1.1/examples/misc/03_tool_agent.py +37 -0
  56. flock_core-0.1.1/examples/misc/04_tool_agent2.py +32 -0
  57. flock_core-0.1.1/examples/misc/05_hand_off.py +45 -0
  58. flock_core-0.1.1/examples/misc/06_chat.py +54 -0
  59. flock_core-0.1.1/examples/misc/07_deploy_as_docker.py +40 -0
  60. flock_core-0.1.1/examples/misc/07_deployment.py +0 -0
  61. flock_core-0.1.1/examples/misc/08_provider.py +55 -0
  62. flock_core-0.1.1/examples/misc/logging_examples/01_basic_logging.py +55 -0
  63. flock_core-0.1.1/examples/misc/logging_examples/02_temporal_logging.py +112 -0
  64. flock_core-0.1.1/examples/web/schwarm_editor/.sesskey +1 -0
  65. flock_core-0.1.1/examples/web/schwarm_editor/main.py +188 -0
  66. flock_core-0.1.1/examples/web/schwarm_editor/saves/alerts.txt +16 -0
  67. flock_core-0.1.1/examples/web/schwarm_editor/scripts/editor.css +34 -0
  68. flock_core-0.1.1/examples/web/schwarm_editor/scripts/editor.js +117 -0
  69. flock_core-0.1.1/examples/web/schwarm_editor/templates/editor.html +73 -0
  70. flock_core-0.1.1/examples/web/schwarm_editor/templates/editor2.html +147 -0
  71. flock_core-0.1.1/pyproject.toml +104 -0
  72. flock_core-0.1.1/src/flock/__init__.py +4 -0
  73. flock_core-0.1.1/src/flock/agents/__init__.py +3 -0
  74. flock_core-0.1.1/src/flock/agents/batch_agent.py +175 -0
  75. flock_core-0.1.1/src/flock/agents/declarative_agent.py +166 -0
  76. flock_core-0.1.1/src/flock/agents/loop_agent.py +178 -0
  77. flock_core-0.1.1/src/flock/agents/trigger_agent.py +191 -0
  78. flock_core-0.1.1/src/flock/agents/user_agent.py +230 -0
  79. flock_core-0.1.1/src/flock/app/components/__init__.py +14 -0
  80. flock_core-0.1.1/src/flock/app/components/charts/agent_workflow.py +14 -0
  81. flock_core-0.1.1/src/flock/app/components/charts/core_architecture.py +14 -0
  82. flock_core-0.1.1/src/flock/app/components/charts/tool_system.py +14 -0
  83. flock_core-0.1.1/src/flock/app/components/history_grid.py +168 -0
  84. flock_core-0.1.1/src/flock/app/components/history_grid_alt.py +189 -0
  85. flock_core-0.1.1/src/flock/app/components/sidebar.py +19 -0
  86. flock_core-0.1.1/src/flock/app/components/theme.py +9 -0
  87. flock_core-0.1.1/src/flock/app/components/util.py +18 -0
  88. flock_core-0.1.1/src/flock/app/hive_app.py +118 -0
  89. flock_core-0.1.1/src/flock/app/html/d3.html +179 -0
  90. flock_core-0.1.1/src/flock/app/modules/__init__.py +12 -0
  91. flock_core-0.1.1/src/flock/app/modules/about.py +17 -0
  92. flock_core-0.1.1/src/flock/app/modules/agent_detail.py +70 -0
  93. flock_core-0.1.1/src/flock/app/modules/agent_list.py +59 -0
  94. flock_core-0.1.1/src/flock/app/modules/playground.py +322 -0
  95. flock_core-0.1.1/src/flock/app/modules/settings.py +96 -0
  96. flock_core-0.1.1/src/flock/core/__init__.py +7 -0
  97. flock_core-0.1.1/src/flock/core/agent.py +150 -0
  98. flock_core-0.1.1/src/flock/core/agent_registry.py +162 -0
  99. flock_core-0.1.1/src/flock/core/config/declarative_agent_config.py +0 -0
  100. flock_core-0.1.1/src/flock/core/context.py +279 -0
  101. flock_core-0.1.1/src/flock/core/context_vars.py +6 -0
  102. flock_core-0.1.1/src/flock/core/flock.py +208 -0
  103. flock_core-0.1.1/src/flock/core/handoff/handoff_base.py +12 -0
  104. flock_core-0.1.1/src/flock/core/logging/__init__.py +18 -0
  105. flock_core-0.1.1/src/flock/core/logging/error_handler.py +84 -0
  106. flock_core-0.1.1/src/flock/core/logging/formatters.py +122 -0
  107. flock_core-0.1.1/src/flock/core/logging/handlers.py +117 -0
  108. flock_core-0.1.1/src/flock/core/logging/logger.py +107 -0
  109. flock_core-0.1.1/src/flock/core/serializable.py +206 -0
  110. flock_core-0.1.1/src/flock/core/tools/basic_tools.py +98 -0
  111. flock_core-0.1.1/src/flock/workflow/activities.py +115 -0
  112. flock_core-0.1.1/src/flock/workflow/agent_activities.py +26 -0
  113. flock_core-0.1.1/src/flock/workflow/temporal_setup.py +37 -0
  114. flock_core-0.1.1/src/flock/workflow/workflow.py +53 -0
  115. flock_core-0.1.1/tests/test_agent.py +196 -0
  116. flock_core-0.1.1/tests/test_basic.py +49 -0
  117. flock_core-0.1.1/tests/test_run_worker.py +49 -0
@@ -0,0 +1,173 @@
1
+ # Byte-compiled / optimized / DLL files
2
+ __pycache__/
3
+ *.py[cod]
4
+ *$py.class
5
+
6
+ # C extensions
7
+ *.so
8
+
9
+ # Distribution / packaging
10
+ .Python
11
+ build/
12
+ develop-eggs/
13
+ dist/
14
+ downloads/
15
+ eggs/
16
+ .eggs/
17
+ lib/
18
+ lib64/
19
+ parts/
20
+ sdist/
21
+ var/
22
+ wheels/
23
+ share/python-wheels/
24
+ *.egg-info/
25
+ .installed.cfg
26
+ *.egg
27
+ MANIFEST
28
+
29
+
30
+ # PyInstaller
31
+ # Usually these files are written by a python script from a template
32
+ # before PyInstaller builds the exe, so as to inject date/other infos into it.
33
+ *.manifest
34
+ *.spec
35
+
36
+ # Installer logs
37
+ pip-log.txt
38
+ pip-delete-this-directory.txt
39
+
40
+ # Unit test / coverage reports
41
+ htmlcov/
42
+ .tox/
43
+ .nox/
44
+ .coverage
45
+ .coverage.*
46
+ .cache
47
+ nosetests.xml
48
+ coverage.xml
49
+ *.cover
50
+ *.py,cover
51
+ .hypothesis/
52
+ .pytest_cache/
53
+ cover/
54
+
55
+ # Translations
56
+ *.mo
57
+ *.pot
58
+
59
+ # Django stuff:
60
+ *.log
61
+ local_settings.py
62
+ db.sqlite3
63
+ db.sqlite3-journal
64
+
65
+ # Flask stuff:
66
+ instance/
67
+ .webassets-cache
68
+
69
+ # Scrapy stuff:
70
+ .scrapy
71
+
72
+ # Sphinx documentation
73
+ docs/_build/
74
+
75
+ # PyBuilder
76
+ .pybuilder/
77
+ target/
78
+
79
+ # Jupyter Notebook
80
+ .ipynb_checkpoints
81
+
82
+ # IPython
83
+ profile_default/
84
+ ipython_config.py
85
+
86
+ # pyenv
87
+ # For a library or package, you might want to ignore these files since the code is
88
+ # intended to run in multiple environments; otherwise, check them in:
89
+ # .python-version
90
+
91
+ # pipenv
92
+ # According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
93
+ # However, in case of collaboration, if having platform-specific dependencies or dependencies
94
+ # having no cross-platform support, pipenv may install dependencies that don't work, or not
95
+ # install all needed dependencies.
96
+ #Pipfile.lock
97
+
98
+ # UV
99
+ # Similar to Pipfile.lock, it is generally recommended to include uv.lock in version control.
100
+ # This is especially recommended for binary packages to ensure reproducibility, and is more
101
+ # commonly ignored for libraries.
102
+ #uv.lock
103
+
104
+ # poetry
105
+ # Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control.
106
+ # This is especially recommended for binary packages to ensure reproducibility, and is more
107
+ # commonly ignored for libraries.
108
+ # https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control
109
+ #poetry.lock
110
+
111
+ # pdm
112
+ # Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control.
113
+ #pdm.lock
114
+ # pdm stores project-wide configurations in .pdm.toml, but it is recommended to not include it
115
+ # in version control.
116
+ # https://pdm.fming.dev/latest/usage/project/#working-with-version-control
117
+ .pdm.toml
118
+ .pdm-python
119
+ .pdm-build/
120
+
121
+ # PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm
122
+ __pypackages__/
123
+
124
+ # Celery stuff
125
+ celerybeat-schedule
126
+ celerybeat.pid
127
+
128
+ # SageMath parsed files
129
+ *.sage.py
130
+
131
+ # Environments
132
+ .env
133
+ .venv
134
+ env/
135
+ venv/
136
+ ENV/
137
+ env.bak/
138
+ venv.bak/
139
+
140
+ # Spyder project settings
141
+ .spyderproject
142
+ .spyproject
143
+
144
+ # Rope project settings
145
+ .ropeproject
146
+
147
+ # mkdocs documentation
148
+ /site
149
+
150
+ # mypy
151
+ .mypy_cache/
152
+ .dmypy.json
153
+ dmypy.json
154
+
155
+ # Pyre type checker
156
+ .pyre/
157
+
158
+ # pytype static type analyzer
159
+ .pytype/
160
+
161
+ # Cython debug symbols
162
+ cython_debug/
163
+
164
+ # PyCharm
165
+ # JetBrains specific template is maintained in a separate JetBrains.gitignore that can
166
+ # be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
167
+ # and can be added to the global gitignore or merged into this file. For a more nuclear
168
+ # option (not recommended) you can uncomment the following to ignore the entire idea folder.
169
+ #.idea/
170
+
171
+ # PyPI configuration file
172
+ .pypirc
173
+ .aider*
@@ -0,0 +1 @@
1
+ 3.12
@@ -0,0 +1,12 @@
1
+ {
2
+ "version": "0.2.0",
3
+ "configurations": [
4
+ {
5
+ "name": "Python Debugger: Current File",
6
+ "type": "debugpy",
7
+ "request": "launch",
8
+ "program": "${file}",
9
+ "console": "integratedTerminal"
10
+ }
11
+ ]
12
+ }
@@ -0,0 +1,30 @@
1
+ {
2
+ "python.testing.pytestArgs": [
3
+ "tests"
4
+ ],
5
+ "python.envFile": "${workspaceFolder}/.env",
6
+ "python.terminal.run_asyncEnvInCurrentTerminal": true,
7
+ "python.testing.unittestEnabled": false,
8
+ "python.testing.pytestEnabled": true,
9
+ "python.testing.autoTestDiscoverOnSaveEnabled": true,
10
+ "editor.formatOnSave": true,
11
+ "editor.codeActionsOnSave": {
12
+ "source.organizeImports.ruff": "always",
13
+ "source.fixAll.ruff": "always"
14
+ },
15
+ // we try to make semantic highlighting look good
16
+ "editor.semanticHighlighting.enabled": true,
17
+ // prevent VSCode from modifying the terminal colors
18
+ "terminal.integrated.minimumContrastRatio": 0,
19
+ "cSpell.words": [
20
+ "deptry",
21
+ "gradio",
22
+ "mkdocs",
23
+ "msgspec",
24
+ "mypy",
25
+ "packb",
26
+ "pyinstrument",
27
+ "pytest",
28
+ "unpackb"
29
+ ],
30
+ }
@@ -0,0 +1,113 @@
1
+ {
2
+ "version": "2.0.0",
3
+ "tasks": [
4
+ {
5
+ "label": "sync env",
6
+ "type": "process",
7
+ "command": "uv",
8
+ "args": [
9
+ "build",
10
+ "--all"
11
+ ],
12
+ "group": {
13
+ "kind": "build",
14
+ "isDefault": true
15
+ },
16
+ "problemMatcher": "$python",
17
+ "presentation": {
18
+ "echo": true,
19
+ "reveal": "always",
20
+ "focus": true,
21
+ "panel": "shared",
22
+ "clear": false
23
+ }
24
+ },
25
+ {
26
+ "label": "Run Test",
27
+ "type": "process",
28
+ "command": "uv",
29
+ "args": [
30
+ "run",
31
+ "poe",
32
+ "run_test"
33
+ ],
34
+ "group": {
35
+ "kind": "test",
36
+ "isDefault": true
37
+ },
38
+ "problemMatcher": "$python",
39
+ "presentation": {
40
+ "echo": true,
41
+ "reveal": "always",
42
+ "focus": true,
43
+ "panel": "new",
44
+ "clear": false
45
+ }
46
+ },
47
+ {
48
+ "label": "Docker Build",
49
+ "type": "process",
50
+ "command": "uv",
51
+ "args": [
52
+ "run",
53
+ "poe",
54
+ "docker_build"
55
+ ],
56
+ "group": {
57
+ "kind": "test",
58
+ "isDefault": true
59
+ },
60
+ "problemMatcher": "$python",
61
+ "presentation": {
62
+ "echo": true,
63
+ "reveal": "always",
64
+ "focus": true,
65
+ "panel": "new",
66
+ "clear": false
67
+ }
68
+ },
69
+ {
70
+ "label": "Docker Run",
71
+ "type": "process",
72
+ "command": "uv",
73
+ "args": [
74
+ "run",
75
+ "poe",
76
+ "docker_run"
77
+ ],
78
+ "group": {
79
+ "kind": "test",
80
+ "isDefault": true
81
+ },
82
+ "problemMatcher": "$python",
83
+ "presentation": {
84
+ "echo": true,
85
+ "reveal": "always",
86
+ "focus": true,
87
+ "panel": "new",
88
+ "clear": false
89
+ }
90
+ },
91
+ {
92
+ "label": "Build Docs",
93
+ "type": "process",
94
+ "command": "uv",
95
+ "args": [
96
+ "run",
97
+ "poe",
98
+ "mkdocs"
99
+ ],
100
+ "group": {
101
+ "kind": "test",
102
+ "isDefault": true
103
+ },
104
+ "presentation": {
105
+ "echo": true,
106
+ "reveal": "always",
107
+ "focus": true,
108
+ "panel": "new",
109
+ "clear": false
110
+ }
111
+ }
112
+ ]
113
+ }
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2024 white duck GmbH
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.