tumblrbot 1.9.4__tar.gz → 1.9.5__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.
- {tumblrbot-1.9.4 → tumblrbot-1.9.5}/.gitignore +221 -221
- {tumblrbot-1.9.4 → tumblrbot-1.9.5}/PKG-INFO +22 -5
- {tumblrbot-1.9.4 → tumblrbot-1.9.5}/README.md +20 -2
- {tumblrbot-1.9.4 → tumblrbot-1.9.5}/pyproject.toml +3 -4
- {tumblrbot-1.9.4 → tumblrbot-1.9.5}/sample_custom_prompts.jsonl +0 -26
- {tumblrbot-1.9.4 → tumblrbot-1.9.5}/src/tumblrbot/flow/download.py +4 -2
- {tumblrbot-1.9.4 → tumblrbot-1.9.5}/src/tumblrbot/flow/examples.py +5 -3
- {tumblrbot-1.9.4 → tumblrbot-1.9.5}/src/tumblrbot/flow/fine_tune.py +7 -4
- {tumblrbot-1.9.4 → tumblrbot-1.9.5}/src/tumblrbot/flow/generate.py +4 -2
- {tumblrbot-1.9.4 → tumblrbot-1.9.5}/src/tumblrbot/utils/models.py +3 -3
- {tumblrbot-1.9.4 → tumblrbot-1.9.5}/.github/FUNDING.yml +0 -0
- {tumblrbot-1.9.4 → tumblrbot-1.9.5}/.github/dependabot.yml +0 -0
- {tumblrbot-1.9.4 → tumblrbot-1.9.5}/UNLICENSE +0 -0
- {tumblrbot-1.9.4 → tumblrbot-1.9.5}/src/tumblrbot/__init__.py +0 -0
- {tumblrbot-1.9.4 → tumblrbot-1.9.5}/src/tumblrbot/__main__.py +0 -0
- {tumblrbot-1.9.4 → tumblrbot-1.9.5}/src/tumblrbot/flow/__init__.py +0 -0
- {tumblrbot-1.9.4 → tumblrbot-1.9.5}/src/tumblrbot/utils/__init__.py +0 -0
- {tumblrbot-1.9.4 → tumblrbot-1.9.5}/src/tumblrbot/utils/common.py +0 -0
- {tumblrbot-1.9.4 → tumblrbot-1.9.5}/src/tumblrbot/utils/tumblr.py +0 -0
|
@@ -1,221 +1,221 @@
|
|
|
1
|
-
# Byte-compiled / optimized / DLL files
|
|
2
|
-
__pycache__/
|
|
3
|
-
*.py[codz]
|
|
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
|
-
# PyInstaller
|
|
30
|
-
#
|
|
31
|
-
#
|
|
32
|
-
*.manifest
|
|
33
|
-
*.spec
|
|
34
|
-
|
|
35
|
-
# Installer logs
|
|
36
|
-
pip-log.txt
|
|
37
|
-
pip-delete-this-directory.txt
|
|
38
|
-
|
|
39
|
-
# Unit test / coverage reports
|
|
40
|
-
htmlcov/
|
|
41
|
-
.tox/
|
|
42
|
-
.nox/
|
|
43
|
-
.coverage
|
|
44
|
-
.coverage.*
|
|
45
|
-
.cache
|
|
46
|
-
nosetests.xml
|
|
47
|
-
coverage.xml
|
|
48
|
-
*.cover
|
|
49
|
-
*.py.cover
|
|
50
|
-
.hypothesis/
|
|
51
|
-
.pytest_cache/
|
|
52
|
-
cover/
|
|
53
|
-
|
|
54
|
-
# Translations
|
|
55
|
-
*.mo
|
|
56
|
-
*.pot
|
|
57
|
-
|
|
58
|
-
# Django stuff:
|
|
59
|
-
*.log
|
|
60
|
-
local_settings.py
|
|
61
|
-
db.sqlite3
|
|
62
|
-
db.sqlite3-journal
|
|
63
|
-
|
|
64
|
-
# Flask stuff:
|
|
65
|
-
instance/
|
|
66
|
-
.webassets-cache
|
|
67
|
-
|
|
68
|
-
# Scrapy stuff:
|
|
69
|
-
.scrapy
|
|
70
|
-
|
|
71
|
-
# Sphinx documentation
|
|
72
|
-
docs/_build/
|
|
73
|
-
|
|
74
|
-
# PyBuilder
|
|
75
|
-
.pybuilder/
|
|
76
|
-
target/
|
|
77
|
-
|
|
78
|
-
# Jupyter Notebook
|
|
79
|
-
.ipynb_checkpoints
|
|
80
|
-
|
|
81
|
-
# IPython
|
|
82
|
-
profile_default/
|
|
83
|
-
ipython_config.py
|
|
84
|
-
|
|
85
|
-
# pyenv
|
|
86
|
-
# For a library or package, you might want to ignore these files since the code is
|
|
87
|
-
# intended to run in multiple environments; otherwise, check them in:
|
|
88
|
-
# .python-version
|
|
89
|
-
|
|
90
|
-
# pipenv
|
|
91
|
-
# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
|
|
92
|
-
# However, in case of collaboration, if having platform-specific dependencies or dependencies
|
|
93
|
-
# having no cross-platform support, pipenv may install dependencies that don't work, or not
|
|
94
|
-
# install all needed dependencies.
|
|
95
|
-
#Pipfile.lock
|
|
96
|
-
|
|
97
|
-
# UV
|
|
98
|
-
# Similar to Pipfile.lock, it is generally recommended to include uv.lock in version control.
|
|
99
|
-
# This is especially recommended for binary packages to ensure reproducibility, and is more
|
|
100
|
-
# commonly ignored for libraries.
|
|
101
|
-
#uv.lock
|
|
102
|
-
|
|
103
|
-
# poetry
|
|
104
|
-
# Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control.
|
|
105
|
-
# This is especially recommended for binary packages to ensure reproducibility, and is more
|
|
106
|
-
# commonly ignored for libraries.
|
|
107
|
-
# https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control
|
|
108
|
-
#poetry.lock
|
|
109
|
-
#poetry.toml
|
|
110
|
-
|
|
111
|
-
# pdm
|
|
112
|
-
# Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control.
|
|
113
|
-
# pdm recommends including project-wide configuration in pdm.toml, but excluding .pdm-python.
|
|
114
|
-
# https://pdm-project.org/en/latest/usage/project/#working-with-version-control
|
|
115
|
-
#pdm.lock
|
|
116
|
-
#pdm.toml
|
|
117
|
-
.pdm-python
|
|
118
|
-
.pdm-build/
|
|
119
|
-
|
|
120
|
-
# pixi
|
|
121
|
-
# Similar to Pipfile.lock, it is generally recommended to include pixi.lock in version control.
|
|
122
|
-
#pixi.lock
|
|
123
|
-
# Pixi creates a virtual environment in the .pixi directory, just like venv module creates one
|
|
124
|
-
# in the .venv directory. It is recommended not to include this directory in version control.
|
|
125
|
-
.pixi
|
|
126
|
-
|
|
127
|
-
# PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm
|
|
128
|
-
__pypackages__/
|
|
129
|
-
|
|
130
|
-
# Celery stuff
|
|
131
|
-
celerybeat-schedule
|
|
132
|
-
celerybeat.pid
|
|
133
|
-
|
|
134
|
-
# Redis
|
|
135
|
-
*.rdb
|
|
136
|
-
*.aof
|
|
137
|
-
*.pid
|
|
138
|
-
|
|
139
|
-
# RabbitMQ
|
|
140
|
-
mnesia/
|
|
141
|
-
rabbitmq/
|
|
142
|
-
rabbitmq-data/
|
|
143
|
-
|
|
144
|
-
# ActiveMQ
|
|
145
|
-
activemq-data/
|
|
146
|
-
|
|
147
|
-
# SageMath parsed files
|
|
148
|
-
*.sage.py
|
|
149
|
-
|
|
150
|
-
# Environments
|
|
151
|
-
.env
|
|
152
|
-
.envrc
|
|
153
|
-
.venv
|
|
154
|
-
env/
|
|
155
|
-
venv/
|
|
156
|
-
ENV/
|
|
157
|
-
env.bak/
|
|
158
|
-
venv.bak/
|
|
159
|
-
|
|
160
|
-
# Spyder project settings
|
|
161
|
-
.spyderproject
|
|
162
|
-
.spyproject
|
|
163
|
-
|
|
164
|
-
# Rope project settings
|
|
165
|
-
.ropeproject
|
|
166
|
-
|
|
167
|
-
# mkdocs documentation
|
|
168
|
-
/site
|
|
169
|
-
|
|
170
|
-
# mypy
|
|
171
|
-
.mypy_cache/
|
|
172
|
-
.dmypy.json
|
|
173
|
-
dmypy.json
|
|
174
|
-
|
|
175
|
-
# Pyre type checker
|
|
176
|
-
.pyre/
|
|
177
|
-
|
|
178
|
-
# pytype static type analyzer
|
|
179
|
-
.pytype/
|
|
180
|
-
|
|
181
|
-
# Cython debug symbols
|
|
182
|
-
cython_debug/
|
|
183
|
-
|
|
184
|
-
# PyCharm
|
|
185
|
-
#
|
|
186
|
-
#
|
|
187
|
-
#
|
|
188
|
-
#
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
# Abstra
|
|
192
|
-
#
|
|
193
|
-
#
|
|
194
|
-
#
|
|
195
|
-
.abstra/
|
|
196
|
-
|
|
197
|
-
# Visual Studio Code
|
|
198
|
-
#
|
|
199
|
-
#
|
|
200
|
-
#
|
|
201
|
-
#
|
|
202
|
-
.vscode/
|
|
203
|
-
|
|
204
|
-
# Ruff stuff:
|
|
205
|
-
.ruff_cache/
|
|
206
|
-
|
|
207
|
-
# PyPI configuration file
|
|
208
|
-
.pypirc
|
|
209
|
-
|
|
210
|
-
# Marimo
|
|
211
|
-
marimo/_static/
|
|
212
|
-
marimo/_lsp/
|
|
213
|
-
__marimo__/
|
|
214
|
-
|
|
215
|
-
# Streamlit
|
|
216
|
-
.streamlit/secrets.toml
|
|
217
|
-
|
|
218
|
-
data
|
|
219
|
-
*.
|
|
220
|
-
*.
|
|
221
|
-
|
|
1
|
+
# Byte-compiled / optimized / DLL files
|
|
2
|
+
__pycache__/
|
|
3
|
+
*.py[codz]
|
|
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
|
+
# PyInstaller
|
|
30
|
+
# Usually these files are written by a python script from a template
|
|
31
|
+
# before PyInstaller builds the exe, so as to inject date/other infos into it.
|
|
32
|
+
*.manifest
|
|
33
|
+
*.spec
|
|
34
|
+
|
|
35
|
+
# Installer logs
|
|
36
|
+
pip-log.txt
|
|
37
|
+
pip-delete-this-directory.txt
|
|
38
|
+
|
|
39
|
+
# Unit test / coverage reports
|
|
40
|
+
htmlcov/
|
|
41
|
+
.tox/
|
|
42
|
+
.nox/
|
|
43
|
+
.coverage
|
|
44
|
+
.coverage.*
|
|
45
|
+
.cache
|
|
46
|
+
nosetests.xml
|
|
47
|
+
coverage.xml
|
|
48
|
+
*.cover
|
|
49
|
+
*.py.cover
|
|
50
|
+
.hypothesis/
|
|
51
|
+
.pytest_cache/
|
|
52
|
+
cover/
|
|
53
|
+
|
|
54
|
+
# Translations
|
|
55
|
+
*.mo
|
|
56
|
+
*.pot
|
|
57
|
+
|
|
58
|
+
# Django stuff:
|
|
59
|
+
*.log
|
|
60
|
+
local_settings.py
|
|
61
|
+
db.sqlite3
|
|
62
|
+
db.sqlite3-journal
|
|
63
|
+
|
|
64
|
+
# Flask stuff:
|
|
65
|
+
instance/
|
|
66
|
+
.webassets-cache
|
|
67
|
+
|
|
68
|
+
# Scrapy stuff:
|
|
69
|
+
.scrapy
|
|
70
|
+
|
|
71
|
+
# Sphinx documentation
|
|
72
|
+
docs/_build/
|
|
73
|
+
|
|
74
|
+
# PyBuilder
|
|
75
|
+
.pybuilder/
|
|
76
|
+
target/
|
|
77
|
+
|
|
78
|
+
# Jupyter Notebook
|
|
79
|
+
.ipynb_checkpoints
|
|
80
|
+
|
|
81
|
+
# IPython
|
|
82
|
+
profile_default/
|
|
83
|
+
ipython_config.py
|
|
84
|
+
|
|
85
|
+
# pyenv
|
|
86
|
+
# For a library or package, you might want to ignore these files since the code is
|
|
87
|
+
# intended to run in multiple environments; otherwise, check them in:
|
|
88
|
+
# .python-version
|
|
89
|
+
|
|
90
|
+
# pipenv
|
|
91
|
+
# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
|
|
92
|
+
# However, in case of collaboration, if having platform-specific dependencies or dependencies
|
|
93
|
+
# having no cross-platform support, pipenv may install dependencies that don't work, or not
|
|
94
|
+
# install all needed dependencies.
|
|
95
|
+
# Pipfile.lock
|
|
96
|
+
|
|
97
|
+
# UV
|
|
98
|
+
# Similar to Pipfile.lock, it is generally recommended to include uv.lock in version control.
|
|
99
|
+
# This is especially recommended for binary packages to ensure reproducibility, and is more
|
|
100
|
+
# commonly ignored for libraries.
|
|
101
|
+
# uv.lock
|
|
102
|
+
|
|
103
|
+
# poetry
|
|
104
|
+
# Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control.
|
|
105
|
+
# This is especially recommended for binary packages to ensure reproducibility, and is more
|
|
106
|
+
# commonly ignored for libraries.
|
|
107
|
+
# https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control
|
|
108
|
+
# poetry.lock
|
|
109
|
+
# poetry.toml
|
|
110
|
+
|
|
111
|
+
# pdm
|
|
112
|
+
# Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control.
|
|
113
|
+
# pdm recommends including project-wide configuration in pdm.toml, but excluding .pdm-python.
|
|
114
|
+
# https://pdm-project.org/en/latest/usage/project/#working-with-version-control
|
|
115
|
+
# pdm.lock
|
|
116
|
+
# pdm.toml
|
|
117
|
+
.pdm-python
|
|
118
|
+
.pdm-build/
|
|
119
|
+
|
|
120
|
+
# pixi
|
|
121
|
+
# Similar to Pipfile.lock, it is generally recommended to include pixi.lock in version control.
|
|
122
|
+
# pixi.lock
|
|
123
|
+
# Pixi creates a virtual environment in the .pixi directory, just like venv module creates one
|
|
124
|
+
# in the .venv directory. It is recommended not to include this directory in version control.
|
|
125
|
+
.pixi
|
|
126
|
+
|
|
127
|
+
# PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm
|
|
128
|
+
__pypackages__/
|
|
129
|
+
|
|
130
|
+
# Celery stuff
|
|
131
|
+
celerybeat-schedule
|
|
132
|
+
celerybeat.pid
|
|
133
|
+
|
|
134
|
+
# Redis
|
|
135
|
+
*.rdb
|
|
136
|
+
*.aof
|
|
137
|
+
*.pid
|
|
138
|
+
|
|
139
|
+
# RabbitMQ
|
|
140
|
+
mnesia/
|
|
141
|
+
rabbitmq/
|
|
142
|
+
rabbitmq-data/
|
|
143
|
+
|
|
144
|
+
# ActiveMQ
|
|
145
|
+
activemq-data/
|
|
146
|
+
|
|
147
|
+
# SageMath parsed files
|
|
148
|
+
*.sage.py
|
|
149
|
+
|
|
150
|
+
# Environments
|
|
151
|
+
.env
|
|
152
|
+
.envrc
|
|
153
|
+
.venv
|
|
154
|
+
env/
|
|
155
|
+
venv/
|
|
156
|
+
ENV/
|
|
157
|
+
env.bak/
|
|
158
|
+
venv.bak/
|
|
159
|
+
|
|
160
|
+
# Spyder project settings
|
|
161
|
+
.spyderproject
|
|
162
|
+
.spyproject
|
|
163
|
+
|
|
164
|
+
# Rope project settings
|
|
165
|
+
.ropeproject
|
|
166
|
+
|
|
167
|
+
# mkdocs documentation
|
|
168
|
+
/site
|
|
169
|
+
|
|
170
|
+
# mypy
|
|
171
|
+
.mypy_cache/
|
|
172
|
+
.dmypy.json
|
|
173
|
+
dmypy.json
|
|
174
|
+
|
|
175
|
+
# Pyre type checker
|
|
176
|
+
.pyre/
|
|
177
|
+
|
|
178
|
+
# pytype static type analyzer
|
|
179
|
+
.pytype/
|
|
180
|
+
|
|
181
|
+
# Cython debug symbols
|
|
182
|
+
cython_debug/
|
|
183
|
+
|
|
184
|
+
# PyCharm
|
|
185
|
+
# JetBrains specific template is maintained in a separate JetBrains.gitignore that can
|
|
186
|
+
# be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
|
|
187
|
+
# and can be added to the global gitignore or merged into this file. For a more nuclear
|
|
188
|
+
# option (not recommended) you can uncomment the following to ignore the entire idea folder.
|
|
189
|
+
# .idea/
|
|
190
|
+
|
|
191
|
+
# Abstra
|
|
192
|
+
# Abstra is an AI-powered process automation framework.
|
|
193
|
+
# Ignore directories containing user credentials, local state, and settings.
|
|
194
|
+
# Learn more at https://abstra.io/docs
|
|
195
|
+
.abstra/
|
|
196
|
+
|
|
197
|
+
# Visual Studio Code
|
|
198
|
+
# Visual Studio Code specific template is maintained in a separate VisualStudioCode.gitignore
|
|
199
|
+
# that can be found at https://github.com/github/gitignore/blob/main/Global/VisualStudioCode.gitignore
|
|
200
|
+
# and can be added to the global gitignore or merged into this file. However, if you prefer,
|
|
201
|
+
# you could uncomment the following to ignore the entire vscode folder
|
|
202
|
+
# .vscode/
|
|
203
|
+
|
|
204
|
+
# Ruff stuff:
|
|
205
|
+
.ruff_cache/
|
|
206
|
+
|
|
207
|
+
# PyPI configuration file
|
|
208
|
+
.pypirc
|
|
209
|
+
|
|
210
|
+
# Marimo
|
|
211
|
+
marimo/_static/
|
|
212
|
+
marimo/_lsp/
|
|
213
|
+
__marimo__/
|
|
214
|
+
|
|
215
|
+
# Streamlit
|
|
216
|
+
.streamlit/secrets.toml
|
|
217
|
+
|
|
218
|
+
data
|
|
219
|
+
*.toml
|
|
220
|
+
*.jsonl
|
|
221
|
+
*.lnk
|
|
@@ -1,12 +1,11 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: tumblrbot
|
|
3
|
-
Version: 1.9.
|
|
3
|
+
Version: 1.9.5
|
|
4
4
|
Summary: An updated bot that posts to Tumblr, based on your very own blog!
|
|
5
|
-
Requires-Python: >= 3.
|
|
5
|
+
Requires-Python: >= 3.14
|
|
6
6
|
Description-Content-Type: text/markdown
|
|
7
7
|
Requires-Dist: click
|
|
8
8
|
Requires-Dist: openai
|
|
9
|
-
Requires-Dist: pwinput
|
|
10
9
|
Requires-Dist: pydantic
|
|
11
10
|
Requires-Dist: requests
|
|
12
11
|
Requires-Dist: requests-oauthlib
|
|
@@ -18,6 +17,8 @@ Project-URL: Source, https://github.com/MaidScientistIzutsumiMarin/tumblrbot
|
|
|
18
17
|
|
|
19
18
|
# tumblrbot
|
|
20
19
|
|
|
20
|
+
[tumblrbot.exe]: https://github.com/MaidScientistIzutsumiMarin/tumblrbot/releases/latest/download/tumblrbot.exe
|
|
21
|
+
|
|
21
22
|
[OAuth]: https://oauth.net/1
|
|
22
23
|
[Python]: https://python.org/download
|
|
23
24
|
|
|
@@ -31,6 +32,7 @@ Project-URL: Source, https://github.com/MaidScientistIzutsumiMarin/tumblrbot
|
|
|
31
32
|
[OpenAI Pricing]: https://platform.openai.com/docs/pricing#fine-tuning
|
|
32
33
|
[OpenAI Tokens]: https://platform.openai.com/settings/organization/api-keys
|
|
33
34
|
[OpenAI Moderation API]: https://platform.openai.com/docs/guides/moderation
|
|
35
|
+
[Flags]: https://platform.openai.com/docs/guides/moderation/over#content-classifications
|
|
34
36
|
[Fine-Tuning Portal]: https://platform.openai.com/finetune
|
|
35
37
|
|
|
36
38
|
[Tumblr]: https://tumblr.com
|
|
@@ -82,11 +84,21 @@ Features:
|
|
|
82
84
|
- Colorful output, progress bars, and post previews using [rich].
|
|
83
85
|
- Automatically keeps the [config][configurable] file up-to-date and recreates it if missing (without overriding user settings).
|
|
84
86
|
|
|
87
|
+
**To-Do:**
|
|
88
|
+
|
|
89
|
+
- Add retry logic for rate limiting.
|
|
90
|
+
|
|
85
91
|
**Known Issues:**
|
|
86
92
|
|
|
93
|
+
- Fine-tuning can fail after the validation phase due to the examples file not passing [OpenAI] moderation checks. There are a few workarounds for this that can be tried in combination:
|
|
94
|
+
- You can retry with the same examples file. This has, on rare occasions, worked.
|
|
95
|
+
- You can submit the examples file to the [OpenAI] moderation API with this program's guided prompts. This has worked consistently for our dataset, but others have reported it not being thorough enough.
|
|
96
|
+
- You can use regular expressions to filter out training data in the [config][configurable]. This is more of a brute-force solution, but it can work if the other solutions do not.
|
|
97
|
+
- You can try limiting your dataset by specifying fewer blogs to download from or limiting the number of posts taken from each one in the [config][configurable].
|
|
98
|
+
- If all else fails, you can manually remove data from the examples file until it passes. It is unfortunately not a definitive resource, but it can help to read about what the [OpenAI moderation API flags][Flags].
|
|
87
99
|
- Sometimes, you will get an error about the training file not being found when starting fine-tuning. We do not currently have a fix or workaround for this. You should instead use the online portal for fine-tuning if this continues to happen. Read more in [fine-tuning].
|
|
88
100
|
- Post counts are incorrect when downloading posts. We are not certain what the cause of this is, but our tests suggest this is a [Tumblr] API problem that is giving inaccurate numbers.
|
|
89
|
-
- During post downloading or post generation, you may receive a
|
|
101
|
+
- During post downloading or post generation, you may receive a “Limit Exceeded” error message from the [Tumblr] API. This is caused by server-side rate-limiting by [Tumblr]. The only workaround is trying again or waiting for a period of time before retrying. In most cases, you either have to wait for a minute or an hour for the limits to reset. You can read more about the limits in the [Tumblr API documentation on rate limits].
|
|
90
102
|
- Similar to the above issue, you may sometimes get a message saying your IP is blocked. This block is temporary and probably follows the same rules as previously described.
|
|
91
103
|
|
|
92
104
|
**Please submit an issue or contact us for features you want added/reimplemented.**
|
|
@@ -101,6 +113,11 @@ Features:
|
|
|
101
113
|
- Alternatively, you can install from this repository: `pip install git+https://github.com/MaidThatPrograms/tumblrbot.git`
|
|
102
114
|
- On Linux, you will have to make a virtual environment or use the flag to install packages system-wide.
|
|
103
115
|
|
|
116
|
+
### Alternative Installation for Windows
|
|
117
|
+
|
|
118
|
+
1. Download the latest release's [tumblrbot.exe].
|
|
119
|
+
1. Run the file directly, or add it to your path, and use it as normal.
|
|
120
|
+
|
|
104
121
|
## Usage
|
|
105
122
|
|
|
106
123
|
Run `tumblrbot` from anywhere. Run `tumblrbot --help` for command-line options. Every command-line option corresponds to a value from the [config][configurable].
|
|
@@ -160,7 +177,7 @@ Specific Options:
|
|
|
160
177
|
To be specific, it should follow the [JSON Lines] file format with one collection of name/value pairs (a dictionary) per line. You can validate your file using the [JSON Lines Validator].
|
|
161
178
|
|
|
162
179
|
- **`post_limit`** - At most, this many valid posts will be included in the training data. This effectively is a filter to select the `N` most recent valid posts from each blog. `0` will use every available valid post.
|
|
163
|
-
- **`filtered_words`** - During training data generation, any posts with the specified words will be removed. Word boundaries are not checked by default, so
|
|
180
|
+
- **`filtered_words`** - During training data generation, any posts with the specified words will be removed. Word boundaries are not checked by default, so “the” will also filter out posts with “them” or “thematic”. This setting supports regular expressions, so you can explicitly look for word boundaries by surrounding an entry with “\\\b”, i.e., “\\\bthe\\\b”. Regular expressions have to be escaped like so due to how JSON data is read in. If you are familiar with regular expressions, it could be useful for you to know that every entry is joined with a “|” which is then used to search the post content for any matches.
|
|
164
181
|
- **`developer_message`** - This message is used in for fine-tuning the AI as well as generating prompts. If you change this, you will need to run the fine-tuning again with the new value before generating posts.
|
|
165
182
|
- **`user_message`** - This setting is used and works in the same way as `developer_message`.
|
|
166
183
|
- **`expected_epochs`** - The default value here is the default number of epochs for `base_model`. You may have to change this value if you change `base_model`. After running fine-tuning once, you will see the number of epochs used in the [fine-tuning portal] under *Hyperparameters*. This value will also be updated automatically if you run fine-tuning through this program.
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
# tumblrbot
|
|
2
2
|
|
|
3
|
+
[tumblrbot.exe]: https://github.com/MaidScientistIzutsumiMarin/tumblrbot/releases/latest/download/tumblrbot.exe
|
|
4
|
+
|
|
3
5
|
[OAuth]: https://oauth.net/1
|
|
4
6
|
[Python]: https://python.org/download
|
|
5
7
|
|
|
@@ -13,6 +15,7 @@
|
|
|
13
15
|
[OpenAI Pricing]: https://platform.openai.com/docs/pricing#fine-tuning
|
|
14
16
|
[OpenAI Tokens]: https://platform.openai.com/settings/organization/api-keys
|
|
15
17
|
[OpenAI Moderation API]: https://platform.openai.com/docs/guides/moderation
|
|
18
|
+
[Flags]: https://platform.openai.com/docs/guides/moderation/over#content-classifications
|
|
16
19
|
[Fine-Tuning Portal]: https://platform.openai.com/finetune
|
|
17
20
|
|
|
18
21
|
[Tumblr]: https://tumblr.com
|
|
@@ -64,11 +67,21 @@ Features:
|
|
|
64
67
|
- Colorful output, progress bars, and post previews using [rich].
|
|
65
68
|
- Automatically keeps the [config][configurable] file up-to-date and recreates it if missing (without overriding user settings).
|
|
66
69
|
|
|
70
|
+
**To-Do:**
|
|
71
|
+
|
|
72
|
+
- Add retry logic for rate limiting.
|
|
73
|
+
|
|
67
74
|
**Known Issues:**
|
|
68
75
|
|
|
76
|
+
- Fine-tuning can fail after the validation phase due to the examples file not passing [OpenAI] moderation checks. There are a few workarounds for this that can be tried in combination:
|
|
77
|
+
- You can retry with the same examples file. This has, on rare occasions, worked.
|
|
78
|
+
- You can submit the examples file to the [OpenAI] moderation API with this program's guided prompts. This has worked consistently for our dataset, but others have reported it not being thorough enough.
|
|
79
|
+
- You can use regular expressions to filter out training data in the [config][configurable]. This is more of a brute-force solution, but it can work if the other solutions do not.
|
|
80
|
+
- You can try limiting your dataset by specifying fewer blogs to download from or limiting the number of posts taken from each one in the [config][configurable].
|
|
81
|
+
- If all else fails, you can manually remove data from the examples file until it passes. It is unfortunately not a definitive resource, but it can help to read about what the [OpenAI moderation API flags][Flags].
|
|
69
82
|
- Sometimes, you will get an error about the training file not being found when starting fine-tuning. We do not currently have a fix or workaround for this. You should instead use the online portal for fine-tuning if this continues to happen. Read more in [fine-tuning].
|
|
70
83
|
- Post counts are incorrect when downloading posts. We are not certain what the cause of this is, but our tests suggest this is a [Tumblr] API problem that is giving inaccurate numbers.
|
|
71
|
-
- During post downloading or post generation, you may receive a
|
|
84
|
+
- During post downloading or post generation, you may receive a “Limit Exceeded” error message from the [Tumblr] API. This is caused by server-side rate-limiting by [Tumblr]. The only workaround is trying again or waiting for a period of time before retrying. In most cases, you either have to wait for a minute or an hour for the limits to reset. You can read more about the limits in the [Tumblr API documentation on rate limits].
|
|
72
85
|
- Similar to the above issue, you may sometimes get a message saying your IP is blocked. This block is temporary and probably follows the same rules as previously described.
|
|
73
86
|
|
|
74
87
|
**Please submit an issue or contact us for features you want added/reimplemented.**
|
|
@@ -83,6 +96,11 @@ Features:
|
|
|
83
96
|
- Alternatively, you can install from this repository: `pip install git+https://github.com/MaidThatPrograms/tumblrbot.git`
|
|
84
97
|
- On Linux, you will have to make a virtual environment or use the flag to install packages system-wide.
|
|
85
98
|
|
|
99
|
+
### Alternative Installation for Windows
|
|
100
|
+
|
|
101
|
+
1. Download the latest release's [tumblrbot.exe].
|
|
102
|
+
1. Run the file directly, or add it to your path, and use it as normal.
|
|
103
|
+
|
|
86
104
|
## Usage
|
|
87
105
|
|
|
88
106
|
Run `tumblrbot` from anywhere. Run `tumblrbot --help` for command-line options. Every command-line option corresponds to a value from the [config][configurable].
|
|
@@ -142,7 +160,7 @@ Specific Options:
|
|
|
142
160
|
To be specific, it should follow the [JSON Lines] file format with one collection of name/value pairs (a dictionary) per line. You can validate your file using the [JSON Lines Validator].
|
|
143
161
|
|
|
144
162
|
- **`post_limit`** - At most, this many valid posts will be included in the training data. This effectively is a filter to select the `N` most recent valid posts from each blog. `0` will use every available valid post.
|
|
145
|
-
- **`filtered_words`** - During training data generation, any posts with the specified words will be removed. Word boundaries are not checked by default, so
|
|
163
|
+
- **`filtered_words`** - During training data generation, any posts with the specified words will be removed. Word boundaries are not checked by default, so “the” will also filter out posts with “them” or “thematic”. This setting supports regular expressions, so you can explicitly look for word boundaries by surrounding an entry with “\\\b”, i.e., “\\\bthe\\\b”. Regular expressions have to be escaped like so due to how JSON data is read in. If you are familiar with regular expressions, it could be useful for you to know that every entry is joined with a “|” which is then used to search the post content for any matches.
|
|
146
164
|
- **`developer_message`** - This message is used in for fine-tuning the AI as well as generating prompts. If you change this, you will need to run the fine-tuning again with the new value before generating posts.
|
|
147
165
|
- **`user_message`** - This setting is used and works in the same way as `developer_message`.
|
|
148
166
|
- **`expected_epochs`** - The default value here is the default number of epochs for `base_model`. You may have to change this value if you change `base_model`. After running fine-tuning once, you will see the number of epochs used in the [fine-tuning portal] under *Hyperparameters*. This value will also be updated automatically if you run fine-tuning through this program.
|
|
@@ -1,13 +1,12 @@
|
|
|
1
1
|
[project]
|
|
2
2
|
name = "tumblrbot"
|
|
3
|
-
version = "1.9.
|
|
3
|
+
version = "1.9.5"
|
|
4
4
|
description = "An updated bot that posts to Tumblr, based on your very own blog!"
|
|
5
5
|
readme = "README.md"
|
|
6
|
-
requires-python = ">= 3.
|
|
6
|
+
requires-python = ">= 3.14"
|
|
7
7
|
dependencies = [
|
|
8
8
|
"click",
|
|
9
9
|
"openai",
|
|
10
|
-
"pwinput",
|
|
11
10
|
"pydantic",
|
|
12
11
|
"requests",
|
|
13
12
|
"requests-oauthlib",
|
|
@@ -25,4 +24,4 @@ tumblrbot = "tumblrbot.__main__:main"
|
|
|
25
24
|
|
|
26
25
|
[build-system]
|
|
27
26
|
requires = ["flit_core"]
|
|
28
|
-
build-backend = "flit_core.buildapi"
|
|
27
|
+
build-backend = "flit_core.buildapi"
|
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
{"Please write a comical Tumblr post.": " According to the author\u2019s original plan, the present pamphlet was to have been devoted to a detailed development of the ideas expressed in the article \u201cWhere To Begin\u201d, We must first apologise to the reader for the delay in fulfilling the promise made in that article One of the reasons for this delay was the attempt, undertaken in June of the past year to unite all the Social-Democratic organisations abroad."}
|
|
2
2
|
{"Please write a comical Tumblr post.": "It was natural to wait for the results of this attempt, for, had the effort proved successful, it would perhaps have been necessary to expound Iskra\u2019s conceptions of organisation from a somewhat different approach; in any case, such a success promised to put an end very quickly to the existence of the two trends in the Russian Social-Democratic movement."}
|
|
3
|
-
{"Please write a comical Tumblr post.": "As the reader knows, the attempt failed, and, as we propose to show, was bound to fail after the new swing, of Rabocheye Dyelo, in its issue No."}
|
|
4
|
-
{"Please write a comical Tumblr post.": "10, towards Economism."}
|
|
5
3
|
{"Please write a comical Tumblr post.": "It was found to be absolutely essential to begin a determined struggle against this trend, diffuse and ill-defined, but for that reason the more persistent, the more capable of reasserting itself in diverse forms."}
|
|
6
4
|
{"Please write a comical Tumblr post.": "Accordingly, the original plan of the pamphlet was altered and considerably enlarged."}
|
|
7
5
|
{"Please write a comical Tumblr post.": "Its main theme was to have been the three questions raised in the article \u201cWhere To Begin\u201d \u2013 the character and main content of our political agitation; our organisational tasks; and the plan for building, simultaneously and from various sides, a militant, all-Russia organisation."}
|
|
@@ -140,9 +138,6 @@
|
|
|
140
138
|
{"Please write a comical Tumblr post.": "This is a feature of Economism generally, and not of the authors of the Credo alone."}
|
|
141
139
|
{"Please write a comical Tumblr post.": "It was revealed by that most outspoken and honest advocate of Economism, Rabochaya Mysl, and by Rabocheye Dyelo as well as by the Kiev Committee, which two years ago refused to permit the publication of its profession de foi, together with a repudiation of it, and by many other individual representatives of Economism."}
|
|
142
140
|
{"Please write a comical Tumblr post.": "This fear of criticism displayed by the advocates of freedom of criticism cannot be attributed solely to craftiness No, the majority of the Economists look with sincere resentment upon all theoretical controversies, factional disagreements, broad political questions, plans for organising revolutionaries, etc."}
|
|
143
|
-
{"Please write a comical Tumblr post.": "\u201cLeave all that to the people abroad!\u201d said a fairly consistent Economist to me one day, thereby expressing a very widespread view; our concern is the working-class movement, the workers, organisations here, in our localities; all the rest is merely the invention of doctrinaires, \u201cthe overrating of ideology\u201d, as the authors of the letter, published in Iskra, No."}
|
|
144
|
-
{"Please write a comical Tumblr post.": "12, expressed it, in unison with Rabocheye Dyelo, No."}
|
|
145
|
-
{"Please write a comical Tumblr post.": "10."}
|
|
146
141
|
{"Please write a comical Tumblr post.": "The question now arises: such being the peculiar features of Russian \u201ccriticism\u201d and Russian Bernsteinism, what should have been the task of those who sought to oppose opportunism in deeds and not merely in words?"}
|
|
147
142
|
{"Please write a comical Tumblr post.": "First, they should have made efforts to resume the theoretical work that had barely begun in the period of legal Marxism and that fell anew on the shoulders of the comrades working underground."}
|
|
148
143
|
{"Please write a comical Tumblr post.": "Without such work the successful growth of the movement was impossible."}
|
|
@@ -277,8 +272,6 @@
|
|
|
277
272
|
{"Please write a comical Tumblr post.": "Before dealing with the literary manifestation of this subservience to spontaneity, we should like to note the following characteristic fact which throws light on the conditions in which the two future conflicting trends in Russian Social-Democracy arose and grew among the comrades working in St. Petersburg."}
|
|
278
273
|
{"Please write a comical Tumblr post.": "In the beginning of 1897, just prior to their banishment, A."}
|
|
279
274
|
{"Please write a comical Tumblr post.": "A. Vaneyev and several of his comrades attended a private meeting at which \u201cold\u201d and \u201cyoung\u201d members of the League of Struggle for the Emancipation of the Working Class gathered."}
|
|
280
|
-
{"Please write a comical Tumblr post.": "The conversation centred chiefly about the question of organisation, particularly about the \u201crules for the workers\u2019 mutual benefit fund\u201d, which, in their final form, were published in \u201cListok\u201d Rabotnika, No."}
|
|
281
|
-
{"Please write a comical Tumblr post.": "9-10, p. 46."}
|
|
282
275
|
{"Please write a comical Tumblr post.": "Sharp differences immediately showed themselves between the \u201cold\u201d members and several the \u201cyoung\u201d members with a heated discussion ensuing."}
|
|
283
276
|
{"Please write a comical Tumblr post.": "The \u201cyoung\u201d members defended the main principles of the rules in the form in which they were published."}
|
|
284
277
|
{"Please write a comical Tumblr post.": "The \u201cold\u201d members contended that the prime necessity was not this, but the consolidation of the League of Struggle into an organisation of revolutionaries to which all the various workers\u2019 mutual benefit funds, students\u2019 propaganda circles, etc., should be subordinated."}
|
|
@@ -322,8 +315,6 @@
|
|
|
322
315
|
{"Please write a comical Tumblr post.": "There is much talk of spontaneity."}
|
|
323
316
|
{"Please write a comical Tumblr post.": "But the spontaneous development of the working-class movement leads to its subordination to bourgeois ideology, to its development along the lines of the Credo programme; for the spontaneous working-class movement is trade-unionism, is Nur-Gewerkschaftlerei, and trade unionism means the ideological enslavement of the workers by the bourgeoisie."}
|
|
324
317
|
{"Please write a comical Tumblr post.": "Hence, our task, the task of Social-Democracy, is to combat spontaneity, to divert the working-class movement from this spontaneous, trade-unionist striving to come under the wing of the bourgeoisie, and to bring it under the wing of revolutionary Social Democracy."}
|
|
325
|
-
{"Please write a comical Tumblr post.": "The sentence employed by the authors of the Economist letter published in Iskra, No."}
|
|
326
|
-
{"Please write a comical Tumblr post.": "12, that the efforts of the most inspired ideologists fail to divert the working-class movement from the path that is determined by the interaction of the material elements and the material environment is therefore tantamount to renouncing socialism."}
|
|
327
318
|
{"Please write a comical Tumblr post.": "If these authors were capable of fearlessly, consistently, and thoroughly considering what they say, as everyone who enters the arena of literary and public activity should be, there would be nothing left for them but to \u201cfold their useless arms over their empty breasts\u201d and surrender the field of action to the Struves and Prokopoviches, who are dragging the working-class movement \u201calong the line of least resistance\u201d, i.e., along the line of bourgeois trade-unionism, or to the Zubatovs, who are dragging it along the line of clerical and gendarme \u201cideology\u201d."}
|
|
328
319
|
{"Please write a comical Tumblr post.": "Let us recall the example of Germany."}
|
|
329
320
|
{"Please write a comical Tumblr post.": "What was the historic service Lassalle rendered to the German working-class movement?"}
|
|
@@ -371,9 +362,6 @@
|
|
|
371
362
|
{"Please write a comical Tumblr post.": "It may be interpreted in one of two ways."}
|
|
372
363
|
{"Please write a comical Tumblr post.": "Either it means bowing to the spontaneity of this movement, i.e., reducing the role of Social-Democracy to mere subservience to the working-class movement as such or it means that the mass movement places before us new theoretical, political, and organisational tasks, far more complicated than those that might have satisfied us in the period before the rise of the mass movement."}
|
|
373
364
|
{"Please write a comical Tumblr post.": "Rabocheye Dyelo inclined and still inclines towards the first interpretation, for it has said nothing definite about any new tasks, but has argued constantly as though the \u201cmass movement\u201d relieves us of the necessity of clearly understanding and fulfilling the tasks it sets before us."}
|
|
374
|
-
{"Please write a comical Tumblr post.": "We need only point out that Rabocheye Dyelo considered that it was impossible to set the overthrow of the autocracy as the first task of the mass working-class movement, and that it degraded this task to that of a struggle for immediate political demands\n\nWe shall pass over the article by B. Krichevsky, editor of Rabocheye Dyelo, entitled \u201cThe Economic and the Political Struggle in the Russian Movement\u201d, published in No."}
|
|
375
|
-
{"Please write a comical Tumblr post.": "7 of that paper, in which these very mistakes are repeated, and proceed directly to Rabocheye Dyelo, No."}
|
|
376
|
-
{"Please write a comical Tumblr post.": "10."}
|
|
377
365
|
{"Please write a comical Tumblr post.": "We shall not, of course, enter in detail into the various objections raised by Krichevsky and Martynov against Zarya and Iskra."}
|
|
378
366
|
{"Please write a comical Tumblr post.": "We are here interested solely in the basis of principles on which Rabocheye Dyelo, in its tenth issue, took its stand."}
|
|
379
367
|
{"Please write a comical Tumblr post.": "To confound recognition, in principle, of all means of struggle, of all plans and methods, provided they are expedient, with the demand at a given political moment to be guided by a strictly observed plan is tantamount, if we are to talk of tactics, to confounding the recognition by medical science of various methods of treating diseases with the necessity for adopting a certain definite method of treatment for a given disease."}
|
|
@@ -425,15 +413,11 @@
|
|
|
425
413
|
{"Please write a comical Tumblr post.": "The upsurge of the masses proceeded and spread with uninterrupted continuity; it not only continued in the places where it began, but spread to new localities and to new strata of the population Revolutionaries, however, lagged behind this upsurge, both in their \u201ctheories\u201d and in their activity; they failed to establish a constant and continuous organisation capable of leading the whole movement."}
|
|
426
414
|
{"Please write a comical Tumblr post.": "In the following chapters, we shall show how this bowing to spontaneity found expression in the sphere of the political tasks and in the organisational work of Social-Democracy."}
|
|
427
415
|
{"Please write a comical Tumblr post.": "We shall again begin by praising Rabocheye Dyelo."}
|
|
428
|
-
{"Please write a comical Tumblr post.": "\u201cLiterature of Exposure and the Proletarian Struggle\u201d is the title Martynov gave the article on his differences with Iskra published in Rabocheye Dyelo, No."}
|
|
429
|
-
{"Please write a comical Tumblr post.": "10."}
|
|
430
416
|
{"Please write a comical Tumblr post.": "He formulated the substance of the differences as follows: \u201cWe cannot confine ourselves solely to exposing the system that stands in its path of development."}
|
|
431
417
|
{"Please write a comical Tumblr post.": "We must also react to the immediate and current interests of the proletariat.... Iskra is in fact an organ of revolutionary opposition that exposes the state of affairs in our country, particularly the political state of affairs.... We, however, work and shall continue to work for the cause of the working class in close organic contact with the proletarian struggle\u201d One cannot help being grateful to Martynov for this formula."}
|
|
432
418
|
{"Please write a comical Tumblr post.": "It is of outstanding general interest, because substantially it embraces not only our disagreements with Rabocheye Dyelo, but the general disagreement between ourselves and the Economists on the political struggle."}
|
|
433
419
|
{"Please write a comical Tumblr post.": "We have shown that the Economists do not altogether repudiate \u201cpolitics\u201d, but that they are constantly straying from the Social-Democratic to the trade-unionist conception of politics."}
|
|
434
420
|
{"Please write a comical Tumblr post.": "Martynov strays in precisely this way, and we shall therefore take his views as a model of Economist error on this question."}
|
|
435
|
-
{"Please write a comical Tumblr post.": "As we shall endeavour to prove, neither the authors of the \u201cSeparate Supplement\u201d to Rabochaya Mysl nor the authors of the manifesto issued by the Self-Emancipation Group, nor the authors of the Economist letter published in Iskra, No."}
|
|
436
|
-
{"Please write a comical Tumblr post.": "12, will have any right to complain against this choice."}
|
|
437
421
|
{"Please write a comical Tumblr post.": "Everyone knows that the economic struggle of the Russian workers underwent widespread development and consolidation simultaneously with the production of \u201cliterature\u201d exposing economic conditions."}
|
|
438
422
|
{"Please write a comical Tumblr post.": "The \u201cleaflets\u201d were devoted mainly to the exposure of the factory system, and very soon a veritable passion for exposures was roused among the workers."}
|
|
439
423
|
{"Please write a comical Tumblr post.": "As soon as the workers realised that the Social-Democratic study circles desired to, and could, supply them with a new kind of leaflet that told the whole truth about their miserable existence, about their unbearably hard toil, and their lack of rights, they began to send in, actually flood us with, correspondence from the factories and workshops."}
|
|
@@ -759,8 +743,6 @@
|
|
|
759
743
|
{"Please write a comical Tumblr post.": "The reply is manifold: we Social-Democrats will organise these nation-wide exposures; all questions raised by the agitation will he explained in a consistently Social-Democratic spirit, without any concessions to deliberate or undeliberate distortions of Marxism; the all-round political agitation will be conducted by a party which unites into one inseparable whole the assault on the government in the name of the entire people, the revolutionary training of the proletariat, and the safeguarding of its political independence, the guidance of the economic struggle of the working class, and the utilisation of all its spontaneous conflicts with its exploiters which rouse and bring into our camp increasing numbers of the proletariat."}
|
|
760
744
|
{"Please write a comical Tumblr post.": "But a most characteristic feature of Economism is its failure to understand this connection, more, this identity of the most pressing need of the proletariat with the need of the general democratic movement."}
|
|
761
745
|
{"Please write a comical Tumblr post.": "This lack of understanding is expressed, not only in \u201cMartynovite\u201d phrases, but in the references to a supposedly class point of view identical in meaning with these phrases."}
|
|
762
|
-
{"Please write a comical Tumblr post.": "Thus, the authors of the Economist letter in Iskra, No."}
|
|
763
|
-
{"Please write a comical Tumblr post.": "12, state: Lack of space has prevented us from replying in detail, in Iskra, to this letter, which is highly characteristic of the Economists."}
|
|
764
746
|
{"Please write a comical Tumblr post.": "We were very glad at its appearance, for the allegations that Iskra did not maintain a consistent class point of view had reached us long before that from various sources, and we were waiting for an appropriate occasion, or for a formulated expression of this fashionable charge, to give our reply."}
|
|
765
747
|
{"Please write a comical Tumblr post.": "Moreover, it is our habit to reply to attacks, not by defence, but by counter-attack.\u2014Lenin \u201cThis basic drawback of Iskra is also the cause of its inconsistency on the question of the attitude of Social-Democracy to the various social classes and tendencies."}
|
|
766
748
|
{"Please write a comical Tumblr post.": "By theoretical reasoning Iskra solved the problem of the immediate transition to the struggle against absolutism."}
|
|
@@ -809,8 +791,6 @@
|
|
|
809
791
|
{"Please write a comical Tumblr post.": "Ostrich-like, they bury their heads in the sand and imagine that everything around has disappeared."}
|
|
810
792
|
{"Please write a comical Tumblr post.": "Liberal publicists who month after month proclaim to the world their triumph over the collapse and even the disappearance of Marxism; liberal newspapers which encourage the liberals who bring to the workers the Brentano conception of the class struggle and the trade-unionist conception of politics; the galaxy of critics of Marxism, whose real tendencies were so very well disclosed by the Credo and whose literary products alone circulate in Russia without let or hindrance; the revival of revolutionary non-Social-Democratic tendencies, particularly after the February and March events \u2014 all these, apparently, are just phantoms!"}
|
|
811
793
|
{"Please write a comical Tumblr post.": "All these have nothing at all to do with bourgeois democracy!"}
|
|
812
|
-
{"Please write a comical Tumblr post.": "Rabocheye Dyelo and the authors of the Economist letter published in Iskra, No."}
|
|
813
|
-
{"Please write a comical Tumblr post.": "12, should \u201cponder over the reason why the events of the spring brought about such a revival of revolutionary non-Social-Democratic tendencies instead of increasing the authority and the prestige of Social-Democracy\u201d."}
|
|
814
794
|
{"Please write a comical Tumblr post.": "The reason lies in the fact that we failed to cope with our tasks."}
|
|
815
795
|
{"Please write a comical Tumblr post.": "The masses of the workers proved to be more active than we."}
|
|
816
796
|
{"Please write a comical Tumblr post.": "We lacked adequately trained revolutionary leaders and organisers possessed of a thorough knowledge of the mood prevailing among all the opposition strata and able to head the movement, to turn a spontaneous demonstration into a political one, broaden its political character, etc."}
|
|
@@ -1333,8 +1313,6 @@
|
|
|
1333
1313
|
{"Please write a comical Tumblr post.": "Examples of successful strikes in a given region, information on higher living standards, on improved working conditions, in one locality, would encourage the workers in other localities to take up the fight again and again."}
|
|
1334
1314
|
{"Please write a comical Tumblr post.": "Fourthly, having made a start in generalising the trade union struggle and in this way strengthening the link between the Russian trade union movement and socialism, the Social-Democrats would at the same time see to it that our trade union work occupied neither too small nor too large a place in our Social-Democratic work as a whole."}
|
|
1335
1315
|
{"Please write a comical Tumblr post.": "A local organisation that is cut off from organisations in other towns finds it very difficult, sometimes almost impossible, to maintain a correct sense of pro portion But an all-Russia organisation of revolutionaries that stands undeviatingly on the basis of Marxism, that leads the entire political struggle and possesses a staff of professional agitators, will never find it difficult to determine the proper proportion."}
|
|
1336
|
-
{"Please write a comical Tumblr post.": "\u201cThe most serious blunder Iskra committed in this connection\u201d writes B. Krichevsky charging us with a tendency to \u201cconvert theory into a lifeless doctrine by isolating it from practice\u201d, \u201cwas its \u2019plan\u2019 for a general party organisation\u201d Martynov echoes this idea in declaring that \u201cIskra\u2019s tendency to belittle the significance of the forward march of the drab everyday struggle in comparison with the propaganda of brilliant and completed ideas.. was crowned with the plan for the organisation of a party which it sets forth in the article entitled \u2019Where To Begin\u2019 in issue No."}
|
|
1337
|
-
{"Please write a comical Tumblr post.": "4\u201d Finally, L. Nadezhdin has of late joined in the chorus of indignation against this \u201cplan\u201d In his pamphlet, which we have just received, entitled The Eve of the Revolution he declares \u201cTo speak now of an organisation held together by an all-Russia newspaper means propagating armchair ideas and armchair work\u201d and represents a manifestation of \u201cbookishness\u201d, etc."}
|
|
1338
1316
|
{"Please write a comical Tumblr post.": "That our terrorist turns out to be in agreement with the champions of the \u201cforward march of the drab everyday struggle\u201d is not surprising, since we have traced the roots of this intimacy between them in the chapters on politics and organisation."}
|
|
1339
1317
|
{"Please write a comical Tumblr post.": "But must draw attention here to the fact that Nadezhdin is the only one who has conscientiously tried to grasp the train of thought in an article he disliked and has made an attempt to reply to the point, whereas Rabocheye Dyelo, has said nothing that is material to the subject, but has tried merely to confuse the question by a series of unseemly, demagogic sallies."}
|
|
1340
1318
|
{"Please write a comical Tumblr post.": "Unpleasant though the task may be, we must first spend some time in cleansing this Augean stable."}
|
|
@@ -1417,10 +1395,6 @@
|
|
|
1417
1395
|
{"Please write a comical Tumblr post.": "Iskra wrote: The publication of an all-Russia political newspaper must be the main line by which we may unswervingly develop, deepen, and expand the organisation Pray tell me, when bricklayers lay bricks in, various parts of an enormous, unprecedentedly large structure, is it \u201cpaper\u201d work to use a line to help them find the correct place for the bricklaying; to indicate to them the ultimate goal of the common work; to enable them to use, not only every brick, but even every piece of brick which, cemented to the bricks laid before and after it, forms a finished, continuous line?"}
|
|
1418
1396
|
{"Please write a comical Tumblr post.": "And are we not now passing through precisely such a period in our Party life when we have bricks and bricklayers, but lack the guide line for all to see and follow?"}
|
|
1419
1397
|
{"Please write a comical Tumblr post.": "Let them shout that in stretching out the line, we want to command."}
|
|
1420
|
-
{"Please write a comical Tumblr post.": "Had we desired to command, gentlemen, we would have written on the title page, not \u201cIskra, No."}
|
|
1421
|
-
{"Please write a comical Tumblr post.": "1\u201d, but \u201cRabochaya Gazeta, No."}
|
|
1422
|
-
{"Please write a comical Tumblr post.": "3\u201d, as we were invited to do by certain comrades, and as we would have had a perfect right to do after the events described above."}
|
|
1423
|
-
{"Please write a comical Tumblr post.": "But we did not do that."}
|
|
1424
1398
|
{"Please write a comical Tumblr post.": "We wished to have our hands free to wage an irreconcilable struggle against all pseudo-Social-Democrats; we wanted our line, if properly laid, to be respected because it was correct, and not because it had been laid by an official organ."}
|
|
1425
1399
|
{"Please write a comical Tumblr post.": "\u201cThe question of uniting local activity in central bodies runs in a vicious circle,\u201d Nadezhdin lectures us; \u201cunification requires homogeneity of the elements, and the homogeneity can be created only by something that unites; but the unifying element may be the product of strong local organisations which at the present time are by no means distinguished for their homogeneity.\u201d This truth is as revered and as irrefutable as that we must train strong political organisations."}
|
|
1426
1400
|
{"Please write a comical Tumblr post.": "And it is equally barren."}
|
|
@@ -1,10 +1,12 @@
|
|
|
1
|
-
from io import TextIOBase
|
|
2
1
|
from json import dump
|
|
3
|
-
from typing import override
|
|
2
|
+
from typing import TYPE_CHECKING, override
|
|
4
3
|
|
|
5
4
|
from tumblrbot.utils.common import FlowClass, PreviewLive
|
|
6
5
|
from tumblrbot.utils.models import Post
|
|
7
6
|
|
|
7
|
+
if TYPE_CHECKING:
|
|
8
|
+
from io import TextIOBase
|
|
9
|
+
|
|
8
10
|
|
|
9
11
|
class PostDownloader(FlowClass):
|
|
10
12
|
@override
|
|
@@ -1,11 +1,9 @@
|
|
|
1
1
|
import re
|
|
2
|
-
from collections.abc import Generator
|
|
3
2
|
from itertools import batched
|
|
4
3
|
from json import loads
|
|
5
4
|
from math import ceil
|
|
6
|
-
from pathlib import Path
|
|
7
5
|
from re import search
|
|
8
|
-
from typing import IO, override
|
|
6
|
+
from typing import IO, TYPE_CHECKING, override
|
|
9
7
|
|
|
10
8
|
import rich
|
|
11
9
|
from openai import BadRequestError
|
|
@@ -13,6 +11,10 @@ from openai import BadRequestError
|
|
|
13
11
|
from tumblrbot.utils.common import FlowClass, PreviewLive
|
|
14
12
|
from tumblrbot.utils.models import Example, Post
|
|
15
13
|
|
|
14
|
+
if TYPE_CHECKING:
|
|
15
|
+
from collections.abc import Generator
|
|
16
|
+
from pathlib import Path
|
|
17
|
+
|
|
16
18
|
|
|
17
19
|
class ExamplesWriter(FlowClass):
|
|
18
20
|
@override
|
|
@@ -1,11 +1,9 @@
|
|
|
1
|
-
from collections.abc import Generator
|
|
2
1
|
from datetime import datetime
|
|
3
2
|
from textwrap import dedent
|
|
4
3
|
from time import sleep
|
|
5
|
-
from typing import override
|
|
4
|
+
from typing import TYPE_CHECKING, override
|
|
6
5
|
|
|
7
6
|
import rich
|
|
8
|
-
from openai.types.fine_tuning import FineTuningJob
|
|
9
7
|
from rich import progress
|
|
10
8
|
from rich.console import Console
|
|
11
9
|
from rich.prompt import Confirm
|
|
@@ -14,6 +12,11 @@ from tiktoken import encoding_for_model, get_encoding
|
|
|
14
12
|
from tumblrbot.utils.common import FlowClass, PreviewLive
|
|
15
13
|
from tumblrbot.utils.models import Example
|
|
16
14
|
|
|
15
|
+
if TYPE_CHECKING:
|
|
16
|
+
from collections.abc import Generator
|
|
17
|
+
|
|
18
|
+
from openai.types.fine_tuning import FineTuningJob
|
|
19
|
+
|
|
17
20
|
|
|
18
21
|
class FineTuner(FlowClass):
|
|
19
22
|
@staticmethod
|
|
@@ -131,4 +134,4 @@ class FineTuner(FlowClass):
|
|
|
131
134
|
yield 4 + len(encoding.encode(message.content))
|
|
132
135
|
|
|
133
136
|
def get_cost_string(self, total_tokens: int) -> str:
|
|
134
|
-
return f"
|
|
137
|
+
return f"{self.config.token_price / 1000000 * total_tokens:.2f} USD"
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
from collections.abc import Iterable
|
|
2
1
|
from functools import cache
|
|
3
2
|
from random import choice, random, sample
|
|
4
|
-
from typing import override
|
|
3
|
+
from typing import TYPE_CHECKING, override
|
|
5
4
|
|
|
6
5
|
import rich
|
|
7
6
|
from pydantic import ConfigDict
|
|
@@ -10,6 +9,9 @@ from rich.prompt import IntPrompt
|
|
|
10
9
|
from tumblrbot.utils.common import FlowClass, PreviewLive
|
|
11
10
|
from tumblrbot.utils.models import Post
|
|
12
11
|
|
|
12
|
+
if TYPE_CHECKING:
|
|
13
|
+
from collections.abc import Iterable
|
|
14
|
+
|
|
13
15
|
|
|
14
16
|
class DraftGenerator(FlowClass):
|
|
15
17
|
model_config = ConfigDict(frozen=True) # Makes this class hashable.
|
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
from collections.abc import Generator
|
|
2
|
+
from getpass import getpass
|
|
2
3
|
from pathlib import Path
|
|
3
|
-
from tomllib import loads
|
|
4
4
|
from typing import Annotated, Any, Literal, Self, override
|
|
5
5
|
|
|
6
6
|
import rich
|
|
7
7
|
from openai.types import ChatModel
|
|
8
|
-
from pwinput import pwinput
|
|
9
8
|
from pydantic import BaseModel, ConfigDict, Field, NonNegativeFloat, NonNegativeInt, PlainSerializer, PositiveFloat, PositiveInt, model_validator
|
|
10
9
|
from pydantic.json_schema import SkipJsonSchema
|
|
11
10
|
from requests_oauthlib import OAuth1Session
|
|
12
11
|
from rich.panel import Panel
|
|
13
12
|
from rich.prompt import Prompt
|
|
14
13
|
from tomlkit import comment, document, dumps # pyright: ignore[reportUnknownVariableType]
|
|
14
|
+
from tomllib import loads
|
|
15
15
|
|
|
16
16
|
|
|
17
17
|
class FullyValidatedModel(BaseModel):
|
|
@@ -145,7 +145,7 @@ class Tokens(FileSyncSettings):
|
|
|
145
145
|
|
|
146
146
|
rich.print(f"Retrieve your {formatted_token_string} from: {url}")
|
|
147
147
|
for token in tokens:
|
|
148
|
-
yield
|
|
148
|
+
yield getpass(f"Enter your {token} (masked): ", echo_char="*").strip()
|
|
149
149
|
|
|
150
150
|
rich.print()
|
|
151
151
|
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|