How to transform dictionary data into a string vector?

I have key,value data where each record is in a Python string. An example record looks like this:

record = {
'first_name': 'john',
'last_name': 'doe',
'age': '50',
}


To encode this into a neural net, I would like to firs have this data as a string vector. A sample output is like this:

"first_name john last_name doe age 50"


How can I make this transformation?

• Does first_name, last_name, age come in order as you wrote or it can be in any order, like "last_name doe age 50 first_name john"? – Ankit Seth Jul 15 '18 at 13:41
• @AnkitSeth the representation which I wrote is one of the possible views of the record since Python dictionary's key/value pairs are unordered. – Bruno Lubascher Jul 15 '18 at 13:44

>>> string_vector = ''