Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

An experiment using the Actor model #24

Open
bensteinberg opened this issue Nov 9, 2023 · 1 comment
Open

An experiment using the Actor model #24

bensteinberg opened this issue Nov 9, 2023 · 1 comment

Comments

@bensteinberg
Copy link

A while back I learned about the Actor model in the context of Akka and Scala, but never got anywhere with it (or with Scala). This will be an attempt to use the mechanism, in the form of Pykka, to generate a novel.

@bensteinberg
Copy link
Author

I have some code and sample output of about 142,000 words, produced with --seconds 0.08. The result of this experiment so far is that I have a better sense of my failure to grasp concurrency.

Some things I may address during the rest of the month:

  • I would like to figure out why runs of the same duration can produce a ton of text or very little or none.
  • The "characters" in this code don't use what was said to them as part of determining their responses; I might change that.
  • An early attempt at a group mechanism, so that "scenes" would contain a subset of characters, failed. I think attributes of actor objects aren't matching up with my instincts about object attributes generally, and I'm not sure whether there's a proper way to maintain global state in this context.
  • I thought of adding locations as another form of Actor.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants