Spiking Neural Network encoding and usage Normal Spiking Neural Networks use spikes as a input mostly encoded onto the entire network as a pattern of the embedding The method i propose is the usage of neurons on a timestep for example if you have a input size of 3 then one timestep for input into the network could be [0,0,0] the encoding scheme i propose is based on lets say abcd a = [1,0,0,0] b = [0,1,0,0] c = [0,0,1,0] d = [0,0,0,1] these will be the same for each neuron the patern is how the specific neuron its inputted at will fire for a text 'abcd' since its of length 4 you split it to ['abc','d'] the split could also be transformed into multiple version of the encoding scheme well first encode it into [[n1-timeframe],[n2-timeframe],[n3-timeframe]] making it into [ [1,0,0,0,0,0,0,1], [0,1,0,0], [0,0,1,0] ]; in other words each timestep that passes [[neuron-1,neuron-2,neuron-3]] would be converted into [ [1,0,0] [0,1,0] [0,0,1] [0,0,0] [0,0,0] [0,0,0] [0,0,0] [1,0,0] ] and transformed into the encoding of ['abc','d'] would be [[[1,0,0,0],[0,1,0,0],[0,0,1,0]],[[0,0,0,1]]] this method would work so well since it process multiple tokens (in this case characters) at once instead of one at a time. this allows the model to learn patterns on a global scale instead of a sequential one. you can scale the input to whatever size you choose since emtpy input spots would not need inputs or if you still want the network to get an input ud choose [0,0,0,0] for example there will be a single outputting neuron this neuron needs to fire in a specific pattern (the embedding pattern) to output a character I will now show another example of text ill first define the encoding for each character => a = [1,0,0,0,0,0] b = [0,1,0,0,0,0] c = [1,1,0,0,0,0] d = [0,0,1,0,0,0] e = [1,0,1,0,0,0] f = [0,1,1,0,0,0] g = [1,1,1,0,0,0] h = [0,0,0,1,0,0] i = [1,0,0,1,0,0] j = [0,1,0,1,0,0] k = [1,1,0,1,0,0] l = [0,0,1,1,0,0] m = [1,0,1,1,0,0] n = [0,1,1,1,0,0] o = [1,1,1,1,0,0] p = [0,0,0,0,1,0] q = [1,0,0,0,1,0] r = [0,1,0,0,1,0] s = [1,1,0,0,1,0] t = [0,0,1,0,1,0] u = [1,0,1,0,1,0] v = [0,1,1,0,1,0] w = [1,1,1,0,1,0] x = [0,0,0,1,1,0] y = [1,0,0,1,1,0] z = [0,1,0,1,1,0] . = [1,1,0,1,1,0] ? = [0,0,1,1,1,0] 0 = [1,0,1,1,1,0] 1 = [0,1,1,1,1,0] 2 = [1,1,1,1,1,0] ' ' = [0,0,0,0,0,1] ```text 'hello how are you.' ``` ```split ['hel','lo ','how',' ar','e y','you','.'] ``` ```encoded ```method [[n1-timeframe],[n2-timeframe],[n3-timeframe]] [ [0,0,0,1,0,0, 0,0,1,1,0,0, 0,0,0,1,0,0, 0,0,0,0,0,1, 1,0,1,0,0,0, 1,0,0,1,1,0, 1,1,0,1,1,0], [1,0,1,0,0,0, 1,1,1,1,0,0, 1,1,1,1,0,0, 1,0,0,0,0,0, 0,0,0,0,0,1, 1,1,1,1,0,0], [0,0,1,1,0,0, 0,0,0,0,0,1, 1,1,1,0,1,0, 0,1,0,0,1,0 1,0,0,1,1,0, 1,0,1,0,1,0] ] ``` ```method [neuron-1,neuron-2,neuron-3] [ [0,1,0], [0,0,0], [0,1,1], [1,0,1], [0,0,0], [0,0,0], [0,1,0], [0,1,0], [1,1,0], [1,1,0], [0,0,0], [0,0,1], etc etc ] ``` ``` a better propositon for the encoding scheme would to always use two spikes for a character. so for a it could be [1,1,0] b = [1,0,1] c = [0,1,1] this would solve dead neuron problem and makes it to where one character cannot dominate the pattern the spiking neural network will be learned using dopamine based stdp runaway activity will be handled by replacing 37.35% of the hidden neurons with inhibitory neurons the encoding should be handled based on a inputted string of the vocab for example 'abc' would result in a = [1,0] b = [0,1] c = [1,1] or with the proposed 2 spikes for a character a = [1,1,0] b = [1,0,1] c = [0,1,1] input batch will be defined before (3 in this example) meaning 3 input neurons these neurons will spike the pattern given to them based on the encoding. the encoding length will be programatically determined based on the inputed vocab with the option to change how many spikes per character