Comment

Comment by fathrowaway12

It's very good at iterating from a description to working code. You still need to know what you're doing, but it can handle a lot of details.

  prompt: How would you design a distributed key value storage system? Assume the values are about one megabyte. We will need to scale up to store petabytes of data.
  gpt: describes data distribution techniques, consistency, durability issues.
  prompt: What techniques can you use for the data distribution?
  gpt: sharding, replication, partitioning, hashing
  prompt: Can you show me an example of the sharding technique in python?
  gpt: spits out code for hash sharding a dictionary
  prompt: What are some pitfalls of the hash function you used?
  gpt: not guaranteed to unique hash values, not guaranteed to be the same for different python installations, not cryptographically secure
  prompt: Can you implement the stub for a GRPC key value service in rust? The service should have a Put API that takes a key and a value and returns a status code enum. The status code can be SUCCESS or FAILURE.
  gpt: spits out code using tonic
  prompt: Can you show me the protocol buffer?
  gpt: spits out the protocol buffer schema
  prompt: Can you implement the put method by storing the data in sqlite?
  gpt: spits out the code with a kv_pairs table
  prompt: Can you show me the sqlite schema for the table?
  gpt: spits out the sql to create the table

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton