Last active
October 10, 2022 14:55
-
-
Save jcblw/9ec839c861aa159669ea5408893cc604 to your computer and use it in GitHub Desktop.
Used for a Medium article
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Create a model for predicting the next word | |
// ^ I wrote this | |
const model = tf.sequential() | |
model.add(tf.layers.lstm({ units: 128, inputShape: [null, 1] })) | |
model.add(tf.layers.dense({ units: 1, activation: 'softmax' })) | |
model.compile({ loss: 'categoricalCrossentropy', optimizer: 'adam' }) | |
// ^ Copilot wrote all this code |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment