Committed version 3 of the bot from the source code on my computer. Older versions of the bot were version controlled manually before I knew how to use Git.

This commit is contained in:
2021-07-06 14:09:06 +01:00
parent eae07b923d
commit 2f10edc3f9
37 changed files with 39162 additions and 2 deletions

7
posting/Dockerfile Normal file
View File

@ -0,0 +1,7 @@
FROM python:3.8.6-buster
COPY . /usr/src/app
WORKDIR /usr/src/app
RUN pip install --upgrade pip
RUN pip install -r requirements.txt
RUN python -m nltk.downloader all
CMD python3 -u ./script.py

2835
posting/lists/1_syllable.txt Normal file

File diff suppressed because it is too large Load Diff

7315
posting/lists/2_syllable.txt Normal file

File diff suppressed because it is too large Load Diff

9740
posting/lists/3_syllable.txt Normal file

File diff suppressed because it is too large Load Diff

8950
posting/lists/4_syllable.txt Normal file

File diff suppressed because it is too large Load Diff

4956
posting/lists/5_syllable.txt Normal file

File diff suppressed because it is too large Load Diff

2387
posting/lists/6_syllable.txt Normal file

File diff suppressed because it is too large Load Diff

1200
posting/lists/7_syllable.txt Normal file

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,571 @@
psychological feature
indefinite quantity
mathematical relation
genital personality
incomprehensibility
uncommunicativeness
animal communication
system of weights and measures
ungradable opposition
physiological property
hydrogen ion concentration
absolute magnitude
interoperability
unintelligibility
environmental condition
sudden infant death syndrome
executive clemency
commercial letter of credit
traveler's letter of credit
mathematical statement
literary composition
division Archaebacteria
grammatical category
musical organization
computer memory unit
electromagnetic unit
unformatted capacity
basic cognitive process
higher cognitive process
internationalization
revolutions per minute
mechanical advantage
relative humidity
computer architecture
electronegativity
conformational entropy
one-dimensionality
incontrovertibility
speech intelligibility
esophagogastric junction
urinary hesitancy
collective security
indefatigability
telephone conversation
Latino sine flexione
declarative sentence
electronic database
circumstantial evidence
frequency-response curve
Talmudic literature
mathematical notation
electromagnetic spectrum
file allocation table
electromotive series
Homobasidiomycetes
coelenterate family
Iraqi National Congress
terrorist organization
ecumenical movement
professional association
Alcoholics Anonymous
American Labor Party
Liberal Democrat Party
Social Democratic Party
Industrial Workers of the World
administrative unit
intensive care unit
Helladic civilization
Mycenaean civilization
hunting and gathering tribe
metric capacity unit
Afghan monetary unit
Austrian monetary unit
British monetary unit
Chilean monetary unit
Cuban monetary unit
Cypriot monetary unit
Danish monetary unit
Finnish monetary unit
Gambian monetary unit
Georgian monetary unit
German monetary unit
Ghanian monetary unit
Guinean monetary unit
Haitian monetary unit
Indian monetary unit
Irish monetary unit
Kenyan monetary unit
Laotian monetary unit
Latvian monetary unit
Libyan monetary unit
Macao monetary unit
Myanmar monetary unit
Papuan monetary unit
Polish monetary unit
Russian monetary unit
Spanish monetary unit
Swedish monetary unit
Syrian monetary unit
Tongan monetary unit
Turkish monetary unit
Turkmen monetary unit
Zambian monetary unit
moment magnitude scale
nonverbal intelligence
political orientation
mitigating circumstance
representational process
out-of-body experience
adversative conjunction
copulative conjunction
subordinating conjunction
angular acceleration
basal metabolic rate
homogeneous polynomial
exogenous obesity
protective coloration
primary color for pigments
element of a cylinder
regular dodecahedron
regular icosahedron
balance-of-payments problem
biodegradable pollution
cardiovascular disease
histoincompatibility
salicylate poisoning
delusions of persecution
dissociative disorder
diplomatic immunity
cystoid macular edema
solitary confinement
electrolyte balance
political incorrectness
irreproducibility
signature recognition
Western Malayo-Polynesian
ablative absolute
hypertext transfer protocol
transmission control protocol
parol evidence rule
character assassination
relational database
conspiracy of silence
computer architecture
dictionary definition
ostensive definition
recursive definition
literal interpretation
Distinguished Conduct Medal
Distinguished Service Cross
derivative instrument
letters of administration
hexadecimal notation
parenthesis-free notation
asterid dicot family
dilleniid dicot family
magnoliid dicot family
liliid monocot family
genus Corynebacterium
genus Anomalopteryx
genus Ibero-mesornis
genus Appendicularia
caryophylloid dicot genus
hamamelid dicot genus
genus Aegyptopithecus
genus Australopithecus
suborder Ceratosaura
Aerobacter aerogenes
Francisella tularensis
Constitutional Convention
World Trade Organization
Protestant denomination
regulatory agency
United Nations agency
coronary care unit
Israeli Defense Force
parliamentary monarchy
Cycladic civilization
coefficient of self induction
coefficient of viscosity
British capacity unit
United States dry unit
Texas Independence Day
antiestablishmentarianism
philosophical doctrine
doctrine of analogy
humanistic discipline
imagination image
nonparametric statistic
hypercholesterolemia
anti-takeover defense
military ceremony
secondary education
undercover operation
emergency procedure
operating procedure
pictorial representation
entrance examination
retaliatory eviction
deliberate defense
psychological warfare
database management
cruel and unusual punishment
economic strangulation
initial public offering
gravitational collapse
military ceremony
elimination tournament
extremely high frequency
extremely low frequency
sodium tripolyphosphate
columbite-tantalite
liability insurance
malpractice insurance
capital expenditure
bank-depositor relation
conservator-ward relation
executor-heir relation
apatetic coloration
pediculosis capitis
pediculosis corporis
chromosomal aberration
fibrous dysplasia of bone
inhalation anesthesia
epidural anesthesia
circulatory failure
personality disorder
psychosomatic disorder
hyperlipoproteinemia
hypolipoproteinemia
lysine intolerance
anterograde amnesia
ecclesiastical province
marriage of convenience
papal infallibility
Social Security number
subornation of perjury
Presidential Directive
Bachelor of Arts in Nursing
Bachelor of Divinity
Bachelor of Medicine
Bachelor of Naval Science
Doctor of Dental Surgery
Doctor of Sacred Theology
Doctor of Humane Letters
Master of Architecture
Master of Library Science
Master of Literature
Higher National Diploma
statute of limitations
partnership certificate
registered security
zero-coupon security
software documentation
supervisory software
United States Senate
commodity brokerage
automobile industry
Federal Reserve System
Religious Society of Friends
Congregational Christian Church
Methodist denomination
United States government
Comptroller of the Currency
executive agency
Food and Drug Administration
law enforcement agency
National Weather Service
Nonproliferation Center
United States Air Force
United Nations Children's Fund
hypothetical creature
irrational hostility
Immaculate Conception
law of diminishing returns
law of multiple proportions
Pauli exclusion principle
landscape architecture
electrical engineering
information technology
mechanical engineering
secondary amenorrhea
keratoconjunctivitis
laryngotracheobronchitis
fetal alcohol syndrome
thoracic outlet syndrome
aversive conditioning
audio lingual acquisition
speaker identification
gravimetric analysis
volumetric analysis
volumetric analysis
line of least resistance
artificial respiration
interdepartmental support
digital communication
amplitude modulation
market capitalization
epideictic oratory
administrative hearing
bureaucratic procedure
academic requirement
employee-owned enterprise
subordinating conjunction
hypertext markup language
monoamine oxidase
manganese tetroxide
acid-base indicator
medullated nerve fiber
phosphate buffer solution
cumulative preferred
whole life insurance
political contribution
going-out-of-business sale
coronary heart disease
secondary hypertension
orthostatic hypotension
congestive heart failure
acute renal failure
agammaglobulinemia
posttraumatic stress disorder
opportunistic infection
staphylococcal infection
cartilaginification
hyperbilirubinemia
borderline schizophrenia
catatonic schizophrenia
ventricular septal defect
parenthetical expression
lexical disambiguation
cataloged procedure
contingency procedure
random number generator
supervisory routine
degree of a polynomial
duodecimal number system
octal numeration system
closely held corporation
multibank holding company
military academy
polytechnic institute
sales finance company
Real Estate Investment Trust
Federal Trade Commission
National Science Foundation
Federal Bureau of Prisons
Commission on Narcotic Drugs
modulus of rigidity
analysis of variance
rehabilitation program
dialectical materialism
conservation of energy
third law of thermodynamics
localization of function
beggar-my-neighbor policy
computational linguistics
cognitive psychology
differential psychology
unidentified flying object
coefficient of concordance
ulcerative colitis
equine encephalitis
West Nile encephalitis
necrotizing enteritis
inclusion body myositis
ankylosing spondylitis
vesicular stomatitis
secondary dysmenorrhea
instrumental conditioning
cost-benefit analysis
modified American plan
immunohistochemistry
object-oriented programming
Secretary of Commerce
Secretary of Defense
Secretary of Energy
Secretary of the Navy
counterpreparation fire
clandestine operation
strategic intelligence
tactical intelligence
natural family planning
arithmetic operation
dilation and curettage
palatopharyngoplasty
fundamental analysis
trespass quare clausum fregit
asynchronous transfer mode
pulse-time modulation
redirect examination
nonprofit organization
overcapitalization
operational damage
descriptive adjective
relational adjective
indefinite article
plasminogen activator
gastrointestinal hormone
obidoxime chloride
glycerinated gelatin
aluminum hydroxide
deoxyribonucleic acid
Philippine mahogany
hydrochlorofluorocarbon
organization expense
disability benefit
ventricular fibrillation
akinetic epilepsy
posttraumatic epilepsy
procursive epilepsy
psychomotor epilepsy
Arnold-Chiari deformity
communicable disease
fibrocystic breast disease
inflammatory disease
occupational disease
periarteritis nodosa
respiratory disease
metabolic acidosis
metabolic alkalosis
classic hemochromatosis
Charcot-Marie-Tooth disease
hepatojugular reflux
ureterorenal reflux
vesicoureteral reflux
disability of walking
command line interface
publishing conglomerate
staggered board of directors
anthropology department
holy day of obligation
conjugal visitation right
attorney-client privilege
conservation of momentum
numerical analysis
physical anthropology
supply-side economics
theory of inheritance
indefinite integral
horizontal integration
dishonorable discharge
physiological nystagmus
post-rotational nystagmus
glucose tolerance test
radioactive iodine test
catechetical instruction
preventive medicine
exfiltration operation
reconnaissance by fire
reconnaissance in force
A-scan ultrasonography
intravenous pyelography
oophorosalpingectomy
robotic telesurgery
electronic surveillance
surveillance of disease
fluorescence microscopy
isotonic exercise
gay liberation movement
international terrorism
state-sponsored terrorism
restriction endonuclease
water of crystallization
essential amino acid
cyclohexanol phthalate
aromatic hydrocarbon
potassium ferrocyanide
potassium permanganate
indolebutyric acid
supplementary benefit
unemployment compensation
cost-of-living allowance
depreciation allowance
reversionary annuity
involutional depression
photogenic epilepsy
hemorrhagic septicemia
lupus erythematosus
macular degeneration
lactose intolerance
valvular incompetence
urinary tract infection
necrobiosis lipoidica
sensorineural hearing loss
United States Cabinet
executive department
Immaculate Conception
equal protection of the laws
freedom from discrimination
freedom from double jeopardy
freedom from search and seizure
classical architecture
Victorian architecture
nonparametric statistics
elementary geometry
spherical trigonometry
general relativity
dissolution of marriage
Thematic Apperception Test
prolonged interrogation
radical hysterectomy
extracapsular surgery
intracapsular surgery
intramuscular injection
megavitamin therapy
occupational therapy
microwave spectroscopy
medroxyprogesterone
oxidized LDL cholesterol
saturated fatty acid
cellulose acetate
polypropenonitrile
polyvinyl acetate
bicarbonate of soda
magnesium bicarbonate
potassium bicarbonate
enteric-coated aspirin
filter-tipped cigarette
Hand-Schuller-Christian disease
infectious mononucleosis
diabetic retinopathy
Becker muscular dystrophy
distal muscular dystrophy
xanthoma disseminatum
intermittent claudication
Department of Education
Department of the Interior
Department of the Treasury
Department of Transportation
inflectional morphology
curvilinear correlation
negative correlation
positive correlation
emergency medicine
quantum electrodynamics
prisoner of war censorship
transorbital lobotomy
client-centered therapy
electron spin resonance
mono-iodotyrosine
cellulose triacetate
mucopolysaccharide
heterophil antibody
monoclonal antibody
megaloblastic anemia
sideroblastic anemia
granuloma inguinale
epidemic pleurodynia
tsutsugamushi disease
miliary tuberculosis
xeroderma pigmentosum
acute pyelonephritis
nonspecific urethritis
schistosome dermatitis
erythema multiforme
microscopic anatomy
cognitive neuroscience
magnetohydrodynamics
transactional immunity
reciprocal inhibition
hydroxybutyric acid
cluster of differentiation 4
cluster of differentiation 8
high-density lipoprotein
low-density lipoprotein
antihemophilic factor
Rocky Mountain spotted fever
endometrial carcinoma
alpha-linolenic acid
docosahexaenoic acid
eicosapentaenoic acid

View File

@ -0,0 +1,279 @@
auditory communication
narcissistic personality
small indefinite quantity
conditional probability
certificate of deposit
professional organization
absolute temperature
multiplicative inverse
military capability
operating capability
coronary insufficiency
meteorological conditions
anatomical reference
ballistic identification
biometric identification
multidimensional language
one-dimensional language
corroborating evidence
military intelligence
Heterobasidiomycetes
deliberative assembly
military-industrial complex
American Baptist Convention
educational institution
Congress of Racial Equality
Constitutional Union Party
States' Rights Democratic Party
parliamentary democracy
Paleo-American culture
pure imaginary number
factor of proportionality
basal body temperature
discriminative stimulus
centripetal acceleration
return on invested capital
borderline intelligence
complex instruction set computing
nonbiodegradable pollution
degenerative disorder
immunological disorder
carbon monoxide poisoning
spinocerebellar disorder
object-oriented database
stipulative definition
Distinguished Service Medal
Distinguished Service Order
articles of incorporation
caryophylloid dicot family
hamamelid dicot family
Schizosaccharomycetaceae
Agrobacterium tumefaciens
Royal Canadian Mounted Police
Federal Home Loan Bank System
extended care facility
redevelopment authority
coefficient of mutual induction
luminous intensity unit
Trinidad and Tobago dollar
Central African Republic franc
United States liquid unit
Cartesian coordinate system
inertial reference frame
elementary education
quantitative analysis
psychological operation
experimental procedure
electronic communication
comparative negligence
contributory negligence
demand for identification
economic mobilization
proportional representation
electromagnetic intrusion
electronic countermeasures
atmospheric electricity
case-fatality proportion
case-to-infection proportion
identification particle
complementary distribution
automobile insurance
director-stockholder relation
receiver-creditor relation
aposematic coloration
atrioventricular nodal rhythm
interventricular foramen
occipital protuberance
inborn error of metabolism
auditory hallucination
hypersensitivity reaction
bank identification number
partial differential equation
Associate in Applied Science
Bachelor of Literature
Doctor of Dental Medicine
personality inventory
mortgage-backed security
proprietorship certificate
United States Marine Corps
Anabaptist denomination
Bureau of Engraving and Printing
Bureau of Justice Statistics
Casualty Care Research Center
Defense Logistics Agency
Federal Aviation Agency
Government Accounting Office
Internal Revenue Service
National Institutes of Health
Technology Administration
United States Border Patrol
political action committee
Economic and Social Council
Intelligence Community
military intelligence
Federal Security Bureau
United Nations Secretariat
National Rifle Association
coefficient of elasticity
multivariate analysis
law of equivalent proportions
principle of relativity
aeronautical engineering
architectural engineering
periodic apnea of the newborn
attention deficit disorder
Chinese restaurant syndrome
Zollinger-Ellison syndrome
Revolutionary calendar
total parenteral nutrition
integrated logistic support
alienation of affection
adenosine deaminase
superoxide dismutase
high-level radioactive waste
low-level radioactive waste
monostotic fibrous dysplasia
benign prostatic hyperplasia
hypogammaglobulinemia
schizotypal personality
abetalipoproteinemia
Wernicke's encephalopathy
respiratory tract infection
binary numeration system
decimal numeration system
hexadecimal number system
attributive genitive
captive finance company
commercial finance company
consumer finance company
Atomic Energy Commission
National Security Council
National Labor Relations Board
Small Business Administration
United States Post Office
Social Development Commission
United States Army Rangers
Reserve Officers Training Corps
diamond wedding anniversary
golden wedding anniversary
silver wedding anniversary
correlational analysis
Maxwell-Boltzmann distribution law
second law of thermodynamics
zeroth law of thermodynamics
law of independent assortment
Gestalt law of organization
mass-energy equivalence
principle of equivalence
principle of superposition
principle of superposition
artificial intelligence
natural language processing
comparative psychology
developmental psychology
experimental psychology
physiological psychology
Kendall partial rank correlation
tau coefficient of correlation
irritable bowel syndrome
herpes simplex encephalitis
sense of responsibility
Secretary of Education
Secretary of the Interior
Secretary of the Treasury
Secretary of Transportation
aeronautical engineering
automotive technology
communications technology
trespass de bonis asportatis
hyperemesis gravidarum
insertional mutagenesis
para aminobenzoic acid
quaternary ammonium compound
fluorescein isothiocyanate
abdominal aortic aneurysm
hypertrophic cardiomyopathy
respiratory acidosis
respiratory alkalosis
acquired hemochromatosis
multiple mononeuropathy
natural language processor
graphical user interface
department of computer science
equality before the law
right to the pursuit of happiness
physician-patient privilege
stationary stochastic process
primary sex characteristic
rubella panencephalitis
just-noticeable difference
planetesimal hypothesis
zero-tolerance policy
alternative medicine
complementary medicine
security intelligence
electronic reconnaissance
electronics intelligence
telemetry intelligence
cyclodestructive surgery
laser trabecular surgery
computerized tomography
growth hormone-releasing factor
glutathione peroxidase
horseradish peroxidase
recombinant human insulin
urea-formaldehyde resin
alkylbenzenesulfonate
disability insurance
musicogenic epilepsy
thrombocytopenic purpura
mucopolysaccharidosis
mucocutaneous leishmaniasis
Ebola hemorrhagic fever
polycystic kidney disease
freedom from self-incrimination
Byzantine architecture
vertebrate paleontology
abatement of a nuisance
Michelson-Morley experiment
breach of trust with fraudulent intent
El Nino southern oscillation
unsaturated fatty acid
adenosine diphosphate
adenosine triphosphate
prostate specific antigen
polymethyl methacrylate
erythroblastosis fetalis
iron deficiency anemia
essential thrombocytopenia
osteogenesis imperfecta
limb-girdle muscular dystrophy
Duchenne's muscular dystrophy
myotonic muscular dystrophy
keratosis blennorrhagica
keratosis follicularis
Department of Agriculture
Department of Veterans Affairs
derivational morphology
veterinary medicine
physical rehabilitation
physician-assisted suicide
adrenergic agonist eyedrop
topical prostaglandin eyedrop
thoracic actinomycosis
lymphogranuloma venereum
cerebrospinal meningitis
pulmonary tuberculosis
nongonococcal urethritis
comparative anatomy
developmental anatomy
desensitization technique
human reproductive cloning
monoamine neurotransmitter
carboxymethyl cellulose
tetanus immunoglobulin
chronic lymphocytic leukemia
chronic myelocytic leukemia
alveolar rhabdomyosarcoma
embryonal rhabdomyosarcoma
pleomorphic rhabdomyosarcoma

