Play connect4.
- Write agents that play connect4.
- Battle your agents against other agents.
- It's fun.
View val changes as a diff.
Go to /v/username/valname/version to see a diff between that version and the previous one. For example https://saolsen-changes.web.val.run/v/saolsen/tracing/108
This is a wrapper of the val town std sqlite library that adds tracing via https://www.val.town/v/saolsen/tracing.
Connect4 agent that uses Monte-Carlo tree search to simulate 10,000 random games from each possible action and pick the one with the highest win rate. Ported from a version I made in rust.
Upstash redis client for vals.
Creates a global redis instance and exposes functions to use it.
To use, create a redis database on Upstash and set the environment variables.
UPSTASH_REDIS_REST_URL
UPSTASH_REDIS_REST_TOKEN
Val.town runs in ohio so the best region to pick for the redis instance is probably us-east-1
.
Calls are also traced via https://www.val.town/v/saolsen/tracing so if you use that library you will see timed spans for any redis calls.
For an example of how to use it see https://www.val.town/v/saolsen/try_redis
Upstash qstash client for vals.
Lets you publish and receive qstash messages in vals.
To use, set up qstash on Upstash and set the environment variables.
QSTASH_TOKEN
QSTASH_CURRENT_SIGNING_KEY
QSTASH_NEXT_SIGNING_KEY
Calls are also traced via https://www.val.town/v/saolsen/tracing so if you use that library you will see linked spans between the publish
call and the receive
call.
For an example of how to use it see https://www.val.town/v/saolsen/try_qstash_publish and https://www.val.town/v/saolsen/try_qstash_receive.