Comments (4)
Are the files UTF-8 encoded? Could you post a gist with an example?
from twitter_markov.
https://gist.github.com/BrekiTomasson/e9814f32c42376af4fe4795dc3cf95aa for the gist.
The file is in UTF-8.
from twitter_markov.
Also, for reference, when it's been standing still for a while and not outputting anything, and I kill it via a simple ctrl-C, this is what I get:
Traceback (most recent call last):
File "/usr/local/bin/twittermarkov", line 9, in <module>
load_entry_point('twitter-markov==0.4.3', 'console_scripts', 'twittermarkov')()
File "/usr/local/lib/python2.7/dist-packages/twitter_markov/cli.py", line 70, in main
func(argdict)
File "/usr/local/lib/python2.7/dist-packages/twitter_markov/cli.py", line 77, in tweet_func
tm.tweet()
File "/usr/local/lib/python2.7/dist-packages/twitter_markov/twitter_markov.py", line 178, in tweet
text = self.compose(model, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/twitter_markov/twitter_markov.py", line 196, in compose
sent = model.make_sentence(**kwargs)
File "/usr/local/lib/python2.7/dist-packages/markovify/text.py", line 115, in make_sentence
words = self.chain.walk(init_state)
File "/usr/local/lib/python2.7/dist-packages/markovify/chain.py", line 98, in walk
return list(self.gen(init_state))
File "/usr/local/lib/python2.7/dist-packages/markovify/chain.py", line 87, in gen
next_word = self.move(state)
File "/usr/local/lib/python2.7/dist-packages/markovify/chain.py", line 74, in move
cumdist = list(accumulate(weights))
File "/usr/local/lib/python2.7/dist-packages/markovify/chain.py", line 9, in accumulate
def accumulate(iterable, func=operator.add):
KeyboardInterrupt
ยด``
from twitter_markov.
Actually, never mind. It seems the problem might have been that there were other non-standard characters in there, parentheses and quotationmarks, especially. Once I cleaned them out, it worked better.
from twitter_markov.
Related Issues (14)
- pip install twitter_markov errors out HOT 3
- After upgrading to ubuntu 16.04, no longer recognizes bots.yaml HOT 4
- Corpus updates and learning [questions] HOT 8
- Odd behavior: Verbose mode seems to indicate that state is always set to 2 no matter what config says HOT 4
- Corpus Creation Errors HOT 5
- Conflicts between twitter_markov and pyyaml HOT 3
- KeyError: 'text' HOT 3
- writelines() argument must be a sequence of strings HOT 7
- Reply To One HOT 3
- Ending reply chains HOT 5
- Limiting length
- Question regarding corpus size HOT 1
- Script doesn't recognize bots.yaml HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. ๐๐๐
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google โค๏ธ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from twitter_markov.