1
posting/post_log.txt Normal file
View File

@ -0,0 +1 @@
2021-03-19-00:28:14: What is artificial intelligence, if not mucopolysaccharidosis persevering?

5
posting/requirements.txt Normal file
View File

@ -0,0 +1,5 @@
python-dotenv
datetime
tweepy
nltk
numpy

64
posting/script.py Normal file
View File

@ -0,0 +1,64 @@
#!/usr/local/bin/python3.8
import tweepy
import time
import os
import random
import sys
from datetime import datetime, timedelta
import math
from nltk.corpus import wordnet as wn
print(datetime.now().strftime("%H:%M:%S"))
callback_uri = 'oob' # https://cfe.sh/twitter/callback
auth = tweepy.OAuthHandler(os.getenv('API_TOKEN'), os.getenv('API_KEY_SECRET'), callback_uri)
auth.set_access_token(os.getenv('ACCESS_TOKEN'), os.getenv('ACCESS_TOKEN_SECRET'))
api = tweepy.API(auth)
def generate_words():
syllables = random.randint(1,sum(1 for file in os.listdir('/usr/src/app/lists')))
w1 = get_word(syllables)
w2 = get_word(syllables)
w1_synset = wn.synsets(w1.replace(' ', '_'))[0]
w2_synset = wn.synsets(w2.replace(' ', '_'))[0]
i = 0
while w1 == w2 or (w1_synset.wup_similarity(w2_synset) < 0.66 and i < 100):
w2 = get_word(syllables)
w2_synset = wn.synsets(w2.replace(' ', '_'))[0]
i += 1
return [w1,w2]
def get_word(syl):
fileName = f'{syl}_syllable.txt'
with open(f'/usr/src/app/lists/{fileName}', 'r') as wordList:
l = sum(1 for line in wordList) - 1
c = random.randint(0,l)
wordList.seek(0)
for i, line in enumerate(wordList):
if i == c:
if c == l:
return line
else:
return line[:-1]
elif i > c:
break
def posting():
words = generate_words()
output = f'What is {words[0]}, if not {words[1]} persevering?'
print(output)
# api.update_status(output)
with open('/usr/src/app/post_log.txt', 'a') as logFile:
logFile.write(f'{datetime.now().strftime("%Y-%m-%d-%X")}: {output}\n')
now = datetime.now()
nextHour = (now + timedelta(hours=1)).replace(minute=0,second=0,microsecond=0)
tdelta = nextHour - datetime.now()
sec = math.floor(tdelta.total_seconds())
print(f'Waiting until {nextHour} for first post, sleeping for {sec} seconds.')
time.sleep(sec)
while True:
posting()
time.sleep(3600)