First let's take this sample data:
words = ['simple', 'dimple' , 'pimple','fickle', 'sickle', 'simkle', 'kettle', 'settle'] start_word = 'simple' end_word = 'fickle'
Now let's generate a graph, where each node is the word and an edge represents, the index where the words differ and the character that is different.
Next, using Djiktra's algorithm, just find the shortest path between the start_word and end_word::
Code here(also generates images using graphviz):